New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error when using a role parameter to parameterize another role. #6506
Comments
From vittore.scolari@gmail.comThe following script role DataNo { my DataNo $a = DataNo.new; role Data[::T] { my Data[uint8] $b = Data[uint8].new; dies with error: |
From @smlsAlthough that particular error message seems to be specific to `Blob`, it also breaks with other parametric roles (such as `Array`), because the generic parameter T of the outer role seems to be passed through without being specialized first. Shorter examples: ➜ role R[::T] { method a { Array[T].new } }; say R[Int].a.perl; ➜ role R[::T] { method a { Blob[T].new } }; say R[Int].a.perl; Looks related to https://rt-archive.perl.org/perl6/Ticket/Display.html?id=131947 . |
The RT System itself - Status changed from 'new' to 'open' |
This seems to work fine nowadays: The original report:
The two shortened evaluations:
The second one errors out for a valid reason -- it works with e.g.
Tagging "testneeded". |
Migrated from rt.perl.org#132051 (status was 'open')
Searchable as RT132051$
The text was updated successfully, but these errors were encountered: