Using namespace or not

Discussions about the development of the TechDraw workbench
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
User avatar
bensay
Posts: 202
Joined: Wed Dec 22, 2021 8:14 pm
Location: Danmark
Contact:

Using namespace or not

Post by bensay »

In some Techdraw files

Code: Select all

using namespace TechDraw;
is used, while lines still include

Code: Select all

TechDraw::DrawView*[...]
. If this should be consistent, is using namespace then preferred or not using it at all?
User avatar
wandererfan
Veteran
Posts: 6309
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: Using namespace or not

Post by wandererfan »

bensay wrote: Wed Jul 06, 2022 1:50 pm In some Techdraw files

Code: Select all

using namespace TechDraw;
is used, while lines still include

Code: Select all

TechDraw::DrawView*[...]
. If this should be consistent, is using namespace then preferred or not using it at all?
I guess "using namespace" makes for tidier code, but I have no strong opinions on either.
Post Reply