private ASTConstantValue MakeConstFloat(CodeLocation location, object val) => new ASTConstantValue()
 {
     Location   = location,
     Type       = IRConstantType.Float,
     FloatValue = Single.Parse((string)val, ParserConstants.ParserCulture.NumberFormat)
 };
 private ASTConstantValue MakeConstString(CodeLocation location, object val) => new ASTConstantValue()
 {
     Location    = location,
     Type        = IRConstantType.String,
     StringValue = (string)val
 };
 private ASTConstantValue MakeConstInteger(CodeLocation location, object val) => new ASTConstantValue()
 {
     Location     = location,
     Type         = IRConstantType.Integer,
     IntegerValue = Int64.Parse((string)val, ParserConstants.ParserCulture.NumberFormat)
 };
 private ASTAction MakeGoalCompletedAction(CodeLocation location) => new ASTGoalCompletedAction
 {
     Location = location
 };
 private ASTLocalVar MakeLocalVar(CodeLocation location, object typeName, object varName) => new ASTLocalVar()
 {
     Location = location,
     Type     = (string)typeName,
     Name     = (string)varName
 };
Beispiel #6
0
 private ASTConstantValue MakeConstFloat(CodeLocation location, ASTNode val) => new ASTConstantValue()
 {
     Location   = location,
     Type       = IRConstantType.Float,
     FloatValue = Single.Parse((val as ASTLiteral).Literal, ParserConstants.ParserCulture.NumberFormat)
 };
 private ASTParentTargetEdge MakeParentTargetEdge(CodeLocation location, object goal) => new ASTParentTargetEdge()
 {
     Location = location,
     Goal     = (string)goal
 };
Beispiel #8
0
 private ASTConstantValue MakeConstInteger(CodeLocation location, ASTNode val) => new ASTConstantValue()
 {
     Location     = location,
     Type         = IRConstantType.Integer,
     IntegerValue = Int64.Parse((val as ASTLiteral).Literal, ParserConstants.ParserCulture.NumberFormat)
 };
Beispiel #9
0
 private ASTConstantValue MakeConstString(CodeLocation location, ASTNode val) => new ASTConstantValue()
 {
     Location    = location,
     Type        = IRConstantType.String,
     StringValue = (val as ASTLiteral).Literal
 };
Beispiel #10
0
 private ASTLocalVar MakeLocalVar(CodeLocation location, ASTNode typeName, ASTNode varName) => new ASTLocalVar()
 {
     Location = location,
     Type     = (typeName as ASTLiteral).Literal,
     Name     = (varName as ASTLiteral).Literal
 };
Beispiel #11
0
 private ASTParentTargetEdge MakeParentTargetEdge(CodeLocation location, ASTNode goal) => new ASTParentTargetEdge()
 {
     Location = location,
     Goal     = (goal as ASTLiteral).Literal
 };
Beispiel #12
0
 private ASTGoalCompletedFact MakeGoalCompletedFact(CodeLocation location) => new ASTGoalCompletedFact
 {
     Location = location
 };