rust/src/test
Corey Farwell 640dbbdd3a Rollup merge of #40627 - estebank:pub-restricted, r=petrochenkov
Add diagnostic for incorrect `pub (restriction)`

Given the following statement

```rust
pub (a) fn afn() {}
```

Provide the following diagnostic:

```rust
error: incorrect restriction in `pub`
  --> file.rs:15:1
   |
15 | pub (a) fn afn() {}
   |     ^^^
   |
   = help: some valid visibility restrictions are:
           `pub(crate)`: visible only on the current crate
           `pub(super)`: visible only in the current module's parent
           `pub(in path::to::module)`: visible only on the specified path
help: to make this visible only to module `a`, add `in` before the path:
   | pub (in a) fn afn() {}
```

Follow up to #40340, fix #40599, cc #32409.
2017-03-23 08:42:46 -05:00
..
codegen rustc: Always emit the uwtable attribute on Windows 2017-03-21 16:47:10 -04:00
codegen-units translate drop glue using MIR 2017-03-18 02:53:08 +02:00
compile-fail Rollup merge of #40627 - estebank:pub-restricted, r=petrochenkov 2017-03-23 08:42:46 -05:00
compile-fail-fulldeps Rollup merge of #40556 - cramertj:stabilize-pub-restricted, r=petrochenkov 2017-03-20 23:44:59 -04:00
debuginfo update gdbr tests 2017-03-09 22:12:36 +01:00
incremental rustc_typeck: hook up collect and item/body check to on-demand. 2017-02-25 18:35:25 +02:00
mir-opt Do not bother creating StorageLive for TyNever 2017-03-09 17:54:00 +02:00
parse-fail Refactor parsing of trait object types 2017-03-21 23:01:53 +03:00
pretty Update pretty test for derive attributes 2017-02-05 12:22:29 +10:30
run-fail Warn when a #[should_panic] test has an unexpected message 2016-11-18 21:01:19 +10:30
run-fail-fulldeps Fix fallout in rustdoc and tests. 2016-11-21 12:16:46 +00:00
run-make Regression test for rust-lang/rust#40535 2017-03-21 16:34:56 -04:00
run-pass Rollup merge of #40523 - durka:patch-38, r=petrochenkov 2017-03-22 19:30:24 -04:00
run-pass-fulldeps Fix bug in legacy #[derive] processing logic. 2017-03-21 16:53:34 -04:00
run-pass-valgrind Removes FIXMEs related to #22405 2017-01-31 21:27:13 -05:00
rustdoc Add whitespace around "=" in assoc items 2017-03-21 16:22:15 -04:00
ui Add diagnostic for incorrect pub (restriction) 2017-03-22 22:51:45 -07:00
ui-fulldeps/custom-derive Separate "ui-fulldeps" tests from "ui" tests 2017-03-04 21:38:26 +03:00
COMPILER_TESTS.md Move COMPILER_TESTS.md out of the root directory 2017-02-25 00:13:00 -06:00