(&mut self)
| 150 | }) |
| 151 | } |
| 152 | fn flag(&mut self) -> FormatResult<bool> { |
| 153 | match get(&mut self.control)? { |
| 154 | 0 => Ok(false), |
| 155 | 1 => Ok(true), |
| 156 | _ => Err(invalid("invalid presence flag")), |
| 157 | } |
| 158 | } |
| 159 | fn count(&mut self, cost: usize, available: usize) -> FormatResult<usize> { |
| 160 | let n = usize::try_from(get(&mut self.control)?).map_err(|_| invalid("count overflow"))?; |
| 161 | if n > available { |
no test coverage detected