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

Review the Typing and Type Checking of Parameters and Variables #875

Open
lrennels opened this issue Nov 15, 2021 · 1 comment
Open

Review the Typing and Type Checking of Parameters and Variables #875

lrennels opened this issue Nov 15, 2021 · 1 comment

Comments

@lrennels
Copy link
Collaborator

The typing story for parameters and variables, particularly for non-Number types like Strings and Symbols, is a bit fragile and can cause some confusing error messages. For example, typing with something like

p1 = Parameter{Array{Symbol}}(default = [:hello, :goodbye], regions = [mydim])

will fail, and only work if you type it with {Symbol}, as if you are indicating the element type instead of the parameter type. We should move through this carefully and think about the conversion story, the typing, etc.

@lrennels
Copy link
Collaborator Author

Update that we should fold this in to all three _check_attributes methods including the one for internal parameter connections as added in #899. That particular method does not currently check datatypes, so as to avoid further complexity before we handle this uniformly, but should check them.

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