| #![feature(no_core)] | |
| #![no_core] | |
| #![feature(rustc_attrs, lang_items)] | |
| #[rustc_builtin_macro] | |
| macro_rules! format_args { | |
| () => {}; | |
| } | |
| #[lang = "sized"] | |
| trait Sized {} | |
| pub mod fmt { | |
| pub struct Formatter; | |
| pub struct Result; | |
| pub struct Arguments<'a>; | |
| impl<'a> Arguments<'a> { | |
| pub fn new_v1(_: &'a [&'static str], _: &'a [ArgumentV1<'a>]) -> Arguments<'a> { | |
| Arguments | |
| } | |
| } | |
| pub struct ArgumentV1<'a>; | |
| impl<'a> ArgumentV1<'a> { | |
| pub fn new<'b, T>(_: &'b T, _: fn(&T, &mut Formatter) -> Result) -> ArgumentV1 { | |
| ArgumentV1 | |
| } | |
| } | |
| pub trait Display { | |
| fn fmt(&self, _: &mut Formatter) -> Result; | |
| } | |
| impl Display for i32 { | |
| fn fmt(&self, _: &mut Formatter) -> Result { | |
| Result | |
| } | |
| } | |
| } | |
| fn main() { | |
| let _formatted = format_args!("hello {}", 15); | |
| } |