my $subref = sub ( $cat, $id = do { state $auto_id = 0; $auto_id++ } ) {
...;
};
+
+# signature and prototype and attribute
+sub foo1 ( $x, $y ) : prototype ( $$ ) : shared { }
+
+sub foo11 ( $thing, % ) { print $thing }
+
+sub animal4 ( $cat, $ = ) { } # second argument is optional
+
+*share = sub ( \[$@%] ) { };
+
+# extruded test
+sub foo2 ( $first, $, $third ) {
+ return "first=$first, third=$third";
+}
+
+# valid attributes
+sub fnord (&\%) : switch(10,foo(7,3)) : expensive;
+sub plugh () : Ugly('\(") : Bad;
../snippets22.t xci.xci2
../snippets22.t mangle4.def
../snippets22.t mangle4.mangle
+../snippets22.t extrude5.def
+../snippets22.t extrude5.extrude
../snippets3.t ce_wn1.ce_wn
../snippets3.t ce_wn1.def
../snippets3.t colin.colin
../snippets9.t rt98902.def
../snippets9.t rt98902.rt98902
../snippets9.t rt99961.def
-../snippets22.t extrude5.def
-../snippets22.t extrude5.extrude
my $subref = sub ( $cat, $id = do { state $auto_id = 0; $auto_id++ } ) {
...;
};
+
+# signature and prototype and attribute
+sub foo1 ( $x, $y ) : prototype ( $$ ) : shared { }
+
+sub foo11 ( $thing, % ) { print $thing }
+
+sub animal4 ( $cat, $ = ) { } # second argument is optional
+
+*share = sub
+( \[$@%] ) { };
+
+# extruded test
+sub foo2
+ (
+ $
+ first
+ ,
+ $
+ ,
+ $
+ third
+ )
+ {
+ return
+ "first=$first, third=$third"
+ ;
+ }
+
+# valid attributes
+sub fnord (&\%) : switch(10,foo(7,3)) : expensive;
+sub plugh () : Ugly('\(") : Bad;
my $subref = sub ( $cat, $id = do { state $auto_id = 0; $auto_id++ } ) {
...;
};
+
+# signature and prototype and attribute
+sub foo1 ( $x, $y ) : prototype ( $$ ) : shared { }
+
+sub foo11 ( $thing, % ) { print $thing }
+
+sub animal4 ( $cat, $ = ) { } # second argument is optional
+
+*share = sub
+( \[$@%] ) { };
+
+# extruded test
+sub foo2
+ (
+ $
+ first
+ ,
+ $
+ ,
+ $
+ third
+ )
+ {
+ return
+ "first=$first, third=$third"
+ ;
+ }
+
+# valid attributes
+sub fnord (&\%) : switch(10,foo(7,3)) : expensive;
+sub plugh () : Ugly('\(") : Bad;
----------
'ternary4' => <<'----------',
my $subref = sub ( $cat, $id = do { state $auto_id = 0; $auto_id++ } ) {
...;
};
+
+# signature and prototype and attribute
+sub foo1 ( $x, $y ) : prototype ( $$ ) : shared { }
+
+sub foo11 ( $thing, % ) { print $thing }
+
+sub animal4 ( $cat, $ = ) { } # second argument is optional
+
+*share = sub ( \[$@%] ) { };
+
+# extruded test
+sub foo2 ( $first, $, $third ) {
+ return "first=$first, third=$third";
+}
+
+# valid attributes
+sub fnord (&\%) : switch(10,foo(7,3)) : expensive;
+sub plugh () : Ugly('\(") : Bad;
#17...........
},