Feature request: relax rules for LAMA0108 "cannot set the compile-time variable 'ii' here because is is part of a block whose execution depends on the run-time condition" #202
Labels
enhancement
New feature or request
I'm trying to solve a variable reference issue. Put simply, I have a loop inside a template that enumerates several compile-time values to write several run-time statements. As these are written to the method via
meta.InsertStatement
, they have no variable with which I can reference them elsewhere in the template (without resorting to another expression or statement builder). As such, I'm trying to usemeta.CompileTime
to provide a compile-time value I can append to this variable so they get different names. My code is similar to the following:The error I'm seeing is:
And then it points to a run-time condition that's one step above where I originally instantiated it. It doesn't make sense to me that:
While I could move the runtime if statement within the loops, I'd rather not because it'll result it in simply repeating unnecessarily within each of the loops.
Thanks!
The text was updated successfully, but these errors were encountered: