You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Currently, the type of the elements of a list or a matrix are based on the first element. However, some containers may have several different but compatible types (int and float). A non-aware user may mix them and get wrong results, and without being able to understand that it comes from different types being used. For example, consider those three lines:
The first and third lines provide the good result. The second one provides a wrong result since all the elements are casted to the type of the first element, which is int. However, it is probably the most natural way to write the matrix, since people don't bother with the ".0" when not needed. What is more confusing is that when writing something like "float a <- 1", there is a warning telling that 1 will be casted to float, and here not, so there is no way for a common user to have a clue about a possible error in the result.
I label this as a bug, since a regular user would think that not having the correct result using a determinant is a bug.
The text was updated successfully, but these errors were encountered:
I wouldn't label this as a bug, because it is clearly the responsibility of the user to force the type when he/she "doesn't bother" writing float elements with a decimal but still wants a matrix<float>. For instance, he/she can use :
Describe the bug
Currently, the type of the elements of a list or a matrix are based on the first element. However, some containers may have several different but compatible types (int and float). A non-aware user may mix them and get wrong results, and without being able to understand that it comes from different types being used. For example, consider those three lines:
the result obtained is
The first and third lines provide the good result. The second one provides a wrong result since all the elements are casted to the type of the first element, which is int. However, it is probably the most natural way to write the matrix, since people don't bother with the ".0" when not needed. What is more confusing is that when writing something like "float a <- 1", there is a warning telling that 1 will be casted to float, and here not, so there is no way for a common user to have a clue about a possible error in the result.
I label this as a bug, since a regular user would think that not having the correct result using a determinant is a bug.
The text was updated successfully, but these errors were encountered: