From 0de7ee6de432b1bdf63909dcde21bcf1282e5751 Mon Sep 17 00:00:00 2001 From: zb226 Date: Sat, 4 Oct 2025 17:31:51 +0200 Subject: [PATCH] Add todo-test for GH 16665 (surprising precedence issue: sort f()->@*) --- t/run/todo.t | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/t/run/todo.t b/t/run/todo.t index c9e1da97fc47..f3c19f8dbe2b 100644 --- a/t/run/todo.t +++ b/t/run/todo.t @@ -290,6 +290,12 @@ TODO: { is($?, 0, 'No assertion failure; GH 16522'); } +TODO: { + local $::TODO = 'GH 16665'; + my $results = fresh_perl('sub f {[1,2,3]}; print sort f()->@*', {}); + is($results, '123', 'function return value sorted before postfix dereference; GH 16665'); +} + TODO: { todo_skip "Test needs -DDEBUGGING", 1 unless $is_debugging_build; local $::TODO = 'GH 16863';