[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#564274: g++-4.4: Program is compiling by g++, even there is a bad conversion



Package: g++-4.4
Version: 4.4.2-8
Severity: normal

I can't make shorter source code, where is this error, thus I've got all source code from my programme, but I've written which lines is the error.

Line from 156 to 161 in engine.cpp:

SingleWord sword;
//definition class SingleWord is in file "SingleWord.h"
for(ushort i = 0; i < number_words; i++) {
      atime = time(NULL);
      sword = courses[activ_course]->getSingleWord(swords[i]);
	//courses is vector<Kurs>, definition class Kurs in file "kurs.hpp"
      sword.setSpelling("cat");

But definition function getSingleWord(swords[i]) is:
SingleWord const* Kurs::getSingleWord(ushort number) const
{
        if(number >= qAllSingleWords)throw Error::newError(Error::BAD_ARGUMENT, "", __LINE__, __FILE__);
        return number < wordl1.size() ? wordl1[number] : wordl2[number-wordl1.size()];
}

The source code is compiling with no errors: "g++-4.4 -pedantic main.cpp engine.cpp nakladka2.cpp kurs.cpp SingleWord.cpp RegisterOfErrors.cpp -lboost_regex-mt -o main.e"

File are on http://godlark.com/upload/, example godlark.com/upload/main.cpp


-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.30-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=pl_PL.UTF-8, LC_CTYPE=pl_PL.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages g++-4.4 depends on:
ii  gcc-4.4                   4.4.2-8        The GNU C compiler
ii  gcc-4.4-base              4.4.2-8        The GNU Compiler Collection (base 
ii  libc6                     2.10.2-5       Embedded GNU C Library: Shared lib
ii  libgmp3c2                 2:4.3.1+dfsg-3 Multiprecision arithmetic library
ii  libmpfr1ldbl              2.4.2-3        multiple precision floating-point 
ii  libstdc++6-4.4-dev        4.4.2-8        The GNU Standard C++ Library v3 (d

g++-4.4 recommends no packages.

Versions of packages g++-4.4 suggests:
pn  g++-4.4-multilib              <none>     (no description available)
pn  gcc-4.4-doc                   <none>     (no description available)
pn  libstdc++6-4.4-dbg            <none>     (no description available)

-- no debconf information



Reply to: