diff options
| author | Rafael Avila de Espindola <espindola@dream.(none)> | 2011-02-16 14:02:02 -0500 |
|---|---|---|
| committer | Rafael Avila de Espindola <espindola@dream.(none)> | 2011-02-16 14:02:02 -0500 |
| commit | 012fa69ea500aa31cb3dd2cd3df67ecd3eefd44e (patch) | |
| tree | 565b715c332f4eaa83460e37c542ff914be77854 /src/comp/front | |
| parent | d4bf67dde638fdeea4361daf16bee421d479628e (diff) | |
| download | rust-012fa69ea500aa31cb3dd2cd3df67ecd3eefd44e.tar.gz rust-012fa69ea500aa31cb3dd2cd3df67ecd3eefd44e.zip | |
More typechecking for native types and the needed plumbing in codegen.
Diffstat (limited to 'src/comp/front')
| -rw-r--r-- | src/comp/front/ast.rs | 4 | ||||
| -rw-r--r-- | src/comp/front/parser.rs | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/comp/front/ast.rs b/src/comp/front/ast.rs index 03ccc216e2e..ee358432ff1 100644 --- a/src/comp/front/ast.rs +++ b/src/comp/front/ast.rs @@ -263,7 +263,7 @@ tag item_ { type native_item = spanned[native_item_]; tag native_item_ { native_item_ty(ident, def_id); - native_item_fn(ident, fn_decl, vec[ty_param], def_id); + native_item_fn(ident, fn_decl, vec[ty_param], def_id, ann); } fn index_view_item(mod_index index, @view_item it) { @@ -314,7 +314,7 @@ fn index_native_item(native_mod_index index, @native_item it) { case (ast.native_item_ty(?id, _)) { index.insert(id, it); } - case (ast.native_item_fn(?id, _, _, _)) { + case (ast.native_item_fn(?id, _, _, _, _)) { index.insert(id, it); } } diff --git a/src/comp/front/parser.rs b/src/comp/front/parser.rs index 8acc8897254..a108d2431e3 100644 --- a/src/comp/front/parser.rs +++ b/src/comp/front/parser.rs @@ -1693,7 +1693,8 @@ impure fn parse_item_native_fn(parser p, ast.effect eff) -> @ast.native_item { auto decl = parse_fn_decl(p, eff); auto hi = p.get_span(); expect(p, token.SEMI); - auto item = ast.native_item_fn(t._1, decl, t._2, p.next_def_id()); + auto item = ast.native_item_fn(t._1, decl, t._2, p.next_def_id(), + ast.ann_none); ret @spanned(t._0, hi, item); } |
