Skip to content

Commit

Permalink
SI-6810 Test for CR
Browse files Browse the repository at this point in the history
  • Loading branch information
som-snytt committed Jun 29, 2015
1 parent d7547cb commit aad7c67
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
12 changes: 9 additions & 3 deletions test/files/neg/t6810.check
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,13 @@ t6810.scala:20: error: unclosed quoted identifier
t6810.scala:21: error: unclosed quoted identifier
` = EOL // not raw string literals aka triple-quoted, multiline strings
^
t6810.scala:22: error: '=' expected but '}' found.
}
t6810.scala:24: error: unclosed character literal
val b = '
^
t6810.scala:25: error: unclosed character literal
' // CR seen as EOL by scanner
^
t6810.scala:24: error: '=' expected but ';' found.
val b = '
^
7 errors found
9 errors found
4 changes: 4 additions & 0 deletions test/files/neg/t6810.scala
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,8 @@ trait t6810 {
val `\u000A` = EOL // backquoted identifiers are arbitrary string literals
val `
` = EOL // not raw string literals aka triple-quoted, multiline strings

val a = '\u000D' // similar treatment of CR
val b = '' // CR seen as EOL by scanner
val c = '\r' // traditionally
}
Expand Down

0 comments on commit aad7c67

Please sign in to comment.