Documentation
¶
Overview ¶
Package expr implements the `expr` built-in.
expr evaluates a single expression made of operators and operands. Operator precedence (lowest → highest):
| logical or & logical and = != < > <= >= comparison + - addition / subtraction * / % multiplication / division / modulo : STRING regex anchor-match (BRE), returns matched substring or length ( EXPR ) grouping
String comparisons fall through to numeric when both sides parse as integers. expr exits with:
0 if the result is non-zero AND non-empty 1 if the result is 0 or empty 2 on syntax error (and writes "expr: ..." to stderr)
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.