Mash icon indicating copy to clipboard operation
Mash copied to clipboard

fix format string

Open sjaenick opened this issue 3 years ago • 0 comments

g++ -c -O3 -std=c++14 -Isrc -I/vol/mgx-sw/src/tools/Mash/../capnproto-c++-0.10.2/include -I/vol/mgx-sw/include -include src/mash/memcpyLink.h -Wl,--wrap=memcpy  -o src/mash/CommandTaxScreen.o src/mash/CommandTaxScreen.cpp
In file included from src/mash/CommandTaxScreen.cpp:11:
src/mash/taxdb.hpp: In member function ‘void mash::TaxDB::writeReport(FILE*, const std::unordered_map<long unsigned int, mash::TaxCounts>&, long unsigned int, long unsigned int, mash::TaxID, int)’:
src/mash/taxdb.hpp:218:45: warning: format ‘%llu’ expects argument of type ‘long long unsigned int’, but argument 9 has type ‘mash::TaxID’ {aka ‘long unsigned int’} [-Wformat=]
  218 |   fprintf(FP, "%.4f\t%i\t%i\t%i\t%i\t%s\t%llu\t%s%s\n",
      |                                          ~~~^
      |                                             |
      |                                             long long unsigned int
      |                                          %lu
......
  224 |     taxon->rank.c_str(), taxID, std::string(2*depth, ' ').c_str(), taxon->name.c_str());
      |                          ~~~~~               
      |                          |
      |                          mash::TaxID {aka long unsigned int}

sjaenick avatar Nov 03 '22 10:11 sjaenick