]> git.lizzy.rs Git - rust.git/commit
Parse and store suffixes on literals.
authorHuon Wilson <dbau.pp+github@gmail.com>
Wed, 19 Nov 2014 04:48:38 +0000 (15:48 +1100)
committerHuon Wilson <dbau.pp+github@gmail.com>
Wed, 19 Nov 2014 13:02:42 +0000 (00:02 +1100)
commit6679595853705ca11f64984a055be60233321a4a
tree5821ae6fb5779244f5aebfd3527b2ab3eca69219
parentff0278bc152c5e3072434615cf9861e98a160e71
Parse and store suffixes on literals.

This adds an optional suffix at the end of a literal token:
`"foo"bar`. An actual use of a suffix in a expression (or other literal
that the compiler reads) is rejected in the parser.

This doesn't switch the handling of numbers to this system, and doesn't
outlaw illegal suffixes for them yet.
src/librustdoc/html/highlight.rs
src/libsyntax/ast.rs
src/libsyntax/diagnostics/plugin.rs
src/libsyntax/ext/quote.rs
src/libsyntax/parse/lexer/mod.rs
src/libsyntax/parse/parser.rs
src/libsyntax/parse/token.rs
src/libsyntax/print/pprust.rs
src/test/compile-fail/bad-lit-suffixes.rs [new file with mode: 0644]