projects
/
cvc5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b060a8e
)
Fix compiler warnings. (#5644)
author
Aina Niemetz
<aina.niemetz@gmail.com>
Wed, 9 Dec 2020 22:13:05 +0000
(14:13 -0800)
committer
GitHub
<noreply@github.com>
Wed, 9 Dec 2020 22:13:05 +0000
(14:13 -0800)
src/theory/strings/sequences_rewriter.cpp
patch
|
blob
|
history
diff --git
a/src/theory/strings/sequences_rewriter.cpp
b/src/theory/strings/sequences_rewriter.cpp
index 1382ab0f92e529604f84eccfcf4cf2d12333e0cc..2a30727ba9e29434370c975b75132740789eda49 100644
(file)
--- a/
src/theory/strings/sequences_rewriter.cpp
+++ b/
src/theory/strings/sequences_rewriter.cpp
@@
-1517,7
+1517,6
@@
RewriteResponse SequencesRewriter::preRewrite(TNode node)
Node SequencesRewriter::rewriteSeqNth(Node node)
{
Assert(node.getKind() == SEQ_NTH || node.getKind() == SEQ_NTH_TOTAL);
- Node ret;
Node s = node[0];
Node i = node[1];
if (s.isConst() && i.isConst())
@@
-1527,7
+1526,7
@@
Node SequencesRewriter::rewriteSeqNth(Node node)
if (pos < len)
{
std::vector<Node> elements = s.getConst<Sequence>().getVec();
- ret = elements[pos];
+
const Node&
ret = elements[pos];
return returnRewrite(node, ret, Rewrite::SEQ_NTH_EVAL);
}
else if (node.getKind() == SEQ_NTH_TOTAL)