Skip to content
Permalink
Browse files

Rename `libsyntax_ext` and `libsyntax_expand` in code

  • Loading branch information
petrochenkov committed Dec 29, 2019
1 parent b9a9c5b commit a2823e3af6fd8bce53419e9945b7f7c63b267789
Showing with 69 additions and 72 deletions.
  1. +1 −1 src/librustc_builtin_macros/Cargo.toml
  2. +1 −1 src/librustc_builtin_macros/asm.rs
  3. +1 −1 src/librustc_builtin_macros/assert.rs
  4. +1 −1 src/librustc_builtin_macros/cfg.rs
  5. +1 −1 src/librustc_builtin_macros/cmdline_attrs.rs
  6. +1 −1 src/librustc_builtin_macros/compile_error.rs
  7. +1 −1 src/librustc_builtin_macros/concat.rs
  8. +1 −1 src/librustc_builtin_macros/concat_idents.rs
  9. +1 −1 src/librustc_builtin_macros/deriving/bounds.rs
  10. +1 −1 src/librustc_builtin_macros/deriving/clone.rs
  11. +1 −1 src/librustc_builtin_macros/deriving/cmp/eq.rs
  12. +1 −1 src/librustc_builtin_macros/deriving/cmp/ord.rs
  13. +1 −1 src/librustc_builtin_macros/deriving/cmp/partial_eq.rs
  14. +1 −1 src/librustc_builtin_macros/deriving/cmp/partial_ord.rs
  15. +1 −1 src/librustc_builtin_macros/deriving/debug.rs
  16. +1 −1 src/librustc_builtin_macros/deriving/decodable.rs
  17. +1 −1 src/librustc_builtin_macros/deriving/default.rs
  18. +1 −1 src/librustc_builtin_macros/deriving/encodable.rs
  19. +1 −1 src/librustc_builtin_macros/deriving/generic/mod.rs
  20. +1 −1 src/librustc_builtin_macros/deriving/generic/ty.rs
  21. +1 −1 src/librustc_builtin_macros/deriving/hash.rs
  22. +1 −1 src/librustc_builtin_macros/deriving/mod.rs
  23. +1 −1 src/librustc_builtin_macros/env.rs
  24. +1 −1 src/librustc_builtin_macros/format.rs
  25. +1 −1 src/librustc_builtin_macros/global_allocator.rs
  26. +1 −1 src/librustc_builtin_macros/global_asm.rs
  27. +2 −2 src/librustc_builtin_macros/lib.rs
  28. +1 −1 src/librustc_builtin_macros/log_syntax.rs
  29. +2 −2 src/librustc_builtin_macros/proc_macro_harness.rs
  30. +2 −2 src/librustc_builtin_macros/source_util.rs
  31. +2 −2 src/librustc_builtin_macros/standard_library_imports.rs
  32. +1 −1 src/librustc_builtin_macros/test.rs
  33. +2 −2 src/librustc_builtin_macros/test_harness.rs
  34. +1 −1 src/librustc_builtin_macros/trace_macros.rs
  35. +1 −1 src/librustc_builtin_macros/util.rs
  36. +1 −1 src/librustc_codegen_llvm/Cargo.toml
  37. +2 −2 src/librustc_interface/Cargo.toml
  38. +10 −10 src/librustc_interface/passes.rs
  39. +1 −1 src/librustc_metadata/Cargo.toml
  40. +1 −1 src/librustc_metadata/creader.rs
  41. +2 −2 src/librustc_metadata/rmeta/decoder.rs
  42. +1 −1 src/librustc_parse/config.rs
  43. +1 −1 src/librustc_resolve/Cargo.toml
  44. +2 −2 src/librustc_resolve/build_reduced_graph.rs
  45. +1 −1 src/librustc_resolve/def_collector.rs
  46. +1 −1 src/librustc_resolve/lib.rs
  47. +4 −4 src/librustc_resolve/macros.rs
  48. +1 −1 src/librustdoc/lib.rs
  49. +1 −1 src/librustdoc/passes/collect_intra_doc_links.rs
  50. +0 −1 src/test/ui-fulldeps/auxiliary/macro-crate-test.rs
  51. +0 −1 src/test/ui-fulldeps/mod_dir_path_canonicalized.rs
  52. +0 −1 src/test/ui-fulldeps/pprust-expr-roundtrip.rs
@@ -19,6 +19,6 @@ rustc_parse = { path = "../librustc_parse" }
rustc_target = { path = "../librustc_target" }
smallvec = { version = "1.0", features = ["union", "may_dangle"] }
syntax = { path = "../libsyntax" }
syntax_expand = { path = "../librustc_expand", package = "rustc_expand" }
rustc_expand = { path = "../librustc_expand" }
syntax_pos = { path = "../librustc_span", package = "rustc_span" }
rustc_error_codes = { path = "../librustc_error_codes" }
@@ -3,14 +3,14 @@
use State::*;

use errors::{DiagnosticBuilder, PResult};
use rustc_expand::base::*;
use rustc_parse::parser::Parser;
use syntax::ast::{self, AsmDialect};
use syntax::ptr::P;
use syntax::symbol::{kw, sym, Symbol};
use syntax::token::{self, Token};
use syntax::tokenstream::{self, TokenStream};
use syntax::{span_err, struct_span_err};
use syntax_expand::base::*;
use syntax_pos::Span;

use rustc_error_codes::*;
@@ -1,13 +1,13 @@
use errors::{Applicability, DiagnosticBuilder};

use rustc_expand::base::*;
use rustc_parse::parser::Parser;
use syntax::ast::{self, *};
use syntax::print::pprust;
use syntax::ptr::P;
use syntax::symbol::{sym, Symbol};
use syntax::token::{self, TokenKind};
use syntax::tokenstream::{DelimSpan, TokenStream, TokenTree};
use syntax_expand::base::*;
use syntax_pos::{Span, DUMMY_SP};

pub fn expand_assert<'cx>(
@@ -3,11 +3,11 @@
/// current compilation environment.
use errors::DiagnosticBuilder;

use rustc_expand::base::{self, *};
use syntax::ast;
use syntax::attr;
use syntax::token;
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_pos::Span;

pub fn expand_cfg(
@@ -1,10 +1,10 @@
//! Attributes injected into the crate root from command line using `-Z crate-attr`.

use rustc_expand::panictry;
use syntax::ast::{self, AttrItem, AttrStyle};
use syntax::attr::mk_attr;
use syntax::sess::ParseSess;
use syntax::token;
use syntax_expand::panictry;
use syntax_pos::FileName;

pub fn inject(mut krate: ast::Crate, parse_sess: &ParseSess, attrs: &[String]) -> ast::Crate {
@@ -1,7 +1,7 @@
// The compiler code necessary to support the compile_error! extension.

use rustc_expand::base::{self, *};
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_pos::Span;

pub fn expand_compile_error<'cx>(
@@ -1,7 +1,7 @@
use rustc_expand::base::{self, DummyResult};
use syntax::ast;
use syntax::symbol::Symbol;
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, DummyResult};

use std::string::String;

@@ -1,8 +1,8 @@
use rustc_expand::base::{self, *};
use syntax::ast;
use syntax::ptr::P;
use syntax::token::{self, Token};
use syntax::tokenstream::{TokenStream, TokenTree};
use syntax_expand::base::{self, *};
use syntax_pos::symbol::Symbol;
use syntax_pos::Span;

@@ -2,8 +2,8 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::MetaItem;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_copy(
@@ -2,10 +2,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, Expr, GenericArg, Generics, ItemKind, MetaItem, VariantData};
use syntax::ptr::P;
use syntax::symbol::{kw, sym, Symbol};
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_clone(
@@ -2,10 +2,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, Expr, GenericArg, Ident, MetaItem};
use syntax::ptr::P;
use syntax::symbol::{sym, Symbol};
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_eq(
@@ -2,10 +2,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, Expr, MetaItem};
use syntax::ptr::P;
use syntax::symbol::sym;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_ord(
@@ -2,10 +2,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::{path_local, path_std};

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{BinOpKind, Expr, MetaItem};
use syntax::ptr::P;
use syntax::symbol::sym;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_partial_eq(
@@ -4,10 +4,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::{path_local, path_std, pathvec_std};

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, BinOpKind, Expr, MetaItem};
use syntax::ptr::P;
use syntax::symbol::{sym, Symbol};
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_partial_ord(
@@ -2,11 +2,11 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, Ident};
use syntax::ast::{Expr, MetaItem};
use syntax::ptr::P;
use syntax::symbol::sym;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::{Span, DUMMY_SP};

pub fn expand_deriving_debug(
@@ -4,11 +4,11 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::pathvec_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast;
use syntax::ast::{Expr, MetaItem, Mutability};
use syntax::ptr::P;
use syntax::symbol::Symbol;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_rustc_decodable(
@@ -2,11 +2,11 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::path_std;

use rustc_expand::base::{Annotatable, DummyResult, ExtCtxt};
use syntax::ast::{Expr, MetaItem};
use syntax::ptr::P;
use syntax::span_err;
use syntax::symbol::{kw, sym};
use syntax_expand::base::{Annotatable, DummyResult, ExtCtxt};
use syntax_pos::Span;

use rustc_error_codes::*;
@@ -89,10 +89,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::pathvec_std;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{Expr, ExprKind, MetaItem, Mutability};
use syntax::ptr::P;
use syntax::symbol::Symbol;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_rustc_encodable(
@@ -181,6 +181,7 @@ use std::cell::RefCell;
use std::iter;
use std::vec;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, BinOpKind, EnumDef, Expr, Generics, Ident, PatKind};
use syntax::ast::{GenericArg, GenericParamKind, VariantData};
use syntax::attr;
@@ -189,7 +190,6 @@ use syntax::sess::ParseSess;
use syntax::source_map::respan;
use syntax::symbol::{kw, sym, Symbol};
use syntax::util::map_in_place::MapInPlace;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

use ty::{LifetimeBounds, Path, Ptr, PtrTy, Self_, Ty};
@@ -4,10 +4,10 @@
pub use PtrTy::*;
pub use Ty::*;

use rustc_expand::base::ExtCtxt;
use syntax::ast::{self, Expr, GenericArg, GenericParamKind, Generics, Ident, SelfKind};
use syntax::ptr::P;
use syntax::source_map::{respan, DUMMY_SP};
use syntax_expand::base::ExtCtxt;
use syntax_pos::symbol::kw;
use syntax_pos::Span;

@@ -2,10 +2,10 @@ use crate::deriving::generic::ty::*;
use crate::deriving::generic::*;
use crate::deriving::{self, path_std, pathvec_std};

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{Expr, MetaItem, Mutability};
use syntax::ptr::P;
use syntax::symbol::sym;
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand_deriving_hash(
@@ -1,9 +1,9 @@
//! The compiler code necessary to implement the `#[derive]` extensions.

use rustc_expand::base::{Annotatable, ExtCtxt, MultiItemModifier};
use syntax::ast::{self, ItemKind, MetaItem};
use syntax::ptr::P;
use syntax::symbol::{sym, Symbol};
use syntax_expand::base::{Annotatable, ExtCtxt, MultiItemModifier};
use syntax_pos::Span;

macro path_local($x:ident) {
@@ -3,10 +3,10 @@
// interface.
//

use rustc_expand::base::{self, *};
use syntax::ast::{self, GenericArg, Ident};
use syntax::symbol::{kw, sym, Symbol};
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_pos::Span;

use std::env;
@@ -7,12 +7,12 @@ use errors::pluralize;
use errors::Applicability;
use errors::DiagnosticBuilder;

use rustc_expand::base::{self, *};
use syntax::ast;
use syntax::ptr::P;
use syntax::symbol::{sym, Symbol};
use syntax::token;
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_pos::{MultiSpan, Span};

use rustc_data_structures::fx::{FxHashMap, FxHashSet};
@@ -1,11 +1,11 @@
use crate::util::check_builtin_macro_attribute;

use rustc_expand::base::{Annotatable, ExtCtxt};
use syntax::ast::{self, Attribute, Expr, FnHeader, FnSig, Generics, Ident, Param};
use syntax::ast::{ItemKind, Mutability, Stmt, Ty, TyKind, Unsafety};
use syntax::expand::allocator::{AllocatorKind, AllocatorMethod, AllocatorTy, ALLOCATOR_METHODS};
use syntax::ptr::P;
use syntax::symbol::{kw, sym, Symbol};
use syntax_expand::base::{Annotatable, ExtCtxt};
use syntax_pos::Span;

pub fn expand(
@@ -9,13 +9,13 @@
/// therefore apply.
use errors::DiagnosticBuilder;

use rustc_expand::base::{self, *};
use smallvec::smallvec;
use syntax::ast;
use syntax::ptr::P;
use syntax::source_map::respan;
use syntax::token;
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_pos::Span;

pub fn expand_global_asm<'cx>(
@@ -13,11 +13,11 @@ extern crate proc_macro;

use crate::deriving::*;

use rustc_expand::base::{MacroExpanderFn, Resolver, SyntaxExtension, SyntaxExtensionKind};
use rustc_expand::proc_macro::BangProcMacro;
use syntax::ast::Ident;
use syntax::edition::Edition;
use syntax::symbol::sym;
use syntax_expand::base::{MacroExpanderFn, Resolver, SyntaxExtension, SyntaxExtensionKind};
use syntax_expand::proc_macro::BangProcMacro;

mod asm;
mod assert;
@@ -1,6 +1,6 @@
use rustc_expand::base;
use syntax::print;
use syntax::tokenstream::TokenStream;
use syntax_expand::base;
use syntax_pos;

pub fn expand_log_syntax<'cx>(
@@ -1,5 +1,7 @@
use std::mem;

use rustc_expand::base::{ExtCtxt, Resolver};
use rustc_expand::expand::{AstFragment, ExpansionConfig};
use smallvec::smallvec;
use syntax::ast::{self, Ident};
use syntax::attr;
@@ -9,8 +11,6 @@ use syntax::ptr::P;
use syntax::sess::ParseSess;
use syntax::symbol::{kw, sym};
use syntax::visit::{self, Visitor};
use syntax_expand::base::{ExtCtxt, Resolver};
use syntax_expand::expand::{AstFragment, ExpansionConfig};
use syntax_pos::hygiene::AstPass;
use syntax_pos::{Span, DUMMY_SP};

@@ -1,3 +1,5 @@
use rustc_expand::base::{self, *};
use rustc_expand::panictry;
use rustc_parse::{self, new_sub_parser_from_file, parser::Parser, DirectoryOwnership};
use syntax::ast;
use syntax::early_buffered_lints::INCOMPLETE_INCLUDE;
@@ -6,8 +8,6 @@ use syntax::ptr::P;
use syntax::symbol::Symbol;
use syntax::token;
use syntax::tokenstream::TokenStream;
use syntax_expand::base::{self, *};
use syntax_expand::panictry;

use smallvec::SmallVec;
use syntax_pos::{self, Pos, Span};
@@ -1,10 +1,10 @@
use rustc_expand::base::{ExtCtxt, Resolver};
use rustc_expand::expand::ExpansionConfig;
use syntax::edition::Edition;
use syntax::ptr::P;
use syntax::sess::ParseSess;
use syntax::symbol::{kw, sym, Ident, Symbol};
use syntax::{ast, attr};
use syntax_expand::base::{ExtCtxt, Resolver};
use syntax_expand::expand::ExpansionConfig;
use syntax_pos::hygiene::AstPass;
use syntax_pos::DUMMY_SP;

@@ -2,12 +2,12 @@
/// Ideally, this code would be in libtest but for efficiency and error messages it lives here.
use crate::util::check_builtin_macro_attribute;

use rustc_expand::base::*;
use syntax::ast;
use syntax::attr;
use syntax::print::pprust;
use syntax::source_map::respan;
use syntax::symbol::{sym, Symbol};
use syntax_expand::base::*;
use syntax_pos::Span;

use std::iter;

0 comments on commit a2823e3

Please sign in to comment.
You can’t perform that action at this time.