This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Call problem..


> Date: Tue, 13 Jun 2000 17:21:22 +0800
> From: kanata <kanata@celab1.ee.ntou.edu.tw>
> To: bug-gcc@gnu.org

> If I want to call a specified address, how can I do it?
> I have use this way  
>     (char *)(0x12345678)();
> But compiler said "called object is not a function"...
> So How can I call a function without define?

(char *) is not a pointer to function, it is a pointer to a character.
A pointer to a function would be (void (*)()).  This isn't a bug in gcc,
so this list is inappropriate.  gcc-help would be better.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]