aboutsummaryrefslogtreecommitdiffstats
path: root/Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend
diff options
context:
space:
mode:
Diffstat (limited to 'Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend')
-rw-r--r--Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend3
1 files changed, 2 insertions, 1 deletions
diff --git a/Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend b/Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend
index 6f20b956..194eba37 100644
--- a/Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend
+++ b/Solvers/SMT-Solver/hu.bme.mit.inf.dslreasoner.smt.reasoner/src/hu/bme/mit/inf/dslreasoner/smt/reasoner/Logic2SmtMapper.xtend
@@ -80,6 +80,7 @@ import org.eclipse.xtext.xbase.lib.Functions.Function1
80import org.eclipse.xtext.xbase.lib.Functions.Function2 80import org.eclipse.xtext.xbase.lib.Functions.Function2
81 81
82import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.* 82import static extension hu.bme.mit.inf.dslreasoner.util.CollectionsUtil.*
83import java.math.BigDecimal
83 84
84class Logic2SmtMapper{ 85class Logic2SmtMapper{
85 val extension SmtLanguageFactory factory = SmtLanguageFactory.eINSTANCE 86 val extension SmtLanguageFactory factory = SmtLanguageFactory.eINSTANCE
@@ -525,7 +526,7 @@ class Logic2SmtMapper{
525 if(literal.value>=0) { new NumericSubterm(#[],#[],createSMTIntLiteral => [value = literal.value])} 526 if(literal.value>=0) { new NumericSubterm(#[],#[],createSMTIntLiteral => [value = literal.value])}
526 else {new NumericSubterm(#[],#[],createSMTMinus => [ leftOperand = (createSMTIntLiteral => [value = - (literal.value) ] ) ]) } } 527 else {new NumericSubterm(#[],#[],createSMTMinus => [ leftOperand = (createSMTIntLiteral => [value = - (literal.value) ] ) ]) } }
527 def dispatch protected TransformedSubterm transformTerm(RealLiteral literal, Logic2SmtMapperTrace trace, Map<Variable, SMTSortedVariable> variables) { 528 def dispatch protected TransformedSubterm transformTerm(RealLiteral literal, Logic2SmtMapperTrace trace, Map<Variable, SMTSortedVariable> variables) {
528 new NumericSubterm(#[],#[],createSMTRealLiteral => [value = literal.value]) } 529 new NumericSubterm(#[],#[],createSMTRealLiteral => [value = BigDecimal.valueOf(literal.value)]) }
529 530
530 /////////////////////////////////////////////////////// 531 ///////////////////////////////////////////////////////
531 // NumericOperators 532 // NumericOperators