about summary refs log tree commit diff
path: root/src/test/ui/conditional-compilation
AgeCommit message (Collapse)AuthorLines
2021-03-15More precise spans for HIR pathsVadim Petrochenkov-1/+1
2021-03-14expand: Resolve and expand inner attributes on out-of-line modulesVadim Petrochenkov-0/+10
2020-11-22resolve: Do not put macros into `module.unexpanded_invocations` unless necessaryVadim Petrochenkov-12/+12
2020-11-19expand: Tell built-in macros whether we are currently in forced expansion modeVadim Petrochenkov-8/+2
2020-11-03Expand `NtExpr` tokens only in key-value attributesVadim Petrochenkov-1/+13
2020-07-26report kind of deprecated item in messageAndy Russell-8/+8
This is important for fields, which are incorrectly referred to as "items".
2020-04-11rustc: Add a warning count upon completionRoccoDev-0/+2
2020-03-10builtin_macros: Add attribute macro `#[cfg_accessible(path)]`Vadim Petrochenkov-0/+186
2020-02-09--bless --compare-mode=nllMatthias Prechtl-3/+3
2020-02-06rustc_macros: don't limit the -Zmacro-backtrace suggestion to extern macros.Eduard-Mihai Burtescu-0/+4
2020-01-24Normalise notes with the/isvarkor-2/+2
2019-12-06cfg_attr: avoid .outer_tokensMazdak Farrokhzad-7/+73
2019-11-02Update error annotations in tests that successfully compileTomasz Miąsko-1/+1
Those annotation are silently ignored rather than begin validated against compiler output. Update them before validation is enabled, to avoid test failures.
2019-09-16Rollup merge of #64467 - Mark-Simulacrum:hide-cfg-failures, r=estebankMazdak Farrokhzad-0/+5
Hide diagnostics emitted during --cfg parsing The early error is more than sufficient for fixing the problem. Fixes https://github.com/rust-lang/rust/issues/31496.
2019-09-15Hide diagnostics emitted during --cfg parsingMark Rousskov-0/+5
The early error is more than sufficient for fixing the problem.
2019-09-15resolve: Tweak "cannot find" wording for attributesVadim Petrochenkov-12/+12
2019-09-14Provide a span if main function is not present in crateMark Rousskov-2/+7
Unfortunately, the diagnotic machinery does not cope well with an empty span which can happen if the crate is empty, in which case we merely set a spanless note.
2019-09-09Resolve attributes in several placesCaio-39/+25
Arm, Field, FieldPat, GenericParam, Param, StructField and Variant
2019-08-23`--bless` some tests due to message format change.Mazdak Farrokhzad-6/+8
2019-07-19Auto merge of #62684 - petrochenkov:scopevisit, r=davidtwcobors-6/+3
resolve: Improve candidate search for unresolved macro suggestions Use same scope visiting machinery for both collecting suggestion candidates and actually resolving the names. The PR is better read in per-commit fashion with whitespace changes ignored (the first commit in particular moves some code around). This should be the last pre-requisite for https://github.com/rust-lang/rust/pull/62086. r? @davidtwco
2019-07-18resolve: Use `feature(custom_attribute)` fallback only if the feature is enabledVadim Petrochenkov-6/+3
Normally `#![feature(...)]` shouldn't change behavior, but custom attributes in particular are in the process of retirement, and we should not produce a message telling to enable them. It also helps with unifying diagnostics for unresolved macros.
2019-07-17normalize use of backticks in compiler messages for librustc/lintSamy Kacimi-2/+2
https://github.com/rust-lang/rust/issues/60532
2019-07-13review commentsEsteban Küber-1/+1
2019-07-13Tweak wording in feature gate errorsEsteban Küber-6/+6
2019-07-09normalize use of backticks in compiler messages for libsyntax/feature_gateSamy Kacimi-9/+9
https://github.com/rust-lang/rust/issues/60532
2019-07-03Migrate compile-pass annotations to build-passYuki Okushi-2/+2
2019-06-23Auto merge of #61778 - petrochenkov:pass, r=Mark-Simulacrumbors-4/+3
compiletest: Introduce `// {check,build,run}-pass` pass modes Pass UI tests now have three modes ``` // check-pass // build-pass // run-pass ``` mirroring equivalent well-known `cargo` commands. `// check-pass` will compile the test skipping codegen (which is expensive and isn't supposed to fail in most cases). `// build-pass` will compile and link the test without running it. `// run-pass` will compile, link and run the test. Tests without a "pass" annotation are still considered "fail" tests. Most UI tests would probably want to switch to `check-pass`. Tests validating codegen would probably want to run the generated code as well and use `run-pass`. `build-pass` should probably be rare (linking tests?). https://github.com/rust-lang/rust/pull/61755 will provide a way to run the tests with any mode, e.g. bump `check-pass` tests to `run-pass` to satisfy especially suspicious people, and be able to make sure that codegen doesn't breaks in some entirely unexpected way. Tests marked with any mode are expected to pass with any other mode, if that's not the case for some legitimate reason, then the test should be made a "fail" test rather than a "pass" test. Perhaps some secondary CI can verify this invariant, but that's not super urgent. `// compile-pass` still works and is equivalent to `build-pass`. Why is `// compile-pass` bad - 1) it gives an impression that the test is only compiled, but not linked, 2) it doesn't mirror a cargo command. It can be removed some time in the future in a separate PR. cc https://github.com/rust-lang/rust/issues/61712
2019-06-22Add test for linting on 'cfg_attr(,)'.Mazdak Farrokhzad-0/+34
2019-06-19Support `cfg` and `cfg_attr` on generic parametersVadim Petrochenkov-0/+104
2019-06-16compiletest: Remove `skip-codegen`Vadim Petrochenkov-4/+3
2019-04-18hide `--explain` hint if error has no extended infoAndy Russell-1/+1
2019-04-14fix testsRalf Jung-0/+12
2019-04-11Reword tracking issue noteEsteban Küber-4/+4
2019-04-10Tweak unstable diagnostic outputEsteban Küber-4/+8
2019-03-11Update testsVadim Petrochenkov-24/+24
2019-03-06Surround found token with `Esteban Küber-2/+2
2019-03-05On incorrect cfg literal/identifier, point at the right spanEsteban Küber-2/+2
2019-01-13Implement basic input validation for built-in attributesVadim Petrochenkov-5/+6
2019-01-08bless youdylan_DPC-2/+2
2019-01-08remove unwanted stage0 line, fix styledylan_DPC-7/+5
2019-01-08remove unused imports and feature gate from testsdylan_DPC-7/+5
2019-01-08stabilise cfg_attrdylan_DPC-5/+3
2019-01-06Make sure feature gate errors are recoverable (take 2)Vadim Petrochenkov-8/+8
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-114/+8
2018-11-07Removed `#[rustc_error]` from tests that are all `// compile-pass`.Felix S. Klock II-15/+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-10-26Auto merge of #54929 - csmoe:cfg_lint, r=petrochenkovbors-9/+19
Suggest to remove prefix `b` in cfg attribute lint string Closes #54926 r? @estebank
2018-10-23fix typos in various placesMatthias Krüger-1/+1
2018-10-23add expected error commentEsteban Kuber-1/+1
Co-Authored-By: csmoe <csmoe@msn.com>
2018-10-23add expected error commentEsteban Kuber-1/+1
Co-Authored-By: csmoe <csmoe@msn.com>