This is not just "before class", rather, this is the part of the specification of the return type of the operator "++".
You you have a type
, the notation
means another type, "a reference to the instance of the type SomeType", and the
makes the constant-modified variant the the same type, that is, the notation
means "a reference to the instance of the type SomeType; and the instance cannot be modified through this reference".
modification can be considered as syntactic sugar and a fool-proof feature protecting the variable
of the type
from modification of the instance, but the value of the variable itself can be modified, as you can assign a different reference of the same type to it later on.
C++ references are well explained here, with their semantics and usage: