Re: Is there way to complete my Calculator with Bison or other GNU tools?

2006-07-03 Thread David Fang
> I want to encapsulate a C++ class ,which can works like a calculator,its > structure seems like this: > Class Calc > { > //in yylex, result will be evaluated... > > }; > In an other word, Can yylex ,yyparse() be encapsulated in a C++ Class ? Hi, "Can...". Yes, but you will nee

Is there way to complete my Calculator with Bison or other GNU tools?

2006-07-03 Thread Wang Yige
Hi everyone, I am a beginner of Flex and Bison and just know litter about them ,I need your help. I want to encapsulate a C++ class ,which can works like a calculator,its structure seems like this: Class Calc { public: Calc(){}; ~Calc(){}; void setExpr(char *cExpr){this->cExpr = cExpr;}