-
Notifications
You must be signed in to change notification settings - Fork 2
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
Play nicely with other struct def macros #4
Comments
So Base.@kwdef @concrete struct Blah
a
b
end julia> blah = Blah(a=1, b="hey")
Blah{Int64,String}(1, "hey") It doesn't work with the |
I’ll bump myself here because I wanted this again today. |
Hopefully dd869e0 does it. Sill doesn't work with the |
|
Thank you for making the I have independently tried to make ConcreteStructs.jl and Parameters.jl work together well. My personal conclusion: It is possible to do so by making the following two changes.
Then For details, see my Jupyter notebook. I am a beginner in programming, so I may be doing something wrong, but I hope it will be helpful. |
Thanks for working on this! I'm trying to remember why that inner constructor was there in the first place. I am all for removing it if it's just getting in the way, though. Let me see if I can remember why I have it set up that way. |
I implemented something for I'm happy to open a PR so you can have a look. Right now, I don't have the right permissions, though. |
@janneshb ha! I didn’t notice it was you at first. Yeah, a PR would be great if you have it handy. I think you should be able to open one without permissions? I just have to approve the CI to run. |
Hm, it shows I can open a PR, but I don't have permission to push to a remote branch on the repo. Which I would need to do to open a PR, right? |
Oh yeah, it'll make you fork your own copy and will be used for the PR. |
Did you ever open that PR? Looks like Parameters' keyword arguments macro doesn't work with |
I did now. |
@concrete
should work withBase.@kwdef
and similar struct definition macros.The text was updated successfully, but these errors were encountered: