Figurecore-fixities
| Precedence | Left | Right | Non |
| 9 | << | >> | |
| 8 | ^ | ||
| 7 | * / // | ||
| 6 | + - | ||
| 5 | ++ :: | ||
| 4 | == /= < > <= >= | ||
| 3 | && | ||
| 2 | || | ||
| 0 | |> | <| |
Referred to from
Tests (20)
- elm / InfixAssocLeftArithTest`-`, `/` and `//` associate to the left.
- elm / InfixAssocPipesTest`|>` associates to the left and `<|` to the right.
- elm / InfixAssocRightConsAppendTest`::` and `++` (both precedence 5) associate to the right, so `"a" ++ "b" :: [ "c" ]` does not type.
- elm / InfixAssocRightPowTest`^` associates to the right.
- elm / InfixLastOperandAnyExprTestThe last operand of a chain may be any expression: an `if` or a lambda.
- elm / InfixMixedAssocComposeTest`f << g >> h` is not a phrase: `<<` and `>>` have equal precedence and associate in opposite ways.
- elm / InfixMixedAssocPipesTest`a |> f <| b` is not a phrase: `|>` and `<|` have equal precedence and associate in opposite ways.
- elm / InfixNegatedOperandTestA negation symbol in an operator chain negates the atomic expression after it, and no more.
- elm / InfixNonAssocCompareTest`a < b == c` is not a phrase: `<` and `==` have equal precedence and associate neither way.
- elm / InfixNonAssocEqTwiceTest`a == b == c` is not a phrase: `==` associates neither way.
- elm / InfixNonAssocSeparatedLegalTestTwo non-associative operators of equal precedence may share a chain when an operator of lower precedence stands between them.
- elm / InfixPrecAddOverConsTest`+` (precedence 6) binds more tightly than `::` (precedence 5).
- elm / InfixPrecAndOverOrTest`&&` (precedence 3) binds more tightly than `||` (precedence 2).
- elm / InfixPrecAppendOverEqTest`++` (precedence 5) binds more tightly than `==` (precedence 4).
- elm / InfixPrecApplicationFirstTestApplication binds more tightly than any operator.
- elm / InfixPrecCompareOverAndTest`<` (precedence 4) binds more tightly than `&&` (precedence 3).
- elm / InfixPrecComposeOverPipeTest`<<` (precedence 9) binds more tightly than `|>` (precedence 0).
- elm / InfixPrecMulOverAddTest`*` (precedence 7) binds more tightly than `+` (precedence 6).
- elm / InfixPrecOrOverPipeTest`||` (precedence 2) binds more tightly than `|>` (precedence 0).
- elm / InfixPrecPowOverMulTest`^` (precedence 8) binds more tightly than `*` (precedence 7).
Discussions
Discuss this figure·Search the discussions on GitHub
Discussions are on GitHub; one about this figure has [fig:core-fixities] in its title.
A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.