Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disabling default namespaces

Rust seems to use some namespaces by default. For example, I don't have to use std::string::String and can simply type String. How can I define my own struct String without clashing with std::string::String? And where can I find a list of the namespaces that are included by default?

like image 520
nwellnhof Avatar asked Dec 20 '22 03:12

nwellnhof


1 Answers

It's not a matter of 'default namespaces', it's the prelude.

like image 119
Steve Klabnik Avatar answered Jan 19 '23 07:01

Steve Klabnik