diff --git a/gdb/testsuite/gdb.ada/mi_task_arg.exp b/gdb/testsuite/gdb.ada/mi_task_arg.exp index 098396d5c09..b4b7b4997f3 100644 --- a/gdb/testsuite/gdb.ada/mi_task_arg.exp +++ b/gdb/testsuite/gdb.ada/mi_task_arg.exp @@ -49,7 +49,8 @@ set frame1 "frame=\{level=\"1\",args=\\\[${frame1_args}(,$frame1_opt_args)?\\\]\ # Frame for system.tasking.stages.task_wrapper set frame2_args "(\{name=\"self_id\",value=\"($hex|)\"\})?" set frame2 "frame=\{level=\"2\",args=\\\[$frame2_args\\\]\}" -mi_gdb_test "-stack-list-arguments 1" \ - "\\^done,stack-args=\\\[$frame0,$frame1,$frame2,.*" \ - "-stack-list-arguments 1" +set frames "$frame0,$frame1,${frame2}(,.*)?" +mi_gdb_test "-stack-list-arguments 1" \ + "\\^done,stack-args=\\\[$frames\\\]" \ + "-stack-list-arguments 1"