Skip to content
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

Make trait_methods_not_found use a lock #59809

Merged
merged 1 commit into from
Apr 12, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/librustc/session/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ pub struct Session {
pub driver_lint_caps: FxHashMap<lint::LintId, lint::Level>,

/// `Span`s of trait methods that weren't found to avoid emitting object safety errors
pub trait_methods_not_found: OneThread<RefCell<FxHashSet<Span>>>,
pub trait_methods_not_found: Lock<FxHashSet<Span>>,
}

pub struct PerfStats {
Expand Down Expand Up @@ -1236,7 +1236,7 @@ fn build_session_(
has_global_allocator: Once::new(),
has_panic_handler: Once::new(),
driver_lint_caps,
trait_methods_not_found: OneThread::new(RefCell::new(Default::default())),
trait_methods_not_found: Lock::new(Default::default()),
};

validate_commandline_args_with_session_available(&sess);
Expand Down