HaxeFoundation / HaxeFoundation/haxe
Weird implicit cast hangs the compiler in pattern matching.
Open
bug
feature-pattern-matching
- Dominant language
- Haxe
- Stars
- 6.9k
- Forks
- 715
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 11
Description
```haxe
class Test {
static function main() {
final v = new Vector([1, 2]);
switch v {
case [1,2]: true;
case _: false;
}
}
}
abstract Vector(Array) {
public inline function new(a)
this = a;
@:from static function fromVector(v:Vector):Vector
return cast v;
}
```
Compiler seems to be stuck in a loop. From https://github.com/haxetink/tink_pure/issues/18
Contributor guide
Assessment
This issue has not been assessed yet.