Classify dots.c
, dots.down
, dots.up
and dots.v
as normal (#1726)
Fixes #713. They were previously classified by Unicode as relations, which caused a '+' sign after one of them to be treated as a unary operator rather than a binary operator. This PR overrides the Unicode classification and classifies them as normal instead, which causes a '+' sign after one of them to be properly treated as a binary operator.
This commit is contained in:
parent
c98c3d1a38
commit
e0e797c27d
@ -216,6 +216,7 @@ impl GlyphFragment {
|
||||
pub fn with_id(ctx: &MathContext, c: char, id: GlyphId, span: Span) -> Self {
|
||||
let class = match c {
|
||||
':' => Some(MathClass::Relation),
|
||||
'⋯' | '⋱' | '⋰' | '⋮' => Some(MathClass::Normal),
|
||||
_ => unicode_math_class::class(c),
|
||||
};
|
||||
let mut fragment = Self {
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 18 KiB |
@ -11,7 +11,8 @@ $a not b$ \
|
||||
$a+b, a*b$ \
|
||||
$sum x, sum(x)$ \
|
||||
$sum product x$ \
|
||||
$f(x), zeta(x), "frac"(x)$
|
||||
$f(x), zeta(x), "frac"(x)$ \
|
||||
$a+dots.c+b$
|
||||
|
||||
---
|
||||
// Test ignored vs non-ignored spaces.
|
||||
|
Loading…
Reference in New Issue
Block a user