Passing local variable to instance of named sequence to which triggered is applied

Hi All,
Consider following examples from LRM

sequence sub_seq2(lv);
(a ##1 !a, lv = data_in) ##1 !b[*0:$] ##1 b && (data_out == lv);
endsequence

sequence seq2a;
int v1;
  c ##1 sub_seq2(v1).triggered ##1 (do1 == v1); // v1 is now bound to lv
endsequence

sequence seq2b;
 int v1; 
 c ##1 !sub_seq2(v1).triggered ##1 (do1 == v1); // v1 unassigned
endsequence

Sequence method ‘triggered’ simply checks for end of the sequence.
The sequence could start at any clock prior i.e the local variable ‘v1’ could be assigned ‘N’ clocks prior to testing result of triggered.

My question is regarding sequence ‘seq2b’.
Assume that !sub_seq2(v1).triggered is true , there is a possibility that ‘v1’ is assigned but the sequence ‘sub_seq2’ doesn’t end at the clock where it is tested.

Shouldn’t the same assigned value of ‘v1’ be used when evaluating (do1 == v1) ?

I understand that there is also an opposite possibility of ‘v1’ being unassigned prior to testing !sub_seq2(v1).triggered.

KISS!
Except for an exercise in testing the language, I never saw a need to pass an actual value to a sequence for use of endpoints.
The way I see it, if you really have to do this, then it’s too complicated.
Played with https://www.edaplayground.com/x/wP_8
It does not work, but gave me those messages:
** Warning: testbench.sv(17): (vlog-2580) Local variable is assigned before it is passed to
a named sequence to which ‘ended’ is applied. The assigned value will not be visible within the named sequence.
** Error: testbench.sv(17): Methods triggered or matched can not be applied to an instance of a
sequence with input or inout local var formals.
** Warning: testbench.sv(17): (vlog-2580) Local variable is assigned before it is passed to a named sequence to which ‘ended’ is applied. The assigned value will not be visible within the named sequence.
End time: 15:26:26 on Feb 05,2024, Elapsed time: 0:00:00

Thanks Ben.
I tried following alternative

int module_lv ;   
function void assign_lv(lv);
     module_lv = lv;
endfunction  

sequence sub_seq2(lv);
   (a ##1 !a, lv = data_in, assign_lv(lv) ) ##1 !b[*0:$] ##1 b && (data_out == lv);
 endsequence

sequence seq2b;
   int v1; 
     c ##1 !sub_seq2(v1).triggered ##1 (do1 == module_lv);
 endsequence  

However I still observe compilation error
Error: testbench.sv(28): The application of ended to a sequence ‘sub_seq2’ to which local variable is being passed should be maximal boolean expression.

As per LRM 16.10

A local variable that is passed in as actual argument to an instance of a named sequence to which triggered is applied will flow out of the application of triggered to that instance provided both of the following conditions are met:
(1) The local variable flows out of the end of the named sequence instance, as defined by the local variable flow rules for sequences.
(2) The application of triggered to this instance is a maximal Boolean expression. In other words, the application of triggered cannot have negation or any other expression operator applied to it.

Any logical reason behind restriction for (2) ?