____ _____
/\ \ // /
\ \ \ // / ______
\ \ \/ / ___ | | _ \ __ _ _ __ ___ ___ _ __
\ \ \ |___| | | |_) / _` | '__/ __|/ _ \ '__|
/ / /\ \ |___| | | __/ (_| | | \\__ \ __/ |
/ / /\ \ \ |_|_| \\__,_|_| ||___/\___|_|
/ / / \ \ \
\/___/ \_\___\ BY JONAYED
- Lightweight and fast expression parser
- New functions can easily be added
- Compiled expressions are cached for performance and later use
- Result types of STRING, NUMBER
- Constants
- Variables
This project uses C++ 21 and requires no additional libraries other than the ones provided by the GCC or Clang.
Clone the repository from Github:
$ git clone https://github.com/JonayedMohiuddin/X-Parser- or, Download the zip and unzip on your workspace folder.
Compile the project and run the object file:
- Compiling :
g++ main.cpp -o main - Running :
./main
- Compiling :
clang++ main.cpp -o main - Running :
./main
NUMBER - All numbers are handled as Double
EMPTY
Evaluation
Assignment =
Operators + - * / MOD % ^ POW
Logical < <= == != >= > AND OR NOT
Ternary ? :
Binary << >> | &
Constants NULL PI
Functions CLEARMEMORY CLEARVARIABLES
Functions ABS ARCCOS ARCSIN ARCTAN ARRAYLEN AVERAGE CEILING CONTAINS CONTAINSALL CONTAINSANY
COS DIGITSONLY ENDSWITH EXP FACTORIAL FIND FLOOR FORMAT FORMATBYLEN GUID HEX ISANYOF ISBLANK ISBOOLEAN ISDATE
ISNONEOF ISNULL ISNUMBER LEFT LEFTOF LEN LOG LOG10 LOWER MAKEBOOLEAN MAKEDATE MATCH
MAX MID MIN NAMECASE RANDOM REPLACE REPLACEALL REPLACEFIRST RIGHT RIGHTOF ROUND SIN
SPLIT SQR SQRT STARTSWITH STR STRING TAN TRIM TRIMLEFT TRIMRIGHT UPPER VAL
Examples:
V.1.1.5 - Last Breath
2.0.0 Future Update (Resurgence)
- Deprecation of old algorithm
- Implementation of new Algorithm
- Lexer and Tokens restructured
1.1.0 Feature Upgrade (Last Breath)
- Improved Lexer
- Multiplication is default operator.
- Added brace/parantheses support
1.0.5 Feature Upgrade
- Added basic functions
- More operators
1.0.0 Initial release to GitHub.
X-Parser is licensed under the MIT Licence license. Permission is granted to anyone to use this software for any purpose, including commercial applications.