()
| 2155 | return 0 |
| 2156 | } |
| 2157 | "#, |
| 2158 | ); |
| 2159 | } |
| 2160 | |
| 2161 | // --- Aggregate by-value function ABI --- |
| 2162 | |
| 2163 | #[test] |
| 2164 | fn enum_argument_is_passed_by_value() { |
| 2165 | assert_exit( |
| 2166 | r#" |
| 2167 | read: (value: Option<i32>) -> i32 { |
| 2168 | match value { |
| 2169 | Some(inner) -> { |
| 2170 | return inner |
| 2171 | } |
| 2172 | None -> { |
| 2173 | return 0 |
| 2174 | } |
| 2175 | } |
nothing calls this directly
no test coverage detected