Click here to Skip to main content
15,916,949 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Calling a member class implicitly Pin
Albert Holguin2-Jul-12 4:30
professionalAlbert Holguin2-Jul-12 4:30 
QuestionFtp : how to know downloading data is completed? Pin
includeh101-Jul-12 2:15
includeh101-Jul-12 2:15 
AnswerRe: Ftp : how to know downloading data is completed? Pin
Richard MacCutchan1-Jul-12 6:13
mveRichard MacCutchan1-Jul-12 6:13 
AnswerRe: Ftp : how to know downloading data is completed? Pin
Jochen Arndt1-Jul-12 22:36
professionalJochen Arndt1-Jul-12 22:36 
QuestionWill CInternetException catch a socket error Pin
ForNow29-Jun-12 11:37
ForNow29-Jun-12 11:37 
QuestionLNK1123: failure during conversion to COFF: file invalid or corrupt Pin
forkbomber29-Jun-12 9:52
forkbomber29-Jun-12 9:52 
AnswerRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
Albert Holguin29-Jun-12 10:53
professionalAlbert Holguin29-Jun-12 10:53 
GeneralRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
forkbomber30-Jun-12 2:17
forkbomber30-Jun-12 2:17 
AnswerRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
Richard MacCutchan30-Jun-12 2:46
mveRichard MacCutchan30-Jun-12 2:46 
GeneralRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
forkbomber30-Jun-12 3:47
forkbomber30-Jun-12 3:47 
GeneralRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
Richard MacCutchan30-Jun-12 5:57
mveRichard MacCutchan30-Jun-12 5:57 
AnswerRe: LNK1123: failure during conversion to COFF: file invalid or corrupt Pin
fat_boy30-Jun-12 20:40
fat_boy30-Jun-12 20:40 
QuestionSearch in *.chm File with C++? Pin
bosfan29-Jun-12 3:10
bosfan29-Jun-12 3:10 
AnswerRe: Search in *.chm File with C++? Pin
bosfan29-Jun-12 6:13
bosfan29-Jun-12 6:13 
Generalhelp about C++ STL container Pin
Falconapollo28-Jun-12 5:40
Falconapollo28-Jun-12 5:40 
GeneralRe: help about C++ STL container Pin
Chris Losinger28-Jun-12 6:11
professionalChris Losinger28-Jun-12 6:11 
GeneralRe: help about C++ STL container Pin
Falconapollo28-Jun-12 15:07
Falconapollo28-Jun-12 15:07 
GeneralRe: help about C++ STL container Pin
Maximilien28-Jun-12 7:27
Maximilien28-Jun-12 7:27 
GeneralRe: help about C++ STL container Pin
Falconapollo28-Jun-12 15:07
Falconapollo28-Jun-12 15:07 
GeneralRe: help about C++ STL container Pin
Aescleal28-Jun-12 8:41
Aescleal28-Jun-12 8:41 
How about abstracting the construction into a function as it's hard to grab the extra level of indirection using a vector constructor or an algorithm:
C++
std::vector<std::set<int>::iterator> build_index( const std::set<int> &s )
{
	std::vector< std::set<int>::iterator > index;

	for( auto iter( s.begin() ); iter != s.end(); ++iter )
	{
		index.push_back( iter );
	}

	return index;
}

int main()
{
	int set_initialisers[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9 };
	std::set<int> s( std::begin( set_initialisers ), std::end( set_initialisers ) );

	std::vector< std::set<int>::iterator > index( build_index( s ) );
}
It's not that inefficient in C++98 as it'll probably trigger NRVO and in C++11 it'll use the move constructor for vector.
GeneralRe: help about C++ STL container Pin
Falconapollo28-Jun-12 15:08
Falconapollo28-Jun-12 15:08 
GeneralRe: help about C++ STL container Pin
Aescleal29-Jun-12 1:03
Aescleal29-Jun-12 1:03 
GeneralRe: help about C++ STL container Pin
Falconapollo29-Jun-12 16:18
Falconapollo29-Jun-12 16:18 
GeneralRe: help about C++ STL container Pin
Falconapollo29-Jun-12 16:25
Falconapollo29-Jun-12 16:25 
QuestionChange CBS_DROPDOWN on runtime ? Pin
_Flaviu28-Jun-12 4:31
_Flaviu28-Jun-12 4:31 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.