[brlcad-commits] SF.net SVN: brlcad:[33158] brlcad/trunk/src/libpc/pcMathGrammar.h
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: <hom...@us...> - 2008-11-12 05:11:19
|
Revision: 33158 http://brlcad.svn.sourceforge.net/brlcad/?rev=33158&view=rev Author: homovulgaris Date: 2008-11-12 05:11:14 +0000 (Wed, 12 Nov 2008) Log Message: ----------- Different closures for MathVM expressions Modified Paths: -------------- brlcad/trunk/src/libpc/pcMathGrammar.h Modified: brlcad/trunk/src/libpc/pcMathGrammar.h =================================================================== --- brlcad/trunk/src/libpc/pcMathGrammar.h 2008-11-10 19:35:56 UTC (rev 33157) +++ brlcad/trunk/src/libpc/pcMathGrammar.h 2008-11-12 05:11:14 UTC (rev 33158) @@ -80,6 +80,31 @@ }; }; +boost::spirit::symbols<char> NameGrammar::reserved_keywords; +/** Different types of closures */ + +struct FuncExprClosure : boost spirit::closure<FuncExprClosure, Stack, std::string, int, boost::shared_ptr<MathFunction> +{ + member1 stack; + member2 name; + member3 arity; + member4 function_ptr; +}; + +struct LogicalClosure : boost::spirit::closure<LogicalClosure, Stack, bool> +{ + member1 stack; + member2 or_op; +}; + + +struct ConditionalClosure : boost::spirit::closure<ConditionalClosure, Stack, Stack, Stack> +{ + member1 stack; + member2 stack1; + member3 stack2; +}; + /** * ExpressionGrammar implementation * Stack closure is attached to the grammar itself This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |