2005-07-06 Colin Walters <walters@verbum.org>
* verify.cc (class _Jv_BytecodeVerifier) <op_new>: Don't
check for abstract classes or interfaces here; JVM spec
says it should throw an exception, so we'll do so later.
* interpret.cc (run): Throw an InstantiationException for
abstract classes and interfaces.
From-SVN: r101788
PR tree-optimization/22360
* tree.c (upper_bound_in_type): Fix calculations for casting
to a non-wider signed type and casting a signed value to a
wider unsigned type.
(lower_bound_in_type): Fix calculations for casting to a
non-wider signed type.
From-SVN: r101785
2005-07-08 Andrew Pinski <pinskia@physics.uc.edu>
PR tree-opt/22356
* testsuite/gcc.dg/pr22356-1.c: New test.
2005-07-08 Andrew Pinski <pinskia@physics.uc.edu>
PR tree-opt/22356
* tree-complex.c (expand_complex_libcall): Produce
REALPART_EXPR/IMAGPART_EXPR with the correct type.
From-SVN: r101781
[gcc/objc/ChangeLog]
2005-07-07 Ziemowit Laski <zlaski@apple.com>
* objc-act.c (objc_build_struct): Pass in an actual @interface
instead of its name, and annotate the struct created (and all
existing variants thereof) with the @interface.
(objc_compare_types): Treat forward-declared ObjC classes
as stand-alone (root) classes for purposes of type comparisons.
(build_private_template): Move some code to objc_build_struct().
[gcc/testsuite/ChangeLog]
2005-07-07 Ziemowit Laski <zlaski@apple.com>
* obj-c++.dg/proto-lossage-6.mm: New.
* objc.dg/proto-lossage-6.m: New.
From-SVN: r101750
2005-07-07 Thomas Koenig <Thomas.Koenig@online.de>
PR libfortran/21594
* intrinsics/eoshift0.c: If abs(shift) > len, fill the
the whole array with the boundary value, but don't overrun it.
* intrinsics/eoshift2.c: Likewise.
* m4/eoshift1.m4: Likewise.
* m4/eoshift3.m4: Likewise.
* generated/eoshift1_4.c: Regenerated.
* generated/eoshift1_8.c: Regenerated.
* generated/eoshift3_4.c: Regenerated.
* generated/eoshift3_8.c: Regenerated.
2005-07-07 Thomas Koenig <Thomas.Koenig@online.de>
PR libfortran/21594
* gfortran.fortran-torture/execute/intrinsic_eoshift.f90:
Add test cases where the shift length is greater than the
array length.
From-SVN: r101738
2005-07-07 Paul Brook <paul@codesourcery.com>
* config/arm/arm.c (arm_pad_arg_upward): Compare return value of
DEFAULT_FUNCTION_ARG_PADDING to upward.
[[Split portion of a mixed commit.]]
From-SVN: r101736.2
* scanner.c (load_line): Add pbuflen argument, don't make
buflen static. If maxlen == 0 or preprocessor_flag,
don't truncate at buflen, but at maxlen. In xrealloc add
1 byte at the end for the terminating '\0'. Don't fill
with spaces up to buflen, but gfc_option.fixed_line_length.
(load_file): Adjust load_line caller. Add line_len variable.
* gfortran.dg/longline.f: New test.
From-SVN: r101718
* scanner.c (preprocessor_line): Only set current_file->line when errors
have not been encountered. Warn and don't crash if a file leave
preprocessor line has no corresponding entering line. Formatting.
* gfortran.dg/badline.f: New test.
From-SVN: r101717
2005-07-07 Bryce McKinlay <mckinlay@redhat.com>
PR java/18119
* parse.y (inner_class_accessible): New function. Logic moved from
check_inner_class_access.
(check_inner_class_access): Use inner_class_accessible.
(resolve_inner_class): Simplify arguments. Create circularity hash
here. Keep looking for classes if we found one that was
inaccessible. Return the inaccessible class only if there is no other
match.
(do_resolve_class): Update for new resolve_inner_class arguments.
Don't create circularity_hash here.
From-SVN: r101715
2005-07-07 Bryce McKinlay <mckinlay@redhat.com>
PR java/21045
* parse.y (add_exception_to_throws): New function.
(purge_unchecked_exceptions): Removed.
(get_constructor_super): Renamed from verify_constructor_super. Now
returns the super constructor after verification.
(java_complete_expand_method): Don't use purge_unchecked_exceptions
or save/restore the exception list.
(check_thrown_exceptions): Add uncaught exceptions in anonymous
class initializers and constructors to the throws clause of the
method.
2005-07-07 Bryce McKinlay <mckinlay@redhat.com>
* testsuite/libjava.compile/PR21045.java: New test.
* testsuite/libjava.jacks/jacks.xfail: Remove 15.9.5.1-exception-1,
15.9.5.1-exception-3, 8.3.2-abrupt-6, 8.3.2-abrupt-7.
From-SVN: r101713
2005-07-07 Kelley Cook <kcook@gcc.gnu.org>
* Makefile.in (echo_quoted_to_gtyp): New template for outputing
filenames to gtyp-gen.h.
(s-typ-gen): Use it in place of for loops.
From-SVN: r101708
2005-07-07 Bernard Banner <banner@adacore.com>
* tracebak.c: Refine tracebacks to use Unwind_Backtrace scheme on
ia64 platform only on platforms that you the GCC unwind library
rather than the system unwind library.
From-SVN: r101699
2005-07-07 Ed Schonberg <schonberg@adacore.com>
* sem_ch8.adb (Find_Direct_Name): Handle properly the case of a
generic package that contains local declarations with the same name.
(Analyze_Object_Renaming): Check wrong renaming of incomplete type.
From-SVN: r101698
2005-07-07 Ed Schonberg <schonberg@adacore.com>
Javier Miranda <miranda@adacore.com>
* par-load.adb (Load): If a child unit is loaded through a limited_with
clause, each parent must be loaded as a limited unit as well.
* sem_ch10.adb (Previous_Withed_Unit): Better name for
Check_Withed_Unit. Return true if there is a previous with_clause for
this unit, whether limited or not.
(Expand_Limited_With_Clause): Do not generate a limited_with_clause on
the current unit.
(Is_Visible_Through_Renamings): New local subprogram of install_limited
_withed_unit that checks if some package installed through normal with
clauses has a renaming declaration of package whose limited-view is
ready to be installed. This enforces the check of the rule 10.1.2 (21/2)
of the current Draft document for Ada 2005.
(Analyze_Context): Complete the list of compilation units that
are allowed to contain limited-with clauses. It also contains
checks that were previously done by Install_Limited_Context_Clauses.
This makes the code more clear and easy to maintain.
(Expand_Limited_With_Clause) It is now a local subprogram of
Install_Limited_Context_Clauses, and contains the code that adds
the implicit limited-with clauses for parents of child units.
This functionality was prevously done by Analyze_Context.
* sem_ch4.adb (Analyze_Selected_Component): Check wrong use of
incomplete type.
* sem_ch7.adb (Analyze_Package_Declaration): Check if the package has
been erroneously named in a limited-with clause of its own context.
In this case the error has been previously notified by Analyze_Context.
From-SVN: r101697
2005-07-07 Olivier Hainque <hainque@adacore.com>
PR ada/22301
* raise.c: Only include unwind.h if IN_RTS, and provide dummy type
definitions for the Unwind wrappers in the compiler case.
From-SVN: r101696
2005-07-07 Javier Miranda <miranda@adacore.com>
* freeze.adb (Freeze_Entity): Check wrong uses of tag incomplete types.
* par-ch3.adb (P_Type_Declaration): Give support to tagged incomplete
types:
--
type DEFINING_IDENTIFIER [DISCRIMINANT_PART] [IS TAGGED];
--
* sem_attr.adb (Check_Not_Incomplete_Type): Additional checks for wrong
use of tag incomplete types.
* sem_ch3.adb (Analyze_Incomplete_Type): Add mininum decoration to
give support to tagged incomplete types.
* sem_ch5.adb (Analyze_Case_Statement): In generated code, if the
expression is a discriminant reference and its type is private, as can
happen within a stream operation for a mutable record, use the full
view of the type to resolve the case alternatives.
(Analyze_Assignment): Check wrong dereference of incomplete types.
* sem_ch6.adb (Process_Formals): Allow the use of tagged incomplete
types.
* sem_res.adb (Resolve_Explicit_Dereference): Allow the use of tagged
incomplete types.
* sinfo.adb (Taggged_Present/Set_Taggged_Present): Applicable to
N_Incomplete_Type_Declaration nodes.
* sinfo.ads (N_Incomplete_Type_Declaration): Addition of attribute
Tag_Present to give support to tagged incomplete types:
--
type DEFINING_IDENTIFIER [DISCRIMINANT_PART] [IS TAGGED];
--
From-SVN: r101695
2005-07-07 Javier Miranda <miranda@adacore.com>
* exp_ch3.adb (Build_Record_Init_Proc/Freeze_Record_Type):
Reimplementation of the support for abstract interface types in order
to leave the code more clear and easy to maintain.
* exp_ch6.adb (Freeze_Subprogram): Reimplementation of the support for
abstract interface types in order to leave the code clearer and easier
to maintain.
* exp_disp.ads, exp_disp.adb (Fill_DT_Entry): Part of its functionality
is now implemented by the new subprogram Fill_Secondary_DT_Entry.
(Fill_Secondary_DT_Entry): Generate the code necessary to fill the
appropriate entry of the secondary dispatch table.
(Make_DT): Add code to inherit the secondary dispatch tables of
the ancestors.
* exp_util.adb (Find_Interface_Tag/Find_Interface_ADT): Instead of
implementing both functionalities by means of a common routine, each
routine has its own code.
From-SVN: r101694
2005-07-07 Eric Botcazou <ebotcazou@adacore.com>
* decl.c (gnat_to_gnu_entity) <E_Procedure>: Do not strip the padding
type if the parameter is not passed by copy but reference by default.
From-SVN: r101693