File tree Expand file tree Collapse file tree 2 files changed +39
-0
lines changed
src/test/run-make/fmt-write-bloat Expand file tree Collapse file tree 2 files changed +39
-0
lines changed Original file line number Diff line number Diff line change 1+ -include ../../run-make-fulldeps/tools.mk
2+
3+ NM =nm
4+
5+ all : main.rs
6+ $(RUSTC ) $< -O
7+ $(NM ) $(call RUN_BINFILE,main) | $(CGREP ) -v panicking panic_fmt panic_bounds_check pad_integral Display Debug
Original file line number Diff line number Diff line change 1+ #![ feature( lang_items) ]
2+ #![ feature( start) ]
3+ #![ no_std]
4+
5+ use core:: fmt;
6+ use core:: fmt:: Write ;
7+
8+ #[ link( name = "c" ) ]
9+ extern "C" { }
10+
11+ struct Dummy ;
12+
13+ impl fmt:: Write for Dummy {
14+ #[ inline( never) ]
15+ fn write_str ( & mut self , _: & str ) -> fmt:: Result {
16+ Ok ( ( ) )
17+ }
18+ }
19+
20+ #[ start]
21+ fn main ( _: isize , _: * const * const u8 ) -> isize {
22+ let _ = writeln ! ( Dummy , "Hello World" ) ;
23+ 0
24+ }
25+
26+ #[ lang = "eh_personality" ]
27+ fn eh_personality ( ) { }
28+
29+ #[ panic_handler]
30+ fn panic ( _: & core:: panic:: PanicInfo ) -> ! {
31+ loop { }
32+ }
You can’t perform that action at this time.
0 commit comments