-
Notifications
You must be signed in to change notification settings - Fork 20
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
crystal deps has been removed #13
Comments
Oh hi, this is caused by bindgens shard.yml, its postinstall hook needs to be updated to reflect that change. Can you PR that over there? |
It seems as if shard.yml of qt5.cr also contains the lines
so should it be updated, too? Whats the “correct” fix, replace that line by “shards build”? |
Yeah that should work. You can verify by running |
It took me some time to even find the "bindgen/" directory, because shards seems to remove the directory immediately if the installation fails. Anyway, I just cloned
So now a little bit lost how to proceed. This is probably a different issue and I should file it in bindgens repo (right?), but should the "crystal deps" thing be fixed first? |
Both issues are bindgen issues in any case. That issue there is new, looks like the type inference algorithm of Crystal got stupider. The I myself am not using Crystal currently, so recent changes in the language are beyond me. |
It's not related to type inference, see crystal-lang/crystal#6024. |
@RX14 thanks, but should the following example work: class Base
def self.create : Base
A.new
end
end
class A < Base
end
class AnyOf < Base
@children : Array(Base)
def initialize
@children = [Base.create]
end
end
AnyOf.new The declaration of |
Return type restrictions are not casts, they're constraints. |
I see, interesting. That makes sense but might lead to surprising errors (in particular if using external shards or so). Anyway, thanks for the explanation. |
I just tried installing it myself (8-year Rubyist new to Crystal) using the steps described here, and it seems to me that this project needs URGENT re-compiliing and testing with the newest Crystal compiler, particularly the Bindgen stuff! I got an avalanche of cascading Type-related errors when I compiled it using crystal 0.25.1. Thank you! |
@PerrinHH You're welcome to do so, I'm not interested in Crystal much anymore. |
@Papierkorb that's sad to hear, just lack of time? |
As for me, I tried.And I came to a point where the backtrace responded this:
Which means that this Hash does not respond to the key? method (which it should, according to documentation). Any ideas what I am supposed to do now? Thank you. |
No it doesn't https://crystal-lang.org/api/0.25.1/Hash.html It's |
You're correct. The documentation I read referred do Crystal 0.24.2. (Classical case for "Polish your glasses and read the small print.") |
UPDATE:Took me a little to fix the bindgen compilation errors caused by the Crystal update to 0.25.1. But finally I got it. Bindgen compiles. Yeeeah! Now: How can I link my private Bindgen update to
What can I do now? Since |
Closing this issue as both bindgen's and qt5.cr's commits for the reported problem have been merged. |
When trying to install the shard using
shards install
I getThe text was updated successfully, but these errors were encountered: