Added new warning flags and fixing warnings.

New flags: Wconversion, Wshadow, Wunreachable-code.