about summary refs log tree commit diff
path: root/src/librustc_metadata/native_libs.rs
AgeCommit message (Collapse)AuthorLines
2020-08-30mv compiler to compiler/mark-269/+0
2020-08-08Eliminate the `SessionGlobals` from `librustc_ast`.Nicholas Nethercote-15/+10
By moving `{known,used}_attrs` from `SessionGlobals` to `Session`. This means they are accessed via the `Session`, rather than via TLS. A few `Attr` methods and `librustc_ast` functions are now methods of `Session`. All of this required passing a `Session` to lots of functions that didn't already have one. Some of these functions also had arguments removed, because those arguments could be accessed directly via the `Session` argument. `contains_feature_attr()` was dead, and is removed. Some functions were moved from `librustc_ast` elsewhere because they now need to access `Session`, which isn't available in that crate. - `entry_point_type()` --> `librustc_builtin_macros` - `global_allocator_spans()` --> `librustc_metadata` - `is_proc_macro_attr()` --> `Session`
2020-08-04rustc_ast: `(Nested)MetaItem::check_name` -> `has_name`Vadim Petrochenkov-4/+4
For consistency with `Attribute::has_name` which doesn't mark the attribute as used either. Replace all uses of `check_name` with `has_name` outside of rustc
2020-05-20Eliminate some `Option<NativeLibKind>`sVadim Petrochenkov-3/+3
2020-05-20Factor out `NativeLibKind::Dylib` from `NativeLibKind::Unspecified`Vadim Petrochenkov-1/+1
2020-05-20Rename some types describing native librariesVadim Petrochenkov-18/+19
NativeLibrary(Kind) -> NativeLib(Kind) NativeStatic -> StaticBundle NativeStaticNobundle -> StaticNoBundle NativeFramework -> Framework NativeRawDylib -> RawDylib NativeUnknown -> Unspecified
2020-04-23librustc_middle: return LocalDefId instead of DefId in local_def_idmarmeladema-1/+1
2020-04-04Update the description of link_cfg unstableRustin-Liu-2/+7
Fmt code Update tests Modify msg Signed-off-by: Rustin-Liu <rustin.liu@gmail.com>
2020-03-30rustc -> rustc_middle part 3 (rustfmt)Mazdak Farrokhzad-2/+2
2020-03-30rustc -> rustc_middle part 2Mazdak Farrokhzad-2/+2
2020-03-20remove redundant returns (clippy::needless_return)Matthias Krüger-1/+1
2020-03-16use direct imports for `rustc::{lint, session}`.Mazdak Farrokhzad-2/+2
2020-02-01Move builtin attribute logic to new rustc_attr crate.Mazdak Farrokhzad-1/+1
For now, this is all the crate contains, but more attribute logic & types will be moved there over time.
2020-01-18remove rustc_error_codes deps except in rustc_driverMazdak Farrokhzad-1/+0
2020-01-11simplify feature_err importsMazdak Farrokhzad-1/+1
2020-01-10nix syntax::errors & prefer rustc_errors over errorsMazdak Farrokhzad-1/+1
2020-01-08- remove syntax::{span_warn!, span_err!, span_fatal!. struct_err!}Mazdak Farrokhzad-4/+3
- remove syntax::{help!, span_help!, span_note!} - remove unused syntax::{struct_span_fatal, struct_span_err_or_warn!, span_err_or_warn!} - lintify check_for_bindings_named_same_as_variants + conflicting_repr_hints - inline syntax::{struct_span_warn!, diagnostic_used!} - stringify_error_code! -> error_code! & use it more. - find_plugin_registrar: de-fatalize an error - de-fatalize metadata errors - move type_error_struct! to rustc_typeck - struct_span_err! -> rustc_errors
2020-01-05Remove rustc_hir reexports in rustc::hir.Mazdak Farrokhzad-2/+2
2020-01-04canonicalize FxHash{Map,Set} importsMazdak Farrokhzad-1/+1
2020-01-02Normalize `syntax::symbol` imports.Mazdak Farrokhzad-1/+1
2020-01-02Normalize `syntax::source_map` imports.Mazdak Farrokhzad-1/+1
2020-01-01Rename `syntax_pos` to `rustc_span` in source codeVadim Petrochenkov-2/+2
2019-12-22Format the worldMark Rousskov-54/+68
2019-12-21Use Arena inside hir::ImplItem.Camille GILLOT-1/+1
2019-12-21Use Arena inside hir::TraitItem.Camille GILLOT-1/+1
2019-12-21Use Arena inside hir::Item.Camille GILLOT-1/+1
2019-11-30move GateIssue to rustc_feature & simplify emit_feature_errMazdak Farrokhzad-17/+19
2019-11-14Update to use new librustc_error_codes libraryGuillaume Gomez-0/+2
2019-11-02Simplify various `Symbol` use points.Nicholas Nethercote-1/+1
Including removing a bunch of unnecessary `.as_str()` calls, and a bunch of unnecessary sigils.
2019-10-16Make use of the return value of `HashSet::insert`Shotaro Yamada-3/+1
2019-10-14rustc_metadata: Privatize private code and remove dead codeVadim Petrochenkov-2/+2
2019-10-07Address review comments.Charles Lew-1/+1
2019-10-07Add feature gate for raw_dylib.Charles Lew-0/+9
2019-09-26Rename `Item.node` to `Item.kind`varkor-1/+1
2019-09-12Auto merge of #64303 - nnethercote:avoid-more-Symbol-to-string-operations, ↵bors-2/+2
r=petrochenkov Avoid more `Symbol`-to-string operations These commits avoid various `Symbol`-to-string conversions, by doing more operations directly on `Symbol`s. This requires adding a few more static `Symbol`s to the binary. r? @petrochenkov
2019-09-11Avoid two `Symbol::as_str()` calls.Nicholas Nethercote-2/+2
2019-09-08Improve wording.Charles Lew-2/+2
2019-07-19normalize use of backticks in compiler messages for librustc_metadataSamy Kacimi-4/+4
https://github.com/rust-lang/rust/issues/60532
2019-07-04rename hir::map::local_def_id_from_hir_id to local_def_idljedrz-1/+1
2019-07-03Remove needless lifetimesJeremy Stucki-1/+1
2019-06-14Unify all uses of 'gcx and 'tcx.Eduard-Mihai Burtescu-2/+2
2019-06-12Run `rustfmt --file-lines ...` for changes from previous commits.Eduard-Mihai Burtescu-1/+1
2019-06-12rustc: replace `TyCtxt<'tcx, 'gcx, 'tcx>` with `TyCtxt<'gcx, 'tcx>`.Eduard-Mihai Burtescu-2/+2
2019-06-12Fix fallout from `deny(unused_lifetimes)`.Eduard-Mihai Burtescu-1/+1
2019-06-12rustc: replace `TyCtxt<'a, 'gcx, 'tcx>` with `TyCtxt<'tcx, 'gcx, 'tcx>`.Eduard-Mihai Burtescu-5/+5
2019-05-13Remove the equality operation between `Symbol` and strings.Nicholas Nethercote-2/+2
And also the equality between `Path` and strings, because `Path` is made up of `Symbol`s.
2019-05-13Pass a `Symbol` to `check_name`, `emit_feature_err`, and related functions.Nicholas Nethercote-8/+8
2019-03-23Fix rebaseEsteban Küber-1/+1
2019-03-23Swap primary/secondary spans for E0458Esteban Küber-2/+3
2019-03-20Auto merge of #57018 - dcreager:redundant-linker, r=alexcrichtonbors-25/+26
Keep last redundant linker flag, not first When a library (L1) is passed to the linker multiple times, this is sometimes purposeful: there might be several other libraries in the linker command (L2 and L3) that all depend on L1. You'd end up with a (simplified) linker command that looks like: ``` -l2 -l1 -l3 -l1 ``` With the previous behavior, when rustc encountered a redundant library, it would keep the first instance, and remove the later ones, resulting in: ``` -l2 -l1 -l3 ``` This can cause a linker error, because on some platforms (e.g. Linux), the linker will only include symbols from L1 that are needed *at the point it's referenced in the command line*. So if L3 depends on additional symbols from L1, which aren't needed by L2, the linker won't know to include them, and you'll end up with "undefined symbols" errors. A better behavior is to keep the *last* instance of the library: ``` -l2 -l3 -l1 ``` This ensures that all "downstream" libraries have been included in the linker command before the "upstream" library is referenced. Fixes rust-lang#47989