Improve error message in tgt-vvp/eval_expr.c:draw_eval_expr_wid().

The IVL_EX_NONE type was not displaying any message and default did not
use the new ivl_expr_{file,lineno} functions to get the source location.
This patch remedies these problems.
This commit is contained in:
Cary R 2008-03-10 09:30:46 -07:00 committed by Stephen Williams
parent 6f1445ff9d
commit cc28a9a734
1 changed files with 3 additions and 2 deletions

View File

@ -2332,9 +2332,10 @@ struct vector_info draw_eval_expr_wid(ivl_expr_t exp, unsigned wid,
switch (ivl_expr_type(exp)) {
default:
fprintf(stderr, "vvp error: unhandled expr type: %u\n",
ivl_expr_type(exp));
case IVL_EX_NONE:
fprintf(stderr, "%s:%u: vvp-tgt error: unhandled expr. type: "
"%u at %s:%d\n", ivl_expr_file(exp), ivl_expr_lineno(exp),
ivl_expr_type(exp), __FILE__, __LINE__);
assert(0);
res.base = 0;
res.wid = 0;