mirror of
https://github.com/zeek/zeek.git
synced 2025-10-05 08:08:19 +00:00
Allow local table variables to be initialized with {} list expressions.
This commit is contained in:
parent
f8ec98625d
commit
aae60a6d76
5 changed files with 50 additions and 6 deletions
|
@ -202,7 +202,8 @@ Stmt* add_local(ID* id, BroType* t, init_class c, Expr* init,
|
|||
Ref(id);
|
||||
|
||||
Stmt* stmt =
|
||||
new ExprStmt(new AssignExpr(new NameExpr(id), init, 0));
|
||||
new ExprStmt(new AssignExpr(new NameExpr(id), init, 0, 0,
|
||||
id->Attrs() ? id->Attrs()->Attrs() : 0 ));
|
||||
stmt->SetLocationInfo(init->GetLocationInfo());
|
||||
|
||||
return stmt;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue