()
| 148 | |
| 149 | #[test] |
| 150 | fn allows_generic_placeholder_arithmetic() { |
| 151 | let source = r#" |
| 152 | struct Box<T> { |
| 153 | val: T, |
| 154 | ptr: T* |
| 155 | } |
| 156 | |
| 157 | main: () -> i32 { |
| 158 | box1: Box<i32>* = new(Box<i32>) |
| 159 | box1.val = 42 |
| 160 | return box1.val + 58 |
| 161 | } |
| 162 | "#; |
| 163 | |
| 164 | let mut pipeline = CompilationPipeline::new(); |
| 165 | pipeline.set_write_artifacts(false); |
| 166 | let result = pipeline.compile(source); |
| 167 | assert!( |
| 168 | result.is_ok(), |
| 169 | "expected generic placeholder arithmetic to compile successfully: {:?}", |
| 170 | result.err() |
| 171 | ); |
| 172 | } |
| 173 | |
| 174 | #[test] |
| 175 | fn allows_array_index_place_access() { |
nothing calls this directly
no test coverage detected