aboutsummaryrefslogtreecommitdiff
path: root/gcc/java/parse.y
diff options
context:
space:
mode:
authorKaveh R. Ghazi <ghazi@caip.rutgers.edu>2001-03-28 19:31:43 +0000
committerKaveh Ghazi <ghazi@gcc.gnu.org>2001-03-28 19:31:43 +0000
commit80122075e36b7c504e81c22358af690ec7218f48 (patch)
treee23785d4eee463f83a1239e37d4b84c198cf1fcf /gcc/java/parse.y
parent3fdefbcc63ada60e2d6bca1dc5581f1cd3716ec1 (diff)
downloadgcc-80122075e36b7c504e81c22358af690ec7218f48.zip
gcc-80122075e36b7c504e81c22358af690ec7218f48.tar.gz
gcc-80122075e36b7c504e81c22358af690ec7218f48.tar.bz2
expr.c (pop_type_0): Call `concat' rather than building the string manually.
* expr.c (pop_type_0): Call `concat' rather than building the string manually. (pop_type): Add format specifier in call to `error'. * parse.y (patch_method_invocation): Avoid casting away const-ness. From-SVN: r40940
Diffstat (limited to 'gcc/java/parse.y')
-rw-r--r--gcc/java/parse.y15
1 files changed, 9 insertions, 6 deletions
diff --git a/gcc/java/parse.y b/gcc/java/parse.y
index 04c9e90..6df483e 100644
--- a/gcc/java/parse.y
+++ b/gcc/java/parse.y
@@ -9963,12 +9963,15 @@ patch_method_invocation (patch, primary, where, from_super,
/* Calls to clone() on array types are permitted as a special-case. */
&& !is_array_clone_call)
{
- char *fct_name = (char *) IDENTIFIER_POINTER (DECL_NAME (list));
- char *access = java_accstring_lookup (get_access_flags_from_decl (list));
- char *klass = (char *) IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (DECL_CONTEXT (list))));
- char *refklass = (char *) IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (current_class)));
- char *what = (char *) (DECL_CONSTRUCTOR_P (list)
- ? "constructor" : "method");
+ const char *fct_name = IDENTIFIER_POINTER (DECL_NAME (list));
+ const char *access =
+ java_accstring_lookup (get_access_flags_from_decl (list));
+ const char *klass =
+ IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (DECL_CONTEXT (list))));
+ const char *refklass =
+ IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (current_class)));
+ const char *what = (DECL_CONSTRUCTOR_P (list)
+ ? "constructor" : "method");
/* FIXME: WFL yields the wrong message here but I don't know
what else to use. */
parse_error_context (wfl,