mirror of
https://github.com/mawww/kakoune.git
synced 2024-12-20 01:41:40 +03:00
Regex: Assert that the regex direction matches the vm direction
This commit is contained in:
parent
74ed102cab
commit
c8966ca701
@ -109,9 +109,7 @@ public:
|
|||||||
ThreadedRegexVM(const CompiledRegex& program)
|
ThreadedRegexVM(const CompiledRegex& program)
|
||||||
: m_program{program}
|
: m_program{program}
|
||||||
{
|
{
|
||||||
kak_assert(m_program);
|
kak_assert(m_program and direction == m_program.direction);
|
||||||
if (direction != program.direction)
|
|
||||||
throw runtime_error{"Regex and VM direction mismatch"};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ThreadedRegexVM(const ThreadedRegexVM&) = delete;
|
ThreadedRegexVM(const ThreadedRegexVM&) = delete;
|
||||||
|
Loading…
Reference in New Issue
Block a user