about summary refs log tree commit diff
path: root/src/test/ui/consts
AgeCommit message (Collapse)AuthorLines
2018-11-08Auto merge of #55532 - pnkfelix:rustc_error-survey, r=nikomatsakisbors-14/+4
#[rustc_error] survey Fix #55505
2018-11-07test diagnostics for more rangesRalf Jung-2/+32
2018-11-07pretty-print scalar range that only has an upper boundRalf Jung-7/+7
2018-11-07do not print wrapping ranges like normal ranges in diagnosticsRalf Jung-22/+47
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-07Auto merge of #55549 - RalfJung:miri-visitor, r=oli-obkbors-37/+59
Value visitors for miri Generalize the traversal part of validation to a `ValueVisitor`. ~~This includes https://github.com/rust-lang/rust/pull/55316, [click here](https://github.com/RalfJung/rust/compare/retagging...RalfJung:miri-visitor) for just the new commits.~~
2018-11-06Auto merge of #55262 - oli-obk:dangling_alloc_id_ice, r=RalfJungbors-0/+51
Change the ICE from #55223 to a hard error cc @SimonSapin r? @RalfJung fixes https://github.com/rust-lang/rust/issues/55287
2018-11-05the visitor can already load the value for visit_primitiveRalf Jung-1/+1
2018-11-05Also test for undef in enum discriminantRalf Jung-3/+16
The error message is sub-par, but fixing that requries moving ScalarMaybeUndef to librustc which would conflict badly with another PR that is in flight.
2018-11-05fix validation error on non-integer enum discriminantsRalf Jung-33/+42
2018-11-05reduce the amount of traversal/projection code that the visitor has to ↵Ralf Jung-2/+2
implement itself
2018-11-04also test with PhantomDataRalf Jung-3/+9
2018-11-04miri: accept extern types in structs if they are the only fieldRalf Jung-0/+21
2018-11-01Fix double_check tests on big-endian targetsSamuel Holland-10/+10
Since the enums get optimized down to 1 byte long, the bits set in the usize member don't align with the enums on big-endian machines. Avoid this issue by shrinking the integer member to the same size as the enums.
2018-10-30Rollup merge of #55474 - oli-obk:const_eval_promoted, r=RalfJungkennytm-0/+18
Fix validation false positive Fixes #55454 r? @RalfJung
2018-10-29Fix wrong validation clasisfication of `Option<&T>::Some` valuesOliver Scherer-0/+18
2018-10-29Turn ICE for dangling pointers into errorOliver Scherer-0/+51
2018-10-29Add UI test for #49296memoryruins-0/+35
2018-10-27Fix an ICE in the min_const_fn analysisOliver Scherer-0/+23
2018-10-26Auto merge of #55382 - kennytm:rollup, r=kennytmbors-0/+17
Rollup of 21 pull requests Successful merges: - #54816 (Don't try to promote already promoted out temporaries) - #54824 (Cleanup rustdoc tests with `@!has` and `@!matches`) - #54921 (Add line numbers option to rustdoc) - #55167 (Add a "cheap" mode for `compute_missing_ctors`.) - #55258 (Fix Rustdoc ICE when checking blanket impls) - #55264 (Compile the libstd we distribute with -Ccodegen-unit=1) - #55271 (Unimplement ExactSizeIterator for MIR traversing iterators) - #55292 (Macro diagnostics tweaks) - #55298 (Point at macro definition when no rules expect token) - #55301 (List allowed tokens after macro fragments) - #55302 (Extend the impl_stable_hash_for! macro for miri.) - #55325 (Fix link to macros chapter) - #55343 (rustbuild: fix remap-debuginfo when building a release) - #55346 (Shrink `Statement`.) - #55358 (Remove redundant clone (2)) - #55370 (Update mailmap for estebank) - #55375 (Typo fixes in configure_cmake comments) - #55378 (rustbuild: use configured linker to build boostrap) - #55379 (validity: assert that unions are non-empty) - #55383 (Use `SmallVec` for the queue in `coerce_unsized`.) - #55391 (bootstrap: clean up a few clippy findings)
2018-10-26Rollup merge of #54816 - oli-obk:double_promotion, r=alexregkennytm-0/+17
Don't try to promote already promoted out temporaries fixes #53201 r? @eddyb
2018-10-25Rebase falloutOliver Schneider-232/+58
2018-10-25add the lint back to the list, and fix testsRalf Jung-263/+69
2018-10-25fix ui tests (rebase fallout)Ralf Jung-3/+4
2018-10-25Addressed minor issues brought up in review.Alexander Regueiro-8/+5
2018-10-25Rebase fallout in ui outputOliver Schneider-24/+13
2018-10-25update tests to changes on rustc masterOliver Schneider-51/+69
2018-10-25Deduplicate all the ~~things~~ errorsOliver Schneider-164/+87
2018-10-25Report const eval error inside the queryOliver Schneider-631/+1039
2018-10-21Use new region infer errors for explaining borrowsMatthew Jasper-132/+132
This gives at least some explanation for why a borrow is expected to last for a certain free region. Also: * Reports E0373: "closure may outlive the current function" with NLL. * Special cases the case of returning a reference to (or value referencing) a local variable or temporary (E0515). * Special case assigning a reference to a local variable in a closure to a captured variable.
2018-10-19skip user-type annotations if they don't have regionsNiko Matsakis-19/+4
2018-10-19lowering casts in constants now creates multiple usesNiko Matsakis-6/+21
This can trigger more errors than before. Not sure what is the best fix here.
2018-10-19Auto merge of #55194 - kennytm:rollup, r=kennytmbors-0/+61
Rollup of 7 pull requests Successful merges: - #54300 (Updated RELEASES.md for 1.30.0) - #55013 ([NLL] Propagate bounds from generators) - #55071 (Fix ICE and report a human readable error) - #55144 (Cleanup resolve) - #55166 (Don't warn about parentheses on `match (return)`) - #55169 (Add a `copysign` function to f32 and f64) - #55178 (Stabilize slice::chunks_exact(), chunks_exact_mut(), rchunks(), rchunks_mut(), rchunks_exact(), rchunks_exact_mut())
2018-10-19Rollup merge of #55071 - oli-obk:const_cast_🍨, r=RalfJungkennytm-0/+61
Fix ICE and report a human readable error fixes #55063 r? @RalfJung
2018-10-19Auto merge of #55004 - oli-obk:sized_static, r=cramertjbors-24/+17
Check the type of statics and constants for `Sized`ness fixes #54410
2018-10-17Update output for borrowck=migrate compare mode.David Wood-4/+10
This commit updates the test output for the updated NLL compare mode that uses `-Z borrowck=migrate` rather than `-Z borrowck=mir`. The previous commit changes `compiletest` and this commit only updates `.nll.stderr` files.
2018-10-16Check the type of statics and constants for `Sized`nessOliver Scherer-24/+17
2018-10-15Add trailing newline to satisfy tidyOliver S̶c̶h̶n̶e̶i̶d̶e̶r Scherer-1/+1
2018-10-15Try to trigger some error casesOliver Scherer-0/+46
2018-10-14Fix ICE and report a human readable errorOliver Scherer-0/+15
2018-10-13validation: accept pointers in integer arraysRalf Jung-1/+12
2018-10-13Fix and test upvar name printing for validityRalf Jung-0/+36
2018-10-12Auto merge of #54715 - oli-obk:nll_deref_promotion, r=RalfJungbors-0/+37
Fix #54224 (const promotion regression) r? @eddyb
2018-10-09unify handling of thin and fat pointers by moving primitive type handling ↵Ralf Jung-8/+19
out of aggregate handling Also, make enum variant handling a bit nicer
2018-10-09add some tests with constants that better be validRalf Jung-0/+18
2018-10-09move a test to a better placeRalf Jung-0/+254
2018-10-09also validate everything that has a Scalar layout, to catch NonNullRalf Jung-4/+56
2018-10-09fix validating arrays of ZSTsRalf Jung-14/+23
Fixes #54751
2018-10-09switch validation of scalars to be type-drivenRalf Jung-32/+50
This does not actually regress anything. It would regress NonNull, but we didn't handle that correctly previously either.
2018-10-09check that entire ref is in-bounds before recursing; add macro for ↵Ralf Jung-9/+30
validation msgs on error