DiscussionsIssue archiveOCCT:Foundation Classes

Archived issue #0005531

Foundation classes - it is impossible avoid "using namespace std" directive when use OCC

Open CASCADEOCCT:Foundation Classesclosed2 public notes

Search issues

Description

In this case there is follow problems.

1. There is dependecies from order of included header files.

2. There is possibility of name conflict with different from std namespaces.

In other words, definition of using some namespace directive must be inside
other namespace or take place in source code, not header files.
 
I suggest to solve the problem like is written in
Bjarne Straustrap"The C++ programming languige", 3-th edition, in [network address removed] paragraf

Public activity

2 archived notes

Participants are labeled by their role within this record.

01Commenter 1
Problem described in issue is reproduced on current state of OCCT.
02Commenter 2
The remaining uses of objects from std:: namespace without prefix have been fixed within #0030895, and remaining "using" directives for std namespace have been removed from OCCT header files in #0008239.

Related records