diff options
| author | Brian Anderson <banderson@mozilla.com> | 2014-07-24 21:33:46 -0700 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2014-07-25 00:02:29 -0700 |
| commit | 4636b32a42ea3111f53048197092e7ac08e6f792 (patch) | |
| tree | 3801e7d70873d01f567f3eda119cc12c3a59cb5a /src/libstd | |
| parent | b9035c26e2c4368b39c8daa979f669d10d484825 (diff) | |
| download | rust-4636b32a42ea3111f53048197092e7ac08e6f792.tar.gz rust-4636b32a42ea3111f53048197092e7ac08e6f792.zip | |
Make most of the failure functions take &(&'static str, uint)
Passing one pointer takes less code than one pointer and an integer.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/macros.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstd/macros.rs b/src/libstd/macros.rs index 3c6c860f516..fd0c72ce313 100644 --- a/src/libstd/macros.rs +++ b/src/libstd/macros.rs @@ -39,7 +39,7 @@ #[macro_export] macro_rules! fail( () => ( - ::std::rt::begin_unwind_no_time_to_explain(file!(), line!()) + ::std::rt::begin_unwind_no_time_to_explain(&(file!(), line!())) ); ($msg:expr) => ( ::std::rt::begin_unwind($msg, file!(), line!()) @@ -58,7 +58,7 @@ macro_rules! fail( // up with the number of calls to fail!() #[inline(always)] fn run_fmt(fmt: &::std::fmt::Arguments) -> ! { - ::std::rt::begin_unwind_fmt(fmt, file!(), line!()) + ::std::rt::begin_unwind_fmt(fmt, &(file!(), line!())) } format_args!(run_fmt, $fmt, $($arg)*) }); |
