-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle opaque aliases of arrays in Space erase
- Loading branch information
Showing
2 changed files
with
12 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
// Capturing the regression will implementing the fix for i18364 | ||
// That broke in CI, "case _" "Unreachable case except for null" | ||
// Because IArray is an opaque alias of Array | ||
object Tup: | ||
/** Convert an immutable array into a tuple of unknown arity and types */ | ||
def fromIArray[T](xs: IArray[T]): Tuple = | ||
val xs2: IArray[Object] = xs match | ||
case xs: IArray[Object] @unchecked => xs | ||
case _ => xs.map(_.asInstanceOf[Object]) | ||
runtime.Tuples.fromIArray(xs2) |