Return-Path: Delivered-To: apmail-incubator-stdcxx-dev-archive@www.apache.org Received: (qmail 66014 invoked from network); 24 Mar 2007 00:32:53 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 24 Mar 2007 00:32:53 -0000 Received: (qmail 42014 invoked by uid 500); 24 Mar 2007 00:33:01 -0000 Delivered-To: apmail-incubator-stdcxx-dev-archive@incubator.apache.org Received: (qmail 41996 invoked by uid 500); 24 Mar 2007 00:33:00 -0000 Mailing-List: contact stdcxx-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: stdcxx-dev@incubator.apache.org Delivered-To: mailing list stdcxx-dev@incubator.apache.org Received: (qmail 41985 invoked by uid 99); 24 Mar 2007 00:33:00 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Mar 2007 17:33:00 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Mar 2007 17:32:52 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 4D0C3714057 for ; Fri, 23 Mar 2007 17:32:32 -0700 (PDT) Message-ID: <20034704.1174696352313.JavaMail.jira@brutus> Date: Fri, 23 Mar 2007 17:32:32 -0700 (PDT) From: "Martin Sebor (JIRA)" To: stdcxx-dev@incubator.apache.org Subject: [jira] Closed: (STDCXX-364) [gcc/Linux] std::tm not declared in In-Reply-To: <2623357.1174338572545.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/STDCXX-364?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Martin Sebor closed STDCXX-364. ------------------------------- Resolution: Fixed Fix Version/s: 4.2 > [gcc/Linux] std::tm not declared in > -------------------------------------------- > > Key: STDCXX-364 > URL: https://issues.apache.org/jira/browse/STDCXX-364 > Project: C++ Standard Library > Issue Type: Bug > Components: 21. Strings > Affects Versions: 4.1.3 > Environment: Linux, gcc 3.4.6 - 4.1.2 > Reporter: Scott (Yu) Zhong > Assigned To: Martin Sebor > Fix For: 4.2 > > > getting this error: > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:568: error: reference to 'tm' is ambiguous > /usr/include/../include/time.h:135: error: candidates are: struct tm > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:550: error: struct Fallback::tm > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:568: error: reference to 'tm' is ambiguous > /usr/include/../include/time.h:135: error: candidates are: struct tm > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:550: error: struct Fallback::tm > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:568: error: 'tm' does not name a type > /home/scottz/stdcxx/tests/strings/21.cwchar.cpp:577: error: 'test_tm' in namespace 'std::Nested' does not name a type > ----------------------------------------------------------------------------------------- > Martin Sebor [m...@roguewave.com] > I was able to reproduce the same error with gcc 3.4.6. > The purpose of the test is to verify the conformance of the header WRT namespace cleanliness (i.e., that symbols like struct tm are defined in namespace std and not also in the global scope). The test is designed to fail at runtime (via assertions) rather than at compile time but it looks like the implementation of the test (or maybe even its > design) is broken. In any case, the fact that the test doesn't compile suggests there is a problem with the header. > The compilation errors for the simple program below confirm this. Can you open an issue for this problem and reference this thread in the archive in the issue? > $ cat t.cpp && nice make t > #include > int main () > { > std::tm tmb = { 0 }; > } > gcc -c -I/amd/devco/sebor/stdcxx/include/ansi -D_RWSTDDEBUG -I/amd/devco/sebor/stdcxx/include -I/build/sebor/stdcxx-gcc-3.4.6-11S/include > -I/amd/devco/sebor/stdcxx/../rwtest > -I/amd/devco/sebor/stdcxx/../rwtest/include > -I/amd/devco/sebor/stdcxx/tests/include -pedantic -nostdinc++ -g -W -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long > -Wcast-align t.cpp > t.cpp: In function `int main()': > t.cpp:5: error: `tm' is not a member of `std' > t.cpp:5: error: expected `;' before "tmb" > make: *** [t.o] Error 1 > Thanks > Martin > $ cat t.cpp && nice make t > #include > int main () > { > std::tm tmb = { 0 }; > } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.