Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
drahnr committed Jul 20, 2023
1 parent 881b57a commit 5b0b922
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
7 changes: 1 addition & 6 deletions compiler/rustc_expand/src/proc_macro_server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,6 @@ use rustc_span::symbol::{self, sym, Symbol};
use rustc_span::{BytePos, FileName, Pos, SourceFile, Span};
use smallvec::{smallvec, SmallVec};
use std::ops::{Bound, Range};
use std::{path, ascii, panic};
use pm::bridge::{
server, DelimSpan, ExpnGlobals, Group, Ident, LitKind, Literal, Punct, TokenTree,
};
use pm::{Delimiter, Level, LineColumn};

trait FromInternal<T> {
fn from_internal(x: T) -> Self;
Expand Down Expand Up @@ -408,7 +403,7 @@ impl server::FreeFunctions for Rustc<'_, '_> {
}

fn track_fs_path(&mut self, path: &str) {
self.sess().file_depinfo.borrow_mut().insert(path::PathBuf::from(path));
self.sess().file_depinfo.borrow_mut().insert(Symbol::intern(path));
}

fn literal_from_str(&mut self, s: &str) -> Result<Literal<Self::Span, Self::Symbol>, ()> {
Expand Down
5 changes: 1 addition & 4 deletions compiler/rustc_session/src/parse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ use rustc_span::source_map::{FilePathMapping, SourceMap};
use rustc_span::{Span, Symbol};

use rustc_ast::attr::AttrIdGenerator;
use std::path;
use std::str;

/// The set of keys (and, optionally, values) that define the compilation
Expand Down Expand Up @@ -210,9 +209,7 @@ pub struct ParseSess {
/// Environment variables accessed during the build and their values when they exist.
pub env_depinfo: Lock<FxHashSet<(Symbol, Option<Symbol>)>>,
/// File paths accessed during the build.
pub file_depinfo: Lock<FxHashSet<path::PathBuf>>,
/// All the type ascriptions expressions that have had a suggestion for likely path typo.
pub type_ascription_path_suggestions: Lock<FxHashSet<Span>>,
pub file_depinfo: Lock<FxHashSet<Symbol>>,
/// Whether cfg(version) should treat the current release as incomplete
pub assume_incomplete_release: bool,
/// Spans passed to `proc_macro::quote_span`. Each span has a numerical
Expand Down

0 comments on commit 5b0b922

Please sign in to comment.