-
Couldn't load subscription status.
- Fork 19
[core][NDArray] Temporarily suspending Type Coercions #242
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
[core][NDArray] Temporarily suspending Type Coercions #242
Conversation
|
@shivasankarka, I prefer "explicit type cast" to "implicit type coercion". If a user sums up a Matrix of |
c8d9b63
into
Mojo-Numerics-and-Algorithms-group:pre-0.7
|
@forfudan Yes, explicitly type casting is better, it gives control to user. |
|
@shivasankarka, for sake of convenience, it is indeed good to have type coercions, but maybe we need to define and document a list of detailed rules of coercions for the users, so that they won't get surprised. Another topic is that not every feature from numpy is the best practice. For example, the pandas is more flexible in data types per column, but polars is stricter. Many people, however, love polars' style because they will never be surprised by implicit type casts. For numojo, we could also listen to users' feedback and see whether implicit type cast is really needed. |
This PR comments out all the Type Coercions for the data types that currently implemented. This is done for the following two reasons,
Therefore these will be temporarily commented out. We will get back to improving it and adding it back in later version of NuMojo once Mojo type system is mature enough for us to implement these data type conversions at compile time.