mirror of
https://github.com/typst/typst
synced 2025-05-14 17:15:28 +08:00
Mention the calc
module in the operator list (#5595)
This commit is contained in:
parent
05559a6638
commit
24c08a7ec0
@ -992,7 +992,7 @@ pub fn div_euclid(
|
|||||||
/// #calc.rem-euclid(1.75, 0.5) \
|
/// #calc.rem-euclid(1.75, 0.5) \
|
||||||
/// #calc.rem-euclid(decimal("1.75"), decimal("0.5"))
|
/// #calc.rem-euclid(decimal("1.75"), decimal("0.5"))
|
||||||
/// ```
|
/// ```
|
||||||
#[func(title = "Euclidean Remainder")]
|
#[func(title = "Euclidean Remainder", keywords = ["modulo", "modulus"])]
|
||||||
pub fn rem_euclid(
|
pub fn rem_euclid(
|
||||||
/// The callsite span.
|
/// The callsite span.
|
||||||
span: Span,
|
span: Span,
|
||||||
|
@ -340,7 +340,10 @@ packages. For more details on this, see the
|
|||||||
|
|
||||||
## Operators
|
## Operators
|
||||||
The following table lists all available unary and binary operators with effect,
|
The following table lists all available unary and binary operators with effect,
|
||||||
arity (unary, binary) and precedence level (higher binds stronger).
|
arity (unary, binary) and precedence level (higher binds stronger). Some
|
||||||
|
operations, such as [modulus]($calc.rem-euclid), do not have a special syntax
|
||||||
|
and can be achieved using functions from the
|
||||||
|
[`calc`]($category/foundations/calc) module.
|
||||||
|
|
||||||
| Operator | Effect | Arity | Precedence |
|
| Operator | Effect | Arity | Precedence |
|
||||||
|:----------:|---------------------------------|:------:|:----------:|
|
|:----------:|---------------------------------|:------:|:----------:|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user