Skip to content

Files

Latest commit

 

History

History

shunting-yard

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Constexpr Shunting Yard parser

This subproject is a constexpr compatible implementation of Dijkstra's Shunting Yard algorithm, which means the produced result can be used to produce a constexpr value.

It can recognize mathematical formulas and turn them into Reverse Polish Notation (RPN). Tokens such as operators, functions, variables, or parenthesis are user-defined.

Example:

Starting formula: sin ( max ( 2, 3 ) / 3 * pi ^ 2 ) Result: 2 3 max 3 / pi 2 ^ * sin

Dependencies