Esteban Küber
c0b134582a
Lint against RTL unicode codepoints in literals and comments
...
Address CVE-2021-42574.
2021-10-31 13:14:04 +01:00
Fabian Wolff
f2c9654dcd
Suggest br
if the unknown string prefix rb
is found
2021-07-31 15:37:36 +02:00
Ryan Levick
d4e384bc1d
rename rust_2021_token_prefixes to rust_2021_prefixes_incompatible_syntax
2021-07-06 20:13:36 +02:00
Ryan Levick
81c11a212e
rust_2021_token_prefixes
2021-07-06 20:13:16 +02:00
Ryan Levick
6c87772e3c
Rename reserved_prefix lint to reserved_prefixes
2021-07-06 20:12:55 +02:00
Mara Bos
7490305e13
No reserved_prefix suggestion in proc macro call_site.
2021-06-26 23:11:14 +08:00
Mara Bos
0eeeebc990
Rename 'bad prefix' to 'unknown prefix'.
2021-06-26 23:11:14 +08:00
Mara Bos
d40be0fc64
Check the span's edition for the reserved prefixes.
2021-06-26 23:11:13 +08:00
Mara Bos
6adce70a58
Improve comments for reserved prefixes.
...
Co-authored-by: Niko Matsakis <niko@alum.mit.edu>
2021-06-26 23:11:13 +08:00
Mara Bos
d837c00d10
Add migration lint for reserved prefixes.
2021-06-26 23:11:04 +08:00
Mara Bos
ce43fc9404
Fix note in reserved prefix error.
2021-06-26 23:09:43 +08:00
Mara Bos
c856e6fa53
Add machine applicable suggestion to unknown prefix error.
2021-06-26 23:09:43 +08:00
lrh2000
8dee9bc8fc
Reserve prefixed identifiers and string literals (RFC 3101)
...
This commit denies any identifiers immediately followed by
one of three tokens `"`, `'` or `#`, which is stricter than
the requirements of RFC 3101 but may be necessary according
to the discussion at [Zulip].
[Zulip]: 238470099
2021-06-26 23:09:43 +08:00
Joshua Nelson
96509b4835
Make Diagnostic::span_fatal
unconditionally raise an error
...
It had no callers which didn't immediately call `raise()`, and this
unifies the behavior with `Session`.
2021-05-08 23:12:04 -04:00
Joshua Nelson
e49f4471aa
Remove some unnecessary uses of struct_span_fatal
...
All of them immediately called `emit()` then `raise()`, so they could
just call `span_fatal` directly.
2021-05-08 23:12:04 -04:00
pierwill
0019ca9141
Fix outdated crate names in compiler docs
...
Changes `librustc_X` to `rustc_X`, only in documentation comments.
Plain code comments are left unchanged.
Also fix incorrect file paths.
2021-04-08 11:12:14 -05:00
Smitty
c6cb014ad6
Clarify error message wording
2021-02-07 11:02:53 -05:00
Smitty
651d289405
Add note about encoding when null bytes found
2021-02-06 19:17:14 -05:00
Esteban Küber
3b5d018ebb
Handle Span
s for byte and raw strings and add more detail
2021-02-03 13:34:28 -08:00
Nicolas
7be6d67f82
Fix typo in doc comment for report_too_many_hashes
...
"to big" -> "too big"
2020-11-22 07:02:58 -03:00
Guillaume Gomez
99200f760b
Fix even more URLs
2020-11-05 20:11:29 +01:00
Aleksey Kladov
ccf41dd5eb
Rename IsJoint -> Spacing
...
To match better naming from proc-macro
2020-09-03 17:32:45 +02:00
Aleksey Kladov
4231fbc0a8
Condense StringReader's API to a single function
2020-09-03 15:52:15 +02:00
Aleksey Kladov
8f24c2ec9d
Don't emit trivia tokens
2020-09-01 11:39:11 +02:00
Aleksey Kladov
30ce15f1fa
Make StringReader private
...
After the recent refactorings, we can actually completely hide this
type. It should help with #63689 .
2020-08-31 18:01:01 +02:00
Aleksey Kladov
518cac9190
Remove unused function
2020-08-30 19:54:45 +02:00
mark
9e5f7d5631
mv compiler to compiler/
2020-08-30 18:45:07 +03:00