harec

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 1b6cb72b854183fd61d8e59f99473fce2173e8b5
parent cc49809c25f641f3d1d83ecf24b104c0c9cc7e35
Author: Drew DeVault <sir@cmpwn.com>
Date:   Sun, 25 Apr 2021 09:43:47 -0400

check: make unhandled error less inscrutable

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

diff --git a/src/check.c b/src/check.c @@ -2549,7 +2549,7 @@ check_expression(struct context *ctx, if (hint && hint->storage == STORAGE_VOID) { if ((expr->result->flags & TYPE_ERROR) != 0) { return error(aexpr->loc, expr, errors, - "Cannot assign error type to void"); + "Cannot ignore error here"); } if (type_dealias(expr->result)->storage != STORAGE_TAGGED) { return errors; @@ -2561,7 +2561,7 @@ check_expression(struct context *ctx, continue; } return error(aexpr->loc, expr, errors, - "Cannot assign error type to void"); + "Cannot ignore error here"); } } return errors;