rustc: Rename native_abi_c_stack_cdecl to native_abi_cdecl

This commit is contained in:
Brian Anderson 2011-11-09 15:59:29 -08:00
parent 10c35959e7
commit 1afc943c91
8 changed files with 10 additions and 10 deletions

View File

@ -51,7 +51,7 @@ fn visit_view_item(e: env, i: @ast::view_item) {
fn visit_item(e: env, i: @ast::item) {
alt i.node {
ast::item_native_mod(m) {
if m.abi != ast::native_abi_c_stack_cdecl &&
if m.abi != ast::native_abi_cdecl &&
m.abi != ast::native_abi_stdcall {
ret;
}

View File

@ -260,7 +260,7 @@ fn parse_ty(st: @pstate, sd: str_def) -> ty::t {
let abi;
alt next(st) as char {
'i' { abi = ast::native_abi_rust_intrinsic; }
'C' { abi = ast::native_abi_c_stack_cdecl; }
'C' { abi = ast::native_abi_cdecl; }
'S' { abi = ast::native_abi_stdcall; }
}
let func = parse_ty_fn(st, sd);

View File

@ -143,7 +143,7 @@ fn enc_sty(w: io::writer, cx: @ctxt, st: ty::sty) {
w.write_char('N');
alt abi {
native_abi_rust_intrinsic. { w.write_char('i'); }
native_abi_c_stack_cdecl. { w.write_char('C'); }
native_abi_cdecl. { w.write_char('C'); }
native_abi_stdcall. { w.write_char('S'); }
}
enc_ty_fn(w, cx, args, out, return_val, []);

View File

@ -5597,7 +5597,7 @@ fn native_fn_ty_param_count(cx: @crate_ctxt, id: ast::node_id) -> uint {
pure fn native_abi_requires_pair(abi: ast::native_abi) -> bool {
alt abi {
ast::native_abi_rust_intrinsic. { ret true; }
ast::native_abi_c_stack_cdecl. |
ast::native_abi_cdecl. |
ast::native_abi_stdcall. { ret false; }
}
}
@ -5641,7 +5641,7 @@ fn register_native_fn(ccx: @crate_ctxt, sp: span, path: [str], name: str,
uses_retptr = true;
cast_to_i32 = false;
}
ast::native_abi_c_stack_cdecl. {
ast::native_abi_cdecl. {
let llfn = decl_cdecl_fn(ccx.llmod, name, T_fn([], ccx.int_type));
ccx.item_ids.insert(id, llfn);
ccx.item_symbols.insert(id, name);

View File

@ -552,7 +552,7 @@ mod collect {
some(ast_map::node_item(item)) { tpt = ty_of_item(cx, item); }
some(ast_map::node_native_item(native_item)) {
tpt = ty_of_native_item(cx, native_item,
ast::native_abi_c_stack_cdecl);
ast::native_abi_cdecl);
}
_ { cx.tcx.sess.fatal("internal error " + std::int::str(id.node)); }
}

View File

@ -427,7 +427,7 @@ type _mod = {view_items: [@view_item], items: [@item]};
tag native_abi {
native_abi_rust_intrinsic;
native_abi_c_stack_cdecl;
native_abi_cdecl;
native_abi_stdcall;
}

View File

@ -2003,13 +2003,13 @@ fn parse_native_mod_items(p: parser, native_name: str, abi: ast::native_abi,
fn parse_item_native_mod(p: parser, attrs: [ast::attribute]) -> @ast::item {
let lo = p.get_last_lo_pos();
let abi = ast::native_abi_c_stack_cdecl;
let abi = ast::native_abi_cdecl;
if !is_word(p, "mod") {
let t = parse_str(p);
if str::eq(t, "rust-intrinsic") {
abi = ast::native_abi_rust_intrinsic;
} else if str::eq(t, "c-stack-cdecl") {
abi = ast::native_abi_c_stack_cdecl;
abi = ast::native_abi_cdecl;
} else if str::eq(t, "c-stack-stdcall") {
abi = ast::native_abi_stdcall;
} else {

View File

@ -404,7 +404,7 @@ fn print_item(s: ps, &&item: @ast::item) {
ast::native_abi_rust_intrinsic. {
word_nbsp(s, "\"rust-intrinsic\"");
}
ast::native_abi_c_stack_cdecl. {
ast::native_abi_cdecl. {
word_nbsp(s, "\"c-stack-cdecl\"");
}
ast::native_abi_stdcall. {