diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-07-20 16:25:35 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2022-07-21 14:27:23 +0200 |
commit | 37dc6cc5ab804da964f22787561d030898115809 (patch) | |
tree | b8d0acd2fcc8f0c2c51b2d76a4d1e5d942143a2b /tests/test/cpp/util.scm | |
parent | Cleanup in lex2 test. (diff) | |
download | calp-37dc6cc5ab804da964f22787561d030898115809.tar.gz calp-37dc6cc5ab804da964f22787561d030898115809.tar.xz |
Acknowledge string prefixes.
Diffstat (limited to 'tests/test/cpp/util.scm')
-rw-r--r-- | tests/test/cpp/util.scm | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/test/cpp/util.scm b/tests/test/cpp/util.scm new file mode 100644 index 00000000..8329294a --- /dev/null +++ b/tests/test/cpp/util.scm @@ -0,0 +1,14 @@ +(define-module (test cpp util) + :use-module (srfi srfi-64) + :use-module (srfi srfi-88) + :use-module (c cpp-util) + :use-module ((c lex2) :select (lex lexeme))) + +(test-group "Merge string literals" + (test-equal "To simple strings" + (list (lexeme type: 'preprocessing-token + body: '(string-literal (encoding-prefix) "Hello" "World"))) + (merge-string-literals (lex "\"Hello\"\"World\""))) + + ;; TODO tests with prefixes + ) |