harec

[hare] Hare compiler, written in C11 for POSIX OSs
Log | Files | Refs | README | LICENSE

commit e2e0d12053b523274432fd682909428756efac62
parent a936b477287e4288c1352a925b0439da5e14a9b8
Author: Bor Grošelj Simić <bgs@turminal.net>
Date:   Sat, 21 May 2022 03:03:09 +0200

scan_enum_field: remove obsolete TODOs

the type contents setting comment is not applicable anymore
and the out of bounds integer cases are handled by generic integer
assignability code.

Signed-off-by: Bor Grošelj Simić <bgs@turminal.net>

Diffstat:
Msrc/check.c | 4----
1 file changed, 0 insertions(+), 4 deletions(-)

diff --git a/src/check.c b/src/check.c @@ -3408,7 +3408,6 @@ scan_enum_field(struct context *ctx, struct incomplete_declaration *idecl) } ctx->resolving_enum = idecl->field->enum_scope; - // TODO set this type's contents to the correct builtin type const struct type *type = type_store_lookup_atype(ctx->store, idecl->field->type); @@ -3416,9 +3415,6 @@ scan_enum_field(struct context *ctx, struct incomplete_declaration *idecl) xcalloc(1, sizeof(struct expression)); value->result = type; if (idecl->field->field->value) { // explicit value - // TODO: negative values in unsigned enums, too big values in - // signed enums - struct expression *initializer = xcalloc(1, sizeof(struct expression)); check_expression(ctx, idecl->field->field->value,