----------------------------------------
> Date: Mon, 31 Mar 2008 19:58:28 -0700
> From: [EMAIL PROTECTED]
> To: [email protected]
> Subject: Re: C++0X gets lambdas/closures
> 
> Christopher Smith wrote:
>> It's pretty hard for it to be impossible to implement a language in any 
>> of what we call "turing complete" languages. 
> 
> Nah.
> 
> Burroughs B series had typed assembly language. It was literally 
> impossible to express
> union { int i; float f; };
> 
> I've worked with machines where ints are in different address spaces 
> than floats, so struct {int i; float f; } cannot be expressed.
> 

Sure it can.  It just can't use the hardware floating point instructions.  It 
can still do software floating point with ints.

Now your compiler may not have allowed that, but it was certainly possible.


> I worked on one machine (a verifone credit card machine) where I 
> mentioned to someone something about using a pointer to a function, and 
> the response was as if I had grown a third head. Turns out I was wrong - 
> even tho it was programmed in something almost exactly like C, you 
> couldn't take the address of a function. Either something to do with the 
> memory hardware, or something to do with the instruction set only 
> allowing branches to literal addresses, prevented this.

Again, a compiler limitation at most-  you can use self-modifying code to 
accomplish this.


> 
> Sure, you could write a C interpreter, but try fitting it in 14K. 
> Remember, "turing complete" assumes no I/O and unbounded memory.
> 
True.  I wouldn't want to do some of the kludges I just suggested.

Gabe
_________________________________________________________________
How well do you know your celebrity gossip?
http://originals.msn.com/thebigdebate?ocid=T002MSN03N0707A
--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-lpsg

Reply via email to