program main fn maybe_value(value: i32) -> (option i32) some : (option i32) var value : i32 fn maybe_empty() -> (option i32) none : (option i32) fn maybe_wide_value(value: i64) -> (option i64) some : (option i64) var value : i64 fn maybe_wide_empty() -> (option i64) none : (option i64) fn maybe_float_value(value: f64) -> (option f64) some : (option f64) var value : f64 fn maybe_float_empty() -> (option f64) none : (option f64) fn maybe_flag_value(value: bool) -> (option bool) some : (option bool) var value : bool fn maybe_flag_empty() -> (option bool) none : (option bool) fn maybe_string_value(value: string) -> (option string) some : (option string) var value : string fn maybe_string_empty() -> (option string) none : (option string) fn option_score(value: (option i32)) -> i32 if : i32 is_some : bool var value : (option i32) int 1 : i32 int 0 : i32 fn option_empty_score(value: (option i32)) -> i32 if : i32 is_none : bool var value : (option i32) int 1 : i32 int 0 : i32 fn option_wide_score(value: (option i64)) -> i32 if : i32 is_some : bool var value : (option i64) int 1 : i32 int 0 : i32 fn option_wide_empty_score(value: (option i64)) -> i32 if : i32 is_none : bool var value : (option i64) int 1 : i32 int 0 : i32 fn option_float_score(value: (option f64)) -> i32 if : i32 is_some : bool var value : (option f64) int 1 : i32 int 0 : i32 fn option_float_empty_score(value: (option f64)) -> i32 if : i32 is_none : bool var value : (option f64) int 1 : i32 int 0 : i32 fn option_flag_score(value: (option bool)) -> i32 if : i32 is_some : bool var value : (option bool) int 1 : i32 int 0 : i32 fn option_flag_empty_score(value: (option bool)) -> i32 if : i32 is_none : bool var value : (option bool) int 1 : i32 int 0 : i32 fn option_string_score(value: (option string)) -> i32 if : i32 is_some : bool var value : (option string) int 1 : i32 int 0 : i32 fn option_string_empty_score(value: (option string)) -> i32 if : i32 is_none : bool var value : (option string) int 1 : i32 int 0 : i32 fn result_ok_value(value: i32) -> (result i32 i32) ok : (result i32 i32) var value : i32 fn result_err_value(code: i32) -> (result i32 i32) err : (result i32 i32) var code : i32 fn result_success_score(value: (result i32 i32)) -> i32 if : i32 is_ok : bool var value : (result i32 i32) int 1 : i32 int 0 : i32 fn result_failure_score(value: (result i32 i32)) -> i32 if : i32 is_err : bool var value : (result i32 i32) int 1 : i32 int 0 : i32 fn option_local_flow() -> i32 local let value : unit call maybe_value : (option i32) int 42 : i32 call option_score : i32 var value : (option i32) fn option_wide_local_flow() -> i32 local let value : unit call maybe_wide_value : (option i64) i64 2147483648 : i64 call option_wide_score : i32 var value : (option i64) fn option_float_local_flow() -> i32 local let value : unit call maybe_float_value : (option f64) float 42.5 : f64 call option_float_score : i32 var value : (option f64) fn option_flag_local_flow() -> i32 local let value : unit call maybe_flag_value : (option bool) bool true : bool call option_flag_score : i32 var value : (option bool) fn option_string_local_flow() -> i32 local let value : unit call maybe_string_value : (option string) string "slovo" : string call option_string_score : i32 var value : (option string) fn result_local_flow() -> i32 local let value : unit call result_err_value : (result i32 i32) int 7 : i32 call result_failure_score : i32 var value : (result i32 i32) fn main() -> i32 int 0 : i32 test "option local value flow" binary = : bool call option_local_flow : i32 int 1 : i32 test "option call observation" binary = : bool call option_empty_score : i32 call maybe_empty : (option i32) int 1 : i32 test "option i64 local value flow" binary = : bool call option_wide_local_flow : i32 int 1 : i32 test "option i64 call observation" binary = : bool call option_wide_empty_score : i32 call maybe_wide_empty : (option i64) int 1 : i32 test "option f64 local value flow" binary = : bool call option_float_local_flow : i32 int 1 : i32 test "option f64 call observation" binary = : bool call option_float_empty_score : i32 call maybe_float_empty : (option f64) int 1 : i32 test "option bool local value flow" binary = : bool call option_flag_local_flow : i32 int 1 : i32 test "option bool call observation" binary = : bool call option_flag_empty_score : i32 call maybe_flag_empty : (option bool) int 1 : i32 test "option string local value flow" binary = : bool call option_string_local_flow : i32 int 1 : i32 test "option string call observation" binary = : bool call option_string_empty_score : i32 call maybe_string_empty : (option string) int 1 : i32 test "result call observation" binary = : bool call result_success_score : i32 call result_ok_value : (result i32 i32) int 42 : i32 int 1 : i32 test "result local value flow" binary = : bool call result_local_flow : i32 int 1 : i32