summaryrefslogtreecommitdiff
path: root/src/ast/ast.cpp
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2016-03-20 12:29:44 +0800
committerJohn Hodge <tpg@mutabah.net>2016-03-20 12:29:44 +0800
commitb79e71e5f11e14516f13ea2f8437d5deaa10e653 (patch)
tree3097c0251c83e32e4e673a840f5708110a8adc4c /src/ast/ast.cpp
parent0ee80748a3dcb97f308e9b0b71c22d28868d12cf (diff)
downloadmrust-b79e71e5f11e14516f13ea2f8437d5deaa10e653.tar.gz
Tagged Union - Rework to remove indirection
Diffstat (limited to 'src/ast/ast.cpp')
-rw-r--r--src/ast/ast.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ast/ast.cpp b/src/ast/ast.cpp
index 16fad76e..72b4455c 100644
--- a/src/ast/ast.cpp
+++ b/src/ast/ast.cpp
@@ -320,7 +320,7 @@ void Module::iterate_functions(fcn_visitor_t *visitor, const Crate& crate)
TU_MATCH_DEF(::AST::Item, (item.data), (e),
( ),
(Function,
- visitor(crate, *this, e.e);
+ visitor(crate, *this, e);
)
)
}
@@ -346,21 +346,21 @@ Module::ItemRef Module::find_item(const ::std::string& needle, bool allow_leaves
(None,
break;
),
- (Module, return ItemRef(e.e); ),
+ (Module, return ItemRef(e); ),
(Crate, return ItemRef(e.name); ),
- (Type, return ItemRef(e.e); ),
- (Struct, return ItemRef(e.e); ),
- (Enum, return ItemRef(e.e); ),
- (Trait, return ItemRef(e.e); ),
+ (Type, return ItemRef(e); ),
+ (Struct, return ItemRef(e); ),
+ (Enum, return ItemRef(e); ),
+ (Trait, return ItemRef(e); ),
(Function,
if( allow_leaves )
- return ItemRef(e.e);
+ return ItemRef(e);
else
DEBUG("Skipping function, leaves not allowed");
),
(Static,
if( allow_leaves )
- return ItemRef(e.e);
+ return ItemRef(e);
else
DEBUG("Skipping function, leaves not allowed");
)