-
-
Notifications
You must be signed in to change notification settings - Fork 87
Open
Description
Compare:
>>> 2 |> celsius
error: while type checking
┌─ Module 'physics::temperature_conversion', File <builtin>/modules/physics/temperature_conversion.nbt:15:12
│
15 │ fn celsius(t_kelvin: Temperature) -> Scalar = t_kelvin / kelvin - _offset_celsius
│ ^^^^^^^^ Temperature
│
┌─ <input:14>:1:1
│
1 │ 2 |> celsius
│ ^ ------- incompatible dimensions in argument 1 of function call to 'celsius'
│ │
│ Angle or Scalar or SolidAngle
│
= parameter type: Temperature
argument type: Scalar [= Angle, Scalar, SolidAngle]
Suggested fix: multiply the function argument by a `Temperature` factor
>>> 2 -> celsius
error: while type checking
┌─ <input:16>:1:1
│
1 │ 2 -> celsius
│ ^ Scalar
│
= Incompatible types in function call: expected 'Temperature', got 'Scalar' instead
Metadata
Metadata
Assignees
Labels
No labels