Friendly-C

via Digitalmars-d digitalmars-d at puremagic.com
Fri Aug 29 14:03:58 PDT 2014


On Friday, 29 August 2014 at 19:37:28 UTC, deadalnix wrote:
> NULL or any address, as you can change memory protection on a 
> per
> page basis, and have different protection for read write and
> execution.

If your semantics require page faults to trap then you should 
declare the storage volatile.

You cannot claim that the semantics of your program presumes that 
the program is incorrect?

Now, the programming language might require compiled programs to 
probe measures of incorrectness at some specific point in time: 
before compilation, before output is written to disk or after 
completion (with a rollback), but that is the semantics of a 
given language, not the semantics of the program. Thus it bears 
little relevance to a discussion of whether it is sound to assume 
unspeficied values and avoid stores.

> Even better, the fault do not have to result in an exception or
> other form of termination. in fact, it is demonstrated that the
> fault mechanism on x86 is Turing complete.

I don't see what TMs have to do with it. The language compiler 
controls generated code.


More information about the Digitalmars-d mailing list