@typeInfo now uses optional types instead of @typeOf(undefined)

This commit is contained in:
Alexandros Naskos
2018-06-19 17:45:19 +03:00
parent 1ca90b5856
commit 1392313236
4 changed files with 65 additions and 44 deletions

View File

@@ -6627,7 +6627,7 @@ Buf *codegen_generate_builtin_source(CodeGen *g) {
"\n"
" pub const Union = struct {\n"
" layout: ContainerLayout,\n"
" tag_type: type,\n"
" tag_type: ?type,\n"
" fields: []UnionField,\n"
" defs: []Definition,\n"
" };\n"
@@ -6644,20 +6644,20 @@ Buf *codegen_generate_builtin_source(CodeGen *g) {
" pub const FnArg = struct {\n"
" is_generic: bool,\n"
" is_noalias: bool,\n"
" arg_type: type,\n"
" arg_type: ?type,\n"
" };\n"
"\n"
" pub const Fn = struct {\n"
" calling_convention: CallingConvention,\n"
" is_generic: bool,\n"
" is_var_args: bool,\n"
" return_type: type,\n"
" async_allocator_type: type,\n"
" return_type: ?type,\n"
" async_allocator_type: ?type,\n"
" args: []FnArg,\n"
" };\n"
"\n"
" pub const Promise = struct {\n"
" child: type,\n"
" child: ?type,\n"
" };\n"
"\n"
" pub const Definition = struct {\n"