Why calling sort() crashes?
-
Could anyone please help me to find why call to sort() is crashing at run-time in following code block:
string s = "Annnitttesrrh.";
vector vecChar(s.begin(), s.end());
sort(vecChar.begin(), vecChar.end(), greater_equal());Am i missing something very basic ?
-
Could anyone please help me to find why call to sort() is crashing at run-time in following code block:
string s = "Annnitttesrrh.";
vector vecChar(s.begin(), s.end());
sort(vecChar.begin(), vecChar.end(), greater_equal());Am i missing something very basic ?
Kumar Anitesh wrote:
Am i missing something very basic ?
Not that I can figure out. I tried the same code, but using
greater
as the predicate and it works fine. This needs an STL expert to look at it, but you posted in the managed C++ forum; try http://www.codeproject.com/Forums/4486/ATL-WTL-STL.aspx[^].Veni, vidi, abiit domum