(&self, i: usize)
| 661 | type Output = ParamType; |
| 662 | |
| 663 | fn index(&self, i: usize) -> &Self::Output { |
| 664 | match self { |
| 665 | Self::Exact(p) => &p[i], |
| 666 | Self::Variadic { leading, trailing } => leading.get(i).unwrap_or(trailing), |
| 667 | } |
| 668 | } |
| 669 | } |
| 670 | |
| 671 | /// Provides a shorthand function for writing `ParamList::Exact`. |
no test coverage detected