]> git.lizzy.rs Git - rust.git/blob - tests/ui/regex.stderr
Merge pull request #2393 from flip1995/regex
[rust.git] / tests / ui / regex.stderr
1 error: regex syntax error: empty alternate
2   --> $DIR/regex.rs:16:45
3    |
4 16 |     let pipe_in_wrong_position = Regex::new("|");
5    |                                             ^^^
6    |
7    = note: `-D invalid-regex` implied by `-D warnings`
8
9 error: regex syntax error: empty alternate
10   --> $DIR/regex.rs:17:60
11    |
12 17 |     let pipe_in_wrong_position_builder = RegexBuilder::new("|");
13    |                                                            ^^^
14
15 error: regex syntax error: invalid character class range
16   --> $DIR/regex.rs:18:40
17    |
18 18 |     let wrong_char_ranice = Regex::new("[z-a]");
19    |                                        ^^^^^^^
20
21 error: regex syntax error: invalid character class range
22   --> $DIR/regex.rs:19:35
23    |
24 19 |     let some_unicode = Regex::new("[é-è]");
25    |                                   ^^^^^^^
26
27 error: regex syntax error on position 0: unclosed parenthesis
28   --> $DIR/regex.rs:21:33
29    |
30 21 |     let some_regex = Regex::new(OPENING_PAREN);
31    |                                 ^^^^^^^^^^^^^
32
33 error: regex syntax error: empty alternate
34   --> $DIR/regex.rs:23:53
35    |
36 23 |     let binary_pipe_in_wrong_position = BRegex::new("|");
37    |                                                     ^^^
38
39 error: regex syntax error on position 0: unclosed parenthesis
40   --> $DIR/regex.rs:24:41
41    |
42 24 |     let some_binary_regex = BRegex::new(OPENING_PAREN);
43    |                                         ^^^^^^^^^^^^^
44
45 error: regex syntax error on position 0: unclosed parenthesis
46   --> $DIR/regex.rs:25:56
47    |
48 25 |     let some_binary_regex_builder = BRegexBuilder::new(OPENING_PAREN);
49    |                                                        ^^^^^^^^^^^^^
50
51 error: regex syntax error on position 0: unclosed parenthesis
52   --> $DIR/regex.rs:40:9
53    |
54 40 |         OPENING_PAREN,
55    |         ^^^^^^^^^^^^^
56
57 error: regex syntax error on position 0: unclosed parenthesis
58   --> $DIR/regex.rs:44:9
59    |
60 44 |         OPENING_PAREN,
61    |         ^^^^^^^^^^^^^
62
63 error: regex syntax error: unrecognized escape sequence
64   --> $DIR/regex.rs:48:45
65    |
66 48 |     let raw_string_error = Regex::new(r"[...//...]");
67    |                                             ^
68
69 error: regex syntax error: unrecognized escape sequence
70   --> $DIR/regex.rs:49:46
71    |
72 49 |     let raw_string_error = Regex::new(r#"[...//...]"#);
73    |                                              ^
74
75 error: trivial regex
76   --> $DIR/regex.rs:53:33
77    |
78 53 |     let trivial_eq = Regex::new("^foobar$");
79    |                                 ^^^^^^^^^^
80    |
81    = note: `-D trivial-regex` implied by `-D warnings`
82    = help: consider using consider using `==` on `str`s
83
84 error: trivial regex
85   --> $DIR/regex.rs:55:48
86    |
87 55 |     let trivial_eq_builder = RegexBuilder::new("^foobar$");
88    |                                                ^^^^^^^^^^
89    |
90    = help: consider using consider using `==` on `str`s
91
92 error: trivial regex
93   --> $DIR/regex.rs:57:42
94    |
95 57 |     let trivial_starts_with = Regex::new("^foobar");
96    |                                          ^^^^^^^^^
97    |
98    = help: consider using consider using `str::starts_with`
99
100 error: trivial regex
101   --> $DIR/regex.rs:59:40
102    |
103 59 |     let trivial_ends_with = Regex::new("foobar$");
104    |                                        ^^^^^^^^^
105    |
106    = help: consider using consider using `str::ends_with`
107
108 error: trivial regex
109   --> $DIR/regex.rs:61:39
110    |
111 61 |     let trivial_contains = Regex::new("foobar");
112    |                                       ^^^^^^^^
113    |
114    = help: consider using consider using `str::contains`
115
116 error: trivial regex
117   --> $DIR/regex.rs:63:39
118    |
119 63 |     let trivial_contains = Regex::new(NOT_A_REAL_REGEX);
120    |                                       ^^^^^^^^^^^^^^^^
121    |
122    = help: consider using consider using `str::contains`
123
124 error: trivial regex
125   --> $DIR/regex.rs:65:40
126    |
127 65 |     let trivial_backslash = Regex::new("a/.b");
128    |                                        ^^^^^^^
129    |
130    = help: consider using consider using `str::contains`
131
132 error: trivial regex
133   --> $DIR/regex.rs:68:36
134    |
135 68 |     let trivial_empty = Regex::new("");
136    |                                    ^^
137    |
138    = help: consider using the regex is unlikely to be useful as it is
139
140 error: trivial regex
141   --> $DIR/regex.rs:70:36
142    |
143 70 |     let trivial_empty = Regex::new("^");
144    |                                    ^^^
145    |
146    = help: consider using the regex is unlikely to be useful as it is
147
148 error: trivial regex
149   --> $DIR/regex.rs:72:36
150    |
151 72 |     let trivial_empty = Regex::new("^$");
152    |                                    ^^^^
153    |
154    = help: consider using consider using `str::is_empty`
155
156 error: trivial regex
157   --> $DIR/regex.rs:74:44
158    |
159 74 |     let binary_trivial_empty = BRegex::new("^$");
160    |                                            ^^^^
161    |
162    = help: consider using consider using `str::is_empty`
163
164 error: aborting due to 23 previous errors
165