I don’t know PL1, but if it has any type of preprocessing ability like C does, you could do something like this:

#define procend end

and then use “procend” in your code. This is not ideal, I admit.

Otherwise, I think you have to define all the statement N’s you might use as the beginning of some fold (Open:) and add the corresponding number of “end” statements to end the fold (Close:). That is, you can have multiple Open:, Middle: and Close: tokens; just make sure they are in the correct order (first Close: goes with the first Open:, etc.).