Skip to content

Lack of ⊻ U+22BB #137

Description

@uwni

Currently, in Typst, the xor symbol is mapped to ⊕ (U+2295, plus.o). I propose remapping xor to ⊻ (U+22BB, XOR in Unicode), which is currently not encoded in Typst.

Rationale

Semantic Consistency: Typst uses ∨ (or, U+2228) for the logical OR operation. In mathematical logic, if "OR" is represented by the "vee" symbol (∨), its exclusive counterpart "XOR" is standardly represented by the "vee with bar" symbol (⊻).

Unicode Alignment: The Unicode character U+22BB is explicitly named "XOR". Using this mapping aligns Typst with international standards.

Ambiguity Resolution: Currently, xor is an alias for plus.o (⊕). While ⊕ is sometimes used for XOR (especially when "OR" is represented as +), it primarily means "circled plus" or "direct sum." Decoupling these allows:

xor → ⊻ (Logical exclusive OR)

plus.o → ⊕ (Mathematical circled plus)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    proposalThis may still need discussion

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions