Skip to content

Commit ddbdf51

Browse files
committed
Remove the vestigial ExtCtxt::print_backtrace function.
It was added in 2011-08-05 and reduced to a no-op ten days later.
1 parent fab3295 commit ddbdf51

File tree

2 files changed

+0
-12
lines changed

2 files changed

+0
-12
lines changed

src/libsyntax/ext/base.rs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -605,7 +605,6 @@ impl<'a> ExtCtxt<'a> {
605605
None => self.bug("missing top span")
606606
})
607607
}
608-
pub fn print_backtrace(&self) { }
609608
pub fn backtrace(&self) -> ExpnId { self.backtrace }
610609
pub fn original_span(&self) -> Span {
611610
let mut expn_id = self.backtrace;
@@ -700,7 +699,6 @@ impl<'a> ExtCtxt<'a> {
700699
/// substitute; we never hit resolve/type-checking so the dummy
701700
/// value doesn't have to match anything)
702701
pub fn span_fatal(&self, sp: Span, msg: &str) -> ! {
703-
self.print_backtrace();
704702
panic!(self.parse_sess.span_diagnostic.span_fatal(sp, msg));
705703
}
706704

@@ -710,35 +708,27 @@ impl<'a> ExtCtxt<'a> {
710708
/// Compilation will be stopped in the near future (at the end of
711709
/// the macro expansion phase).
712710
pub fn span_err(&self, sp: Span, msg: &str) {
713-
self.print_backtrace();
714711
self.parse_sess.span_diagnostic.span_err(sp, msg);
715712
}
716713
pub fn span_warn(&self, sp: Span, msg: &str) {
717-
self.print_backtrace();
718714
self.parse_sess.span_diagnostic.span_warn(sp, msg);
719715
}
720716
pub fn span_unimpl(&self, sp: Span, msg: &str) -> ! {
721-
self.print_backtrace();
722717
self.parse_sess.span_diagnostic.span_unimpl(sp, msg);
723718
}
724719
pub fn span_bug(&self, sp: Span, msg: &str) -> ! {
725-
self.print_backtrace();
726720
self.parse_sess.span_diagnostic.span_bug(sp, msg);
727721
}
728722
pub fn span_note(&self, sp: Span, msg: &str) {
729-
self.print_backtrace();
730723
self.parse_sess.span_diagnostic.span_note(sp, msg);
731724
}
732725
pub fn span_help(&self, sp: Span, msg: &str) {
733-
self.print_backtrace();
734726
self.parse_sess.span_diagnostic.span_help(sp, msg);
735727
}
736728
pub fn fileline_help(&self, sp: Span, msg: &str) {
737-
self.print_backtrace();
738729
self.parse_sess.span_diagnostic.fileline_help(sp, msg);
739730
}
740731
pub fn bug(&self, msg: &str) -> ! {
741-
self.print_backtrace();
742732
self.parse_sess.span_diagnostic.handler().bug(msg);
743733
}
744734
pub fn trace_macros(&self) -> bool {

src/libsyntax/ext/log_syntax.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ pub fn expand_syntax_ext<'cx>(cx: &'cx mut base::ExtCtxt,
2626
return base::DummyResult::any(sp);
2727
}
2828

29-
cx.print_backtrace();
30-
3129
println!("{}", print::pprust::tts_to_string(tts));
3230

3331
// any so that `log_syntax` can be invoked as an expression and item.

0 commit comments

Comments
 (0)