-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Couple of global state and driver refactors #114803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
ef2da4a
4a6de8e
980143b
c624738
223c43b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,7 +29,6 @@ use rustc_ast::{Async, AttrArgs, AttrArgsEq, Expr, ExprKind, Mutability, StrLit} | |
use rustc_ast::{HasAttrs, HasTokens, Unsafe, Visibility, VisibilityKind}; | ||
use rustc_ast_pretty::pprust; | ||
use rustc_data_structures::fx::FxHashMap; | ||
use rustc_data_structures::sync::Ordering; | ||
use rustc_errors::PResult; | ||
use rustc_errors::{ | ||
Applicability, DiagnosticBuilder, ErrorGuaranteed, FatalError, IntoDiagnostic, MultiSpan, | ||
|
@@ -1455,18 +1454,6 @@ pub(crate) fn make_unclosed_delims_error( | |
Some(err) | ||
} | ||
|
||
pub fn emit_unclosed_delims(unclosed_delims: &mut Vec<UnmatchedDelim>, sess: &ParseSess) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can we use some check in There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Tidy can't, https://github.com/est31/warnalyzer can, in some cases. But save-analysis was removed so it became harder work. |
||
let _ = sess.reached_eof.fetch_or( | ||
unclosed_delims.iter().any(|unmatched_delim| unmatched_delim.found_delim.is_none()), | ||
Ordering::Relaxed, | ||
); | ||
for unmatched in unclosed_delims.drain(..) { | ||
if let Some(mut e) = make_unclosed_delims_error(unmatched, sess) { | ||
e.emit(); | ||
} | ||
} | ||
} | ||
|
||
/// A helper struct used when building an `AttrTokenStream` from | ||
/// a `LazyAttrTokenStream`. Both delimiter and non-delimited tokens | ||
/// are stored as `FlatToken::Token`. A vector of `FlatToken`s | ||
|
Uh oh!
There was an error while loading. Please reload this page.