Article View: gnu.gcc.bug
Article #2253GCC 1.33 function invocation problem.
From: Keith Gabryelski
Date: Wed, 08 Feb 1989 18:08
Date: Wed, 08 Feb 1989 18:08
86 lines
3194 bytes
3194 bytes
In a few places in GCC 1.33 I found:
foo (func)
int (*func)(); /* No sweat */
{
.
.
func(); /* Bummer */
.
.
}
Shouldn't the invocation be `(*func)()'? At least my compiler barfs
on `func()' as `not a function'. I don't think this is standard (or
ansi) `C' either.
The problems seem to be in gnulib.c and stmt.c.
My diffs:
*------ In gnulib.c -----------------------------------------------*
443c443
< (*ctor) (p);
---
> ctor (p);
506c506
< (*dtor) (ptr, auto_delete);
---
> dtor (ptr, auto_delete);
*------ In stmt.c -------------------------------------------------*
2775c2775
< emit_jump_insn ((*gen_bgt_pat) (label_rtx (node->right->code_label)));
---
> emit_jump_insn (gen_bgt_pat (label_rtx (node->right->code_label)));
2785c2785
< emit_jump_insn ((*gen_blt_pat) (label_rtx (node->left->code_label)));
---
> emit_jump_insn (gen_blt_pat (label_rtx (node->left->code_label)));
2790c2790
< emit_jump_insn ((*gen_bgt_pat) (label_rtx (node->right->test_label)));
---
> emit_jump_insn (gen_bgt_pat (label_rtx (node->right->test_label)));
2810c2810
< emit_jump_insn ((*gen_blt_pat) (default_label));
---
> emit_jump_insn (gen_blt_pat (default_label));
2839c2839
< emit_jump_insn ((*gen_bgt_pat) (label_rtx (node->right->code_label)));
---
> emit_jump_insn (gen_bgt_pat (label_rtx (node->right->code_label)));
2847c2847
< emit_jump_insn ((*gen_bgt_pat) (label_rtx (node->right->test_label)));
---
> emit_jump_insn (gen_bgt_pat (label_rtx (node->right->test_label)));
2850c2850
< emit_jump_insn ((*gen_bge_pat) (label_rtx (node->code_label)));
---
> emit_jump_insn (gen_bge_pat (label_rtx (node->code_label)));
2870c2870
< emit_jump_insn ((*gen_blt_pat) (default_label));
---
> emit_jump_insn (gen_blt_pat (default_label));
2873c2873
< emit_jump_insn ((*gen_ble_pat) (label_rtx (node->code_label)));
---
> emit_jump_insn (gen_ble_pat (label_rtx (node->code_label)));
2890c2890
< emit_jump_insn ((*gen_bgt_pat) (default_label));
---
> emit_jump_insn (gen_bgt_pat (default_label));
2893c2893
< emit_jump_insn ((*gen_bge_pat) (label_rtx (node->code_label)));
---
> emit_jump_insn (gen_bge_pat (label_rtx (node->code_label)));
2913c2913
< emit_jump_insn ((*gen_bgt_pat) (default_label));
---
> emit_jump_insn (gen_bgt_pat (default_label));
2918c2918
< emit_jump_insn ((*gen_bge_pat) (label_rtx (node->code_label)));
---
> emit_jump_insn (gen_bge_pat (label_rtx (node->code_label)));
*------------------------------------------------------------------*
--
ag@elgar.CTS.COM Keith Gabryelski ...!{ucsd, crash}!elgar!ag
Technical Details
Message-ID:
<65@elgar.UUCP>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!eos!agate!ucbvax!ucsd!ucsdhub!isg100!elgar!agShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!eos!agate!ucbvax!ucsd!ucsdhub!isg100!elgar!ag From: ag@elgar.UUCP (Keith Gabryelski) Newsgroups: gnu.gcc.bug Subject: GCC 1.33 function invocation problem. Message-ID: <65@elgar.UUCP> Date: 8 Feb 89 18:08:33 GMT Reply-To: ag@elgar.UUCP (Keith Gabryelski) Distribution: gnu Organization: Elgar Corporation, San Diego, CA Lines: 86