Issue #1024: Factor out the transformation of a 's result declaration into transformCommonResultDecl(). Then call it outside the scope of the substitution introduced as a side-effect of transformInnermostThen(), thus avoiding the situation where the outer CondList transformation introduces a substitution which is immediately masked by the unclosable substitution introduced by the inner AssertCond
Issue #1024: Add a test, also test 'while', which was similarly afflicted.
Issue #1024: Change the order in which alias var decls occur in the transformation of `if(cond1, cond2, ..., condN)` to preserve the 1..N order (was N..1).
Issue #1024: Fix .src because we now generate some var decls in a different order