about summary refs log tree commit diff
path: root/src/test/ui/feature-gate
AgeCommit message (Collapse)AuthorLines
2019-04-25Make `-Z allow-features` work for stdlib featuresTyler Mandry-2/+18
2019-04-20Fix additional variadic typosvarkor-2/+2
2019-04-18hide `--explain` hint if error has no extended infoAndy Russell-1/+0
2019-04-15Update testJohn Kåre Alsaker-182/+186
2019-04-11Reword tracking issue noteEsteban Küber-2/+2
2019-04-10Tweak unstable diagnostic outputEsteban Küber-2/+4
2019-03-14Add `-Z allow_features=...` flagTyler Mandry-0/+50
2019-03-11Update testsVadim Petrochenkov-21/+21
2019-02-27Add c_variadic language feature itemDan Robertson-0/+15
2019-01-18Rollup merge of #57650 - AB1908:master, r=petrochenkovMazdak Farrokhzad-0/+13
librustc_metadata: Pass a default value when unwrapping a span Fixes #57323. When compiling with `static-nobundle` a-la `rustc -l static-nobundle=nonexistent main.rs` we now get a neat output in the form of: ``` error[E0658]: kind="static-nobundle" is feature gated (see issue #37403) | = help: add #![feature(static_nobundle)] to the crate attributes to enable error: aborting due to previous error For more information about this error, try `rustc --explain E0658`. ``` The build and tests completed successfully on my machine. Should I be adding a new test?
2019-01-17Add test for linking non-existent static libraryAB1908-0/+13
2019-01-13Address review commentsVadim Petrochenkov-1/+1
2019-01-13Implement basic input validation for built-in attributesVadim Petrochenkov-817/+661
2018-12-27Do not abort compilation if expansion produces errorsVadim Petrochenkov-0/+4
Fix a number of uncovered deficiencies in diagnostics
2018-12-25Remove licensesMark Rousskov-435/+265
2018-11-11Fix typos.Bruce Mitchener-1/+1
2018-11-07Removed `#[rustc_error]` from tests that are all `// compile-pass`.Felix S. Klock II-14/+4
I also added `// skip-codegen` to each one, to address potential concerns that this change would otherwise slow down our test suite spending time generating code for files that are really just meant to be checks of compiler diagnostics. (However, I will say: My preference is to not use `// skip-codegen` if one can avoid it. We can use all the testing of how we drive LLVM that we can get...) (Updated post rebase.)
2018-11-07Replaced use of `#[rustc_error]` with `// skip-codegen`.Felix S. Klock II-15/+9
This test specifically notes that it does not want to invoke the linker, due to the way it (IMO weakly) exercises the `#[link=...]` attribute. In any case, removing the the `#[rustc_error]` here uncovered an "invalid windows subsystem" error that was previously not included in the transcript of diagnostic output. So that's a step forward, (right?).
2018-10-06rustc: Allow `#[no_mangle]` anywhere in a crateAlex Crichton-132/+121
This commit updates the compiler to allow the `#[no_mangle]` (and `#[export_name]` attributes) to be located anywhere within a crate. These attributes are unconditionally processed, causing the compiler to always generate an exported symbol with the appropriate name. After some discussion on #54135 it was found that not a great reason this hasn't been allowed already, and it seems to match the behavior that many expect! Previously the compiler would only export a `#[no_mangle]` symbol if it were *publicly reachable*, meaning that it itself is `pub` and it's otherwise publicly reachable from the root of the crate. This new definition is that `#[no_mangle]` *is always reachable*, no matter where it is in a crate or whether it has `pub` or not. This should make it much easier to declare an exported symbol with a known and unique name, even when it's an internal implementation detail of the crate itself. Note that these symbols will persist beyond LTO as well, always making their way to the linker. Along the way this commit removes the `private_no_mangle_functions` lint (also for statics) as there's no longer any need to lint these situations. Furthermore a good number of tests were updated now that symbol visibility has been changed. Closes #54135
2018-09-10Feature gate non-builtin attributes in inner attribute positionVadim Petrochenkov-0/+2
2018-08-05Convert unknown_features lint into an errorvarkor-225/+219
2018-08-05Turn the duplicate feature lint into an errorvarkor-15/+9
2018-08-05Add a test for feature attribute consistencyvarkor-0/+41
Note that this doesn't test consistency of some properties, like `reason`.
2018-08-05Add test for duplicate featuresvarkor-0/+40
2018-08-05Add a test for unknown featuresvarkor-0/+29
2018-07-14Lint the use of async as an identifierOliver Schneider-14/+14
2018-06-06Do not account for inner/outer attrEsteban Küber-2/+2
2018-06-06Use consistent span for repr attr suggestionEsteban Küber-2/+2
2018-06-06Change repr documentation linkEsteban Küber-6/+6
2018-06-06Add `transparent` as valid `repr` hintEsteban Küber-6/+6
2018-06-06Turn warning into lintEsteban Küber-214/+226
2018-06-06Expand output and suggestions, fix testsEsteban Küber-142/+192
2018-05-01Fix an error from "unused" lint + Fix rebaseVadim Petrochenkov-81/+73
2018-05-01Remove `macro_reexport`Vadim Petrochenkov-267/+213
It's subsumed by `feature(use_extern_macros)` and `pub use`
2018-04-28stabilize `#[must_use]` for functions and must-use operatorsZack M. Davis-82/+73
This is in the matter of RFC 1940 and tracking issue #43302.
2018-04-27Allow #[inline] on closuresAmanieu d'Antras-18/+18
Fixes #49632
2018-04-15don't see issue #0Zack M. Davis-0/+27
The unstable-feature attribute requires an issue (neglecting it is E0547), which gets used in the error messages. Unfortunately, there are some cases where "0" is apparently used a placeholder where no issue exists, directing the user to see the (nonexistent) issue #0. (It would have been better to either let `issue` be optional—compare to how issue is an `Option<u32>` in the feature-gate declarations in libsyntax/feature-gate.rs—or actually require that an issue be created.) Rather than endeavoring to change how `#[unstable]` works at this time (given competing contributor and reviewer priorities), this simple patch proposes the less-ambitious solution of just not adding the "(see issue)" note when the number is zero. Resolves #49983.
2018-04-13Rename must-compile-successfully into compile-passGuillaume Gomez-1/+1
2018-03-16Update testsJohn Kåre Alsaker-0/+4
2018-03-14Add backticks to `main` not found errors.Eric Huss-6/+6
2018-03-14Add suggestion where to add main function.Eric Huss-0/+4
2018-03-14Add empty main() to tests where it is missing.Eric Huss-27/+20
2018-03-14Add crate name to "main function not found" error message.Eric Huss-8/+8
Fixes #44798 and rust-lang/cargo#4948.
2018-03-14update testsGuillaume Gomez-9/+9
2018-02-26Update UI testsVadim Petrochenkov-1/+1
2018-02-26Update UI testsVadim Petrochenkov-883/+883
2018-02-25Update ui testsGuillaume Gomez-0/+9
2018-02-17fix more typos found by codespell.Matthias Krüger-1/+1
2018-01-13rustc: Refactor attribute checking to operate on HIRAlex Crichton-2/+2
This'll enable running queries that could be cached and overall be more amenable to the query infastructure.
2018-01-07Remove deprecated unstable attribute `#[simd]`Robin Kruppe-466/+411
The `#[simd]` attribute has been deprecated since c8b6d5b23cc8b2d43ece9f06252c7e98280fb8e5 back in 2015. Any nightly crates using it have had ample time to switch to `#[repr(simd)]`, and if they didn't they're likely broken by now anyway.