mirror of
https://github.com/zeek/zeek.git
synced 2025-10-08 17:48:21 +00:00
Merge remote-tracking branch 'origin/topic/johanna/1095-just-get-rid-of-it'
* origin/topic/johanna/1095-just-get-rid-of-it: Re-add TYPE_COUNTER without function and deprecation marker. Completely remove all traces of the COUNTER type.
This commit is contained in:
commit
22b401f52f
26 changed files with 24 additions and 69 deletions
|
@ -1685,12 +1685,9 @@ BitExpr::BitExpr(BroExprTag arg_tag, ExprPtr arg_op1, ExprPtr arg_op2)
|
|||
if ( IsVector(bt2) )
|
||||
bt2 = t2->AsVectorType()->Yield()->Tag();
|
||||
|
||||
if ( (bt1 == zeek::TYPE_COUNT || bt1 == zeek::TYPE_COUNTER) &&
|
||||
(bt2 == zeek::TYPE_COUNT || bt2 == zeek::TYPE_COUNTER) )
|
||||
if ( (bt1 == zeek::TYPE_COUNT) && (bt2 == zeek::TYPE_COUNT) )
|
||||
{
|
||||
if ( bt1 == zeek::TYPE_COUNTER && bt2 == zeek::TYPE_COUNTER )
|
||||
ExprError("cannot apply a bitwise operator to two \"counter\" operands");
|
||||
else if ( is_vector(op1) || is_vector(op2) )
|
||||
if ( is_vector(op1) || is_vector(op2) )
|
||||
SetType(zeek::make_intrusive<zeek::VectorType>(base_type(zeek::TYPE_COUNT)));
|
||||
else
|
||||
SetType(base_type(zeek::TYPE_COUNT));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue