[Swift-devel] random seed generator?

Mihael Hategan hategan at mcs.anl.gov
Wed Apr 25 11:56:49 CDT 2007


On Wed, 2007-04-25 at 16:53 +0000, Ben Clifford wrote:
> 
> On Wed, 25 Apr 2007, Mihael Hategan wrote:
> 
> > > On Wed, 25 Apr 2007, Mihael Hategan wrote:
> > > 
> > > > I was trying:
> > > > string a;
> > > > a = random();
> > > > 
> > > > But for some reason this translates into random(a).
> > > 
> > > @random
> > 
> > that yields "unexpected token"
> 
> huh. It seems to not like zero-parameter functions now. I thought it did 
> before. Maybe I broke it.

Hold your horses. I haven't done an update in a while.

> 
> > And it would translate to vdl:random(). I wanted to avoid having an 
> > explicit namespace, so that it would pick math:random().
> 
> I don't think you can do that any way at the moment, and I'm not terribly 
> inclined to have it project all of karajan's function space into 
> SwiftScript space by default.

It may be useful to have a way of explicitly doing that though.

> 




More information about the Swift-devel mailing list