summaryrefslogtreecommitdiff
path: root/src/syntax/kind.rs
diff options
context:
space:
mode:
authorMarmare314 <49279081+Marmare314@users.noreply.github.com>2023-05-03 11:16:38 +0200
committerGitHub <noreply@github.com>2023-05-03 11:16:38 +0200
commitedc0632d8c9d7a17cc795a57de27c6b22a748158 (patch)
treea1c6e412512bed7b56c7c100b8affeac7e29f389 /src/syntax/kind.rs
parent2772e6436c8a010662820c3e545e69ab922f133a (diff)
Add shorthand for root operation (#929)
Diffstat (limited to 'src/syntax/kind.rs')
-rw-r--r--src/syntax/kind.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/syntax/kind.rs b/src/syntax/kind.rs
index 0717e16c..111fb260 100644
--- a/src/syntax/kind.rs
+++ b/src/syntax/kind.rs
@@ -67,6 +67,8 @@ pub enum SyntaxKind {
MathAttach,
/// A fraction in math: `x/2`.
MathFrac,
+ /// A root in math: `√x`, `∛x` or `∜x`.
+ MathRoot,
/// A hashtag that switches into code mode: `#`.
Hashtag,
@@ -134,6 +136,8 @@ pub enum SyntaxKind {
Dots,
/// An arrow between a closure's parameters and body: `=>`.
Arrow,
+ /// A root: `√`, `∛` or `∜`.
+ Root,
/// The `not` operator.
Not,
@@ -347,6 +351,7 @@ impl SyntaxKind {
Self::MathDelimited => "delimited math",
Self::MathAttach => "math attachments",
Self::MathFrac => "math fraction",
+ Self::MathRoot => "math root",
Self::Hashtag => "hashtag",
Self::LeftBrace => "opening brace",
Self::RightBrace => "closing brace",
@@ -378,6 +383,7 @@ impl SyntaxKind {
Self::SlashEq => "divide-assign operator",
Self::Dots => "dots",
Self::Arrow => "arrow",
+ Self::Root => "root",
Self::Not => "operator `not`",
Self::And => "operator `and`",
Self::Or => "operator `or`",