Get an example member of this type set. This is used for error messages to avoid suggesting invalid types.
(self)
| 844 | /// |
| 845 | /// This is used for error messages to avoid suggesting invalid types. |
| 846 | pub fn example(self) -> Type { |
| 847 | let t = if self.ints.max().unwrap_or(0) > 5 { |
| 848 | types::I32 |
| 849 | } else if self.floats.max().unwrap_or(0) > 5 { |
| 850 | types::F32 |
| 851 | } else { |
| 852 | types::I8 |
| 853 | }; |
| 854 | t.by(1 << self.lanes.min().unwrap()).unwrap() |
| 855 | } |
| 856 | } |
| 857 | |
| 858 | /// Operand constraints. This describes the value type constraints on a single `Value` operand. |