Remove ParseSess
methods that duplicate DiagCtxt
methods.
Also add missing `#[track_caller]` attributes to `DiagCtxt` methods as necessary to keep tests working.
This commit is contained in:
parent
ec9af0d6cb
commit
d51db05d7e
22 changed files with 256 additions and 308 deletions
|
@ -1115,7 +1115,7 @@ impl<'a> ExtCtxt<'a> {
|
|||
|
||||
pub fn trace_macros_diag(&mut self) {
|
||||
for (span, notes) in self.expansions.iter() {
|
||||
let mut db = self.sess.parse_sess.create_note(errors::TraceMacro { span: *span });
|
||||
let mut db = self.dcx().create_note(errors::TraceMacro { span: *span });
|
||||
for note in notes {
|
||||
db.note(note.clone());
|
||||
}
|
||||
|
|
|
@ -957,7 +957,7 @@ pub fn ensure_complete_parse<'a>(
|
|||
|
||||
let expands_to_match_arm = kind_name == "pattern" && parser.token == token::FatArrow;
|
||||
|
||||
parser.sess.emit_err(IncompleteParse {
|
||||
parser.dcx().emit_err(IncompleteParse {
|
||||
span: def_site_span,
|
||||
token,
|
||||
label_span: span,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue