Draft: Disallow unlifted binders in TransformListComp/ParallelListComp
As noted in #20864 the variables used by a then clause in TransformListComp
need to be of lifted type, because they are passed to the "take" function and put into tuples, which require lifted arguments.
Also: #20844 (closed)
This patch ensures that the variables bound by a TransformListComp
statement are lifted by calling unifyKind .. ki liftedTypeKind
and making use of the resulting coercion.
We take a similar approach for parallel list comprehensions. In that case I'm not making use of the resulting coercions, so I'd appreciate some advice. I tried to write a test case that would cause a problem if we're not using the coercions (T20855b
), but it compiles without any Core Lint errors.