-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Give error if using instance_sizeof on a generic type without type vars #5209
Conversation
LGTM 👍 ? |
@sdogruyol in the interests of keeping noise down, can you not "LGTM" random prs, unless they need bumping (this PR isn't even a day old). |
@RX14 they're mostly approved PRs not random.. |
Ok but its still not helpful |
I agree, the LGTM end up in my mail box and when I think there's some new interesting reply or something relevant to the issue, it's just a 👍 . Let's avoid that. |
raise "BUG: #{node} at #{node.location} should receive a type" | ||
end | ||
|
||
if type.is_a? GenericClassType |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be GenericType
. That's the base module for both generic classes and modules.
ec94145
to
8c2d6eb
Compare
@asterite Done. |
8c2d6eb
to
07ca484
Compare
After some `git bisect` work, it was discovered that the following bug fix causes a regression on a patch which should be detectable. > 074d61c is the first bad commit > commit 074d61c > Author: Guilherme Bernal <[email protected]> > Date: Fri Nov 3 11:44:21 2017 -0300 > > give error if using instance_sizeof on a generic type without type vars (crystal-lang#5209) > > :040000 040000 2fa5bdc54dead5c6c70f011e4e131f74bc170156 546f4b9d362c210b3b26f688e9314fb31ea64acb M spec > :040000 040000 a3694241ab2bdfc038018e3280758fa3937b29de 80ec4ae5f0c337447208280893acb2fca45dbf5b M src
Fixes #5207