Why there is no warning while compiling

why there is no warning while compiling, event if there is a obviously incorrect code that should be warn in my code.
Im using vs2019, and vs2017 has no warning as well