[Bug 858425] Re: g++ has a new syntax complaint

Julian Taylor jtaylor.debian at googlemail.com
Sat Sep 24 19:53:57 UTC 2011


This is most certainly a bug in your code caught by the stricter compiler.
I did not check as 43mb is to large for me to download, but probably you are calling a base constructor from an overloaded constructor which will just create an temporary which is instantly removed.
Please provide a smaller testcase.

** Changed in: gcc-defaults (Ubuntu)
       Status: New => Invalid

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to gcc-defaults in Ubuntu.
https://bugs.launchpad.net/bugs/858425

Title:
  g++ has a new syntax complaint

Status in “gcc-defaults” package in Ubuntu:
  Invalid

Bug description:
  Not 100% certain this is a bug, as opposed to some new C++/g++
  development.  But the following sequence of commands runs without error
  in g++ 4.4.3 on ubuntu lynx, while in g++ 4.5.2 on ubuntu natty it fails
  with the complaint

    g++ -c -Wall -O3   PB.cpp
    PB.cpp: In function ‘int main(int, char**)’:
    PB.cpp:1076:22: error: cannot call constructor ‘Random::Random’ directly
    PB.cpp:1076:22: error:   for a function-style cast, remove the redundant ‘::Random’
    
  Here is the sequence of commands which produces the above error on
  ubuntu natty:

    met% wget http://megasun.bch.umontreal.ca/People/lartillot/www/phylobayes3.3b.tar.gz
    met% tar zxf phylobayes3.3b.tar.gz 
    met% cd phylobayes3.3b/sources/
    met% make

  Hope this helps.

  Alex

  ProblemType: Bug
  DistroRelease: Ubuntu 11.04
  Package: g++ 4:4.5.2-1ubuntu3
  ProcVersionSignature: Ubuntu 2.6.38-11.48-generic 2.6.38.8
  Uname: Linux 2.6.38-11-generic x86_64
  Architecture: amd64
  Date: Sat Sep 24 14:34:12 2011
  InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release amd64 (20091027)
  ProcEnviron:
   LANGUAGE=en_US:en
   PATH=(custom, user)
   LANG=en_US.UTF-8
   SHELL=/bin/bash
  SourcePackage: gcc-defaults
  UpgradeStatus: Upgraded to natty on 2011-08-03 (51 days ago)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gcc-defaults/+bug/858425/+subscriptions




More information about the foundations-bugs mailing list