diff options
| author | Ralf Jung <post@ralfj.de> | 2024-11-02 10:17:16 +0100 |
|---|---|---|
| committer | Ralf Jung <post@ralfj.de> | 2024-11-02 10:17:16 +0100 |
| commit | 0804815e69cd5e0428c087b5191f7f3f34d9122b (patch) | |
| tree | 5e605983272fa584e1e1ff4143f9e81a4a3d11f8 /src | |
| parent | b5f4883a06f1d861b108ac892f07f4fa37eb1bed (diff) | |
| download | rust-0804815e69cd5e0428c087b5191f7f3f34d9122b.tar.gz rust-0804815e69cd5e0428c087b5191f7f3f34d9122b.zip | |
make char::is_whitespace unstably const
Diffstat (limited to 'src')
| -rw-r--r-- | src/tools/unicode-table-generator/src/cascading_map.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tools/unicode-table-generator/src/cascading_map.rs b/src/tools/unicode-table-generator/src/cascading_map.rs index 036f0bd7eac..1eb35e819c0 100644 --- a/src/tools/unicode-table-generator/src/cascading_map.rs +++ b/src/tools/unicode-table-generator/src/cascading_map.rs @@ -65,7 +65,7 @@ impl RawEmitter { self.bytes_used += 256; writeln!(&mut self.file, "#[inline]").unwrap(); - writeln!(&mut self.file, "pub fn lookup(c: char) -> bool {{").unwrap(); + writeln!(&mut self.file, "pub const fn lookup(c: char) -> bool {{").unwrap(); writeln!(&mut self.file, " match c as u32 >> 8 {{").unwrap(); for arm in arms { writeln!(&mut self.file, " {},", arm).unwrap(); |
