improved size and speed for asts with ran nums