diff options
author | Tom Tromey <tromey@redhat.com> | 2008-10-22 16:38:09 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2008-10-22 16:38:09 +0000 |
commit | c209f8472e7d7ea6abb109945f2c53a0b9a92d53 (patch) | |
tree | ee74641df441de6fa951f19d69b25b7037455f3c /gdb/testsuite/gdb.base/exprs.exp | |
parent | 4267b19fc71aba8dafa490b9d71b90ef013f5cd9 (diff) | |
download | gdb-c209f8472e7d7ea6abb109945f2c53a0b9a92d53.zip gdb-c209f8472e7d7ea6abb109945f2c53a0b9a92d53.tar.gz gdb-c209f8472e7d7ea6abb109945f2c53a0b9a92d53.tar.bz2 |
gdb
PR gdb/2506:
* c-exp.y (string_exp): New production.
(exp): Use it.
gdb/testsuite
* gdb.base/exprs.exp (test_expr): Add test for string
concatenation.
Diffstat (limited to 'gdb/testsuite/gdb.base/exprs.exp')
-rw-r--r-- | gdb/testsuite/gdb.base/exprs.exp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gdb/testsuite/gdb.base/exprs.exp b/gdb/testsuite/gdb.base/exprs.exp index e25de77..484b5a4 100644 --- a/gdb/testsuite/gdb.base/exprs.exp +++ b/gdb/testsuite/gdb.base/exprs.exp @@ -248,3 +248,7 @@ gdb_test "print (void*) ((long long) (unsigned long) -1 + 1)" \ if [expr ! $ok] { setup_xfail "*-*-*" } gdb_test "print (void*) (~((long long)(unsigned long) -1) - 1)" \ "warning: value truncated.*" "truncate (void*) 0xffffffff00000000 - 1" + +# String concatentation. +test_expr "print \"x\" \"y\"" "\\$\[0-9\]* = \"xy\"" +test_expr "print \"x\" \"y\" \"z\"" "\\$\[0-9\]* = \"xyz\"" |