mirror of
https://github.com/isocpp/CppCoreGuidelines.git
synced 2024-03-22 13:30:58 +08:00
SL_3 'Do not add non-standard entities to namespace std
' add example (#2031)
* SL_3 add example * Update isocpp.dic add My_Vector
This commit is contained in:
parent
6a0b5e6eca
commit
0d70ae927d
|
@ -19754,7 +19754,17 @@ Additions to `std` might clash with future versions of the standard.
|
||||||
|
|
||||||
##### Example
|
##### Example
|
||||||
|
|
||||||
???
|
namespace std { // BAD: violates standard
|
||||||
|
class My_vector {
|
||||||
|
// . . .
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
namespace Foo { // GOOD: user namespace is allowed
|
||||||
|
class My_vector {
|
||||||
|
// . . .
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
##### Enforcement
|
##### Enforcement
|
||||||
|
|
||||||
|
|
|
@ -347,6 +347,7 @@ Murray93
|
||||||
mutex
|
mutex
|
||||||
mutexes
|
mutexes
|
||||||
mx
|
mx
|
||||||
|
My_vector
|
||||||
MyCustomError
|
MyCustomError
|
||||||
MyException
|
MyException
|
||||||
myMap
|
myMap
|
||||||
|
|
Loading…
Reference in New Issue
Block a user