is a sealed class an abstract class?
# announcements
r
is a sealed class an abstract class?
g
not necessary, it may be abstract
Or you mean in bytecode?
In bytecode it’s always abstract
r
in bytecode
What is the reason?
t
It's by definition : a
sealed class
is a special kind of
abstract class
with a restricted inheritance hierarchy.
g
Yes
so you cannot instantiate it
s
do we have like commonly-accepted terms to refer to both a
sealed class
declaration and classes that inherit from them?
the naming gets a little confusing there lol
g
I'm personally just call it sealed class
Same way as enum class
s
but then what do you call members of a sealed class?
or, rather, inheriting members of a sealed class hierarchy
p
They are simply a class