[Solved] What is the difference between using “::std” or including “using namespace std” in the header?


You are using QString, and QString is not from std namespace. When you directly type std::QString you will get an error, because QString is not defined in std namespace, but when you type using namespace std, You can use everything from std namespace without directly typing std (what is defined in that namespace), but not QString because definition of QString is not there.

solved What is the difference between using “::std” or including “using namespace std” in the header?