scope of header files

Roman Leshchinskiy rl at
Sun Mar 16 21:38:44 EDT 2008

Jason Dusek wrote:
> Ross Paterson <ross at> wrote:
>> Jason Dusek wrote:
>>> Why doesn't GHC know about const?
>>  Because the Ptr type doesn't indicate const-ness (perhaps it
>>  should).
>   If it did, could we read constant strings without
>   unsafePerformIO?

That would be unsound since a const pointer doesn't necessarily point to 
const data. Constness here only means that the data can't be modified 
through this particular pointer.


More information about the Glasgow-haskell-users mailing list