GCC Code Coverage Report
Directory: . Exec Total Coverage
File: src/theory/theory_engine.h Lines: 42 42 100.0 %
Date: 2021-09-16 Branches: 100 364 27.5 %

Line Exec Source
1
/******************************************************************************
2
 * Top contributors (to current version):
3
 *   Andrew Reynolds, Dejan Jovanovic, Morgan Deters
4
 *
5
 * This file is part of the cvc5 project.
6
 *
7
 * Copyright (c) 2009-2021 by the authors listed in the file AUTHORS
8
 * in the top-level source directory and their institutional affiliations.
9
 * All rights reserved.  See the file COPYING in the top-level source
10
 * directory for licensing information.
11
 * ****************************************************************************
12
 *
13
 * The theory engine.
14
 */
15
16
#include "cvc5_private.h"
17
18
#ifndef CVC5__THEORY_ENGINE_H
19
#define CVC5__THEORY_ENGINE_H
20
21
#include <memory>
22
#include <vector>
23
24
#include "base/check.h"
25
#include "context/cdhashmap.h"
26
#include "expr/node.h"
27
#include "options/theory_options.h"
28
#include "proof/trust_node.h"
29
#include "smt/env_obj.h"
30
#include "theory/atom_requests.h"
31
#include "theory/engine_output_channel.h"
32
#include "theory/interrupted.h"
33
#include "theory/rewriter.h"
34
#include "theory/sort_inference.h"
35
#include "theory/theory.h"
36
#include "theory/theory_preprocessor.h"
37
#include "theory/trust_substitutions.h"
38
#include "theory/uf/equality_engine.h"
39
#include "theory/valuation.h"
40
#include "util/hash.h"
41
#include "util/statistics_stats.h"
42
#include "util/unsafe_interrupt_exception.h"
43
44
namespace cvc5 {
45
46
class Env;
47
class ResourceManager;
48
class TheoryEngineProofGenerator;
49
class ProofChecker;
50
51
/**
52
 * A pair of a theory and a node. This is used to mark the flow of
53
 * propagations between theories.
54
 */
55
507365077
struct NodeTheoryPair {
56
  Node d_node;
57
  theory::TheoryId d_theory;
58
  size_t d_timestamp;
59
73793917
  NodeTheoryPair(TNode n, theory::TheoryId t, size_t ts = 0)
60
73793917
      : d_node(n), d_theory(t), d_timestamp(ts)
61
  {
62
73793917
  }
63
50736276
  NodeTheoryPair() : d_theory(theory::THEORY_LAST), d_timestamp() {}
64
  // Comparison doesn't take into account the timestamp
65
88767164
  bool operator == (const NodeTheoryPair& pair) const {
66
88767164
    return d_node == pair.d_node && d_theory == pair.d_theory;
67
  }
68
};/* struct NodeTheoryPair */
69
70
struct NodeTheoryPairHashFunction {
71
  std::hash<Node> hashFunction;
72
  // Hash doesn't take into account the timestamp
73
139609635
  size_t operator()(const NodeTheoryPair& pair) const {
74
139609635
    uint64_t hash = fnv1a::fnv1a_64(std::hash<Node>()(pair.d_node));
75
139609635
    return static_cast<size_t>(fnv1a::fnv1a_64(pair.d_theory, hash));
76
  }
77
};/* struct NodeTheoryPairHashFunction */
78
79
80
/* Forward declarations */
81
namespace theory {
82
83
class CombinationEngine;
84
class DecisionManager;
85
class RelevanceManager;
86
class Rewriter;
87
class SharedSolver;
88
class TheoryModel;
89
90
}  // namespace theory
91
92
namespace prop {
93
class PropEngine;
94
}
95
96
/**
97
 * This is essentially an abstraction for a collection of theories.  A
98
 * TheoryEngine provides services to a PropEngine, making various
99
 * T-solvers look like a single unit to the propositional part of
100
 * cvc5.
101
 */
102
class TheoryEngine : protected EnvObj
103
{
104
  /** Shared terms database can use the internals notify the theories */
105
  friend class SharedTermsDatabase;
106
  friend class theory::EngineOutputChannel;
107
  friend class theory::CombinationEngine;
108
  friend class theory::SharedSolver;
109
110
 public:
111
  /** Constructs a theory engine */
112
  TheoryEngine(Env& env);
113
114
  /** Destroys a theory engine */
115
  ~TheoryEngine();
116
117
  void interrupt();
118
119
  /** "Spend" a resource during a search or preprocessing.*/
120
  void spendResource(Resource r);
121
122
  /**
123
   * Adds a theory. Only one theory per TheoryId can be present, so if
124
   * there is another theory it will be deleted.
125
   */
126
  template <class TheoryClass>
127
129282
  void addTheory(theory::TheoryId theoryId)
128
  {
129
129282
    Assert(d_theoryTable[theoryId] == NULL && d_theoryOut[theoryId] == NULL);
130
129282
    d_theoryOut[theoryId] = new theory::EngineOutputChannel(this, theoryId);
131
258564
    d_theoryTable[theoryId] =
132
129282
        new TheoryClass(d_env, *d_theoryOut[theoryId], theory::Valuation(this));
133
517128
    getRewriter()->registerTheoryRewriter(
134
387846
        theoryId, d_theoryTable[theoryId]->getTheoryRewriter());
135
129282
  }
136
137
  /** Register theory proof rule checkers to the given proof checker */
138
  void initializeProofChecker(ProofChecker* pc);
139
140
10009
  void setPropEngine(prop::PropEngine* propEngine)
141
  {
142
10009
    d_propEngine = propEngine;
143
10009
  }
144
145
  /**
146
   * Called when all initialization of options/logic is done, after theory
147
   * objects have been created.
148
   *
149
   * This initializes the quantifiers engine, the "official" equality engines
150
   * of each theory as required, and the model and model builder utilities.
151
   */
152
  void finishInit();
153
154
  /**
155
   * Get a pointer to the underlying propositional engine.
156
   */
157
2712081
  prop::PropEngine* getPropEngine() const { return d_propEngine; }
158
159
  /** Get the proof node manager */
160
  ProofNodeManager* getProofNodeManager() const;
161
162
  /**
163
   * Get a pointer to the underlying sat context.
164
   */
165
  context::Context* getSatContext() const;
166
167
  /**
168
   * Get a pointer to the underlying user context.
169
   */
170
  context::UserContext* getUserContext() const;
171
172
  /**
173
   * Get a pointer to the underlying quantifiers engine.
174
   */
175
14077
  theory::QuantifiersEngine* getQuantifiersEngine() const
176
  {
177
14077
    return d_quantEngine;
178
  }
179
  /**
180
   * Get a pointer to the underlying decision manager.
181
   */
182
  theory::DecisionManager* getDecisionManager() const
183
  {
184
    return d_decManager.get();
185
  }
186
187
  /**
188
   * Preprocess rewrite equality, called by the preprocessor to rewrite
189
   * equalities appearing in the input.
190
   */
191
  TrustNode ppRewriteEquality(TNode eq);
192
  /** Notify (preprocessed) assertions. */
193
  void notifyPreprocessedAssertions(const std::vector<Node>& assertions);
194
195
  /** Return whether or not we are incomplete (in the current context). */
196
7486
  bool isIncomplete() const { return d_incomplete; }
197
198
  /**
199
   * Returns true if we need another round of checking.  If this
200
   * returns true, check(FULL_EFFORT) _must_ be called by the
201
   * propositional layer before reporting SAT.
202
   *
203
   * This is especially necessary for incomplete theories that lazily
204
   * output some lemmas on FULL_EFFORT check (e.g. quantifier reasoning
205
   * outputing quantifier instantiations).  In such a case, a lemma can
206
   * be asserted that is simplified away (perhaps it's already true).
207
   * However, we must maintain the invariant that, if a theory uses the
208
   * OutputChannel, it implicitly requests that another check(FULL_EFFORT)
209
   * be performed before exit, even if no new facts are on its fact queue,
210
   * as it might decide to further instantiate some lemmas, precluding
211
   * a SAT response.
212
   */
213
5132514
  bool needCheck() const { return d_outputChannelUsed || d_lemmasAdded; }
214
  /**
215
   * Is the literal lit (possibly) critical for satisfying the input formula in
216
   * the current context? This call is applicable only during collectModelInfo
217
   * or during LAST_CALL effort.
218
   */
219
  bool isRelevant(Node lit) const;
220
  /**
221
   * This is called at shutdown time by the SmtEngine, just before
222
   * destruction.  It is important because there are destruction
223
   * ordering issues between PropEngine and Theory.
224
   */
225
  void shutdown();
226
227
  /**
228
   * Solve the given literal with a theory that owns it. The proof of tliteral
229
   * is carried in the trust node. The proof added to substitutionOut should
230
   * take this proof into account (when proofs are enabled).
231
   */
232
  theory::Theory::PPAssertStatus solve(
233
      TrustNode tliteral, theory::TrustSubstitutionMap& substitutionOut);
234
235
  /**
236
   * Preregister a Theory atom with the responsible theory (or
237
   * theories).
238
   */
239
  void preRegister(TNode preprocessed);
240
241
  /**
242
   * Assert the formula to the appropriate theory.
243
   * @param node the assertion
244
   */
245
  void assertFact(TNode node);
246
247
  /**
248
   * Check all (currently-active) theories for conflicts.
249
   * @param effort the effort level to use
250
   */
251
  void check(theory::Theory::Effort effort);
252
253
  /**
254
   * Calls ppStaticLearn() on all theories, accumulating their
255
   * combined contributions in the "learned" builder.
256
   */
257
  void ppStaticLearn(TNode in, NodeBuilder& learned);
258
259
  /**
260
   * Calls presolve() on all theories and returns true
261
   * if one of the theories discovers a conflict.
262
   */
263
  bool presolve();
264
265
  /**
266
   * Calls postsolve() on all theories.
267
   */
268
  void postsolve();
269
270
  /**
271
   * Calls notifyRestart() on all active theories.
272
   */
273
  void notifyRestart();
274
275
12020374
  void getPropagatedLiterals(std::vector<TNode>& literals)
276
  {
277
27306224
    for (; d_propagatedLiteralsIndex < d_propagatedLiterals.size();
278
15285850
         d_propagatedLiteralsIndex = d_propagatedLiteralsIndex + 1)
279
    {
280
15285850
      Debug("getPropagatedLiterals")
281
7642925
          << "TheoryEngine::getPropagatedLiterals: propagating: "
282
7642925
          << d_propagatedLiterals[d_propagatedLiteralsIndex] << std::endl;
283
7642925
      literals.push_back(d_propagatedLiterals[d_propagatedLiteralsIndex]);
284
    }
285
4377449
  }
286
287
  /**
288
   * Returns the next decision request, or null if none exist. The next
289
   * decision request is a literal that this theory engine prefers the SAT
290
   * solver to make as its next decision. Decision requests are managed by
291
   * the decision manager d_decManager.
292
   */
293
  Node getNextDecisionRequest();
294
295
  bool properConflict(TNode conflict) const;
296
297
  /**
298
   * Returns an explanation of the node propagated to the SAT solver.
299
   */
300
  TrustNode getExplanation(TNode node);
301
302
  /**
303
   * Get the pointer to the model object used by this theory engine.
304
   */
305
  theory::TheoryModel* getModel();
306
  /**
307
   * Get the current model for the current set of assertions. This method
308
   * should only be called immediately after a satisfiable or unknown
309
   * response to a check-sat call, and only if produceModels is true.
310
   *
311
   * If the model is not already built, this will cause this theory engine
312
   * to build the model.
313
   *
314
   * If the model is not available (for instance, if the last call to check-sat
315
   * was interrupted), then this returns the null pointer.
316
   */
317
  theory::TheoryModel* getBuiltModel();
318
  /**
319
   * This forces the model maintained by the combination engine to be built
320
   * if it has not been done so already. This should be called only during a
321
   * last call effort check after theory combination is run.
322
   *
323
   * @return true if the model was successfully built (possibly prior to this
324
   * call).
325
   */
326
  bool buildModel();
327
328
  /**
329
   * Get the theory associated to a given Node.
330
   *
331
   * @returns the theory, or NULL if the TNode is
332
   * of built-in type.
333
   */
334
2362577
  theory::Theory* theoryOf(TNode node) const
335
  {
336
2362577
    return d_theoryTable[theory::Theory::theoryOf(node)];
337
  }
338
339
  /**
340
   * Get the theory associated to a the given theory id.
341
   *
342
   * @returns the theory
343
   */
344
45119550
  theory::Theory* theoryOf(theory::TheoryId theoryId) const
345
  {
346
45119550
    Assert(theoryId < theory::THEORY_LAST);
347
45119550
    return d_theoryTable[theoryId];
348
  }
349
350
1961030
  bool isTheoryEnabled(theory::TheoryId theoryId) const
351
  {
352
1961030
    return d_logicInfo.isTheoryEnabled(theoryId);
353
  }
354
  /** get the logic info used by this theory engine */
355
  const LogicInfo& getLogicInfo() const;
356
  /** get the separation logic heap types */
357
  bool getSepHeapTypes(TypeNode& locType, TypeNode& dataType) const;
358
359
  /**
360
   * Declare heap. This is used for separation logics to set the location
361
   * and data types. It should be called only once, and before any separation
362
   * logic constraints are asserted to this theory engine.
363
   */
364
  void declareSepHeap(TypeNode locT, TypeNode dataT);
365
366
  /**
367
   * Returns the equality status of the two terms, from the theory
368
   * that owns the domain type.  The types of a and b must be the same.
369
   */
370
  theory::EqualityStatus getEqualityStatus(TNode a, TNode b);
371
372
  /**
373
   * Returns the value that a theory that owns the type of var currently
374
   * has (or null if none);
375
   */
376
  Node getModelValue(TNode var);
377
378
  /**
379
   * Get relevant assertions. This returns a set of assertions that are
380
   * currently asserted to this TheoryEngine that propositionally entail the
381
   * (preprocessed) input formula and all theory lemmas that have been marked
382
   * NEEDS_JUSTIFY. For more details on this, see relevance_manager.h.
383
   *
384
   * This method updates success to false if the set of relevant assertions
385
   * is not available. This may occur if we are not in SAT mode, if the
386
   * relevance manager is disabled (see option::relevanceFilter) or if the
387
   * relevance manager failed to compute relevant assertions due to an internal
388
   * error.
389
   */
390
  const std::unordered_set<TNode>& getRelevantAssertions(bool& success);
391
392
  /**
393
   * Get difficulty map, which populates dmap, mapping preprocessed assertions
394
   * to a value that estimates their difficulty for solving the current problem.
395
   *
396
   * For details, see theory/difficuly_manager.h.
397
   */
398
  void getDifficultyMap(std::map<Node, Node>& dmap);
399
400
  /**
401
   * Forwards an entailment check according to the given theoryOfMode.
402
   * See theory.h for documentation on entailmentCheck().
403
   */
404
  std::pair<bool, Node> entailmentCheck(options::TheoryOfMode mode, TNode lit);
405
406
  //---------------------- information about cardinality of types
407
  /**
408
   * Is the cardinality of type tn finite? This method depends on whether
409
   * finite model finding is enabled. If finite model finding is enabled, then
410
   * we assume that all uninterpreted sorts have finite cardinality.
411
   *
412
   * Notice that if finite model finding is enabled, this method returns true
413
   * if tn is an uninterpreted sort. It also returns true for the sort
414
   * (Array Int U) where U is an uninterpreted sort. This type
415
   * is finite if and only if U has cardinality one; for cases like this,
416
   * we conservatively return that tn has finite cardinality.
417
   *
418
   * This method does *not* depend on the state of the theory engine, e.g.
419
   * if U in the above example currently is entailed to have cardinality >1
420
   * based on the assertions.
421
   */
422
  bool isFiniteType(TypeNode tn) const;
423
  //---------------------- end information about cardinality of types
424
425
5177
  theory::SortInference* getSortInference() { return d_sortInfer.get(); }
426
427
  /** Prints the assertions to the debug stream */
428
  void printAssertions(const char* tag);
429
430
  /**
431
   * Check that the theory assertions are satisfied in the model.
432
   * This function is called from the smt engine's checkModel routine.
433
   */
434
  void checkTheoryAssertionsWithModel(bool hardFailure);
435
436
 private:
437
  typedef context::
438
      CDHashMap<NodeTheoryPair, NodeTheoryPair, NodeTheoryPairHashFunction>
439
          PropagationMap;
440
441
  /**
442
   * Called by the theories to notify of a conflict.
443
   *
444
   * @param conflict The trust node containing the conflict and its proof
445
   * generator (if it exists),
446
   * @param theoryId The theory that sent the conflict
447
   */
448
  void conflict(TrustNode conflict, theory::TheoryId theoryId);
449
450
  /** set in conflict */
451
  void markInConflict();
452
453
  /**
454
   * Called by the theories to notify that the current branch is incomplete.
455
   */
456
  void setIncomplete(theory::TheoryId theory, theory::IncompleteId id);
457
458
  /**
459
   * Called by the output channel to propagate literals and facts
460
   * @return false if immediate conflict
461
   */
462
  bool propagate(TNode literal, theory::TheoryId theory);
463
464
  /**
465
   * Internal method to call the propagation routines and collect the
466
   * propagated literals.
467
   */
468
  void propagate(theory::Theory::Effort effort);
469
470
  /**
471
   * Assert the formula to the given theory.
472
   * @param assertion the assertion to send (not necesserily normalized)
473
   * @param original the assertion as it was sent in from the propagating theory
474
   * @param toTheoryId the theory to assert to
475
   * @param fromTheoryId the theory that sent it
476
   */
477
  void assertToTheory(TNode assertion,
478
                      TNode originalAssertion,
479
                      theory::TheoryId toTheoryId,
480
                      theory::TheoryId fromTheoryId);
481
482
  /**
483
   * Marks a theory propagation from a theory to a theory where a
484
   * theory could be the THEORY_SAT_SOLVER for literals coming from
485
   * or being propagated to the SAT solver. If the receiving theory
486
   * already recieved the literal, the method returns false, otherwise
487
   * it returns true.
488
   *
489
   * @param assertion the normalized assertion being sent
490
   * @param originalAssertion the actual assertion that was sent
491
   * @param toTheoryId the theory that is on the receiving end
492
   * @param fromTheoryId the theory that sent the assertion
493
   * @return true if a new assertion, false if theory already got it
494
   */
495
  bool markPropagation(TNode assertion,
496
                       TNode originalAssertions,
497
                       theory::TheoryId toTheoryId,
498
                       theory::TheoryId fromTheoryId);
499
500
  /**
501
   * Computes the explanation by traversing the propagation graph and
502
   * asking relevant theories to explain the propagations. Initially
503
   * the explanation vector should contain only the element (node, theory)
504
   * where the node is the one to be explained, and the theory is the
505
   * theory that sent the literal.
506
   */
507
  TrustNode getExplanation(std::vector<NodeTheoryPair>& explanationVector);
508
509
  /** Are proofs enabled? */
510
  bool isProofEnabled() const;
511
512
  /**
513
   * Get a pointer to the rewriter owned by the associated Env.
514
   */
515
  theory::Rewriter* getRewriter();
516
517
  /**
518
   * Adds a new lemma, returning its status.
519
   * @param node the lemma
520
   * @param p the properties of the lemma.
521
   * @param atomsTo the theory that atoms of the lemma should be sent to
522
   * @param from the theory that sent the lemma
523
   */
524
  void lemma(TrustNode node,
525
             theory::LemmaProperty p,
526
             theory::TheoryId from = theory::THEORY_LAST);
527
528
  /** Ensure atoms from the given node are sent to the given theory */
529
  void ensureLemmaAtoms(TNode n, theory::TheoryId atomsTo);
530
  /** Ensure that the given atoms are sent to the given theory */
531
  void ensureLemmaAtoms(const std::vector<TNode>& atoms,
532
                        theory::TheoryId atomsTo);
533
534
  /** Dump the assertions to the dump */
535
  void dumpAssertions(const char* tag);
536
537
  /** Associated PropEngine engine */
538
  prop::PropEngine* d_propEngine;
539
540
  /**
541
   * A table of from theory IDs to theory pointers. Never use this table
542
   * directly, use theoryOf() instead.
543
   */
544
  theory::Theory* d_theoryTable[theory::THEORY_LAST];
545
546
  /**
547
   * A collection of theories that are "active" for the current run.
548
   * This set is provided by the user (as a logic string, say, in SMT-LIBv2
549
   * format input), or else by default it's all-inclusive.  This is important
550
   * because we can optimize for single-theory runs (no sharing), can reduce
551
   * the cost of walking the DAG on registration, etc.
552
   */
553
  const LogicInfo& d_logicInfo;
554
555
  /** The separation logic location and data types */
556
  TypeNode d_sepLocType;
557
  TypeNode d_sepDataType;
558
559
  //--------------------------------- new proofs
560
  /** Proof node manager used by this theory engine, if proofs are enabled */
561
  ProofNodeManager* d_pnm;
562
  /** The lazy proof object
563
   *
564
   * This stores instructions for how to construct proofs for all theory lemmas.
565
   */
566
  std::shared_ptr<LazyCDProof> d_lazyProof;
567
  /** The proof generator */
568
  std::shared_ptr<TheoryEngineProofGenerator> d_tepg;
569
  //--------------------------------- end new proofs
570
  /** The combination manager we are using */
571
  std::unique_ptr<theory::CombinationEngine> d_tc;
572
  /** The shared solver of the above combination engine. */
573
  theory::SharedSolver* d_sharedSolver;
574
  /** The quantifiers engine, which is owned by the quantifiers theory */
575
  theory::QuantifiersEngine* d_quantEngine;
576
  /**
577
   * The decision manager
578
   */
579
  std::unique_ptr<theory::DecisionManager> d_decManager;
580
  /** The relevance manager */
581
  std::unique_ptr<theory::RelevanceManager> d_relManager;
582
  /**
583
   * An empty set of relevant assertions, which is returned as a dummy value for
584
   * getRelevantAssertions when relevance is disabled.
585
   */
586
  std::unordered_set<TNode> d_emptyRelevantSet;
587
588
  /** are we in eager model building mode? (see setEagerModelBuilding). */
589
  bool d_eager_model_building;
590
591
  /**
592
   * Output channels for individual theories.
593
   */
594
  theory::EngineOutputChannel* d_theoryOut[theory::THEORY_LAST];
595
596
  /**
597
   * Are we in conflict.
598
   */
599
  context::CDO<bool> d_inConflict;
600
601
  /**
602
   * Are we in "SAT mode"? In this state, the user can query for the model.
603
   * This corresponds to the state in Figure 4.1, page 52 of the SMT-LIB
604
   * standard, version 2.6.
605
   */
606
  bool d_inSatMode;
607
608
  /**
609
   * Debugging flag to ensure that shutdown() is called before the
610
   * destructor.
611
   */
612
  bool d_hasShutDown;
613
614
  /**
615
   * True if a theory has notified us of incompleteness (at this
616
   * context level or below).
617
   */
618
  context::CDO<bool> d_incomplete;
619
  /** The theory and identifier that (most recently) set incomplete */
620
  context::CDO<theory::TheoryId> d_incompleteTheory;
621
  context::CDO<theory::IncompleteId> d_incompleteId;
622
623
  /**
624
   * Mapping of propagations from recievers to senders.
625
   */
626
  PropagationMap d_propagationMap;
627
628
  /**
629
   * Timestamp of propagations
630
   */
631
  context::CDO<size_t> d_propagationMapTimestamp;
632
633
  /**
634
   * Literals that are propagated by the theory. Note that these are TNodes.
635
   * The theory can only propagate nodes that have an assigned literal in the
636
   * SAT solver and are hence referenced in the SAT solver.
637
   */
638
  context::CDList<TNode> d_propagatedLiterals;
639
640
  /**
641
   * The index of the next literal to be propagated by a theory.
642
   */
643
  context::CDO<unsigned> d_propagatedLiteralsIndex;
644
645
  /**
646
   * A variable to mark if we added any lemmas.
647
   */
648
  bool d_lemmasAdded;
649
650
  /**
651
   * A variable to mark if the OutputChannel was "used" by any theory
652
   * since the start of the last check.  If it has been, we require
653
   * a FULL_EFFORT check before exiting and reporting SAT.
654
   *
655
   * See the documentation for the needCheck() function, below.
656
   */
657
  bool d_outputChannelUsed;
658
659
  /** Atom requests from lemmas */
660
  AtomRequests d_atomRequests;
661
662
  /** sort inference module */
663
  std::unique_ptr<theory::SortInference> d_sortInfer;
664
665
  /** Time spent in theory combination */
666
  TimerStat d_combineTheoriesTime;
667
668
  Node d_true;
669
  Node d_false;
670
671
  /** Whether we were just interrupted (or not) */
672
  bool d_interrupted;
673
674
  /**
675
   * Queue of nodes for pre-registration.
676
   */
677
  std::queue<TNode> d_preregisterQueue;
678
679
  /**
680
   * Boolean flag denoting we are in pre-registration.
681
   */
682
  bool d_inPreregister;
683
684
  /**
685
   * Did the theories get any new facts since the last time we called
686
   * check()
687
   */
688
  context::CDO<bool> d_factsAsserted;
689
690
}; /* class TheoryEngine */
691
692
}  // namespace cvc5
693
694
#endif /* CVC5__THEORY_ENGINE_H */