aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/java-tree.h
diff options
context:
space:
mode:
authorPer Bothner <per@bothner.com>2004-09-29 19:16:00 -0700
committerPer Bothner <bothner@gcc.gnu.org>2004-09-29 19:16:00 -0700
commitd68acc044e8b214f490718612e1c2d1a122813eb (patch)
tree3fa17ee92a3bfa8794ed1b9bee93f0ebb4d2e19b /gcc/java/java-tree.h
parent7ce3fc8ffed7f487ea24b17a01ace93082787d5e (diff)
downloadgcc-d68acc044e8b214f490718612e1c2d1a122813eb.zip
gcc-d68acc044e8b214f490718612e1c2d1a122813eb.tar.gz
gcc-d68acc044e8b214f490718612e1c2d1a122813eb.tar.bz2
java-tree.h: Redefine some macros and add soem declaration to handle the USE_MAPPED_LOCATION...
* java-tree.h: Redefine some macros and add soem declaration to handle the USE_MAPPED_LOCATION case. * parse.h (EXPR_WFL_QUALIFICATION): Use operand 1, not 2. * java-tree.h (EXPR_WFL_FILENAME_NODE): Use operand 2, not 1. * java-tree.def (EXPR_WITH_FILE_LOCATION): Only need two operands in USE_MAPPED_LOCATION case, since EXPR_WFL_FILENAME_NODE is gone. From-SVN: r88323
Diffstat (limited to 'gcc/java/java-tree.h')
-rw-r--r--gcc/java/java-tree.h18
1 files changed, 14 insertions, 4 deletions
diff --git a/gcc/java/java-tree.h b/gcc/java/java-tree.h
index 1b707c6..7ecf091 100644
--- a/gcc/java/java-tree.h
+++ b/gcc/java/java-tree.h
@@ -1824,19 +1824,29 @@ enum
#undef EXPR_WFL_NODE
#define EXPR_WFL_NODE(NODE) \
TREE_OPERAND (EXPR_WITH_FILE_LOCATION_CHECK (NODE), 0)
+#ifdef USE_MAPPED_LOCATION
+#define EXPR_WFL_LINECOL(NODE) ((NODE)->exp.locus)
+#define EXPR_WFL_FILENAME(NODE) EXPR_FILENAME (NODE)
+#define EXPR_WFL_LINENO(NODE) EXPR_LINENO (NODE)
+extern tree build_expr_wfl PARAMS ((tree, source_location));
+extern tree expr_add_location PARAMS ((tree, source_location, bool));
+#define build_unknown_wfl(NODE) build_expr_wfl(NODE, UNKNOWN_LOCATION)
+#else
+#define EXPR_WFL_LINECOL(NODE) (EXPR_CHECK (NODE)->exp.complexity)
+#define EXPR_WFL_LINENO(NODE) (EXPR_WFL_LINECOL (NODE) >> 12)
+#define EXPR_WFL_COLNO(NODE) (EXPR_WFL_LINECOL (NODE) & 0xfff)
#undef EXPR_WFL_FILENAME_NODE
#define EXPR_WFL_FILENAME_NODE(NODE) \
- TREE_OPERAND (EXPR_WITH_FILE_LOCATION_CHECK (NODE), 1)
+ TREE_OPERAND (EXPR_WITH_FILE_LOCATION_CHECK (NODE), 2)
#define EXPR_WFL_FILENAME(NODE) \
IDENTIFIER_POINTER (EXPR_WFL_FILENAME_NODE (NODE))
/* ??? Java uses this in all expressions. */
-#define EXPR_WFL_LINECOL(NODE) (EXPR_CHECK (NODE)->exp.complexity)
-#define EXPR_WFL_LINENO(NODE) (EXPR_WFL_LINECOL (NODE) >> 12)
-#define EXPR_WFL_COLNO(NODE) (EXPR_WFL_LINECOL (NODE) & 0xfff)
#define EXPR_WFL_SET_LINECOL(NODE, LINE, COL) \
(EXPR_WFL_LINECOL(NODE) = ((LINE) << 12) | ((COL) & 0xfff))
extern tree build_expr_wfl PARAMS ((tree, const char *, int, int));
+#define build_unknown_wfl(NODE) build_expr_wfl(NODE, NULL, 0, 0)
+#endif
extern void java_genericize PARAMS ((tree));
extern int java_gimplify_expr PARAMS ((tree *, tree *, tree *));