> > Or should I just rip this Unsafe nonsense from mllex altogether? > > I was going to be my suggestion -- or at least see if it has a significant > performance impact. Maybe MLton can optimize to unsafe subs. I took it out. I doubt this is a case where MLton can optimize away the bounds check, but I can't imagine that it has much of a performance impact. I've never observed it in other benchmarks.