diff --git a/src/ast/sls/sls_seq_plugin.cpp b/src/ast/sls/sls_seq_plugin.cpp index 3f09f3792..eaccfb9bd 100644 --- a/src/ast/sls/sls_seq_plugin.cpp +++ b/src/ast/sls/sls_seq_plugin.cpp @@ -694,7 +694,7 @@ namespace sls { hashtable> set; set.insert(zstring("")); for (unsigned i = 0; i < val_other.length(); ++i) { - for (unsigned j = val_other.length() - i; j-- > 0; ) { + for (unsigned j = 1; j <= val_other.length() - i; ++j) { zstring sub = val_other.extract(i, j); if (set.contains(sub)) break;