Fix type checker not promoting ints. Fix some issues in the codegen.
This commit is contained in:
14
test/simple_float2_expressions.shd
Normal file
14
test/simple_float2_expressions.shd
Normal file
@@ -0,0 +1,14 @@
|
||||
vertex main :: (pos : float4 @position) -> float4 @position {
|
||||
src_p0 : float2 = float2(0.0, 1.0);
|
||||
src_p1 : float2 = float2(1.0, 0.0);
|
||||
|
||||
src_half_size : float2 = (src_p1 - src_p0) / 2;
|
||||
src_center : float2 = (src_p1 + src_p0) / 2;
|
||||
src_pos : float2 = float2(pos.x, pos.y) * src_half_size + src_center;
|
||||
|
||||
return float4(1, 1, 1, 1);
|
||||
}
|
||||
|
||||
pixel main :: () -> float4 @target0 {
|
||||
return float4(1, 1, 1, 1);
|
||||
}
|
||||
Reference in New Issue
Block a user