| ... | @@ -239,3 +239,11 @@ fn docap(alloc: *std.mem.Allocator, writer: anytype, comptime top: astgen.Value, | ... | @@ -239,3 +239,11 @@ fn docap(alloc: *std.mem.Allocator, writer: anytype, comptime top: astgen.Value, |
| 239 | try do(alloc, writer, bottom, data, ctx, indent, flag1); | 239 | try do(alloc, writer, bottom, data, ctx, indent, flag1); |
| 240 | } | 240 | } |
| 241 | } | 241 | } |
| | 242 | |
| | 243 | fn FnArgsTuple(func: anytype) type { |
| | 244 | var types: []const type = &.{}; |
| | 245 | inline for (@typeInfo(@TypeOf(func)).Fn.args) |arg| { |
| | 246 | types = types ++ &[_]type{arg.arg_type.?}; |
| | 247 | } |
| | 248 | return std.meta.Tuple(types); |
| | 249 | } |