Skip to content

Commit

Permalink
Use $crate in core::panic!
Browse files Browse the repository at this point in the history
  • Loading branch information
chris-morgan committed Jul 29, 2015
1 parent 523ee8d commit fc5b79c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/libcore/macros.rs
Expand Up @@ -17,15 +17,15 @@ macro_rules! panic {
);
($msg:expr) => ({
static _MSG_FILE_LINE: (&'static str, &'static str, u32) = ($msg, file!(), line!());
::core::panicking::panic(&_MSG_FILE_LINE)
$crate::panicking::panic(&_MSG_FILE_LINE)
});
($fmt:expr, $($arg:tt)*) => ({
// The leading _'s are to avoid dead code warnings if this is
// used inside a dead function. Just `#[allow(dead_code)]` is
// insufficient, since the user may have
// `#[forbid(dead_code)]` and which cannot be overridden.
static _FILE_LINE: (&'static str, u32) = (file!(), line!());
::core::panicking::panic_fmt(format_args!($fmt, $($arg)*), &_FILE_LINE)
$crate::panicking::panic_fmt(format_args!($fmt, $($arg)*), &_FILE_LINE)
});
}

Expand Down

0 comments on commit fc5b79c

Please sign in to comment.