mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
-O gen-C++ fixes for compatibility with GH-3249 changes
minor -O gen-C++ BTest updates
This commit is contained in:
parent
85cd1d69a4
commit
80eed34985
6 changed files with 19 additions and 8 deletions
|
@ -541,7 +541,9 @@ string CPPCompile::GenAddToExpr(const Expr* e, GenType gt, bool top_level)
|
|||
|
||||
if ( t->Tag() == TYPE_VECTOR )
|
||||
{
|
||||
if ( same_type(lhs->GetType(), rhs->GetType()) )
|
||||
auto& rt = rhs->GetType();
|
||||
|
||||
if ( IsVector(rt->Tag()) && same_type(lhs->GetType(), rt) )
|
||||
add_to_func = "vector_vec_append__CPP";
|
||||
else
|
||||
add_to_func = "vector_append__CPP";
|
||||
|
|
|
@ -24,7 +24,8 @@ inline ValPtr vector_append__CPP(VectorValPtr v1, const ValPtr& v2)
|
|||
// Appends vector v2 to the vector v1.
|
||||
inline ValPtr vector_vec_append__CPP(VectorValPtr v1, const VectorValPtr& v2)
|
||||
{
|
||||
v2->AddTo(v1.get(), false);
|
||||
if ( ! v2->AddTo(v1.get(), false) )
|
||||
reporter->CPPRuntimeError("incompatible vector element assignment");
|
||||
return v1;
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||
error in <...>/create-failure.zeek (C++), line 61: Failed to attach master store backend_failure: (<___>testing_btest__tmp_broker_store_create_failure_create_failure_zeek__zeek_init__35__zf())
|
||||
error in <...>/create-failure.zeek (C++), line 61: Could not create Broker master store '../fail' (<___>testing_btest__tmp_broker_store_create_failure_create_failure_zeek__zeek_init__35__zf())
|
||||
error in <...>/create-failure.zeek (C++), line 61: Failed to attach master store backend_failure: (<___>testing_btest__tmp_broker_store_create_failure_create_failure_zeek__zeek_init__36__zf())
|
||||
error in <...>/create-failure.zeek (C++), line 61: Could not create Broker master store '../fail' (<___>testing_btest__tmp_broker_store_create_failure_create_failure_zeek__zeek_init__36__zf())
|
||||
error in <no location>: invalid Broker store handle (broker::store::{})
|
||||
error in <no location>: invalid Broker store handle (broker::store::{})
|
||||
error in <no location>: invalid Broker store handle (broker::store::{})
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||
runtime error in compiled code: incompatible vector element assignment
|
|
@ -0,0 +1,6 @@
|
|||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||
[0, 1, 2, 3]
|
||||
[4, 0, 1, 2, 3]
|
||||
[1, 2, 3, [4, 5]], 4, count, count, vector of count
|
||||
[[r=r], [r=r], [s=s], [s=s]]
|
||||
[a, -3]
|
|
@ -1,5 +1,5 @@
|
|||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__35__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__35__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__35__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type string for key, got port (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__35__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__36__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__36__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type Cluster::Pool for pool (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__36__zf())
|
||||
error in <...>/publish-hrw-type-check.zeek (C++), line 13: expected type string for key, got port (<___>testing_btest__tmp_scripts_base_frameworks_cluster_publish_hrw_type_check_publish_hrw_type_check_zeek__zeek_init__36__zf())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue