This document discusses how constraints should be generated and resolved for sound inference of composite types.
The simplest possible scenario for type inference on composite types is a direct call to a zero-filled vector constructor.
x = numeric(4)
In this case, the type of the right-hand side is known and inference should:
x#1
to the write operand.x#1
to x
.x#1 <=> ArrayType(RealType, 4)
This scenario becomes more difficult when the length argument is a variable.
n = 4 x = numeric(n)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.