xref: /trunk/odf_docs/openformula-operators.tsv (revision 1354dfcdad4129e7cc561fdcfbb4f6c8958f0428) !
1Operator    Symbol  OpCode  OpCodeValue Precedence  Associativity   Arity   ParserFile  CompilerFile    EvaluatorFile   ODFSection  Status  Notes
2Range   :   ocRange SC_OPCODE_RANGE 56  Left    Binary  FormulaCompiler.cxx:RangeLine   compiler.cxx    interpr1.cxx:ScRangeFunc    6.1/3.3 FULL    Cell range A1:B3.
3Intersection    !   ocIntersect SC_OPCODE_INTERSECT 54  Left    Binary  FormulaCompiler.cxx:IntersectionLine    compiler.cxx    interpr1.cxx:ScIntersect    6.1/3.4 FULL    Automatic via whitespace too (ocSpaces->ocIntersect at FormulaCompiler.cxx:830-831).
4Union   ~   ocUnion SC_OPCODE_UNION 55  Left    Binary  FormulaCompiler.cxx:UnionLine   compiler.cxx    interpr1.cxx:ScUnionFunc    6.1/3.5 FULL    Range list (A1;A2) converted to union at FormulaCompiler.cxx:914-922.
5Concatenation   &   ocAmpersand SC_OPCODE_AMPERSAND 44  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScAmpersand    6.1 FULL    String concatenation.
6Addition    +   ocAdd   SC_OPCODE_ADD   40  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScAdd  6.1 FULL    Also unary plus.
7Subtraction -   ocSub / ocNegSub    SC_OPCODE_SUB / SC_OPCODE_NEG_SUB   41/62   Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScSub  6.1 FULL    Also unary minus.
8Multiplication  *   ocMul   SC_OPCODE_MUL   42  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScMul  6.1 FULL    Standard.
9Division    /   ocDiv   SC_OPCODE_DIV   43  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScDiv  6.1 FULL    Div by zero -> errDivisionByZero (interpre.hxx:955-959).
10Power   ^   ocPow   SC_OPCODE_POW   45  Right   Binary  FormulaCompiler.cxx compiler.cxx    interpr5.cxx:ScPow  6.1 FULL    Right-associative; POWER(0,0) impl-defined.
11Equal   =   ocEqual SC_OPCODE_EQUAL 46  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScEqual    6.1 FULL    Comparison.
12NotEqual    <>  ocNotEqual  SC_OPCODE_NOT_EQUAL 47  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScNotEqual 6.1 FULL    Comparison.
13Less    <   ocLess  SC_OPCODE_LESS  48  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScLess 6.1 FULL    Comparison.
14Greater >   ocGreater   SC_OPCODE_GREATER   49  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScGreater  6.1 FULL    Comparison.
15LessEqual   <=  ocLessEqual SC_OPCODE_LESS_EQUAL    50  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScLessEqual    6.1 FULL    Comparison.
16GreaterEqual    >=  ocGreaterEqual  SC_OPCODE_GREATER_EQUAL 51  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScGreaterEqual 6.1 FULL    Comparison.
17LogicalAND  AND ocAnd   SC_OPCODE_AND   52  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScAnd  6.1 FULL    Logical AND.
18LogicalOR   OR  ocOr    SC_OPCODE_OR    53  Left    Binary  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScOr   6.1 FULL    Logical OR.
19LogicalNOT  NOT ocNot   SC_OPCODE_NOT   60  Right   Unary (prefix)  FormulaCompiler.cxx:UnaryLine   compiler.cxx    interpr1.cxx:ScNot  6.1 FULL    Prefix.
20Negation    -   ocNeg   SC_OPCODE_NEG   61  Right   Unary (prefix)  FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScNeg  6.1 FULL    Prefix.
21Percent %   ocPercentSign   SC_OPCODE_PERCENT_SIGN  19  Left    Postfix FormulaCompiler.cxx compiler.cxx    interpr1.cxx:ScPercentSign  6.1 FULL    Divides by 100, postfix.
22FunctionCall    ( ) ocOpen/ocClose  SC_OPCODE_OPEN/CLOSE    8/9 N/A N/A FormulaCompiler.cxx compiler.cxx    -   5.1 FULL    name(arg-list).
23InlineArray { } ocArrayOpen/ocArrayClose    SC_OPCODE_ARRAY_OPEN/CLOSE  20/21   N/A N/A FormulaCompiler.cxx compiler.cxx    -   5.4 FULL    {1,2;3,4} matrix.
24ErrorConst  #NULL!  ocErrNull   SC_OPCODE_ERROR_NULL    30  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
25ErrorConst  #DIV/0! ocErrDivZero    SC_OPCODE_ERROR_DIVZERO 31  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
26ErrorConst  #VALUE! ocErrValue  SC_OPCODE_ERROR_VALUE   32  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
27ErrorConst  #REF!   ocErrRef    SC_OPCODE_ERROR_REF 33  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
28ErrorConst  #NAME?  ocErrName / ocNoName    SC_OPCODE_ERROR_NAME / SC_OPCODE_NO_NAME    34/367  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    #NAME? = bad function/ref.
29ErrorConst  #NUM!   ocErrNum    SC_OPCODE_ERROR_NUM 35  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
30ErrorConst  #N/A    ocErrNA SC_OPCODE_ERROR_NA  36  N/A Constant    FormulaCompiler.cxx compiler.cxx    -   5.5 FULL    Error constant.
31Missing Missing ocMissing   SC_OPCODE_MISSING   11  N/A N/A FormulaCompiler.cxx compiler.cxx    -   5.6 FULL    Optional parameter placeholder.
32Spaces  sp  ocSpaces    SC_OPCODE_SPACES    13  N/A N/A FormulaCompiler.cxx:830 compiler.cxx    -   5.2 FULL    Whitespace converted to intersection in references.
33NamedExpr   Name    ocName  SC_OPCODE_NAME  4   N/A N/A FormulaCompiler.cxx compiler.cxx    -   3.7 FULL    Named expressions resolvable.
34ExternalRef External    ocExternalRef   SC_OPCODE_EXTERNAL_REF  5   N/A N/A FormulaCompiler.cxx compiler.cxx    -   3.8 FULL    External named expressions (UNO ext).
35QuotedLabel "Label" -   -   -   N/A N/A FormulaCompiler.cxx compiler.cxx    -   3.9 UNVERIFIED  Quoted labels as implicit intersection not confirmed in source.
36