• Brad King's avatar
    Add \-continuation to CMake language quoted arguments · efcf318f
    Brad King authored
    Teach the CMake language lexer to treat the \-LF pair terminating a
    line ending in an odd number of backslashes inside a quoted argument
    as a continuation.  Drop the pair from the returned quoted argument
    token text.  This will allow long lines inside quoted argument
    strings to be divided across multiple lines in the source file.
    It will also allow quoted argument text to start on the line after
    the opening quote.  For example, the code:
    
     set(x "\
     ...")
    
    sets variable "x" to the value "..." with no opening newline.
    
    Previously an odd number of backslashes at the end of a line inside
    a quoted argument would put a \-LF pair (or a \-CR pair) literally
    in the argument.  Then the command-argument evaluator would complain
    that the \-escape sequence is invalid.  Therefore this syntax is
    available to use without changing behavior of valid existing code.
    
    Teach the RunCMake.Syntax test to cover cases of quoted arguments
    with lines ending in \, \\, and \\\.  Odd counts are continuations.
    efcf318f
Name
Last commit
Last update
..
.gitattributes Loading commit data...
BOM-UTF-16-BE-result.txt Loading commit data...
BOM-UTF-16-BE-stderr.txt Loading commit data...
BOM-UTF-16-BE.cmake Loading commit data...
BOM-UTF-16-LE-result.txt Loading commit data...
BOM-UTF-16-LE-stderr.txt Loading commit data...
BOM-UTF-16-LE.cmake Loading commit data...
BOM-UTF-32-BE-result.txt Loading commit data...
BOM-UTF-32-BE-stderr.txt Loading commit data...
BOM-UTF-32-BE.cmake Loading commit data...
BOM-UTF-32-LE-result.txt Loading commit data...
BOM-UTF-32-LE-stderr.txt Loading commit data...
BOM-UTF-32-LE.cmake Loading commit data...
BOM-UTF-8-stdout.txt Loading commit data...
BOM-UTF-8.cmake Loading commit data...
Bracket0-stderr.txt Loading commit data...
Bracket0.cmake Loading commit data...
Bracket1-stderr.txt Loading commit data...
Bracket1.cmake Loading commit data...
Bracket2-stdout.txt Loading commit data...
Bracket2.cmake Loading commit data...
BracketBackslash-result.txt Loading commit data...
BracketBackslash-stderr.txt Loading commit data...
BracketBackslash.cmake Loading commit data...
BracketCRLF-stderr.txt Loading commit data...
BracketCRLF.cmake Loading commit data...
BracketComment0-stdout.txt Loading commit data...
BracketComment0.cmake Loading commit data...
BracketComment1-result.txt Loading commit data...
BracketComment1-stderr.txt Loading commit data...
BracketComment1.cmake Loading commit data...
BracketComment2-result.txt Loading commit data...
BracketComment2-stderr.txt Loading commit data...
BracketComment2.cmake Loading commit data...
BracketComment3-stdout.txt Loading commit data...
BracketComment3.cmake Loading commit data...
BracketComment4-result.txt Loading commit data...
BracketComment4-stderr.txt Loading commit data...
BracketComment4.cmake Loading commit data...
BracketComment5-stdout.txt Loading commit data...
BracketComment5.cmake Loading commit data...
BracketNoSpace0-result.txt Loading commit data...
BracketNoSpace0-stderr.txt Loading commit data...
BracketNoSpace0.cmake Loading commit data...
BracketNoSpace1-result.txt Loading commit data...
BracketNoSpace1-stderr.txt Loading commit data...
BracketNoSpace1.cmake Loading commit data...
BracketNoSpace2-result.txt Loading commit data...
BracketNoSpace2-stderr.txt Loading commit data...
BracketNoSpace2.cmake Loading commit data...
BracketNoSpace3-result.txt Loading commit data...
BracketNoSpace3-stderr.txt Loading commit data...
BracketNoSpace3.cmake Loading commit data...
BracketNoSpace4-result.txt Loading commit data...
BracketNoSpace4-stderr.txt Loading commit data...
BracketNoSpace4.cmake Loading commit data...
BracketNoSpace5-result.txt Loading commit data...
BracketNoSpace5-stderr.txt Loading commit data...
BracketNoSpace5.cmake Loading commit data...
CMakeLists.txt Loading commit data...
CommandComments-stderr.txt Loading commit data...
CommandComments.cmake Loading commit data...
CommandError0-result.txt Loading commit data...
CommandError0-stderr.txt Loading commit data...
CommandError0.cmake Loading commit data...
CommandError1-result.txt Loading commit data...
CommandError1-stderr.txt Loading commit data...
CommandError1.cmake Loading commit data...
CommandError2-result.txt Loading commit data...
CommandError2-stderr.txt Loading commit data...
CommandError2.cmake Loading commit data...
CommandNewlines-stderr.txt Loading commit data...
CommandNewlines.cmake Loading commit data...
CommandSpaces-stderr.txt Loading commit data...
CommandSpaces.cmake Loading commit data...
CommandTabs-stderr.txt Loading commit data...
CommandTabs.cmake Loading commit data...
OneLetter-stderr.txt Loading commit data...
OneLetter.cmake Loading commit data...
ParenNoSpace0-stdout.txt Loading commit data...
ParenNoSpace0.cmake Loading commit data...
ParenNoSpace1-result.txt Loading commit data...
ParenNoSpace1-stderr.txt Loading commit data...
ParenNoSpace1.cmake Loading commit data...
ParenNoSpace2-stderr.txt Loading commit data...
ParenNoSpace2-stdout.txt Loading commit data...
ParenNoSpace2.cmake Loading commit data...
RunCMakeTest.cmake Loading commit data...
String0-stderr.txt Loading commit data...
String0.cmake Loading commit data...
String1-stderr.txt Loading commit data...
String1.cmake Loading commit data...
StringBackslash-result.txt Loading commit data...
StringBackslash-stderr.txt Loading commit data...
StringBackslash.cmake Loading commit data...
StringCRLF-stderr.txt Loading commit data...
StringCRLF.cmake Loading commit data...
StringContinuation1-result.txt Loading commit data...
StringContinuation1-stderr.txt Loading commit data...
StringContinuation1.cmake Loading commit data...
StringContinuation2-result.txt Loading commit data...
StringContinuation2-stderr.txt Loading commit data...
StringContinuation2.cmake Loading commit data...
StringNoSpace-stderr.txt Loading commit data...
StringNoSpace.cmake Loading commit data...
Unquoted0-stderr.txt Loading commit data...
Unquoted0.cmake Loading commit data...
Unquoted1-stderr.txt Loading commit data...
Unquoted1.cmake Loading commit data...
UnterminatedBracket0-result.txt Loading commit data...
UnterminatedBracket0-stderr.txt Loading commit data...
UnterminatedBracket0.cmake Loading commit data...
UnterminatedBracket1-result.txt Loading commit data...
UnterminatedBracket1-stderr.txt Loading commit data...
UnterminatedBracket1.cmake Loading commit data...
UnterminatedBracketComment-result.txt Loading commit data...
UnterminatedBracketComment-stderr.txt Loading commit data...
UnterminatedBracketComment.cmake Loading commit data...
UnterminatedCall1-result.txt Loading commit data...
UnterminatedCall1-stderr.txt Loading commit data...
UnterminatedCall1.cmake Loading commit data...
UnterminatedCall2-result.txt Loading commit data...
UnterminatedCall2-stderr.txt Loading commit data...
UnterminatedCall2.cmake Loading commit data...
UnterminatedString-result.txt Loading commit data...
UnterminatedString-stderr.txt Loading commit data...
UnterminatedString.cmake Loading commit data...