Skip to content
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

--> Int:D allowed but not checked correctly #4627

Closed
p6rt opened this issue Oct 7, 2015 · 6 comments
Closed

--> Int:D allowed but not checked correctly #4627

p6rt opened this issue Oct 7, 2015 · 6 comments

Comments

@p6rt
Copy link

p6rt commented Oct 7, 2015

Migrated from rt.perl.org#126284 (status was 'resolved')

Searchable as RT126284$

@p6rt
Copy link
Author

p6rt commented Oct 7, 2015

From @lizmat

[14​:56​:02] <lizmat> m​: sub a(--> Int​:D) { Int }; a # jnthn, is this supposed to die or not ?
[14​:56​:03] <+camelia> rakudo-moar dafcfe​: ( no output )
[14​:56​:48] <lizmat> jnthn​: perhaps a compile time NYI for --> Foo​:D ?
[15​:00​:14] <jnthn> lizmat​: Either we should fix it or disallow it
[15​:00​:48] <lizmat> jnthn​: will ticket it, ok?
[15​:00​:59] <jnthn> +1

@p6rt
Copy link
Author

p6rt commented Oct 11, 2015

From @FROGGS

Seems to work now that we have DefiniteHOW​:

m​: sub a() returns Int​:U { 42 }; say &a.returns; a
rakudo-moar 8f4e90​: OUTPUT«(Int​:U)␤Type check failed for return value; expected Int​:U but got Int␤ in sub a at /tmp/LRo5pcMZof​:1␤ in block <unit> at /tmp/LRo5pcMZof​:1␤␤»

m​: sub a() returns Int​:D { Int }; say &a.returns; a
rakudo-moar 8f4e90​: OUTPUT«(Int​:D)␤Type check failed for return value; expected Int​:D but got Int␤ in sub a at /tmp/SnKt55D7zj​:1␤ in block <unit> at /tmp/SnKt55D7zj​:1␤␤»

Tagging it testneeded.

@p6rt
Copy link
Author

p6rt commented Oct 11, 2015

The RT System itself - Status changed from 'new' to 'open'

@p6rt
Copy link
Author

p6rt commented Oct 11, 2015

From @FROGGS

Marked existing tests as related to this ticket​:
Raku/roast@5bd83c5b01

Closing ticket.

1 similar comment
@p6rt
Copy link
Author

p6rt commented Oct 11, 2015

From @FROGGS

Marked existing tests as related to this ticket​:
Raku/roast@5bd83c5b01

Closing ticket.

@p6rt p6rt closed this as completed Oct 11, 2015
@p6rt
Copy link
Author

p6rt commented Oct 11, 2015

@FROGGS - Status changed from 'open' to 'resolved'

@p6rt p6rt added the testneeded label Jan 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant