objectWarning extends Level with Product with Serializable
Warnings are reserved for code that has bad semantics.
This by itself does not necessarily mean the code is buggy, but could mean the developer
made a mistake or does not fully understand the contructs or best practice.
An example is an expression as a statement. While this is perfectly legal, it could indicate
that the developer meant to assign the result to or otherwise use it.
Another example is a constant if. You can do things like if (true) { } if you want, but since the block
will always evaluate, the if statement perhaps indicates a mistake.
Linear Supertypes
Serializable, Serializable, Product, Equals, Level, AnyRef, Any
Warnings are reserved for code that has bad semantics. This by itself does not necessarily mean the code is buggy, but could mean the developer made a mistake or does not fully understand the contructs or best practice.
An example is an expression as a statement. While this is perfectly legal, it could indicate that the developer meant to assign the result to or otherwise use it.
Another example is a constant if. You can do things like if (true) { } if you want, but since the block will always evaluate, the if statement perhaps indicates a mistake.