From d4bd2f77c3545307502b4ad138c68247d8b1dd81 Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Wed, 23 Mar 2022 13:26:26 -0600 Subject: [PATCH] re/anyof.t: Add debugging info This is in response to https://github.com/Perl/perl5/pull/19558#issuecomment-1076659884 --- t/re/anyof.t | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/t/re/anyof.t b/t/re/anyof.t index 6cc34ef..8ce5cdc 100644 --- a/t/re/anyof.t +++ b/t/re/anyof.t @@ -75,6 +75,10 @@ sub get_compiled ($) { } $_ = shift @lines; + unless (defined $_) { + die "Unexpected compilation result: '$result'\n" + . " Compiled from '$actual_pattern'"; + } s/ \s* \( \d+ \) \s* //x; # Get rid of the node branch s/ ^ \s* \d+ : \s* //x; # ... And the node number -- 1.8.3.1