2023-02-01 13:52:18 +01:00
|
|
|
func test():
|
|
|
|
var left_hard_int := 1
|
|
|
|
var right_hard_int := 2
|
|
|
|
var result_hard_int := left_hard_int if true else right_hard_int
|
2024-08-28 16:41:52 +02:00
|
|
|
Utils.check(result_hard_int == 1)
|
2023-02-01 13:52:18 +01:00
|
|
|
|
2023-02-06 18:19:18 +01:00
|
|
|
@warning_ignore("inference_on_variant")
|
2023-02-01 13:52:18 +01:00
|
|
|
var left_hard_variant := 1 as Variant
|
2023-02-06 18:19:18 +01:00
|
|
|
@warning_ignore("inference_on_variant")
|
2023-02-01 13:52:18 +01:00
|
|
|
var right_hard_variant := 2.0 as Variant
|
2023-02-06 18:19:18 +01:00
|
|
|
@warning_ignore("inference_on_variant")
|
2023-02-01 13:52:18 +01:00
|
|
|
var result_hard_variant := left_hard_variant if true else right_hard_variant
|
2024-08-28 16:41:52 +02:00
|
|
|
Utils.check(result_hard_variant == 1)
|
2023-02-01 13:52:18 +01:00
|
|
|
|
|
|
|
print('ok')
|