diff options
| author | Richard Smith <richard-llvm@metafoo.co.uk> | 2014-02-28 20:06:02 +0000 |
|---|---|---|
| committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2014-02-28 20:06:02 +0000 |
| commit | 35ddad07232f0fd3b5ba637983ac8eb45e457b75 (patch) | |
| tree | a5ed8ce10aee986a995254a485b8a33f3008e933 /clang/test/Lexer/cxx1y_digit_separators.cpp | |
| parent | 3b0a866a4c646641cb9ecc290ebe60b4785ca741 (diff) | |
| download | bcm5719-llvm-35ddad07232f0fd3b5ba637983ac8eb45e457b75.tar.gz bcm5719-llvm-35ddad07232f0fd3b5ba637983ac8eb45e457b75.zip | |
Fix a minor bug in lexing pp-numbers with digit separators: if a pp-number contains "'e+", the pp-number ends between the 'e' and the '+'.
llvm-svn: 202533
Diffstat (limited to 'clang/test/Lexer/cxx1y_digit_separators.cpp')
| -rw-r--r-- | clang/test/Lexer/cxx1y_digit_separators.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/test/Lexer/cxx1y_digit_separators.cpp b/clang/test/Lexer/cxx1y_digit_separators.cpp index 39ea3e7b8d7..df0c2624616 100644 --- a/clang/test/Lexer/cxx1y_digit_separators.cpp +++ b/clang/test/Lexer/cxx1y_digit_separators.cpp @@ -18,6 +18,8 @@ namespace integral { int e = 0'b1010; // expected-error {{digit 'b' in octal constant}} int f = 0b'1010; // expected-error {{invalid digit 'b' in octal}} int g = 123'ms; // expected-error {{digit separator cannot appear at end of digit sequence}} + int h = 0x1e+1; // expected-error {{invalid suffix '+1' on integer constant}} + int i = 0x1'e+1; // ok, 'e+' is not recognized after a digit separator int z = 0'123'_foo; //'; // expected-error {{cannot appear at end of digit seq}} } |

