vlog95: Emit a new doing a shallow copy as an error.
This commit is contained in:
parent
c55eb37148
commit
431d62185b
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2000-2012 Stephen Williams (steve@icarus.com)
|
||||
* Copyright (c) 2000-2013 Stephen Williams (steve@icarus.com)
|
||||
* Copyright CERN 2013 / Stephen Williams (steve@icarus.com)
|
||||
*
|
||||
* This source code is free software; you can redistribute it
|
||||
|
|
@ -308,6 +308,7 @@ static void elaborate_scope_class(Design*des, NetScope*scope,
|
|||
// not allowed to escape a class method.
|
||||
NetScope*class_scope = new NetScope(0, hname_t(pclass->pscope_name()),
|
||||
NetScope::CLASS);
|
||||
class_scope->set_line(pclass);
|
||||
class_scope->set_class_def(use_class);
|
||||
use_class->set_class_scope(class_scope);
|
||||
|
||||
|
|
|
|||
|
|
@ -724,6 +724,15 @@ void emit_expr(ivl_scope_t scope, ivl_expr_t expr, unsigned wid)
|
|||
fprintf(vlog_out, "%s", ivl_expr_name(expr));
|
||||
emit_expr_func(scope, expr, wid);
|
||||
break;
|
||||
case IVL_EX_SHALLOWCOPY:
|
||||
fprintf(vlog_out, "<new> ");
|
||||
emit_expr(scope, ivl_expr_oper2(expr), wid);
|
||||
fprintf(stderr, "%s:%u: vlog95 error: New operator "
|
||||
"is not supported.\n",
|
||||
ivl_expr_file(expr),
|
||||
ivl_expr_lineno(expr));
|
||||
vlog_errors += 1;
|
||||
break;
|
||||
case IVL_EX_SIGNAL:
|
||||
emit_expr_signal(scope, expr, wid);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Reference in New Issue