mirror of
https://github.com/zeek/zeek.git
synced 2025-10-01 22:28:20 +00:00
Merge remote-tracking branch 'origin/topic/vern/gen-CPP-precedence-fix'
* origin/topic/vern/gen-CPP-precedence-fix: fix for '?' operator precedence when compiling scripts to C++
This commit is contained in:
commit
00ba3483bb
3 changed files with 6 additions and 2 deletions
4
CHANGES
4
CHANGES
|
@ -1,3 +1,7 @@
|
|||
8.1.0-dev.540 | 2025-09-16 10:52:44 -0700
|
||||
|
||||
* fix for '?' operator precedence when compiling scripts to C++ (Vern Paxson, Corelight)
|
||||
|
||||
8.1.0-dev.538 | 2025-09-12 09:24:51 -0700
|
||||
|
||||
* for -O gen-standalone-C++, make the presence of uncompilable functions fatal unless -O allow-cond is used (Vern Paxson, Corelight)
|
||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
8.1.0-dev.538
|
||||
8.1.0-dev.540
|
||||
|
|
|
@ -260,7 +260,7 @@ string CPPCompile::GenCondExpr(const Expr* e, GenType gt) {
|
|||
if ( op1->GetType()->Tag() == TYPE_VECTOR )
|
||||
return string("vector_select__CPP(") + gen1 + ", " + gen2 + ", " + gen3 + ")";
|
||||
|
||||
return string("(") + gen1 + ") ? (" + gen2 + ") : (" + gen3 + ")";
|
||||
return string("((") + gen1 + ") ? (" + gen2 + ") : (" + gen3 + "))";
|
||||
}
|
||||
|
||||
string CPPCompile::GenCallExpr(const CallExpr* c, GenType gt, bool top_level) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue