+Statement &Statement::append_from_token(const Token &token)
+{
+ if(token.type==Token::INTEGER)
+ return append(lexical_cast<IntType::Store>(token.str, Fmt().autobase()));
+ else if(token.type==Token::FLOAT)
+ return append(lexical_cast<FloatType::Store>(token.str));
+ else if(token.type==Token::STRING)
+ return append(token.str);
+ else if(token.type==Token::IDENTIFIER)
+ {
+ if(token.str=="true")
+ return append(true);
+ else if(token.str=="false")
+ return append(false);
+ else
+ return append(Value(Symbol(token.str)));
+ }
+ else
+ throw invalid_argument("Statement::append_from_token");
+}