+2001-12-16 Joseph S. Myers <jsm28@cam.ac.uk>
+
+ * ChangeLog, Make-lang.in, class.c, expr.c, gcj.texi, java-tree.h,
+ jcf-parse.c, jcf-write.c, lex.c, parse.h, parse.y, verify.c: Fix
+ spelling errors.
+
2001-12-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* lex.c (java_read_unicode, java_lex): Use hex_p/hex_value.
* class.c (build_method_symbols_entry): New function.
(make_method_value): Set "index" to to method's vtable index for
virtual methods when indirect-dispatch is not used.
- (make_class_data): For indirect-dispatch, dont emit the dtable_decl,
+ (make_class_data): For indirect-dispatch, don't emit the dtable_decl,
and set vtable_method_count to -1. Set otable and otable_syms field
if indirect-dispatch is used and there was something to put in them.
(build_method_symbols_entry): New function.
* jvgenmain.c (main_method_prefix): Global variable removed.
(main_method_suffix): Likewise.
(do_mangle_classname): New function.
- (main): Call it. Format changed to accomodate new mangling scheme.
+ (main): Call it. Format changed to accommodate new mangling scheme.
* lex.c: (utf8_cmp): Conditionally prototyped.
(cxx_keywords): Moved from class.c, conditionally defined.
(utf8_cmp, cxx_keyword_p): Likewise.
* jcf-parse.c (get_constant): Don't mess with obstacks.
(read_class): Likewise.
(jcf_parse): Likewise.
- * lex.c (expresion_obstack): Remove.
+ * lex.c (expression_obstack): Remove.
(java_lex): Don't use obstack_free.
* parse.h (exit_java_complete_class): Don't mess with obstacks.
(MANGLE_OUTER_LOCAL_VARIABLE_NAME): Adjust.
(add_inner_class_fields): Adjust calls to MANGLE_* macros.
(lookup_field_wrapper): Likewise.
(obtain_incomplete_type): Don't mess with obstacks.
- (build_alias_initializer_paramter_list): Adjust calls to MANGLE_*
+ (build_alias_initializer_parameter_list): Adjust calls to MANGLE_*
macros.
(craft_constructor): Don't mess with obstacks.
(safe_layout_class): Likewise.
entering the function. `fprintf' format modified not to use
INNER_QUALIFIER.
(report_class_declaration): Assign `package_name' and
- `current_class' to NULL separatly.
+ `current_class' to NULL separately.
2000-07-31 Alexandre Petit-Bianco <apbianco@cygnus.com>
(maybe_make_nested_class_name): Mark nested class name as
qualified when necessary.
(end_class_declaration): Don't call java_parse_context_resume when
- one or more error occured.
+ one or more error occurred.
(add_inner_class_fields): Use SET_CPC_INITIALIZER_STMT.
(register_fields): Use SET_CPC_STATIC_INITIALIZER_STMT and
SET_CPC_INITIALIZER_STMT.
* parse.y (outer_field_access_fix): First parameter now a tree
node. Check for assignement to final. First argument to
- build_outer_field_access_fix modified to accomodate prototype.
+ build_outer_field_access_fix modified to accommodate prototype.
(build_outer_field_access): Don't check for assignment to final
here.
(java_complete_lhs): MODIFY_EXPR case: Check for `error_mark_node'
Tue Nov 30 12:36:15 1999 Anthony Green <green@cygnus.com>
* verify.c (verify_jvm_instructions): Create new return label
- chain if non existant (don't rely on the verified state of the jsr
+ chain if non existent (don't rely on the verified state of the jsr
target.)
Tue Nov 30 12:28:34 1999 Alexandre Petit-Bianco <apbianco@cygnus.com>
(yyerror): New static elc. Removed static error_line, error_pos.
New local code_from_source. Save ctxp->elc into elc at the first
pass. Call java_get_line_col to get a string of the line where
- the error occured.
+ the error occurred.
(debug_line): Removed static function.
(parse_error_context, parse_warning_context): Parameter cl is now
a WFL node. Use its value to initialize ctxp->elc.
* java-tree.h (PUSH_FIELD): Set DECL_ARTIFICIAL.
* class.c (make_class_data): Don't build fields_decl if no fields.
- When building fields_decl, skip if DECL_ARTIFICAL.
+ When building fields_decl, skip if DECL_ARTIFICIAL.
* expr.c (java_stack_swap): Update stack_type_map.
* verify.c (merge_types): Handle array types better.
* java-opcodes.h: Use javaop.def to avoid duplicated list.
* javaop.def: Rename invokevirt -> invokevirtual.
* lang.c (use_handles): Removed.
- * parse.c: Add support for ConstantValue atribute.
+ * parse.c: Add support for ConstantValue attribute.
Handle nested loading of a class. (JPOOL_UTF): New.
Tue Mar 11 20:11:05 1997 Per Bothner <bothner@deneb.cygnus.com>
java: jc1$(exeext) $(GCJ)$(exeext) jvgenmain$(exeext) \
gcjh$(exeext) jv-scan$(exeext) jcf-dump$(exeext)
-# Define the name of target independant tools to be installed in $(bindir)
+# Define the name of target independent tools to be installed in $(bindir)
# Names are subject to changes
JAVA_TARGET_INDEPENDENT_BIN_TOOLS = gcjh jv-scan jcf-dump
signature = identifier_subst (class_name, "L", '.', '/', ";");
IDENTIFIER_SIGNATURE_TYPE (signature) = build_pointer_type (class_type);
- /* Setting DECL_ARTIFICAL forces dbxout.c to specific the type is
+ /* Setting DECL_ARTIFICIAL forces dbxout.c to specific the type is
both a typedef and in the struct name-space. We may want to re-visit
this later, but for now it reduces the changes needed for gdb. */
DECL_ARTIFICIAL (decl) = 1;
if (field == NULL_TREE)
warning ("misplaced ConstantValue attribute (not in any field)");
else if (DECL_INITIAL (field) != NULL_TREE)
- warning ("duplicate ConstanValue atribute for field '%s'",
+ warning ("duplicate ConstantValue attribute for field '%s'",
IDENTIFIER_POINTER (DECL_NAME (field)));
else
{
}
/* Do the expansion of a Java switch. With Gcc, switches are front-end
- dependant things, but they rely on gcc routines. This function is
+ dependent things, but they rely on gcc routines. This function is
placed here because it uses things defined locally in parse.y. */
static tree
attribute @code{gnu.gcj.gcj-compiled}. The compiler looks for this
attribute when loading @code{java.lang.Object} and will report an error
if it isn't found, unless it compiles to bytecode (the option
-@code{-fforce-classes-archive-check} can be used to overide this
+@code{-fforce-classes-archive-check} can be used to override this
behavior in this particular case.)
@table @gcctabopt
#define ID_INIT_P(ID) ((ID) == init_identifier_node)
/* Match ID to either `$finit$' or `finit$', so that `$finit$'
continues to be recognized as an equivalent to `finit$' which is
- now the prefered name used for the field initialization special
+ now the preferred name used for the field initialization special
method. */
#define ID_FINIT_P(ID) ((ID) == finit_identifier_node \
|| (ID) == finit_leg_identifier_node)
#define BCODE_JUMP_TARGET 2
/* True iff there is a return to this location.
- (I.e. the preceedng instruction was a call.) */
+ (I.e. the preceding instruction was a call.) */
#define BCODE_RETURN_TARGET 4
/* True iff this is the start of an exception handler. */
TYPE_LANG_FLAG_5 (TYPE)
/* True if class TYPE is currently being laid out. Helps in detection
- of inheritance cycle occuring as a side effect of performing the
+ of inheritance cycle occurring as a side effect of performing the
layout of a class. */
#define CLASS_BEING_LAIDOUT(TYPE) TYPE_LANG_FLAG_6 (TYPE)
/* True if class TYPE is currently being laid out. Helps in detection
- of inheritance cycle occuring as a side effect of performing the
+ of inheritance cycle occurring as a side effect of performing the
layout of a class. */
#define CLASS_BEING_LAIDOUT(TYPE) TYPE_LANG_FLAG_6 (TYPE)
class_name_in_zip_dir = ZIPDIR_FILENAME (zdir);
/* We choose to not to process entries with a zero size or entries
- not bearing the .class extention. */
+ not bearing the .class extension. */
if (!zdir->size || !zdir->filename_offset ||
strncmp (&class_name_in_zip_dir[zdir->filename_length-6],
".class", 6))
to the beginning of the block.
If (pc < 0), the jcf_block is not an actual block (i.e. it has no
- assocated code yet), but it is an undefined label.
+ associated code yet), but it is an undefined label.
*/
struct jcf_block
/* new_ptr and old_ptr point into the old and new buffers,
respectively. (If no relocations cause the buffer to
grow, the buffer will be the same buffer, and new_ptr==old_ptr.)
- The bytes at higher adress have been copied and relocations
+ The bytes at higher address have been copied and relocations
handled; those at lower addresses remain to process. */
/* Lower old index of piece to be copied with no relocation.
/* This is called by the parser to see if an error should be generated
due to numeric overflow. This function only handles the particular
case of the largest negative value, and is only called in the case
- where this value is not preceeded by `-'. */
+ where this value is not preceded by `-'. */
static void
error_if_numeric_overflow (value)
tree value;
}
/* Build the string parm$<O> and store in into the identifier N. This
- is used to contruct the name of hidden parameters used to
+ is used to construct the name of hidden parameters used to
initialize outer scope aliases. */
#define MANGLE_ALIAS_INITIALIZER_PARAMETER_NAME_ID(N, O) \
{ \
switch_block
{
/* Make into "proper list" of COMPOUND_EXPRs.
- I.e. make the last statment also have its own
+ I.e. make the last statement also have its own
COMPOUND_EXPR. */
maybe_absorb_scoping_blocks ();
TREE_OPERAND ($1, 1) = exit_block ();
if ((flags & ACC_ABSTRACT) && flag_redundant)
parse_warning_context
(MODIFIER_WFL (ABSTRACT_TK),
- "Redundant use of `abstract' modifier. Interface `%s' is implicitely abstract", IDENTIFIER_POINTER (raw_name));
+ "Redundant use of `abstract' modifier. Interface `%s' is implicitly abstract", IDENTIFIER_POINTER (raw_name));
/* Create a new decl if DECL is NULL, otherwise fix it */
decl = maybe_create_class_interface_decl (decl, raw_name, q_name, id);
end_class_declaration (resume)
int resume;
{
- /* If an error occured, context weren't pushed and won't need to be
+ /* If an error occurred, context weren't pushed and won't need to be
popped by a resume. */
- int no_error_occured = ctxp->next && GET_CPC () != error_mark_node;
+ int no_error_occurred = ctxp->next && GET_CPC () != error_mark_node;
java_parser_context_pop_initialized_field ();
POP_CPC ();
- if (resume && no_error_occured)
+ if (resume && no_error_occurred)
java_parser_context_resume ();
/* We're ending a class declaration, this is a good time to reset
tree mdecl = JDEP_DECL (dep), signature;
/* Recompute and reset the signature, check first that
all types are now defined. If they're not,
- dont build the signature. */
+ don't build the signature. */
if (check_method_types_complete (mdecl))
{
signature = build_java_signature (TREE_TYPE (mdecl));
}
/* Check all the methods of CLASS_DECL. Methods are first completed
- then checked according to regular method existance rules. If no
+ then checked according to regular method existence rules. If no
constructor for CLASS_DECL were encountered, then build its
declaration. */
}
/* Possibly find a type in the import on demands specified
- types. Returns 1 if an error occured, 0 otherwise. Run throught the
+ types. Returns 1 if an error occurred, 0 otherwise. Run through the
entire list, to detected potential double definitions. */
static int
return mdecl;
}
-/* Starts the body if an artifical method. */
+/* Starts the body if an artificial method. */
static void
start_artificial_method_body (mdecl)
IDENTIFIER_POINTER (DECL_NAME (TYPE_NAME (class_type))));
}
-/* 15.10.1 Field Acess Using a Primary and/or Expression Name.
+/* 15.10.1 Field Access Using a Primary and/or Expression Name.
We return something suitable to generate the field access. We also
return the field decl in FIELD_DECL and its type in FIELD_TYPE. If
recipient's address can be null. */
parse_error_context (wfl, "Can't reference `this' before the superclass constructor has been called");
return 1;
}
- /* We have to generate code for intermediate acess */
+ /* We have to generate code for intermediate access */
if (!from_type || TREE_TYPE (TREE_TYPE (current_this)) == type)
{
*where_found = decl = current_this;
if (where && !inherits_from_p (reference, where))
return 1;
- /* Otherwise, access is granted if occuring from the class where
+ /* Otherwise, access is granted if occurring from the class where
member is declared or a subclass of it. Find the right
context to perform the check */
if (PURE_INNER_CLASS_TYPE_P (reference))
return 1;
}
- /* Default access are permitted only when occuring within the
+ /* Default access are permitted only when occurring within the
package in which the type (REFERENCE) is declared. In other words,
REFERENCE is defined in the current package */
if (ctxp->package)
return node;
}
-/* Create a new function block and link it approriately to current
+/* Create a new function block and link it appropriately to current
function block chain */
static tree
{
lhs_type = TREE_TYPE (lvalue);
}
- /* Or Lhs can be a array acccess. Should that be lvalue ? FIXME +
+ /* Or Lhs can be a array access. Should that be lvalue ? FIXME +
comment on reason why */
else if (TREE_CODE (wfl_op1) == ARRAY_REF)
{
}
/* Unary numeric promotion (5.6.1) is performed on each operand
- separatly */
+ separately */
op1 = do_unary_numeric_promotion (op1);
op2 = do_unary_numeric_promotion (op2);
COMPOUND_EXPR (loop main body)
EXIT_EXPR (this order is for while/for loops.
LABELED_BLOCK_EXPR the order is reversed for do loops)
- LABEL_DECL (a continue occuring here branches at the
+ LABEL_DECL (a continue occurring here branches at the
BODY end of this labeled block)
INCREMENT (if any)
SET_WFL_OPERATOR (wfl_operator, node, wfl_op1);
/* An instance can't throw a checked exception unless that exception
- is explicitely declared in the `throws' clause of each
+ is explicitly declared in the `throws' clause of each
constructor. This doesn't apply to anonymous classes, since they
don't have declared constructors. */
if (!unchecked_ok
/* Note that TARGET_LABEL is a possible successor instruction.
Merge the type state etc.
- Return NULL on sucess, or an error message on failure. */
+ Return NULL on success, or an error message on failure. */
static const char *
check_pending_block (target_label)
#define BCODE byte_ops
/* Verify the bytecodes of the current method.
- Return 1 on sucess, 0 on failure. */
+ Return 1 on success, 0 on failure. */
int
verify_jvm_instructions (jcf, byte_ops, length)
JCF* jcf;