diff --git a/src/nfagraph/ng_violet.cpp b/src/nfagraph/ng_violet.cpp index 0a3a97a0..7a4de5f5 100644 --- a/src/nfagraph/ng_violet.cpp +++ b/src/nfagraph/ng_violet.cpp @@ -1713,6 +1713,11 @@ void removeRedundantLiteralsFromInfix(const NGHolder &h, RoseInGraph &ig, continue; } + if (!delay) { + /* unable to trim graph --> no point swapping to new holder */ + continue; + } + assert(isCorrectlyTopped(*h_new)); graphs[right] = make_pair(h_new, delay); }