C++
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
Runtime options...
- voluntas
- @ignis_fatuus
- ブン
- @Linda_pp
- 清楚なC++メイドBOT
- @tzik_tack
- 長谷川一輝
- wraith13
- @jj1bdx
- @cpp_akira
- 安藤敏彦
- @srz_zumix
- Siv3D
- takezoh
- まろ
- @okdshin
- @hnokx
- @ishidakei
- @take_cheeze
- TAKEI Yuya
- @mumumu
- I (@wx257osn2)
- イズカワタカノブ
- @tyottyoworks
- ___shanon
- わたやん
- @KorekaraSEDB
- @kariya_mitsuru
- @ciniml
- @beam2d
- @grafi_tt
- @nekketsuuu
- LouiS0616
- @volanja
- 大鎌広
- むてら
- ガチKGB
x
15
1
2
using namespace std;
3
4
void func()
5
{
6
map<pair<uint,ulong>, pair<int,int> > myMap();
7
vector<myMap::value_type> mapVector();
8
//...
9
for(myMap::iterator it = myMap.begin(); it != myMap.end(); it++)
10
{
11
//if(...)
12
mapVector.push_back(*it);
13
}
14
//...
15
}
$ g++ prog.cc -Wall -Wextra
Start
prog.cc: In function 'void func()': prog.cc:7:12: error: 'std::map<std::pair<unsigned int, long unsigned int>, std::pair<int, int> > myMap()' cannot appear in a constant-expression vector<myMap::value_type> mapVector(); ^ prog.cc:7:29: error: template argument 1 is invalid vector<myMap::value_type> mapVector(); ^ prog.cc:7:29: error: template argument 2 is invalid prog.cc:7:42: error: invalid type in declaration before ';' token vector<myMap::value_type> mapVector(); ^ prog.cc:9:9: error: 'myMap' is not a class or namespace for(myMap::iterator it = myMap.begin(); it != myMap.end(); it++) ^ prog.cc:9:45: error: 'it' was not declared in this scope for(myMap::iterator it = myMap.begin(); it != myMap.end(); it++) ^ prog.cc:9:57: error: request for member 'end' in 'myMap', which is of non-class type 'std::map<std::pair<unsigned int, long unsigned int>, std::pair<int, int> >()' for(myMap::iterator it = myMap.begin(); it != myMap.end(); it++) ^ prog.cc:12:23: error: request for member 'push_back' in 'mapVector', which is of non-class type 'int()' mapVector.push_back(*it); ^
1
Finish