diff options
author | chriseth <c@ethdev.com> | 2016-04-18 19:47:40 +0800 |
---|---|---|
committer | chriseth <c@ethdev.com> | 2016-04-20 00:35:21 +0800 |
commit | ed9da5171b84e6e1846820a45d97e5c041d57206 (patch) | |
tree | fd74dd485ded436d3b170be627087857396ea65d /libevmasm/SourceLocation.h | |
parent | 81ae2a78321fddcd2d32efc51568ebeca28866a8 (diff) | |
download | dexon-solidity-ed9da5171b84e6e1846820a45d97e5c041d57206.tar.gz dexon-solidity-ed9da5171b84e6e1846820a45d97e5c041d57206.tar.zst dexon-solidity-ed9da5171b84e6e1846820a45d97e5c041d57206.zip |
Source location for inline assembly.
Diffstat (limited to 'libevmasm/SourceLocation.h')
-rw-r--r-- | libevmasm/SourceLocation.h | 23 |
1 files changed, 5 insertions, 18 deletions
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<std::string const> _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); } |