Re: Optimization bug in VC++ 6.0
From: David Lowndes (davidl_at_example.invalid)
Date: 03/23/04
- Next message: Andy Coates: "Re: C1001 ICE with .NET 2003 compiling templates"
- Previous message: tom_usenet: "Re: C1001 ICE with .NET 2003 compiling templates"
- In reply to: Emmanuel Stapf: "Optimization bug in VC++ 6.0"
- Next in thread: Emmanuel Stapf: "Re: Optimization bug in VC++ 6.0"
- Reply: Emmanuel Stapf: "Re: Optimization bug in VC++ 6.0"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 23 Mar 2004 17:55:04 +0000
>The following code fails to compile and cl (VC++ 6.0 SP5) returns an internal
>error.
What's the critical line of code supposed to be doing?
tab[i] = (void *) f;
Is the "tab" array meant to be an array of function pointers, or do
you intend to call f() and store a returned pointer in the array? I
presume the intention is the latter, in which case, the following
might be what you need:
extern void * f();
void *tab[40];
void tab_init () {
long i;
for (i = 8; i < 11; i++) {
tab[i] = f();
}
}
Dave
-- MVP VC++ FAQ: http://www.mvps.org/vcfaq
- Next message: Andy Coates: "Re: C1001 ICE with .NET 2003 compiling templates"
- Previous message: tom_usenet: "Re: C1001 ICE with .NET 2003 compiling templates"
- In reply to: Emmanuel Stapf: "Optimization bug in VC++ 6.0"
- Next in thread: Emmanuel Stapf: "Re: Optimization bug in VC++ 6.0"
- Reply: Emmanuel Stapf: "Re: Optimization bug in VC++ 6.0"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|