Support for primitive types in instanceof and type patterns

Brian Goetz brian.goetz at oracle.com
Tue Nov 15 20:13:32 UTC 2022



On 11/15/2022 2:55 PM, Dan Heidinga wrote:
> Hi Angelos,
>
> The overall direction and writeup for this looks good to me.  I think 
> we need to be more specific about how doubles & floats fit into this 
> though as they are perpetual source of special cases.

Indeed, floating point is the gift that keeps on giving.

Joe recently did some nice work in the spec of Float and Double, 
outlining the various different ways in which floats can be compared.  
This allows language features like pattern matching, casting, and switch 
to appeal to "compared by FooBar comparison", rather than spelling it 
out for each use.




More information about the amber-spec-experts mailing list