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
Writing a method that takes a type with a unit of measure causes the compiler to hang forever with no error, but only if the measure is derived from another measure.
Repro code
[<Measure>]typeMeasure1[<Measure>]typeMeasure2= Measure1
typeClass()=member_.Method(x:float<Measure2>)= x
@inosik Yes, this only happens when the unit of measure is derived from another one. I'll update the title and the repro code.
theprash
changed the title
Compiler hangs on any method taking a type with unit of measure
Compiler hangs on method taking a type with unit of measure derived from another unit of measure
Dec 14, 2020
Thanks a lot for reporting @theprash and for the pointer @inosik! There was a version of nonAbbreviatedType in OverloadSuffix that still could fall in the infinite loop. It only affects class members so we didn't see it before. I should put the helper in a common module somewhere to avoid these issues, but for now I just copied the code. It will be fixed in the next release 👍
Description
Writing a method that takes a type with a unit of measure causes the compiler to hang forever with no error, but only if the measure is derived from another measure.
Repro code
The bug is also present for static methods.
Related information
Fable version: 3.0.1 on https://fable.io/repl/#
The text was updated successfully, but these errors were encountered: