Primitive values and void

Nir Lisker nlisker at gmail.com
Tue Feb 16 20:48:38 UTC 2021


Hi,

After reading the JEPs about primitive objects (.ref and .val) and the
conversion of primitives, I was wondering what happens with void and Void.
They are not interchangeable like primitives - a method returning void must
have 'return;` while a method returning Void must 'return null;' - but they
are the same semantically. Since Void mainly (only?) exists for generic
types purposes, will void be valid as a generic type and make Void more or
less useless? Will they have reference-value conversions like primitives,
if that makes sense?

- Nir



More information about the valhalla-dev mailing list