summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorajreynol <andrew.j.reynolds@gmail.com>2017-06-15 12:47:43 -0500
committerajreynol <andrew.j.reynolds@gmail.com>2017-06-15 12:47:43 -0500
commit209b08887bc55349880b9ed6d858e23637267dee (patch)
treea26cea8c8c7f00eeb4a5beb9e754a6384a1380be /src
parentfc3f728a4b9939e296e67ec4f30d3f99330d7399 (diff)
Fix for issue related to cbqi + E-matching.
Diffstat (limited to 'src')
-rw-r--r--src/theory/quantifiers/inst_match.cpp1
-rw-r--r--src/theory/quantifiers/inst_match_generator.cpp6
2 files changed, 5 insertions, 2 deletions
diff --git a/src/theory/quantifiers/inst_match.cpp b/src/theory/quantifiers/inst_match.cpp
index 12e15d353..9a3fe379c 100644
--- a/src/theory/quantifiers/inst_match.cpp
+++ b/src/theory/quantifiers/inst_match.cpp
@@ -129,6 +129,7 @@ void InstMatch::setValue( int i, TNode n ) {
}
bool InstMatch::set( QuantifiersEngine* qe, int i, TNode n ) {
+ Assert( i>=0 );
if( !d_vals[i].isNull() ){
if( qe->getEqualityQuery()->areEqual( d_vals[i], n ) ){
return true;
diff --git a/src/theory/quantifiers/inst_match_generator.cpp b/src/theory/quantifiers/inst_match_generator.cpp
index 889fe667e..8d7b321c8 100644
--- a/src/theory/quantifiers/inst_match_generator.cpp
+++ b/src/theory/quantifiers/inst_match_generator.cpp
@@ -955,8 +955,10 @@ void InstMatchGeneratorSimple::addInstantiations( InstMatch& m, QuantifiersEngin
Debug("simple-trigger") << "Actual term is " << t << std::endl;
//convert to actual used terms
for( std::map< int, int >::iterator it = d_var_num.begin(); it != d_var_num.end(); ++it ){
- Debug("simple-trigger") << "...set " << it->second << " " << t[it->first] << std::endl;
- m.setValue( it->second, t[it->first] );
+ if( it->second>=0 ){
+ Debug("simple-trigger") << "...set " << it->second << " " << t[it->first] << std::endl;
+ m.setValue( it->second, t[it->first] );
+ }
}
if( qe->addInstantiation( d_f, m ) ){
addedLemmas++;
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback