about summary refs log tree commit diff
path: root/src/comp
diff options
context:
space:
mode:
authorNiko Matsakis <niko@alum.mit.edu>2012-02-03 13:59:15 -0800
committerNiko Matsakis <niko@alum.mit.edu>2012-02-10 20:48:28 -0800
commitefd393d6137b06715dbd3a3e18bfd7ae4bd9bb6b (patch)
treed41e395c2a259dc58c93a2891836ffa18ec3692a /src/comp
parent9fde2a54f47a84f34add6994c6c90100d83247fb (diff)
downloadrust-efd393d6137b06715dbd3a3e18bfd7ae4bd9bb6b.tar.gz
rust-efd393d6137b06715dbd3a3e18bfd7ae4bd9bb6b.zip
Remove dead code
Diffstat (limited to 'src/comp')
-rw-r--r--src/comp/middle/trans/base.rs37
1 files changed, 0 insertions, 37 deletions
diff --git a/src/comp/middle/trans/base.rs b/src/comp/middle/trans/base.rs
index b4ee740b56e..f5eebd3bb88 100644
--- a/src/comp/middle/trans/base.rs
+++ b/src/comp/middle/trans/base.rs
@@ -4826,43 +4826,6 @@ fn fill_fn_pair(bcx: @block_ctxt, pair: ValueRef, llfn: ValueRef,
     Store(bcx, llenvblobptr, env_cell);
 }
 
-// Returns the number of type parameters that the given native function has.
-fn native_fn_ty_param_count(cx: @crate_ctxt, id: ast::node_id) -> uint {
-    let count;
-    let native_item =
-        // invariant?!
-        alt cx.ast_map.find(id) {
-          some(ast_map::node_native_item(i, _)) { i }
-         _ { cx.sess.bug("native_fn_ty_param_count \
-                          given a non-native item"); } };
-    alt native_item.node {
-      ast::native_item_fn(_, tps) {
-        count = vec::len::<ast::ty_param>(tps);
-      }
-    }
-    ret count;
-}
-
-
-// TODO: precondition
-fn native_fn_wrapper_type(cx: @crate_ctxt, sp: span,
-                          param_bounds: [ty::param_bounds],
-                          x: ty::t) -> TypeRef {
-    alt ty::get(x).struct {
-      ty::ty_fn({inputs: args, output: out, _}) {
-        ret type_of_fn(cx, args, out, param_bounds);
-      }
-      _ { cx.sess.span_bug(sp, "native_fn_wrapper_type got ill-typed\
-              thing"); }
-    }
-}
-
-fn raw_native_fn_type(ccx: @crate_ctxt, args: [ty::arg],
-                      ret_ty: ty::t) -> TypeRef {
-    check type_has_static_size(ccx, ret_ty);
-    ret T_fn(type_of_explicit_args(ccx, args), type_of(ccx, ret_ty));
-}
-
 fn link_name(i: @ast::native_item) -> str {
     alt attr::get_meta_item_value_str_by_name(i.attrs, "link_name") {
       none { ret i.ident; }