<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: vector initialization with in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/vector-initialization-with/m-p/2759455#M101598</link>
    <description>It appears your T violates 23.1(3), it has to be CopyConstructable.  Table 30 in 20.1.3(1) says that &amp;amp;t returns *T.  And I assume it better not be private.&lt;BR /&gt;&lt;BR /&gt;I've heard from Roguewave on this and he said sometimes there are changes that can be made to allow this but is isn't required by the Standard.</description>
    <pubDate>Thu, 09 Mar 2006 22:56:55 GMT</pubDate>
    <dc:creator>Dennis Handly</dc:creator>
    <dc:date>2006-03-09T22:56:55Z</dc:date>
    <item>
      <title>vector initialization with</title>
      <link>https://community.hpe.com/t5/operating-system-linux/vector-initialization-with/m-p/2759454#M101597</link>
      <description>I'm using a stl::vector to maintain list. &lt;BR /&gt;Program fails during compilation time when the template class's overloaded address operator is private.&lt;BR /&gt;When it's made public files get compiled without a problem. However the same test program gets compiled with the VC compiler in Windows. Is this a stl implementation specific issue in HP-UX.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;My test files are as follows&lt;BR /&gt;&lt;BR /&gt;// Test.h: file&lt;BR /&gt;//&lt;BR /&gt;//////////////////////////////////////////////////////////////////////&lt;BR /&gt;&lt;BR /&gt;#if !defined(_TEST_HDR_)&lt;BR /&gt;#define _TEST_HDR_&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;class CTest  &lt;BR /&gt;{&lt;BR /&gt;public:&lt;BR /&gt; CTest();&lt;BR /&gt; virtual ~CTest();&lt;BR /&gt;private:&lt;BR /&gt; CTest * operator&amp;amp;();  &lt;BR /&gt;};&lt;BR /&gt;&lt;BR /&gt;#endif //&lt;BR /&gt;&lt;BR /&gt;// Test.cpp: implementation of the CTest class.&lt;BR /&gt;//&lt;BR /&gt;//////////////////////////////////////////////////////////////////////&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#include "Test.h"&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;//////////////////////////////////////////////////////////////////////&lt;BR /&gt;// Construction/Destruction&lt;BR /&gt;//////////////////////////////////////////////////////////////////////&lt;BR /&gt;&lt;BR /&gt;CTest::CTest()&lt;BR /&gt;{&lt;BR /&gt;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;CTest::~CTest()&lt;BR /&gt;{&lt;BR /&gt;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;CTest * CTest::operator&amp;amp;()&lt;BR /&gt;{&lt;BR /&gt; return this;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;///// mytest.h file&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#ifndef __MYTEST_H__&lt;BR /&gt;#define __MYTEST_H__&lt;BR /&gt;&lt;BR /&gt;#include &lt;IOSTREAM.H&gt;&lt;BR /&gt;#include &lt;STRING&gt; &lt;BR /&gt;&lt;BR /&gt;#include "Test.h"&lt;BR /&gt;&lt;BR /&gt;class mytest&lt;BR /&gt;{&lt;BR /&gt;&lt;BR /&gt;public:&lt;BR /&gt; mytest();&lt;BR /&gt; int test(int a);&lt;BR /&gt; std::vector&lt;CTEST&gt; mNodeMap;&lt;BR /&gt;&lt;BR /&gt;};&lt;BR /&gt;&lt;BR /&gt;#endif //MYTEST&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;//mytest.cpp file&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;#include "mytest.h"&lt;BR /&gt;&lt;BR /&gt;mytest::mytest()&lt;BR /&gt;{&lt;BR /&gt; mNodeMap.resize(30);&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;int mytest::test(int a)&lt;BR /&gt;{&lt;BR /&gt; &lt;BR /&gt; &lt;BR /&gt; return a;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;version of aCC compiler I'm using is &lt;BR /&gt;A.03.33&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/CTEST&gt;&lt;/STRING&gt;&lt;/IOSTREAM.H&gt;</description>
      <pubDate>Mon, 08 Jul 2002 15:17:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/vector-initialization-with/m-p/2759454#M101597</guid>
      <dc:creator>sanjai</dc:creator>
      <dc:date>2002-07-08T15:17:36Z</dc:date>
    </item>
    <item>
      <title>Re: vector initialization with</title>
      <link>https://community.hpe.com/t5/operating-system-linux/vector-initialization-with/m-p/2759455#M101598</link>
      <description>It appears your T violates 23.1(3), it has to be CopyConstructable.  Table 30 in 20.1.3(1) says that &amp;amp;t returns *T.  And I assume it better not be private.&lt;BR /&gt;&lt;BR /&gt;I've heard from Roguewave on this and he said sometimes there are changes that can be made to allow this but is isn't required by the Standard.</description>
      <pubDate>Thu, 09 Mar 2006 22:56:55 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/vector-initialization-with/m-p/2759455#M101598</guid>
      <dc:creator>Dennis Handly</dc:creator>
      <dc:date>2006-03-09T22:56:55Z</dc:date>
    </item>
  </channel>
</rss>

