Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1d824a4

Browse files
committed
Kotlin: Add a test for truncated literals
1 parent 6c19409 commit 1d824a4

3 files changed

Lines changed: 29 additions & 0 deletions

File tree

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
| long_string.kt:12:31:12:1048605 | long_string.kt:12:31:12:1048605 | 1048575 | ABBBB...BBBBC | StringLiteral |
2+
| long_string.kt:13:31:13:1048606 | long_string.kt:13:31:13:1048606 | 1048576 | ABBBB...BBBCD | StringLiteral |
3+
| long_string.kt:14:31:14:1048607 | long_string.kt:14:31:14:1048607 | 1048576 | ABBBB...BBBCD | StringLiteral |
4+
| long_string.kt:15:31:15:1048608 | long_string.kt:15:31:15:1048608 | 1048576 | ABBBB...BBBCD | StringLiteral |
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
import java
2+
3+
from Literal l, int len
4+
where len = l.getValue().length()
5+
select l.getLocation(),
6+
len,
7+
l.getValue().prefix(5) + "..." + l.getValue().suffix(len - 5),
8+
l.getPrimaryQlClasses()

java/ql/test/kotlin/library-tests/trap/long_string.kt

Lines changed: 17 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)