diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2011-03-02 18:36:03 -0800 |
|---|---|---|
| committer | Patrick Walton <pcwalton@mimiga.net> | 2011-03-02 18:36:03 -0800 |
| commit | 7ab58db4d02443fdfd68e135224a79fe3a212bda (patch) | |
| tree | 8e8c174b6511b5713c21db2de37850fc48bf4849 /src/comp | |
| parent | 675f762621a0e2bb7d746e82bcafa05650786b94 (diff) | |
| download | rust-7ab58db4d02443fdfd68e135224a79fe3a212bda.tar.gz rust-7ab58db4d02443fdfd68e135224a79fe3a212bda.zip | |
rustc: Use llsize_of rather than size_of in trans_malloc_without_cleanup(). Should put out burning tinderbox...
Diffstat (limited to 'src/comp')
| -rw-r--r-- | src/comp/middle/trans.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/comp/middle/trans.rs b/src/comp/middle/trans.rs index 3d4f44eaf3e..4d1bfde75e1 100644 --- a/src/comp/middle/trans.rs +++ b/src/comp/middle/trans.rs @@ -1071,8 +1071,8 @@ fn trans_raw_malloc(@block_ctxt cx, TypeRef llptr_ty, ValueRef llsize) fn trans_malloc_without_cleanup(@block_ctxt cx, @ty.t t) -> result { auto llty = type_of(cx.fcx.ccx, t); - auto rslt = size_of(cx, t); - ret trans_raw_malloc(rslt.bcx, llty, rslt.val); + auto llsize = llsize_of(llvm.LLVMGetElementType(llty)); + ret trans_raw_malloc(cx, llty, llsize); } fn trans_malloc(@block_ctxt cx, @ty.t t) -> result { |
