[struct] Lifetime: 48
[struct] Path: 104
[struct] def_id: 16
[struct] TyParam: 32
[struct] Generics: 16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%struct.Foo = type { i64 } | |
define void @_ZN14__extensions__9meth_29568finalize16_d7d397690bb61803_00E({ i64, %tydesc*, i8*, i8*, i8 }*) #1 { | |
static_allocas: | |
br label %1 | |
; <label>:1 ; preds = %static_allocas | |
br label %return | |
return: ; preds = %1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[allow(default_methods)]; | |
pub enum ParseResult<T> { | |
Err(ParseError), | |
Ok(T) | |
} | |
pub trait GenParser<T,S,A> { | |
pub fn parse<Tok:TokenStream<T>>(&mut self, &mut ParseState<Tok, S>) -> ParseResult<A>; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
; Function Attrs: uwtable | |
define internal fastcc void @_ZN4main16_d7d397690bb61803_00E() #1 { | |
static_allocas: | |
%tmp.i = alloca { i64, %tydesc*, {}*, {}*, { i64* } }, align 8 | |
%tmp5 = alloca i64, align 8 | |
%tmp13 = bitcast i64* %tmp5 to i8* | |
call void @llvm.lifetime.start(i64 8, i8* %tmp13) | |
store i64 543210, i64* %tmp5, align 8 | |
%0 = bitcast { i64, %tydesc*, {}*, {}*, { i64* } }* %tmp.i to i8* | |
call void @llvm.lifetime.start(i64 40, i8* %0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
enum opaque {} | |
trait thing { | |
pub fn foo(&self); | |
} | |
impl thing for opaque { | |
pub fn foo(&self) { | |
unsafe { | |
let o : *[int,..8] = std::cast::transmute(self); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[allow(default_methods)]; | |
extern mod syntax; | |
use std::os; | |
use syntax::abi::AbiSet; | |
use syntax::codemap::span; | |
use syntax::parse; | |
use syntax::opt_vec; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
execve("./test", ["./test"], [/* 54 vars */]) = 0 | |
brk(0) = 0x6f8000 | |
readlink("/proc/self/exe", "/home/james/tmp/test", 4096) = 20 | |
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fb03fd5d000 | |
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) | |
open("/home/james/tmp/../../../usr/local/lib/rustc/x86_64-unknown-linux-gnu/lib/tls/x86_64/librt.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) | |
stat("/home/james/tmp/../../../usr/local/lib/rustc/x86_64-unknown-linux-gnu/lib/tls/x86_64", 0x7fff360cf100) = -1 ENOENT (No such file or directory) | |
open("/home/james/tmp/../../../usr/local/lib/rustc/x86_64-unknown-linux-gnu/lib/tls/librt.so.1", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory) | |
stat("/home/james/tmp/../../../usr/local/lib/rustc/x86_64-unknown-linux-gnu/lib/tls", 0x7fff360cf100) = -1 ENOENT (No such file or directory) | |
open("/home/james/tmp/../../../usr/local/lib/rustc/x86_64-unknown-linux-gnu/lib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[allow(default_methods)]; | |
trait Foo { | |
pub fn visit_crate(&mut self) { | |
self.visit_mod([1,2,3]) | |
} | |
pub fn visit_mod(&mut self, a: &[uint]) { | |
for a.iter().advance |i| { | |
self.visit_item(i); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_ZN7rt_exit17_96fb77fd6c6361db3_00E: | |
.cfi_startproc | |
cmpq %fs:112, %rsp | |
ja .LBB5_2 | |
movabsq $8, %r10 | |
movabsq $0, %r11 | |
callq __morestack | |
ret | |
.LBB5_2: | |
pushq %rbp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extern mod std; | |
extern mod syntax; | |
use syntax::ast::*; | |
use std::sys::size_of; | |
macro_rules! type_size ( | |
(S $t:ident) => (print_type_size::<$t>("struct", stringify!($t))); | |
(E $t:ident) => (print_type_size::<$t>("enum", stringify!($t))) | |
) |