[omniORB] String_var and ostream operations.

Óscar Óscar
Wed, 23 Jan 2002 17:58:04 +0100


Hi,

Why do I have to cast a CORBA::String_var to print its contents:

CORBA::String_var s = CORBA::string_dup("Whatever!!!!");
cout << static_cast<char*>(s)[1] << endl; // fine
cout << s << endl; 			  // print address of s

Thanks and regards.
-- 
=========================================================
Óscar Rafael de la Cruz Sánchez de la Plaza.
GMV S.A. Directorate of Space and Defense.
Ground Systems / Control Systems and On-board Software.
P.T.M. Isaac Newton, 11. 28760. Tres Cantos. MADRID.
Phone.: +34 91 807 3348 Fax.: +34 91 807 2199
Ext.: 3348. Office.: 201
e-mail: ocruz@gmv.es