The lowering done by SemLiterals is better done in SemTypes, which has all the context about integer types it needs. With the current implementation the following is invalid:
because 1 is inferred to be of type Int32, which cannot be converted to an unsigned type like Size.
The lowering done by
SemLiteralsis better done inSemTypes, which has all the context about integer types it needs. With the current implementation the following is invalid:because
1is inferred to be of typeInt32, which cannot be converted to an unsigned type likeSize.