[mercury-users] unsafe_set_char

Paul Bone pbone at csse.unimelb.edu.au
Mon May 31 11:15:33 AEST 2010


On Mon, May 31, 2010 at 11:01:26AM +1000, Peter Wang wrote:
> On 2010-05-30, Julien Fischer <juliensf at csse.unimelb.edu.au> wrote:
> > 
> > We do, unsafe_set_char has a commented out mode, (in, in, di, uo),  that
> > does the update in constant time.  (And indeed, it is to that mode, that
> > the existing documentation refers.)  The reason that mode is currently
> > commented out is that the compiler will may place string constants in
> > static data, even when they may be updated.
> 
> I'm in favour of re-enabling the destructive update modes (which is the
> only reason for the predicate to exist), and adding a warning about
> static constants to the documentation.

We should try to fix this properly.

How can something that is static ever be considered unique anyway?  If it's
static, it makes sense that it could be referenced multiple times.

Do you guys agree?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 489 bytes
Desc: Digital signature
URL: <http://lists.mercurylang.org/archives/users/attachments/20100531/0919b881/attachment.sig>


More information about the users mailing list