Compiling C++, Visual Studio vs. Code::Blocks output

closed account (E0p9LyTq)
I personally like the information VS 2017 Community outputs when compiling a simple C++ program:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#include <map>
#include <string>

template<typename KeyType>
struct ReverseSort
{
   bool operator()(const KeyType& key1, const KeyType& key2)
   {
      return (key1 > key2);
   }
};

int main()
{
   // map and multimap key of type short to value of type string
   std::map<short, std::string> mapIntToString1;
   std::multimap<short, std::string> mmapIntToString1;

   // map and multimap constructed as a copy of another
   std::map<short, std::string> mapIntToString2(mapIntToString1);
   std::multimap<short, std::string> mmapIntToString2(mmapIntToString1);

   // map and multimap constructed given a part of another map or multimap
   std::map<short, std::string> mapIntToString3(mapIntToString1.cbegin(), mapIntToString1.cend());

   std::multimap<short, std::string> mmapIntToString3(mmapIntToString1.cbegin(), mmapIntToString1.cend());

   // map and multimap with a predicate that inverses sort order
   std::map<short, std::string, ReverseSort<short> > mapIntToString4(mapIntToString1.cbegin(), mapIntToString1.cend());

   std::multimap<short, std::string, ReverseSort<short> > mmapIntToString4(mapIntToString1.cbegin(), mapIntToString1.cend());
}


VS output:
1>------ Build started: Project: 20-1_InstantiatingMapMultimap, Configuration: Release Win32 ------
1>20-1_InstantiatingMapMultimap.cpp
1>Generating code
1>All 346 functions were compiled because no usable IPDB/IOBJ from previous compilation was found.
1>Finished generating code
1>20-1_InstantiatingMapMultimap.vcxproj -> C:\Programming\My Projects\Lesson20\Release\20-1_InstantiatingMapMultimap.exe
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========


C::B (MinGW) output:
ingw32-g++.exe -Wall -std=c++1z -fexceptions -O2 -std=c++1z  -c D:\Programming\Projects\CBTest\main.cpp -o obj\Release\main.o
mingw32-g++.exe  -o bin\Release\CBTest.exe obj\Release\main.o  -s  
Output file is bin\Release\CBTest.exe with size 723.50 KB
Process terminated with status 0 (0 minute(s), 2 second(s))
0 error(s), 0 warning(s) (0 minute(s), 2 second(s))


Is there some switch or option I can use in C::B to be more informational about a compilation? I like to see how many functions are needed to make up a program using various C++ features. STL objects seem to require quite a few functions.

I wish VS could show the executable's size, as C::B shows.
Topic archived. No new replies allowed.