From ed9da5171b84e6e1846820a45d97e5c041d57206 Mon Sep 17 00:00:00 2001 From: chriseth Date: Mon, 18 Apr 2016 13:47:40 +0200 Subject: Source location for inline assembly. --- libevmasm/SourceLocation.h | 23 +++++------------------ 1 file changed, 5 insertions(+), 18 deletions(-) (limited to 'libevmasm/SourceLocation.h') diff --git a/libevmasm/SourceLocation.h b/libevmasm/SourceLocation.h index b8b57b60..54f86450 100644 --- a/libevmasm/SourceLocation.h +++ b/libevmasm/SourceLocation.h @@ -36,26 +36,13 @@ namespace dev */ struct SourceLocation { + SourceLocation(): start(-1), end(-1) { } SourceLocation(int _start, int _end, std::shared_ptr _sourceName): start(_start), end(_end), sourceName(_sourceName) { } - SourceLocation(): start(-1), end(-1) { } - - SourceLocation(SourceLocation const& _other): - start(_other.start), - end(_other.end), - sourceName(_other.sourceName) - {} - - SourceLocation& operator=(SourceLocation const& _other) - { - if (&_other == this) - return *this; - - start = _other.start; - end = _other.end; - sourceName = _other.sourceName; - return *this; - } + SourceLocation(SourceLocation&&) = default; + SourceLocation(SourceLocation const& _other) = default; + SourceLocation& operator=(SourceLocation const&) = default; + SourceLocation& operator=(SourceLocation&&) = default; bool operator==(SourceLocation const& _other) const { return start == _other.start && end == _other.end;} bool operator!=(SourceLocation const& _other) const { return !operator==(_other); } -- cgit