| ... | ... | @@ -175,13 +175,7 @@ pub fn Elem(comptime T: type) type { |
| 175 | 175 | }, |
| 176 | 176 | .Many, .C, .Slice => return info.child, |
| 177 | 177 | }, |
| 178 | | .Optional => |info| switch (@typeInfo(info.child)) { |
| 179 | | .Pointer => |ptr_info| switch (ptr_info.size) { |
| 180 | | .Many => return ptr_info.child, |
| 181 | | else => {}, |
| 182 | | }, |
| 183 | | else => {}, |
| 184 | | }, |
| 178 | .Optional => |info| return Elem(info.child), |
| 185 | 179 | else => {}, |
| 186 | 180 | } |
| 187 | 181 | @compileError("Expected pointer, slice, array or vector type, found '" ++ @typeName(T) ++ "'"); |