[MLton] Re: Type of _address?
Wesley W. Terpstra
Thu, 21 Jul 2005 21:01:53 +0200
On Thu, Jul 21, 2005 at 08:54:49PM +0200, Wesley W. Terpstra wrote:
> On Fri, Jul 22, 2005 at 04:27:19AM +1000, skaller wrote:
> > On Thu, 2005-07-21 at 15:23 +0200, Wesley W. Terpstra wrote:
> > > I think this is particularily questionable. Casting an int (what you get if
> > > you say nothing) to a function is almost certainly a bad idea. I think some
> > > systems have distinct address spaces for data and code.
> > Huh? MY system!! gcc-4.0: int is 32 bits. pointers are 64 bits.
> Fortunately, I've already cleverly fixed this by making it use a pointer.
Scratch that; it's irrelevant.
The cast is from an integer *pointer* to a function pointer.
So, the integer being too small doesn't matter here.
Wesley W. Terpstra <email@example.com>