3 ms·
if you do not include the namespace separator, and you import a namespace with the same name defined, you'll have a not-so-pleasant surprise. e.g.:you use "Exce
by lucio 11y ago
if you do not include the namespace separator, and you import a namespace with the same name defined, you'll have a not-so-pleasant surprise. e.g.:you use "Exception" to catch all exceptions, and someone defines "SQL\Exception", then you import "SQL", and now all your catch blocks stop working. But don't worry. This is business as usual in the PHP world.