diff options
author | John Hodge <tpg@mutabah.net> | 2016-12-31 19:45:55 +0800 |
---|---|---|
committer | John Hodge <tpg@mutabah.net> | 2016-12-31 19:45:55 +0800 |
commit | dce12144273c307d858017c76fabbc574db4337e (patch) | |
tree | 61a32386e87674b8b5e1ba141b2503f748d4da8a /src/mir/mir.hpp | |
parent | 936db1595619a25fb4a7ccf902e9e8af5852484e (diff) | |
download | mrust-dce12144273c307d858017c76fabbc574db4337e.tar.gz |
MIR Optimise - Structure for rvalue replacements
Diffstat (limited to 'src/mir/mir.hpp')
-rw-r--r-- | src/mir/mir.hpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mir/mir.hpp b/src/mir/mir.hpp index cacaea99..fb69c7d9 100644 --- a/src/mir/mir.hpp +++ b/src/mir/mir.hpp @@ -102,7 +102,7 @@ TAGGED_UNION(Constant, Int, ); extern ::std::ostream& operator<<(::std::ostream& os, const Constant& v); -TAGGED_UNION(RValue, Use, +TAGGED_UNION_EX(RValue, (), Use, ( (Use, LValue), (Constant, Constant), (SizedArray, struct { @@ -163,6 +163,9 @@ TAGGED_UNION(RValue, Use, unsigned int variant_idx; // if ~0, it's a struct ::std::vector<LValue> vals; }) + ), (),(), ( + RValue clone() const; + ) ); extern ::std::ostream& operator<<(::std::ostream& os, const RValue& x); |