Cloning the fixes from 9f8d8eb into the Compiler clone of the RandomValue generator
Cloning changes from 99f379cf into the RandomValueTypeVisitor