aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Brook <paul@codesourcery.com>2004-02-18 11:02:23 +0000
committerPaul Brook <pbrook@gcc.gnu.org>2004-02-18 11:02:23 +0000
commitcdbafce1363a1dbda16e23accbd5af588c498b64 (patch)
tree0d3d7cef922fa5bd81d1f7ee5d378e3e85ef851d
parent5a0855a09136c8e2deef37cf06e61849a7286286 (diff)
downloadgcc-cdbafce1363a1dbda16e23accbd5af588c498b64.zip
gcc-cdbafce1363a1dbda16e23accbd5af588c498b64.tar.gz
gcc-cdbafce1363a1dbda16e23accbd5af588c498b64.tar.bz2
dwarf2out.c (loc_descriptor_from_tree): Handle EXPR_WITH_FILE_LOCATION.
* dwarf2out.c (loc_descriptor_from_tree): Handle EXPR_WITH_FILE_LOCATION. testsuite/ * gcc.dg/debug/debug-7.c: New test. From-SVN: r78017
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/dwarf2out.c3
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gcc.dg/debug/debug-7.c17
4 files changed, 29 insertions, 0 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 2092702..3aaa11b 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2004-02-18 Paul Brook <paul@codesourcery.com>
+
+ * dwarf2out.c (loc_descriptor_from_tree): Handle
+ EXPR_WITH_FILE_LOCATION.
+
2004-02-18 Jakub Jelinek <jakub@redhat.com>
* config/i386/i386.md (zero_extendqidi2, zero_extendqidi2,
diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c
index 91a4705..87f1be7 100644
--- a/gcc/dwarf2out.c
+++ b/gcc/dwarf2out.c
@@ -9001,6 +9001,9 @@ loc_descriptor_from_tree (tree loc, int addressp)
}
break;
+ case EXPR_WITH_FILE_LOCATION:
+ return loc_descriptor_from_tree (EXPR_WFL_NODE (loc), addressp);
+
default:
/* Leave front-end specific codes as simply unknown. This comes
up, for instance, with the C STMT_EXPR. */
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 52863b0..d77221a 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2004-02-18 Paul Brook <paul@codesourcery.com>
+
+ * gcc.dg/debug/debug-7.c: New test.
+
2004-02-17 Ulrich Weigand <uweigand@de.ibm.com>
* gcc.dg/20040217-1.c: New test.
diff --git a/gcc/testsuite/gcc.dg/debug/debug-7.c b/gcc/testsuite/gcc.dg/debug/debug-7.c
new file mode 100644
index 0000000..361bc4b
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/debug/debug-7.c
@@ -0,0 +1,17 @@
+/* { dg-do compile } */
+/* { dg-options "-dA" } */
+
+typedef __SIZE_TYPE__ size_t;
+
+static inline size_t foo (int n)
+{
+ return (n + sizeof (int) * 8 - 1) / (sizeof (int) * 8);
+}
+
+void bar (int, int *);
+
+void baz (int n)
+{
+ int a[foo (n)];
+ bar (n, a);
+}