cparser
13 years agoFix another typo in the same comment.
Christoph Mallon [Thu, 24 Feb 2011 11:01:30 +0000 (11:01 +0000)]
Fix another typo in the same comment.

[r28448]

13 years agoFix typo in comment.
Christoph Mallon [Thu, 24 Feb 2011 10:22:09 +0000 (10:22 +0000)]
Fix typo in comment.

[r28444]

13 years agoRemove duplicate assert.
Christoph Mallon [Thu, 24 Feb 2011 10:22:08 +0000 (10:22 +0000)]
Remove duplicate assert.

[r28443]

13 years agoThere is no need to #ifdef an identifier before #undefing it.
Christoph Mallon [Thu, 24 Feb 2011 10:22:06 +0000 (10:22 +0000)]
There is no need to #ifdef an identifier before #undefing it.

[r28442]

13 years agoAllow declarations after labels in C++ mode.
Christoph Mallon [Thu, 24 Feb 2011 10:22:04 +0000 (10:22 +0000)]
Allow declarations after labels in C++ mode.

[r28441]

13 years agoImprove error message: Show the position of the label statement instead of the }...
Christoph Mallon [Thu, 24 Feb 2011 10:22:02 +0000 (10:22 +0000)]
Improve error message: Show the position of the label statement instead of the } when complaining about a label at the end of a compound statement.

[r28440]

13 years agoDo not check for a null pointer in the type printer, because we stopped using null...
Christoph Mallon [Thu, 24 Feb 2011 10:21:59 +0000 (10:21 +0000)]
Do not check for a null pointer in the type printer, because we stopped using null pointers as error type long ago.

[r28439]

13 years agoHandle GNU extension __REDIRECT
Andreas Zwinkau [Thu, 24 Feb 2011 09:59:09 +0000 (09:59 +0000)]
Handle GNU extension __REDIRECT

Used to specify a different ld_name than function name.
E.g. use to redirect fstat to fstat64 in GNU.

Fixes C/gnu99/redirect

[r28437]

13 years agoAttemp to fix typedef_init.c testcase.
Michael Beck [Sun, 20 Feb 2011 11:13:11 +0000 (11:13 +0000)]
Attemp to fix typedef_init.c testcase.

[r28425]

13 years agoadd some comments, made for loop look "more usual", no functional change
Michael Beck [Sun, 20 Feb 2011 11:13:02 +0000 (11:13 +0000)]
add some comments, made for loop look "more usual", no functional change

[r28424]

13 years agoChange is_error_entity() to !is_entity_valid(), which is consistent with is_type_valid().
Christoph Mallon [Fri, 18 Feb 2011 21:05:13 +0000 (21:05 +0000)]
Change is_error_entity() to !is_entity_valid(), which is consistent with is_type_valid().

[r28419]

13 years agoCorrect logic in is_error_entity().
Christoph Mallon [Fri, 18 Feb 2011 21:05:10 +0000 (21:05 +0000)]
Correct logic in is_error_entity().

This fixes C/should_fail/typedef_enum.c.

[r28418]

13 years agoimplement sizeof(func) and alignof(func) in gnu99 mode
Matthias Braun [Fri, 18 Feb 2011 16:45:53 +0000 (16:45 +0000)]
implement sizeof(func) and alignof(func) in gnu99 mode

[r28414]

13 years agoCorrect off-by-whatever errors of the source position in parse_select_expression().
Christoph Mallon [Fri, 18 Feb 2011 12:09:26 +0000 (12:09 +0000)]
Correct off-by-whatever errors of the source position in parse_select_expression().

[r28407]

13 years agoCorrect typo in comment.
Christoph Mallon [Fri, 18 Feb 2011 12:09:24 +0000 (12:09 +0000)]
Correct typo in comment.

[r28406]

13 years agoPrefer get_mode_{minus_one,null}() over new_tarval_from_long({-1,0}).
Christoph Mallon [Fri, 18 Feb 2011 12:09:23 +0000 (12:09 +0000)]
Prefer get_mode_{minus_one,null}() over new_tarval_from_long({-1,0}).

[r28405]

13 years agoAssign the proper namespace to all new entities and assert that nobody tries to retri...
Christoph Mallon [Fri, 18 Feb 2011 12:09:19 +0000 (12:09 +0000)]
Assign the proper namespace to all new entities and assert that nobody tries to retrieve entities with NAMESPACE_INVALID.

This corrects C/should_fail/conflicting_types.c.

[r28404]

13 years agoSupport -pthread argument on Linux
Andreas Zwinkau [Fri, 18 Feb 2011 10:02:51 +0000 (10:02 +0000)]
Support -pthread argument on Linux

Other platforms require different arguments or different behavior.

[r28402]

13 years agoRate EXPR_REFERENCE (variable uses) with error type as EXPR_CLASS_ERROR instead of...
Christoph Mallon [Thu, 17 Feb 2011 13:45:49 +0000 (13:45 +0000)]
Rate EXPR_REFERENCE (variable uses) with error type as EXPR_CLASS_ERROR instead of EXPR_CLASS_VARIABLE.

For "case unknown_var:" this prevents the subsequent error that the case label is not constant.

[r28393]

13 years agofix last commit: conditional_expression might use compounds
Matthias Braun [Wed, 9 Feb 2011 16:13:41 +0000 (16:13 +0000)]
fix last commit: conditional_expression might use compounds

[r28359]

13 years agofix cp_error065.c
Matthias Braun [Wed, 9 Feb 2011 14:50:48 +0000 (14:50 +0000)]
fix cp_error065.c

[r28357]

13 years agoAdding some file extensions for detection
Andreas Zwinkau [Wed, 9 Feb 2011 14:48:45 +0000 (14:48 +0000)]
Adding some file extensions for detection

Interpretation according to gcc.

[r28355]

13 years agofix warning
Matthias Braun [Wed, 9 Feb 2011 13:55:49 +0000 (13:55 +0000)]
fix warning

[r28348]

13 years agoadapt to remove of Quot node in latest libfirm
Matthias Braun [Wed, 9 Feb 2011 13:55:48 +0000 (13:55 +0000)]
adapt to remove of Quot node in latest libfirm

[r28347]

13 years agoTurn all exits inside main into returns, replace exit(1) by exit(FAILURE).
Michael Beck [Sun, 6 Feb 2011 20:39:18 +0000 (20:39 +0000)]
Turn all exits inside main into returns, replace exit(1) by exit(FAILURE).

[r28335]

13 years agoEnter constant folding mode before doing so. Fixes some regression tests.
Christoph Mallon [Sun, 6 Feb 2011 07:51:23 +0000 (07:51 +0000)]
Enter constant folding mode before doing so.  Fixes some regression tests.

[r28326]

13 years agoPrefer new_Const(get_mode_null(mode)) over new_Const_long(mode, 0).
Christoph Mallon [Sun, 6 Feb 2011 07:51:19 +0000 (07:51 +0000)]
Prefer new_Const(get_mode_null(mode)) over new_Const_long(mode, 0).

[r28325]

13 years agoAdd the helper function create_Const_from_bool() to create 0/1 constant from a boolea...
Christoph Mallon [Sun, 6 Feb 2011 07:51:16 +0000 (07:51 +0000)]
Add the helper function create_Const_from_bool() to create 0/1 constant from a boolean value.

[r28324]

13 years agoLet is_constant_expression() and friends return an enum so constant expressions can...
Christoph Mallon [Sun, 6 Feb 2011 07:51:12 +0000 (07:51 +0000)]
Let is_constant_expression() and friends return an enum so constant expressions can be differentiated from erroneous expressions. Now the latter do not cause panics when trying to constant fold them.

[r28323]

13 years agoImprove error recovery: eat_until_anchor() when parse_primary_expression() finds...
Christoph Mallon [Sun, 6 Feb 2011 07:51:08 +0000 (07:51 +0000)]
Improve error recovery: eat_until_anchor() when parse_primary_expression() finds no token to consume.

[r28322]

13 years agoFix C/should_fail/decl_without_name.c.
Christoph Mallon [Sun, 6 Feb 2011 07:51:04 +0000 (07:51 +0000)]
Fix C/should_fail/decl_without_name.c.

[r28321]

13 years agoUse get_break_label() instead of duplicating it.
Christoph Mallon [Sun, 6 Feb 2011 07:51:00 +0000 (07:51 +0000)]
Use get_break_label() instead of duplicating it.

[r28320]

13 years agoOverhaul conditional_to_firm(). Now it is a tad shorter/simpler and more friendly...
Christoph Mallon [Sun, 6 Feb 2011 07:50:57 +0000 (07:50 +0000)]
Overhaul conditional_to_firm(). Now it is a tad shorter/simpler and more friendly towards SSA construction due to maturing in dominance order.

[r28319]

13 years agoSimplify produce_condition_result().
Christoph Mallon [Sun, 6 Feb 2011 07:50:53 +0000 (07:50 +0000)]
Simplify produce_condition_result().

[r28318]

13 years agoAdd jump_if_reachable() to reduce code duplication.
Christoph Mallon [Sun, 6 Feb 2011 07:50:49 +0000 (07:50 +0000)]
Add jump_if_reachable() to reduce code duplication.

[r28317]

13 years agoOverhaul for_statement_to_firm() so it is more friendly towards SSA construction...
Christoph Mallon [Sun, 6 Feb 2011 07:50:46 +0000 (07:50 +0000)]
Overhaul for_statement_to_firm() so it is more friendly towards SSA construction due to maturing in dominance order.

[r28316]

13 years agoSimplify maturing of the header block in do_while_statement_to_firm(). This also...
Christoph Mallon [Sun, 6 Feb 2011 07:50:42 +0000 (07:50 +0000)]
Simplify maturing of the header block in do_while_statement_to_firm(). This also is more friendly towards SSA construction due to maturing in dominance order.

[r28315]

13 years agoOverhaul while_statement_to_firm(). Now it is a tad shorter/simpler and more friendly...
Christoph Mallon [Sun, 6 Feb 2011 07:50:39 +0000 (07:50 +0000)]
Overhaul while_statement_to_firm(). Now it is a tad shorter/simpler and more friendly towards SSA construction due to maturing in dominance order.

[r28314]

13 years agoOverhaul if_statement_to_firm(). Now it is a tad shorter/simpler and more friendly...
Christoph Mallon [Sun, 6 Feb 2011 07:50:35 +0000 (07:50 +0000)]
Overhaul if_statement_to_firm(). Now it is a tad shorter/simpler and more friendly towards SSA construction due to maturing in dominance order.

[r28313]

13 years agoSimplify daisy chaining local labels.
Christoph Mallon [Sat, 5 Feb 2011 09:04:11 +0000 (09:04 +0000)]
Simplify daisy chaining local labels.

[r28309]

13 years agoDo not eat() the semicolon at the end of a local label declaration, but expect() it.
Christoph Mallon [Sat, 5 Feb 2011 09:04:07 +0000 (09:04 +0000)]
Do not eat() the semicolon at the end of a local label declaration, but expect() it.

[r28308]

13 years agoImprove error recovery: Do not create an invalid statement if the semicolon at the...
Christoph Mallon [Sat, 5 Feb 2011 09:04:03 +0000 (09:04 +0000)]
Improve error recovery: Do not create an invalid statement if the semicolon at the end of a goto statement is missing.

[r28307]

13 years agoCorrect typo in label name.
Christoph Mallon [Sat, 5 Feb 2011 09:04:00 +0000 (09:04 +0000)]
Correct typo in label name.

[r28306]

13 years agoRemove unnecessary gotos.
Christoph Mallon [Sat, 5 Feb 2011 09:03:56 +0000 (09:03 +0000)]
Remove unnecessary gotos.

[r28305]

13 years agoProvide the specific error message about a label at the end of a compound statement...
Christoph Mallon [Sat, 5 Feb 2011 09:03:51 +0000 (09:03 +0000)]
Provide the specific error message about a label at the end of a compound statement not just for goto labels but for case and default labels, too.

[r28304]

13 years agoReduce variable scope.
Christoph Mallon [Sat, 5 Feb 2011 09:03:47 +0000 (09:03 +0000)]
Reduce variable scope.

[r28303]

13 years agoSimplify case_label_to_firm() a bit, which can be done since new_immBlock() does...
Christoph Mallon [Sat, 5 Feb 2011 09:03:43 +0000 (09:03 +0000)]
Simplify case_label_to_firm() a bit, which can be done since new_immBlock() does not set current_block anymore.

[r28302]

13 years agoSimplify do_while_statement_to_firm() a bit, which can be done since new_immBlock...
Christoph Mallon [Sat, 5 Feb 2011 09:03:39 +0000 (09:03 +0000)]
Simplify do_while_statement_to_firm() a bit, which can be done since new_immBlock() does not set current_block anymore.

[r28301]

13 years agoCorrect copy&paste-o in warning message.
Christoph Mallon [Sat, 5 Feb 2011 09:03:34 +0000 (09:03 +0000)]
Correct copy&paste-o in warning message.

[r28300]

13 years agoRemove unnecessary test in ast2firm: A label-statement always has an inner statement.
Christoph Mallon [Fri, 4 Feb 2011 14:27:21 +0000 (14:27 +0000)]
Remove unnecessary test in ast2firm: A label-statement always has an inner statement.

[r28299]

13 years agoRemove unnecessary test in ast2firm: A case-label-statement always has an inner state...
Christoph Mallon [Fri, 4 Feb 2011 14:27:18 +0000 (14:27 +0000)]
Remove unnecessary test in ast2firm: A case-label-statement always has an inner statement.

[r28298]

13 years agoRemove unnecessary test in ast2firm: A switch-statement always has a body.
Christoph Mallon [Fri, 4 Feb 2011 14:27:16 +0000 (14:27 +0000)]
Remove unnecessary test in ast2firm: A switch-statement always has a body.

[r28297]

13 years agoRemove unnecessary test in ast2firm: A for-statement always has a body.
Christoph Mallon [Fri, 4 Feb 2011 14:27:14 +0000 (14:27 +0000)]
Remove unnecessary test in ast2firm: A for-statement always has a body.

[r28296]

13 years agoRemove unnecessary tests in ast2firm: An if-statement always has a true_statement.
Christoph Mallon [Fri, 4 Feb 2011 14:27:13 +0000 (14:27 +0000)]
Remove unnecessary tests in ast2firm: An if-statement always has a true_statement.

[r28295]

13 years agoImprove error recovery: Produce a valid statement and continue parsing even if the...
Christoph Mallon [Fri, 4 Feb 2011 14:27:10 +0000 (14:27 +0000)]
Improve error recovery: Produce a valid statement and continue parsing even if the ":" after "default" is missing.

[r28294]

13 years agoWhitespace fixes.
Christoph Mallon [Fri, 4 Feb 2011 14:27:06 +0000 (14:27 +0000)]
Whitespace fixes.

[r28293]

13 years agoRemove unnecessary/wrong cast. ARR_SHRINKLEN() uses size_t now.
Christoph Mallon [Mon, 31 Jan 2011 10:02:34 +0000 (10:02 +0000)]
Remove unnecessary/wrong cast. ARR_SHRINKLEN() uses size_t now.

[r28284]

13 years agoUse correct parameter name in comment.
Christoph Mallon [Mon, 31 Jan 2011 10:02:31 +0000 (10:02 +0000)]
Use correct parameter name in comment.

[r28283]

13 years agoRemoved superflous computations, these are done later again.
Michael Beck [Fri, 28 Jan 2011 01:06:19 +0000 (01:06 +0000)]
Removed superflous computations, these are done later again.

[r28275]

13 years agoBugFix: Implement missing void casts, this fixed cp_error064.c
Michael Beck [Fri, 28 Jan 2011 01:06:10 +0000 (01:06 +0000)]
BugFix: Implement missing void casts, this fixed cp_error064.c

[r28274]

13 years agoSimplify while_statement_to_firm() a bit, which can be done since new_immBlock()...
Christoph Mallon [Wed, 19 Jan 2011 14:53:32 +0000 (14:53 +0000)]
Simplify while_statement_to_firm() a bit, which can be done since new_immBlock() does not set current_block anymore.

[r28260]

13 years agoworkaround/fix jam dependency problems
Matthias Braun [Thu, 13 Jan 2011 11:55:59 +0000 (11:55 +0000)]
workaround/fix jam dependency problems

[r28245]

13 years agoconstructors/destructors pointers must have visibility_private
Matthias Braun [Thu, 13 Jan 2011 11:55:58 +0000 (11:55 +0000)]
constructors/destructors pointers must have visibility_private

[r28244]

13 years agoattempt to workaround input problems on OS/X gdb
Matthias Braun [Wed, 5 Jan 2011 17:28:27 +0000 (17:28 +0000)]
attempt to workaround input problems on OS/X gdb

[r28207]

13 years agoFixed type sizes and alignment for -m64.
Michael Beck [Thu, 30 Dec 2010 21:23:22 +0000 (21:23 +0000)]
Fixed type sizes and alignment for -m64.

[r28205]

13 years agoonly write out functions for the main file when generating JNA declarations
Matthias Braun [Fri, 3 Dec 2010 15:05:26 +0000 (15:05 +0000)]
only write out functions for the main file when generating JNA declarations

[r28178]

13 years agoadapt to latest libfirm
Matthias Braun [Wed, 1 Dec 2010 13:11:32 +0000 (13:11 +0000)]
adapt to latest libfirm

[r28173]

13 years agowe might also have array null-initializers; do NOT do anythign for union members
Matthias Braun [Wed, 1 Dec 2010 12:45:55 +0000 (12:45 +0000)]
we might also have array null-initializers; do NOT do anythign for union members

[r28171]

13 years agofix dyanimc_initializer creation for IR_INITIALIZER_NULL on struct types
Matthias Braun [Wed, 1 Dec 2010 12:02:48 +0000 (12:02 +0000)]
fix dyanimc_initializer creation for IR_INITIALIZER_NULL on struct types

[r28170]

13 years agocond may be NULL
Matthias Braun [Wed, 1 Dec 2010 12:02:47 +0000 (12:02 +0000)]
cond may be NULL

[r28169]

13 years agonew_d_defaultProj fails if its argument is already a Bad. Do not use it anymore ...
Matthias Braun [Mon, 29 Nov 2010 18:01:48 +0000 (18:01 +0000)]
new_d_defaultProj fails if its argument is already a Bad. Do not use it anymore (defaultProj is odd anyway IMO)

[r28165]

13 years agolong double must not be exported as java double
Matthias Braun [Mon, 29 Nov 2010 18:01:48 +0000 (18:01 +0000)]
long double must not be exported as java double

[r28164]

13 years agoFix Bug 62 aka C_struct_init testcase
Andreas Zwinkau [Thu, 25 Nov 2010 14:47:21 +0000 (14:47 +0000)]
Fix Bug 62 aka C_struct_init testcase

[r28158]

13 years agoadapt style of generated code to java coding conventions
Matthias Braun [Mon, 22 Nov 2010 14:04:44 +0000 (14:04 +0000)]
adapt style of generated code to java coding conventions

[r28151]

13 years agoadapt to latest libfirm
Matthias Braun [Thu, 4 Nov 2010 12:15:45 +0000 (12:15 +0000)]
adapt to latest libfirm

[r28129]

13 years agoLet git ignore more visual studio files.
Michael Beck [Sat, 30 Oct 2010 00:56:42 +0000 (00:56 +0000)]
Let git ignore more visual studio files.

[r28123]

13 years agoUse EXIT_SUCCESS and EXIT_FAILURE where appropriate.
Michael Beck [Thu, 28 Oct 2010 19:19:12 +0000 (19:19 +0000)]
Use EXIT_SUCCESS and EXIT_FAILURE where appropriate.

[r28122]

13 years agoavoid warning in generated jna code
Matthias Braun [Wed, 13 Oct 2010 14:59:07 +0000 (14:59 +0000)]
avoid warning in generated jna code

[r28117]

13 years agoFix JNA direct-mode wrapper
Andreas Zwinkau [Wed, 13 Oct 2010 14:47:22 +0000 (14:47 +0000)]
Fix JNA direct-mode wrapper

[r28115]

13 years agoadd more definitions for __builtin___XXX_chk
Matthias Braun [Tue, 12 Oct 2010 22:17:54 +0000 (22:17 +0000)]
add more definitions for __builtin___XXX_chk

[r28113]

13 years agoinitial implementation of builtin_object_size
Matthias Braun [Tue, 12 Oct 2010 22:17:53 +0000 (22:17 +0000)]
initial implementation of builtin_object_size

[r28112]

13 years agofix bug on darwn introduced in the '-mtriple' commit
Matthias Braun [Tue, 12 Oct 2010 21:53:20 +0000 (21:53 +0000)]
fix bug on darwn introduced in the '-mtriple' commit

[r28110]

13 years agoJNA generator now emits for JNA direct-mode
Andreas Zwinkau [Mon, 11 Oct 2010 12:52:02 +0000 (12:52 +0000)]
JNA generator now emits for JNA direct-mode
(hopefully performance gains)

[r28094]

13 years agowork when strings are const char*
Matthias Braun [Mon, 11 Oct 2010 12:03:01 +0000 (12:03 +0000)]
work when strings are const char*

[r28092]

13 years agoperform archep lowering before the target-lowering pass
Matthias Braun [Mon, 11 Oct 2010 12:03:00 +0000 (12:03 +0000)]
perform archep lowering before the target-lowering pass

[r28091]

13 years agoadapt to libfirm (rename tarval to ir_tarval)
Matthias Braun [Fri, 8 Oct 2010 13:37:02 +0000 (13:37 +0000)]
adapt to libfirm (rename tarval to ir_tarval)

[r28063]

13 years agoadapt to latest libfirm
Matthias Braun [Wed, 6 Oct 2010 08:40:49 +0000 (08:40 +0000)]
adapt to latest libfirm

[r28045]

13 years agoadd -mtriple= to specify target architecture; refactor target architecture specific...
Matthias Braun [Wed, 6 Oct 2010 08:40:48 +0000 (08:40 +0000)]
add -mtriple= to specify target architecture; refactor target architecture specific code

[r28044]

13 years agoadapt to latest libfirm
Matthias Braun [Wed, 22 Sep 2010 14:08:07 +0000 (14:08 +0000)]
adapt to latest libfirm

[r28025]

13 years agoset graph to phase_low directly after running lower_for_target
Matthias Braun [Wed, 22 Sep 2010 14:08:06 +0000 (14:08 +0000)]
set graph to phase_low directly after running lower_for_target

[r28024]

13 years agoadapt to latest firm (no need to explicitely invoke switch lowerer, backend does...
Matthias Braun [Fri, 10 Sep 2010 13:32:55 +0000 (13:32 +0000)]
adapt to latest firm (no need to explicitely invoke switch lowerer, backend does it now

[r28005]

13 years agoadd missing semantic check: varargs arguments must have object type (= not void)
Matthias Braun [Fri, 10 Sep 2010 09:29:48 +0000 (09:29 +0000)]
add missing semantic check: varargs arguments must have object type (= not void)

[r27986]

13 years agonew bitfield struct layout code for big-endian (=sparc) machines
Matthias Braun [Mon, 6 Sep 2010 13:06:09 +0000 (13:06 +0000)]
new bitfield struct layout code for big-endian (=sparc) machines

[r27975]

13 years agoCopy gcc behavior: unknown file extension means object file
Andreas Zwinkau [Wed, 18 Aug 2010 14:51:21 +0000 (14:51 +0000)]
Copy gcc behavior: unknown file extension means object file

[r27943]

13 years agoadapt to libfirm API changes
Matthias Braun [Wed, 18 Aug 2010 13:37:15 +0000 (13:37 +0000)]
adapt to libfirm API changes

[r27939]

13 years agocparser ignores -fmessage-length now
Andreas Zwinkau [Wed, 18 Aug 2010 12:51:13 +0000 (12:51 +0000)]
cparser ignores -fmessage-length now

[r27935]

13 years agoFixed icc warning by using enum instead of (equivalent) 0.
Michael Beck [Sat, 7 Aug 2010 10:11:10 +0000 (10:11 +0000)]
Fixed icc warning by using enum instead of (equivalent) 0.

[r27896]

13 years agoNo need for libdl.
Christoph Mallon [Wed, 4 Aug 2010 10:25:54 +0000 (10:25 +0000)]
No need for libdl.

[r27870]

13 years agoUpdate config.mak.example: No more libcore and liblpp.
Christoph Mallon [Wed, 4 Aug 2010 09:26:43 +0000 (09:26 +0000)]
Update config.mak.example: No more libcore and liblpp.

[r27869]

13 years agoadapt to latest libfirm
Matthias Braun [Wed, 28 Jul 2010 15:00:22 +0000 (15:00 +0000)]
adapt to latest libfirm

[r27841]