Release v0.0.6
--------------
Additions:
+* #solidify directive for explicitly specifying type variables in polymorphic procs.
* properly different kinds of allocators in core/alloc/.
* `map.empty`
* `string.compare`
* `map.update`
Removals:
+* struct literals can no longer specify values for members brought in through a `use`.
Changes:
+* `::` declarations in a procedure are treated differently now. They used to represent a constant
+ value, but one that was still computed at the assignment site. Now, they instead are used to
+ declare top level expressions in the procedure scope. This means that things like structs and
+ enums can be declared at any block scope. The top-level expressions currently do not have
+ access to polymoprhic variables in the procedure.
* enum values are compile time known.
* struct literals are compile time known can be used at top level scope.
* range literals are proper things in the compiler code now.
Bug fixes:
* polymorphic procedures would get 'confused' when two structs in the program had the same name.
* function argument type mismatch would give wrong function name.
+* `structs` with `use`d members caused all sorts of problems.
Release v0.0.5
is that 'use package' can only be at the top level, and 'use' can only
be used at the block level.
- [ ] :: should not declare a local variable, just bind a name to an expression.
+ [X] :: should not declare a local variable, just bind a name to an expression.
They can still be lexically scoped.
[X] Currently accessing a field directly on a function call produces invalid
return;
}
- (*value)->value->type = enum_node->backing_type;
+ (*value)->value->type = enum_node->etcache;
} else {
AstNumLit* num = onyx_ast_node_new(semstate.node_allocator, sizeof(AstNumLit), Ast_Kind_NumLit);
num->value.l = next_assign_value;
num->flags |= Ast_Flag_Comptime;
num->type = enum_node->etcache;
-
+
(*value)->value = num;
}