Added support for the mod operator

This commit is contained in:
2025-11-24 22:53:00 -07:00
parent 56f0e292b7
commit 37d5643615
7 changed files with 161 additions and 140 deletions

View File

@@ -158,6 +158,8 @@ pub enum Symbol {
Dot,
/// Represents the `^` symbol
Caret,
/// Represents the `%` symbol
Percent,
// Double Character Symbols
/// Represents the `==` symbol
@@ -180,7 +182,12 @@ impl Symbol {
pub fn is_operator(&self) -> bool {
matches!(
self,
Symbol::Plus | Symbol::Minus | Symbol::Asterisk | Symbol::Slash | Symbol::Exp
Symbol::Plus
| Symbol::Minus
| Symbol::Asterisk
| Symbol::Slash
| Symbol::Exp
| Symbol::Percent
)
}