[omniORB] Omniorb4 and Visual C++ and hash problem

Duncan Grisby duncan at grisby.org
Wed Sep 10 15:24:56 BST 2003


On Thursday 4 September, Bartosz Zembrzuski wrote:

> c:\omni402\include\omniorb4\omniinternal.h(296) : error C2955: 'hash' : 
> use of class template requires template argument list
>  
> d:\users\bartek\test\narzedzia\stlport\stlport\stl_hash_fun.h(40) : see
> declaration of 'hash'
> 
> I've searched archive of this group, and found someone reported similar 
> problem in 1999, but only answer was to change include order or not to 
> use "using namespace std".
> 
> Both solution doesn't work for me, because I'm mainly use STL classes 
> and sometimes use omniORB so I can't delete "using namespace std", and 
> also I cannot prevent someone includes STL header before omniORB one.

It is fundamentally a wrong thing to do in C++ to use #include after a
using namespace declaration. Once another namespace's definitions have
been imported into the global namespace, all bets are off about the
meanings of all sorts of things.

Cheers,

Duncan.

-- 
 -- Duncan Grisby         --
  -- duncan at grisby.org     --
   -- http://www.grisby.org --



More information about the omniORB-list mailing list