Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

[GGE::OPTable] cloned closure

Triggered a nasty reentrancy bug if the closure wasn't manually cloned.
  • Loading branch information...
commit 686e6ed28bd756f77651897323a7236ea1765370 1 parent 3f4bdd4
Carl Mäsak authored

Showing 1 changed file with 3 additions and 2 deletions. Show diff stats Hide diff stats

  1. 5  lib/GGE/OPTable.pm
5  lib/GGE/OPTable.pm
@@ -112,7 +112,8 @@ class GGE::OPTable {
112 112
             $pos = $oper.to;
113 113
             $expect = $token<expect> +> 8;
114 114
         };
115  
-        my &reduce = {
  115
+        # RAKUDO: Need to manually clone the closure [perl #73034]
  116
+        my &reduce = pir::clone({
116 117
             my $top = pop @tokenstack;
117 118
             my $oper = pop @operstack;
118 119
             my $reduce = True;
@@ -161,7 +162,7 @@ class GGE::OPTable {
161 162
                     $pos = -1;
162 163
                 }
163 164
             }
164  
-        };
  165
+        });
165 166
         while $pos < $target.chars {
166 167
             my $stop_matching = False;
167 168
             if $stoptoken

0 notes on commit 686e6ed

Please sign in to comment.
Something went wrong with that request. Please try again.