Subversion Repositories psp

Compare Revisions

Ignore whitespace Rev 1352 → Rev 1353

/trunk/libbulletml/src/calc.yy
1,9 → 1,9
/* Ãæ´Öµ­Ë¡ÅÅÂî -- calc */
 
%{
typedef double NumType;
typedef float NumType;
 
#define YYSTYPE double
#define YYSTYPE float
#define YYERROR_VERBOSE
 
#include <cmath>
32,7 → 32,7
CalcFormula* formula;
std::vector<CalcFormula*> formulas;
 
CalcFormula* f(double d) { return formulas[(int)d]; }
CalcFormula* f(float d) { return formulas[(int)d]; }
 
int paramId;
}
118,7 → 118,7
if (c == '.' || isdigit (c))
{
yyinStr--;
sscanf (yyinStr, "%lf", &yylval);
sscanf (yyinStr, "%f", &yylval);
while ((c = *(++yyinStr)) == '.' || isdigit(c)) {}
return NUM;
}