summaryrefslogtreecommitdiff
path: root/gcc/java
diff options
context:
space:
mode:
authorghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4>2001-03-26 02:26:09 +0000
committerghazi <ghazi@138bc75d-0d04-0410-961f-82ee72b054a4>2001-03-26 02:26:09 +0000
commit443b1b77fb626409914cf641a8e34e7740a048cc (patch)
tree1d29c7017bbff47e9722e9b0b853769c29366d8e /gcc/java
parentf702522a4b9deb5a774b5a8816ae4866a0d80be4 (diff)
downloadgcc-443b1b77fb626409914cf641a8e34e7740a048cc.tar.gz
* constants.c (PUTN): Use memcpy, not bcopy.
* lex.c (java_read_char): Use memmove, not bcopy. * parse.y (java_parser_context_resume): Use memcpy, not bcopy. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@40836 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/java')
-rw-r--r--gcc/java/ChangeLog8
-rw-r--r--gcc/java/constants.c2
-rw-r--r--gcc/java/lex.c6
-rw-r--r--gcc/java/parse.y4
4 files changed, 13 insertions, 7 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog
index 8104fe84295..a7ffcea9abd 100644
--- a/gcc/java/ChangeLog
+++ b/gcc/java/ChangeLog
@@ -1,3 +1,11 @@
+2001-03-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * constants.c (PUTN): Use memcpy, not bcopy.
+
+ * lex.c (java_read_char): Use memmove, not bcopy.
+
+ * parse.y (java_parser_context_resume): Use memcpy, not bcopy.
+
2001-03-23 Per Bothner <per@bothner.com>
* verify.c (verify_jvm_instructions): Replace 3 pop_type by POP_TYPE
diff --git a/gcc/java/constants.c b/gcc/java/constants.c
index 0dcd715b2d9..59b8c4f16c4 100644
--- a/gcc/java/constants.c
+++ b/gcc/java/constants.c
@@ -214,7 +214,7 @@ find_methodref_index (cpool, decl)
#define PUT1(X) (*ptr++ = (X))
#define PUT2(X) (PUT1((X) >> 8), PUT1(X))
#define PUT4(X) (PUT2((X) >> 16), PUT2(X))
-#define PUTN(P, N) (bcopy(P, ptr, N), ptr += (N))
+#define PUTN(P, N) (memcpy(ptr, (P), (N)), ptr += (N))
/* Give the number of bytes needed in a .class file for the CPOOL
constant pool. Includes the 2-byte constant_pool_count. */
diff --git a/gcc/java/lex.c b/gcc/java/lex.c
index f66ed579d07..0bf6d7a1ff5 100644
--- a/gcc/java/lex.c
+++ b/gcc/java/lex.c
@@ -417,10 +417,8 @@ java_read_char (lex)
is in the middle of a character sequence. We just
move the valid part of the buffer to the beginning
to force a read. */
- /* We use bcopy() because it should work for
- overlapping strings. Use memmove() instead... */
- bcopy (&lex->buffer[lex->first], &lex->buffer[0],
- lex->last - lex->first);
+ memmove (&lex->buffer[0], &lex->buffer[lex->first],
+ lex->last - lex->first);
lex->last -= lex->first;
lex->first = 0;
}
diff --git a/gcc/java/parse.y b/gcc/java/parse.y
index 461e6c4e197..782a6536504 100644
--- a/gcc/java/parse.y
+++ b/gcc/java/parse.y
@@ -2783,8 +2783,8 @@ java_parser_context_resume ()
ctxp = restored;
/* Re-installed the data for the parsing to carry on */
- bcopy (&old->marker_begining, &ctxp->marker_begining,
- (size_t)(&ctxp->marker_end - &ctxp->marker_begining));
+ memcpy (&ctxp->marker_begining, &old->marker_begining,
+ (size_t)(&ctxp->marker_end - &ctxp->marker_begining));
/* Buffer context can now be discarded */
free (saver);