Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Type inference for casts is not trivial, because the result type is usually explicitly given (main purpose of a cast). - However, when the data type of the result is given, but the value type is unknown, we should infer the value type from the argument. - So far, this was only done when the result is a matrix and the argument is a single-column frame. - Furthermore, the result type was reset to unknown if we could not infer anything. - This commit introduces two improvements: - If the result type is a matrix of unknown value type, the value type is also inferred for matrix and scalar arguments. - If we decide not to infer the result type, we do not reset it to unknown, but leave it as it is in order not to remove any information (e.g., on the data type) that was explicitly given.
- Loading branch information