Const return warnings

Silence some compiler warnings.
The fist change is about const return types.
The second change is about using statements.