Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Class with [<AllowNullLiteral(false)>] barred from inheriting from normal non-nullable class #383
Super minor, but might as well log it. Up for grabs.
I would think this code should be legal
type A() = class end [<AllowNullLiteral(false)>] type B() = inherit A() // error FS0935: Types with the 'AllowNullLiteral' attribute may only inherit from or implement types which also allow the use of the null literal
The check makes sense, but fails to consider the case when the attribute explicitly disallows nulls. I made the same mistake in #376.
Fix is to change