Remove -Z continue-parse-after-error
This commit is contained in:
parent
ed6468da16
commit
41a93cba38
36 changed files with 77 additions and 125 deletions
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
fn main() {
|
||||
let x = "\x80"; //~ ERROR may only be used
|
||||
let y = "\xff"; //~ ERROR may only be used
|
||||
|
|
|
|||
|
|
@ -1,17 +1,17 @@
|
|||
error: this form of character escape may only be used with characters in the range [\x00-\x7f]
|
||||
--> $DIR/ascii-only-character-escape.rs:4:14
|
||||
--> $DIR/ascii-only-character-escape.rs:2:14
|
||||
|
|
||||
LL | let x = "\x80";
|
||||
| ^^^^
|
||||
|
||||
error: this form of character escape may only be used with characters in the range [\x00-\x7f]
|
||||
--> $DIR/ascii-only-character-escape.rs:5:14
|
||||
--> $DIR/ascii-only-character-escape.rs:3:14
|
||||
|
|
||||
LL | let y = "\xff";
|
||||
| ^^^^
|
||||
|
||||
error: this form of character escape may only be used with characters in the range [\x00-\x7f]
|
||||
--> $DIR/ascii-only-character-escape.rs:6:14
|
||||
--> $DIR/ascii-only-character-escape.rs:4:14
|
||||
|
|
||||
LL | let z = "\xe2";
|
||||
| ^^^^
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
// ignore-tidy-cr
|
||||
// ignore-tidy-tab
|
||||
|
||||
fn main() {
|
||||
// these literals are just silly.
|
||||
''';
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
error: character constant must be escaped: '
|
||||
--> $DIR/bad-char-literals.rs:7:6
|
||||
--> $DIR/bad-char-literals.rs:6:6
|
||||
|
|
||||
LL | ''';
|
||||
| ^
|
||||
|
||||
error: character constant must be escaped: \n
|
||||
--> $DIR/bad-char-literals.rs:11:6
|
||||
--> $DIR/bad-char-literals.rs:10:6
|
||||
|
|
||||
LL | '
|
||||
| ______^
|
||||
|
|
@ -13,13 +13,13 @@ LL | | ';
|
|||
| |_
|
||||
|
||||
error: character constant must be escaped: \r
|
||||
--> $DIR/bad-char-literals.rs:16:6
|
||||
--> $DIR/bad-char-literals.rs:15:6
|
||||
|
|
||||
LL | '
';
|
||||
| ^
|
||||
|
||||
error: character constant must be escaped: \t
|
||||
--> $DIR/bad-char-literals.rs:19:6
|
||||
--> $DIR/bad-char-literals.rs:18:6
|
||||
|
|
||||
LL | ' ';
|
||||
| ^^^^
|
||||
|
|
|
|||
|
|
@ -1,6 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
|
||||
// ignore-tidy-tab
|
||||
|
||||
static FOO: u8 = b'\f'; //~ ERROR unknown byte escape
|
||||
|
|
|
|||
|
|
@ -1,41 +1,41 @@
|
|||
error: unknown byte escape: f
|
||||
--> $DIR/byte-literals.rs:6:21
|
||||
--> $DIR/byte-literals.rs:3:21
|
||||
|
|
||||
LL | static FOO: u8 = b'\f';
|
||||
| ^ unknown byte escape
|
||||
|
||||
error: unknown byte escape: f
|
||||
--> $DIR/byte-literals.rs:9:8
|
||||
--> $DIR/byte-literals.rs:6:8
|
||||
|
|
||||
LL | b'\f';
|
||||
| ^ unknown byte escape
|
||||
|
||||
error: invalid character in numeric character escape: Z
|
||||
--> $DIR/byte-literals.rs:10:10
|
||||
--> $DIR/byte-literals.rs:7:10
|
||||
|
|
||||
LL | b'\x0Z';
|
||||
| ^
|
||||
|
||||
error: byte constant must be escaped: \t
|
||||
--> $DIR/byte-literals.rs:11:7
|
||||
--> $DIR/byte-literals.rs:8:7
|
||||
|
|
||||
LL | b' ';
|
||||
| ^^^^
|
||||
|
||||
error: byte constant must be escaped: '
|
||||
--> $DIR/byte-literals.rs:12:7
|
||||
--> $DIR/byte-literals.rs:9:7
|
||||
|
|
||||
LL | b''';
|
||||
| ^
|
||||
|
||||
error: byte constant must be ASCII. Use a \xHH escape for a non-ASCII byte
|
||||
--> $DIR/byte-literals.rs:13:7
|
||||
--> $DIR/byte-literals.rs:10:7
|
||||
|
|
||||
LL | b'é';
|
||||
| ^
|
||||
|
||||
error: unterminated byte constant
|
||||
--> $DIR/byte-literals.rs:14:6
|
||||
--> $DIR/byte-literals.rs:11:6
|
||||
|
|
||||
LL | b'a
|
||||
| ^^^^
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
static FOO: &'static [u8] = b"\f"; //~ ERROR unknown byte escape
|
||||
|
||||
pub fn main() {
|
||||
|
|
|
|||
|
|
@ -1,29 +1,29 @@
|
|||
error: unknown byte escape: f
|
||||
--> $DIR/byte-string-literals.rs:3:32
|
||||
--> $DIR/byte-string-literals.rs:1:32
|
||||
|
|
||||
LL | static FOO: &'static [u8] = b"\f";
|
||||
| ^ unknown byte escape
|
||||
|
||||
error: unknown byte escape: f
|
||||
--> $DIR/byte-string-literals.rs:6:8
|
||||
--> $DIR/byte-string-literals.rs:4:8
|
||||
|
|
||||
LL | b"\f";
|
||||
| ^ unknown byte escape
|
||||
|
||||
error: invalid character in numeric character escape: Z
|
||||
--> $DIR/byte-string-literals.rs:7:10
|
||||
--> $DIR/byte-string-literals.rs:5:10
|
||||
|
|
||||
LL | b"\x0Z";
|
||||
| ^
|
||||
|
||||
error: byte constant must be ASCII. Use a \xHH escape for a non-ASCII byte
|
||||
--> $DIR/byte-string-literals.rs:8:7
|
||||
--> $DIR/byte-string-literals.rs:6:7
|
||||
|
|
||||
LL | b"é";
|
||||
| ^
|
||||
|
||||
error: unterminated double quote byte string
|
||||
--> $DIR/byte-string-literals.rs:9:6
|
||||
--> $DIR/byte-string-literals.rs:7:6
|
||||
|
|
||||
LL | b"a
|
||||
| ______^
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
impl ! {} // OK
|
||||
impl ! where u8: Copy {} // OK
|
||||
|
||||
|
|
|
|||
|
|
@ -1,29 +1,29 @@
|
|||
error: missing `for` in a trait impl
|
||||
--> $DIR/impl-parsing.rs:6:11
|
||||
--> $DIR/impl-parsing.rs:4:11
|
||||
|
|
||||
LL | impl Trait Type {}
|
||||
| ^ help: add `for` here
|
||||
|
||||
error: missing `for` in a trait impl
|
||||
--> $DIR/impl-parsing.rs:7:11
|
||||
--> $DIR/impl-parsing.rs:5:11
|
||||
|
|
||||
LL | impl Trait .. {}
|
||||
| ^ help: add `for` here
|
||||
|
||||
error: expected a trait, found type
|
||||
--> $DIR/impl-parsing.rs:8:6
|
||||
--> $DIR/impl-parsing.rs:6:6
|
||||
|
|
||||
LL | impl ?Sized for Type {}
|
||||
| ^^^^^^
|
||||
|
||||
error: expected a trait, found type
|
||||
--> $DIR/impl-parsing.rs:9:6
|
||||
--> $DIR/impl-parsing.rs:7:6
|
||||
|
|
||||
LL | impl ?Sized for .. {}
|
||||
| ^^^^^^
|
||||
|
||||
error: expected `impl`, found `FAIL`
|
||||
--> $DIR/impl-parsing.rs:11:16
|
||||
--> $DIR/impl-parsing.rs:9:16
|
||||
|
|
||||
LL | default unsafe FAIL
|
||||
| ^^^^ expected `impl`
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
fn main() {
|
||||
let _ = b"\u{a66e}";
|
||||
//~^ ERROR unicode escape sequences cannot be used as a byte or in a byte string
|
||||
|
|
|
|||
|
|
@ -1,17 +1,17 @@
|
|||
error: unicode escape sequences cannot be used as a byte or in a byte string
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:4:15
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:2:15
|
||||
|
|
||||
LL | let _ = b"\u{a66e}";
|
||||
| ^^^^^^^^
|
||||
|
||||
error: unicode escape sequences cannot be used as a byte or in a byte string
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:7:15
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:5:15
|
||||
|
|
||||
LL | let _ = b'\u{a66e}';
|
||||
| ^^^^^^^^
|
||||
|
||||
error: incorrect unicode escape sequence
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:10:15
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:8:15
|
||||
|
|
||||
LL | let _ = b'\u';
|
||||
| ^^ incorrect unicode escape sequence
|
||||
|
|
@ -19,43 +19,43 @@ LL | let _ = b'\u';
|
|||
= help: format of unicode escape sequences is `\u{...}`
|
||||
|
||||
error: numeric character escape is too short
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:13:15
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:11:15
|
||||
|
|
||||
LL | let _ = b'\x5';
|
||||
| ^^^
|
||||
|
||||
error: invalid character in numeric character escape: x
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:16:17
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:14:17
|
||||
|
|
||||
LL | let _ = b'\xxy';
|
||||
| ^
|
||||
|
||||
error: numeric character escape is too short
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:19:14
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:17:14
|
||||
|
|
||||
LL | let _ = '\x5';
|
||||
| ^^^
|
||||
|
||||
error: invalid character in numeric character escape: x
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:22:16
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:20:16
|
||||
|
|
||||
LL | let _ = '\xxy';
|
||||
| ^
|
||||
|
||||
error: unicode escape sequences cannot be used as a byte or in a byte string
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:25:15
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:23:15
|
||||
|
|
||||
LL | let _ = b"\u{a4a4} \xf \u";
|
||||
| ^^^^^^^^
|
||||
|
||||
error: invalid character in numeric character escape:
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:25:27
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:23:27
|
||||
|
|
||||
LL | let _ = b"\u{a4a4} \xf \u";
|
||||
| ^
|
||||
|
||||
error: incorrect unicode escape sequence
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:25:28
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:23:28
|
||||
|
|
||||
LL | let _ = b"\u{a4a4} \xf \u";
|
||||
| ^^ incorrect unicode escape sequence
|
||||
|
|
@ -63,13 +63,13 @@ LL | let _ = b"\u{a4a4} \xf \u";
|
|||
= help: format of unicode escape sequences is `\u{...}`
|
||||
|
||||
error: invalid character in numeric character escape:
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:30:17
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:28:17
|
||||
|
|
||||
LL | let _ = "\xf \u";
|
||||
| ^
|
||||
|
||||
error: incorrect unicode escape sequence
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:30:18
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:28:18
|
||||
|
|
||||
LL | let _ = "\xf \u";
|
||||
| ^^ incorrect unicode escape sequence
|
||||
|
|
@ -77,7 +77,7 @@ LL | let _ = "\xf \u";
|
|||
= help: format of unicode escape sequences is `\u{...}`
|
||||
|
||||
error: incorrect unicode escape sequence
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:34:14
|
||||
--> $DIR/issue-23620-invalid-escapes.rs:32:14
|
||||
|
|
||||
LL | let _ = "\u8f";
|
||||
| ^^--
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
"\u\\"
|
||||
//~^ ERROR incorrect unicode escape sequence
|
||||
//~| ERROR invalid trailing slash in literal
|
||||
//~| ERROR expected item, found `"\u\\"`
|
||||
|
|
|
|||
|
|
@ -12,5 +12,11 @@ error: invalid trailing slash in literal
|
|||
LL | "\u\"
|
||||
| ^
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
error: expected item, found `"\u\"`
|
||||
--> $DIR/issue-62913.rs:1:1
|
||||
|
|
||||
LL | "\u\"
|
||||
| ^^^^^^ expected item
|
||||
|
||||
error: aborting due to 3 previous errors
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
static c3: char =
|
||||
'\x1' //~ ERROR: numeric character escape is too short
|
||||
;
|
||||
|
|
|
|||
|
|
@ -1,23 +1,23 @@
|
|||
error: numeric character escape is too short
|
||||
--> $DIR/lex-bad-char-literals-1.rs:3:6
|
||||
--> $DIR/lex-bad-char-literals-1.rs:2:6
|
||||
|
|
||||
LL | '\x1'
|
||||
| ^^^
|
||||
|
||||
error: numeric character escape is too short
|
||||
--> $DIR/lex-bad-char-literals-1.rs:7:6
|
||||
--> $DIR/lex-bad-char-literals-1.rs:6:6
|
||||
|
|
||||
LL | "\x1"
|
||||
| ^^^
|
||||
|
||||
error: unknown character escape: \u{25cf}
|
||||
--> $DIR/lex-bad-char-literals-1.rs:11:7
|
||||
--> $DIR/lex-bad-char-literals-1.rs:10:7
|
||||
|
|
||||
LL | '\●'
|
||||
| ^ unknown character escape
|
||||
|
||||
error: unknown character escape: \u{25cf}
|
||||
--> $DIR/lex-bad-char-literals-1.rs:15:7
|
||||
--> $DIR/lex-bad-char-literals-1.rs:14:7
|
||||
|
|
||||
LL | "\●"
|
||||
| ^ unknown character escape
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
fn main() {
|
||||
let _: char = '';
|
||||
//~^ ERROR: empty character literal
|
||||
|
|
|
|||
|
|
@ -1,17 +1,17 @@
|
|||
error: empty character literal
|
||||
--> $DIR/lex-bad-char-literals-7.rs:3:20
|
||||
--> $DIR/lex-bad-char-literals-7.rs:2:20
|
||||
|
|
||||
LL | let _: char = '';
|
||||
| ^
|
||||
|
||||
error: empty unicode escape (must have at least 1 hex digit)
|
||||
--> $DIR/lex-bad-char-literals-7.rs:5:20
|
||||
--> $DIR/lex-bad-char-literals-7.rs:4:20
|
||||
|
|
||||
LL | let _: char = '\u{}';
|
||||
| ^^^^
|
||||
|
||||
error: unterminated character literal
|
||||
--> $DIR/lex-bad-char-literals-7.rs:12:13
|
||||
--> $DIR/lex-bad-char-literals-7.rs:11:13
|
||||
|
|
||||
LL | let _ = ' hello // here's a comment
|
||||
| ^^^^^^^^
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
// ignore-tidy-cr
|
||||
|
||||
/// doc comment with bare CR: '
'
|
||||
|
|
|
|||
|
|
@ -1,41 +1,41 @@
|
|||
error: bare CR not allowed in doc-comment
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:5:32
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:3:32
|
||||
|
|
||||
LL | /// doc comment with bare CR: '
'
|
||||
| ^
|
||||
|
||||
error: bare CR not allowed in block doc-comment
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:9:38
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:7:38
|
||||
|
|
||||
LL | /** block doc comment with bare CR: '
' */
|
||||
| ^
|
||||
|
||||
error: bare CR not allowed in doc-comment
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:14:36
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:12:36
|
||||
|
|
||||
LL | //! doc comment with bare CR: '
'
|
||||
| ^
|
||||
|
||||
error: bare CR not allowed in block doc-comment
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:17:42
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:15:42
|
||||
|
|
||||
LL | /*! block doc comment with bare CR: '
' */
|
||||
| ^
|
||||
|
||||
error: bare CR not allowed in string, use \r instead
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:21:18
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:19:18
|
||||
|
|
||||
LL | let _s = "foo
bar";
|
||||
| ^
|
||||
|
||||
error: bare CR not allowed in raw string
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:24:19
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:22:19
|
||||
|
|
||||
LL | let _s = r"bar
foo";
|
||||
| ^
|
||||
|
||||
error: unknown character escape: \r
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:27:19
|
||||
--> $DIR/lex-bare-cr-string-literal-doc-comment.rs:25:19
|
||||
|
|
||||
LL | let _s = "foo\
bar";
|
||||
| ^ unknown character escape
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
// ignore-tidy-cr
|
||||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
pub fn main() {
|
||||
br"a
"; //~ ERROR bare CR not allowed in raw string
|
||||
br"é"; //~ ERROR raw byte string must be ASCII
|
||||
|
|
|
|||
|
|
@ -1,5 +1,3 @@
|
|||
// compile-flags: -Z continue-parse-after-error
|
||||
|
||||
struct Foo {
|
||||
x: isize,
|
||||
y: isize,
|
||||
|
|
|
|||
|
|
@ -1,17 +1,17 @@
|
|||
error: field expressions may not have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:13:10
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:11:10
|
||||
|
|
||||
LL | f.x::<isize>;
|
||||
| ^^^^^^^
|
||||
|
||||
error: field expressions may not have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:15:10
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:13:10
|
||||
|
|
||||
LL | f.x::<>;
|
||||
| ^^
|
||||
|
||||
error: field expressions may not have generic arguments
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:17:7
|
||||
--> $DIR/type-parameters-in-field-exprs.rs:15:7
|
||||
|
|
||||
LL | f.x::();
|
||||
| ^^^^^
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue