summaryrefslogtreecommitdiff
path: root/src/hir/from_ast.cpp
diff options
context:
space:
mode:
authorJohn Hodge <tpg@mutabah.net>2016-09-27 15:58:17 +0800
committerJohn Hodge <tpg@mutabah.net>2016-09-27 15:58:17 +0800
commit7ecb789e0c19e636652866ba08328ba413afe302 (patch)
tree6c206108cf9029faa9b2354210d1048fdd1aabf0 /src/hir/from_ast.cpp
parent5fbfd267b54e243ebe2ad3820d75359d7ed95988 (diff)
downloadmrust-7ecb789e0c19e636652866ba08328ba413afe302.tar.gz
AST - Stub out extern and impl blocks as Item-s
Diffstat (limited to 'src/hir/from_ast.cpp')
-rw-r--r--src/hir/from_ast.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/hir/from_ast.cpp b/src/hir/from_ast.cpp
index 46e9afa1..9667aa70 100644
--- a/src/hir/from_ast.cpp
+++ b/src/hir/from_ast.cpp
@@ -1029,12 +1029,22 @@ void _add_mod_val_item(::HIR::Module& mod, ::std::string name, bool is_pub, ::H
for( const auto& item : ast_mod.items() )
{
+ const auto& sp = item.data.span;
auto item_path = ::HIR::ItemPath(path, item.name.c_str());
TU_MATCH(::AST::Item, (item.data), (e),
(None,
),
(MacroInv,
- BUG(Span(), "Stray macro invocation in " << path);
+ BUG(sp, "Stray macro invocation in " << path);
+ ),
+ (ExternBlock,
+ TODO(sp, "Expand ExternBlock");
+ ),
+ (Impl,
+ TODO(sp, "Expand Item::Impl");
+ ),
+ (NegImpl,
+ TODO(sp, "Expand Item::NegImpl");
),
(Use,
// Ignore - The index is used to add `Import`s