mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 22:58:20 +00:00
update script-to-C++ compilation for new record constructor internals
This commit is contained in:
parent
e7412e257f
commit
a1324a882d
3 changed files with 39 additions and 2 deletions
|
@ -224,6 +224,17 @@ RecordValPtr record_constructor__CPP(vector<ValPtr> vals, RecordTypePtr t)
|
|||
return rv;
|
||||
}
|
||||
|
||||
RecordValPtr record_constructor_map__CPP(vector<ValPtr> vals, vector<int> map, RecordTypePtr t)
|
||||
{
|
||||
auto rv = make_intrusive<RecordVal>(move(t));
|
||||
auto n = vals.size();
|
||||
|
||||
for ( auto i = 0u; i < n; ++i )
|
||||
rv->Assign(map[i], vals[i]);
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
VectorValPtr vector_constructor__CPP(vector<ValPtr> vals, VectorTypePtr t)
|
||||
{
|
||||
auto vv = make_intrusive<VectorVal>(move(t));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue