Added the possibility to use sqrt() in the FUNCTION block - it could be removed again when finally pow() will be implemented
This commit is contained in:
@@ -69,6 +69,7 @@
|
||||
#define FUN_LOG 12
|
||||
#define FUN_LN 13
|
||||
#define FUN_EXP 14
|
||||
#define FUN_SQRT 15
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
typedef struct func_tree_node {
|
||||
|
||||
@@ -105,6 +105,7 @@ struct PFunctionGrammar : public grammar<PFunctionGrammar>
|
||||
| lexeme_d[ root_node_d[ str_p("LOG") ] >> ch_p('(') ] >> expression >> ch_p(')')
|
||||
| lexeme_d[ root_node_d[ str_p("LN") ] >> ch_p('(') ] >> expression >> ch_p(')')
|
||||
| lexeme_d[ root_node_d[ str_p("EXP") ] >> ch_p('(') ] >> expression >> ch_p(')')
|
||||
| lexeme_d[ root_node_d[ str_p("SQRT") ] >> ch_p('(') ] >> expression >> ch_p(')')
|
||||
;
|
||||
|
||||
factor = real
|
||||
|
||||
Reference in New Issue
Block a user