Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign
r9738 compile error with wx3.0-trunk
(1/1)
Jenna:
I get the followinhg error with wx3.0 trunk on my linux system (64bit gcc 4.8):
--- Quote ---/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp: In function 'int CCManagerHelper::CallTipToInt(const wxString&, int)':
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: error: ambiguous overload for 'operator^' (operand types are 'int' and 'wxString::const_iterator::reference {aka wxUniChar}')
val = 33 * val ^ (*itr);
^
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: candidates are:
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, int) <built-in>
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, unsigned int) <built-in>
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, long int) <built-in>
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, long unsigned int) <built-in>
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, long long int) <built-in>
/home/jens/codeblocks-build/codeblocks.git/src/sdk/ccmanager.cpp:72:28: note: operator^(int, long long unsigned int) <built-in>
--- End quote ---
Casting the (*itr) to int makes the error go away, but as I don't know what this function does, I don't know if this is the corect fix or does something really harmful.
@Alpha and other devs more familiar with CC could you please look into it ?
Alpha:
--- Quote from: jens on March 14, 2014, 07:37:17 pm ---Casting the (*itr) to int makes the error go away, but as I don't know what this function does, I don't know if this is the corect fix or does something really harmful.
@Alpha and other devs more familiar with CC could you please look into it ?
--- End quote ---
That is the correct fix.
(The function is used to store a dictionary between calltip context, and the previously user selected calltip page. I choose to store an int (hash value) instead of the full strings, because CCManager has no need to waste memory duplicating all displayed calltips.)
Edit: Fix committed.
Navigation
[0] Message Index
Go to full version