Author Topic: The 25 August 2012 build (8248) is out.  (Read 151012 times)

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5193
The 25 August 2012 build (8248) is out.
« on: August 25, 2012, 08:06:20 pm »
Get quick announcements through the RSS feed http://www.codeblocks.org/nightly/CodeBlock_RSS.xml

Before you use a nightly make sure you understand how it works.

A link to the unicode windows wxWidget dll for Code::Blocks : http://prdownload.berlios.de/codeblocks/wxmsw28u_gcc_cb_wx2812_gcc452-TDM.7z

For those who might need this one (when no MingW installed on your system) : the mingw10m.dll : http://prdownload.berlios.de/codeblocks/mingwm10_gcc452-TDM.7z

The 25 August 2012 build is out.
  - Windows :
   http://prdownload.berlios.de/codeblocks/CB_20120825_rev8248_win32.7z
  - Linux :
   none

Resolved Fixed:

  • minor API changes in cbStatusBasr and ProgressDialog (un-used so far to my knowledge) to avoid compiler warnings
  • added basic support for importing MSVC10 solutions/projects (files only for the moment)
  • some further support for importing MSVC10 solutions/projects (defines, libs, includes, switches)
  • speedup scrolling in wxScintilla, remove no longer needed workaround/hack to block mousewheel-events;
    see: http://forums.codeblocks.org/index.php/topic,12164.msg112891.html#msg112891 and also: http://trac.wxwidgets.org/ticket/9057
  • added fix for native applications as described here: http://forums.codeblocks.org/index.php/topic,16560.msg112575.html
  • cleaned up the XRC mess in replace dialog
  • separated editor/project hooks via namespace
  • wxScintilla: implemented DrawRGBAImage
  • fix memory leak : (deprecated) auto_ptr can NOT deal with arrays
  • gcc 4.7 build fixes: no need to use -fpermissive compiler-flag anymore
  • applied patch #3310: Fix use of numpad enter
  • CC: fixed max_matches settings
    * CC: moved parsing of project o DoParseOpenedProjectAndActiveEditor (in preparation)
    * CC: renamed ParsingType to ParserState and moved it to namespace
    * CC: separated macro parsing of GCC and MSVC
    * CC: AddGCCCompilerDirs no does not need a compiler anymore -> can be moved to ParserBase for tests
  • CC: applied (modified) patch #3311: do not draw tooltips off the edge of the window. ignore wxSCI_C_IDENTIFIER and wxSCI_C_GLOBALCLASS in editor tooltip
  • try to fix a crash at shutdown of C::B with active debugger session
  • debugger: exit properly when application cannot be run (i.e. on Windows: Missing access rights)
  • CC: avoid refreshing class browser if not needed
  • CC: report issues with class browser updates (i.e. due to missing parser)
  • CC: changed logic of how parser stores file names (they are always being converted to forward slashes for comparison) -> should be more fail-safe, i.e. with patch from here: http://forums.codeblocks.org/index.php/topic,16596.msg113355.html
  • CC: avoid expensive calls to UnixFileName
  • BrowsTracker - Add option to wrap jump entries
  • applied (slightly modified) patch #3313: Improve handling of inactive preprocessor code
  • added power user support for units glob feature (these are directory paths that can be specified, and all files in there will be considered as sources for the project. This can be based on a wildcard for the * file types, and can be recursive. When no wildcard is specified (empty) the default CB wildcard for adding files is used.
  • applied patch #3315: Fix 018704 bug related to 'paste' into IncrementalSearch
  • provided cppcheck plugin with a config panel to setup cppcheck app and args (closes some "bug" reports with deprecated options)
  • applied patch #3316: SpellChecker: search harder for resources
  • SpellChecker: updated hunspell to 1.3.3 (Windows only)
  • applied (modified) patch #3319: Fix loading of custom colour schemes
  • wxSmith: removed specialisations not required for some controls (font picker, rich text, simple html listbox), should fix the wxValidator issue reported here: http://forums.codeblocks.org/index.php/topic,16744.0.html
  • added two new SDK events: cbEVT_PROJECT_OPTIONS_CHANGED and cbEVT_COMPILER_SETTINGS_CHANGED

Regressions/Confirmed/Annoying/Common bugs:



    TiberiuGal

    • Guest
    Re: The 25 August 2012 build (8248) is out.
    « Reply #1 on: August 25, 2012, 08:18:58 pm »
    Hi,

    The CB archive cannot be unpacked.

    Offline savya

    • Single posting newcomer
    • *
    • Posts: 7
    Re: The 25 August 2012 build (8248) is out.
    « Reply #2 on: August 25, 2012, 09:10:21 pm »
    I'm also having the same problem as TiberiuGal. The archive is corrupt.

    Offline killerbot

    • Administrator
    • Lives here!
    • *****
    • Posts: 5193
    Re: The 25 August 2012 build (8248) is out.
    « Reply #3 on: August 25, 2012, 09:36:28 pm »
    re-uploaded and ok now

    Offline KnIxX

    • Single posting newcomer
    • *
    • Posts: 3
    Re: The 25 August 2012 build (8248) is out.
    « Reply #4 on: August 26, 2012, 10:22:33 am »
    thanks for the gift... 25th of aug is my birthday... ::) :D

    Offline Folco

    • Regular
    • ***
    • Posts: 343
      • Folco's blog (68k lover)
    Re: The 25 August 2012 build (8248) is out.
    « Reply #5 on: August 26, 2012, 01:11:57 pm »
    Happy birthday !
    Kernel Extremist - PedroM power

    Offline Agetian

    • Multiple posting newcomer
    • *
    • Posts: 16
    Re: The 25 August 2012 build (8248) is out.
    « Reply #6 on: August 26, 2012, 08:09:44 pm »
    Here's an interesting issue I ran into with the last couple SVN builds including the latest one: I'm using MinGW 4.7.1 with the stock GDB that comes with it (also v4.7.1). Whenever I try to debug a program that features std::string in it, if I watch a std::string object, the value is never shown correctly, and if I hover the mouse over it with the "show value" mode turned on (don't remember what this option is actually called), a SIGSEGV message will pop up. Amazingly enough this only seems to happen for strings, std::vector<int>, for instance, is shown just fine, as are all the built-in types, such as int or float. Is it something I'm doing wrong or is it something wrong with C::B? :\

    Offline oBFusCATed

    • Developer
    • Lives here!
    • *****
    • Posts: 12123
      • Travis build status
    Re: The 25 August 2012 build (8248) is out.
    « Reply #7 on: August 26, 2012, 08:41:09 pm »
    Agetian:
    Have your string variables being initialized?
    Do you have python enabled gdb or non-python gdb?
    Have you installed any pretty printers?
    Can you post the full log from the debugger? (you have to enabled full logging)
    (most of the time I ignore long posts)
    [strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

    Offline Agetian

    • Multiple posting newcomer
    • *
    • Posts: 16
    Re: The 25 August 2012 build (8248) is out.
    « Reply #8 on: August 27, 2012, 06:17:01 am »
    Agetian:
    Have your string variables being initialized?
    Do you have python enabled gdb or non-python gdb?
    Have you installed any pretty printers?
    Can you post the full log from the debugger? (you have to enabled full logging)

    1) Yes, the string variables are initialized. This is easily tested even on a simple "std::string s = "Test";" line.
    2) I believe it's a Python-enabled gdb (it references python27.dll), but I'm not sure how to tell you with bigger degree of certainty.
    3) No, at least not that I'm aware of it - nothing out of the ordinary, just stock C::B SVN and stock MinGW/GDB, with whatever configuration they both came with. If you're interested, MinGW 4.7.1 came from this source: http://sourceforge.net/projects/mingwbuilds/
    4) Sure thing, I think this is what you meant about full log, but if I'm wrong, please tell me where to obtain the correct thing:
    Code: [Select]
    Building to ensure sources are up-to-date
    Selecting target:
    Debug
    Adding source dir: D:\cppclasstest\
    Adding source dir: D:\cppclasstest\
    Adding file: D:\cppclasstest\bin\Debug\cppclasstest.exe
    Changing directory to: D:/cppclasstest/.

    [debug]PATH=.;D:\mingw-4.7.1\bin;D:\mingw-4.7.1;C:\Program Files\NVIDIA Corporation\PhysX\Common;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Windows Live\Shared;D:\mingw-TDD-4.6.1\bin;C:\Program Files\Calibre2;C:\D\dmd\windows\bin;C:\D\dmd2\windows\bin;C:\D\dm\bin;C:\Program Files\TortoiseSVN\bin
    [debug]Command-line: D:\mingw-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    [debug]Working dir : D:\cppclasstest

    Starting debugger: D:\mingw-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    done

    [debug]> set prompt >>>>>>cb_gdb:

    Registered new type: wxString
    Registered new type: STL String
    Registered new type: STL Vector
    Setting breakpoints

    [debug]Reading symbols from D:/cppclasstest/bin/Debug/cppclasstest.exe...
    [debug]done.
    [debug](gdb) >>>>>>cb_gdb:
    [debug]> show version
    [debug]GNU gdb (GDB) 7.4.1
    [debug]Copyright (C) 2012 Free Software Foundation, Inc.
    [debug]License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    [debug]This is free software: you are free to change and redistribute it.
    [debug]There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
    [debug]and "show warranty" for details.
    [debug]This GDB was configured as "i686-w64-mingw32".
    [debug]For bug reporting instructions, please see:
    [debug]<http://www.gnu.org/software/gdb/bugs/>.
    [debug]>>>>>>cb_gdb:
    [debug]> set confirm off

    Debugger name and version: GNU gdb (GDB) 7.4.1

    [debug]>>>>>>cb_gdb:
    [debug]> set width 0
    [debug]>>>>>>cb_gdb:
    [debug]> set height 0
    [debug]>>>>>>cb_gdb:
    [debug]> set breakpoint pending on
    [debug]>>>>>>cb_gdb:
    [debug]> set print asm-demangle on
    [debug]>>>>>>cb_gdb:
    [debug]> set unwindonsignal on
    [debug]>>>>>>cb_gdb:
    [debug]> set print elements 0
    [debug]>>>>>>cb_gdb:
    [debug]> set new-console on
    [debug]>>>>>>cb_gdb:
    [debug]> set disassembly-flavor att
    [debug]>>>>>>cb_gdb:
    [debug]> catch throw
    [debug]Catchpoint 1 (throw)
    [debug]>>>>>>cb_gdb:
    [debug]> source D:\CB_Portable\share\codeblocks/scripts/stl-views-1.0.3.gdb
    [debug]>>>>>>cb_gdb:
    [debug]> directory D:/cppclasstest/
    [debug]>>>>>>cb_gdb:
    [debug]> break "D:/cppclasstest/main.cpp:15"
    [debug]Breakpoint 2 at 0x401394: file D:\cppclasstest\main.cpp, line 15.
    [debug]>>>>>>cb_gdb:
    [debug]> run

    Child process PID: 3968

    [debug][New Thread 3968.0x16a4]
    [debug]Breakpoint 2, main () at D:\cppclasstest\main.cpp:15
    [debug]D:\cppclasstest\main.cpp:15:188:beg:0x401394
    [debug]>>>>>>cb_gdb:

    At D:\cppclasstest\main.cpp:15

    [debug]> bt 30
    [debug]#0  main () at D:\cppclasstest\main.cpp:15
    [debug]>>>>>>cb_gdb:
    [debug]> next
    [debug]D:\cppclasstest\main.cpp:17:214:beg:0x4013c3
    [debug]>>>>>>cb_gdb:

    At D:\cppclasstest\main.cpp:17

    [debug]> bt 30
    [debug]#0  main () at D:\cppclasstest\main.cpp:17
    [debug]>>>>>>cb_gdb:
    [debug]> whatis s
    [debug]type = std::string
    [debug]>>>>>>cb_gdb:
    [debug]> output &s
    [debug](std::string *) 0x22fef0>>>>>>cb_gdb:
    [debug]> output s.c_str()[0]@s.size()
    [debug]The program being debugged was signaled while in a function called from GDB.
    [debug]GDB has restored the context to what it was before the call.
    [debug]To change this behavior use "set unwindonsignal off".
    [debug]Evaluation of the expression containing the function
    [debug](std::string::size() const) will be abandoned.
    [debug]Program received signal SIGSEGV, Segmentation fault.
    [debug]0x00412f42 in std::string::size() const ()
    [debug]>>>>>>cb_gdb:

    Program received signal SIGSEGV, Segmentation fault.
    In std::string::size() const () ()

    [debug]> whatis s
    [debug]type = std::string
    [debug]>>>>>>cb_gdb:
    [debug]> output s.c_str()[0]@s.size()
    [debug]The program being debugged was signaled while in a function called from GDB.
    [debug]GDB has restored the context to what it was before the call.
    [debug]To change this behavior use "set unwindonsignal off".
    [debug]Evaluation of the expression containing the function
    [debug](std::string::size() const) will be abandoned.
    [debug]Program received signal SIGSEGV, Segmentation fault.
    [debug]0x00412f42 in std::string::size() const ()
    [debug]>>>>>>cb_gdb:
    [debug]> bt 30

    Program received signal SIGSEGV, Segmentation fault.

    [debug]> bt 30
    [debug]#0  main () at D:\cppclasstest\main.cpp:17
    [debug]>>>>>>cb_gdb:#0  main () at D:\cppclasstest\main.cpp:17
    [debug]>>>>>>cb_gdb:

    This was done with a breakpoint set on a line that said:

    std::string s = "Test";

    I used the "Next line (F7)" command to go over this line to ensure that "s" was initialized, and then hovered the mouse over s to get its value, upon which it segfaulted.
    « Last Edit: August 27, 2012, 06:32:40 am by Agetian »

    Offline oBFusCATed

    • Developer
    • Lives here!
    • *****
    • Posts: 12123
      • Travis build status
    Re: The 25 August 2012 build (8248) is out.
    « Reply #9 on: August 27, 2012, 09:20:23 am »
    Putting a breakpoint on the initialization line is not a good idea.
    Can you try to put a breakpoint only on the next line?
    Also can you disable the watch scripts and post the log again?

    Another thing to try is to execute the commands: "p s.size()" and "p s.c_str()" in the debug log window.
    (most of the time I ignore long posts)
    [strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

    Offline Agetian

    • Multiple posting newcomer
    • *
    • Posts: 16
    Re: The 25 August 2012 build (8248) is out.
    « Reply #10 on: August 27, 2012, 01:54:02 pm »
    Putting a breakpoint on the initialization line is not a good idea.
    Can you try to put a breakpoint only on the next line?
    Also can you disable the watch scripts and post the log again?

    Another thing to try is to execute the commands: "p s.size()" and "p s.c_str()" in the debug log window.


    Putting a breakpoint on the next line remedies the segfault but still doesn't resolve the problem completely:
    With the watch scripts disabled, no segfault occurs and the proper value is shown when I hover the mouse over "s", but doing "p s.c_str()" and "p s.size()" both yield a strange outcome in the form of the message "Cannot evaluate function - may be inlined". Here's the full output:
    Code: [Select]
    Building to ensure sources are up-to-date
    Selecting target:
    Debug
    Adding source dir: D:\cppclasstest\
    Adding source dir: D:\cppclasstest\
    Adding file: D:\cppclasstest\bin\Debug\cppclasstest.exe
    Changing directory to: D:/cppclasstest/.

    [debug]PATH=.;D:\MinGW-4.7.1\bin;D:\MinGW-4.7.1;C:\Program Files\NVIDIA Corporation\PhysX\Common;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Windows Live\Shared;D:\MinGW-TDD-4.6.1\bin;C:\Program Files\Calibre2;C:\D\dmd\windows\bin;C:\D\dmd2\windows\bin;C:\D\dm\bin;C:\Program Files\TortoiseSVN\bin
    [debug]Command-line: D:\MinGW-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    [debug]Working dir : D:\cppclasstest

    Starting debugger: D:\MinGW-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    done

    [debug]> set prompt >>>>>>cb_gdb:
    [debug]Skip initializing the scripting!

    Setting breakpoints

    [debug]Reading symbols from D:/cppclasstest/bin/Debug/cppclasstest.exe...done.
    [debug](gdb) >>>>>>cb_gdb:
    [debug]> show version
    [debug]GNU gdb (GDB) 7.4.1
    [debug]Copyright (C) 2012 Free Software Foundation, Inc.
    [debug]License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    [debug]This is free software: you are free to change and redistribute it.
    [debug]There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
    [debug]and "show warranty" for details.
    [debug]This GDB was configured as "i686-w64-mingw32".
    [debug]For bug reporting instructions, please see:
    [debug]<http://www.gnu.org/software/gdb/bugs/>.
    [debug]>>>>>>cb_gdb:
    [debug]> set confirm off

    Debugger name and version: GNU gdb (GDB) 7.4.1

    [debug]>>>>>>cb_gdb:
    [debug]> set width 0
    [debug]>>>>>>cb_gdb:
    [debug]> set height 0
    [debug]>>>>>>cb_gdb:
    [debug]> set breakpoint pending on
    [debug]>>>>>>cb_gdb:
    [debug]> set print asm-demangle on
    [debug]>>>>>>cb_gdb:
    [debug]> set unwindonsignal on
    [debug]>>>>>>cb_gdb:
    [debug]> set print elements 0
    [debug]>>>>>>cb_gdb:
    [debug]> set new-console on
    [debug]>>>>>>cb_gdb:
    [debug]> set disassembly-flavor att
    [debug]>>>>>>cb_gdb:
    [debug]> catch throw
    [debug]Function "__cxa_throw" not defined.
    [debug]Catchpoint 1 (throw)
    [debug]>>>>>>cb_gdb:
    [debug]> directory D:/cppclasstest/
    [debug]>>>>>>cb_gdb:
    [debug]> break "D:/cppclasstest/main.cpp:17"
    [debug]Breakpoint 2 at 0x401638: file D:\cppclasstest\main.cpp, line 17.
    [debug]>>>>>>cb_gdb:
    [debug]> run

    Child process PID: 4036

    [debug][New Thread 4036.0x548]
    [debug]Breakpoint 2, main () at D:\cppclasstest\main.cpp:17
    [debug]D:\cppclasstest\main.cpp:17:214:beg:0x401638
    [debug]>>>>>>cb_gdb:

    At D:\cppclasstest\main.cpp:17

    [debug]> bt 30
    [debug]#0  main () at D:\cppclasstest\main.cpp:17
    [debug]>>>>>>cb_gdb:

    > p s.c_str()

    [debug]> p s.c_str()
    [debug]Cannot evaluate function -- may be inlined
    [debug]>>>>>>cb_gdb:

    Cannot evaluate function -- may be inlined
    Cannot evaluate function -- may be inlined
    > p s.size()

    [debug]> p s.size()
    [debug]Cannot evaluate function -- may be inlined
    [debug]>>>>>>cb_gdb:

    Cannot evaluate function -- may be inlined
    Cannot evaluate function -- may be inlined

    With the watch scripts enabled, the same thing happens with both "p s.size()" and "p s.c_str()" but also the proper value is not shown in the watch window or when hovering the mouse over "s" - instead, the message "Cannot evaluate function -- may be inlined" also shows up in the watch window. Here's the full output with watch scripts enabled:
    Code: [Select]
    Building to ensure sources are up-to-date
    Selecting target:
    Debug
    Adding source dir: D:\cppclasstest\
    Adding source dir: D:\cppclasstest\
    Adding file: D:\cppclasstest\bin\Debug\cppclasstest.exe
    Changing directory to: D:/cppclasstest/.

    [debug]PATH=.;D:\MinGW-4.7.1\bin;D:\MinGW-4.7.1;C:\Program Files\NVIDIA Corporation\PhysX\Common;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\Windows Live\Shared;D:\MinGW-TDD-4.6.1\bin;C:\Program Files\Calibre2;C:\D\dmd\windows\bin;C:\D\dmd2\windows\bin;C:\D\dm\bin;C:\Program Files\TortoiseSVN\bin
    [debug]Command-line: D:\MinGW-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    [debug]Working dir : D:\cppclasstest

    Starting debugger: D:\MinGW-4.7.1\bin\gdb.exe -nx -fullname  -quiet  -args D:/cppclasstest/bin/Debug/cppclasstest.exe
    done

    [debug]> set prompt >>>>>>cb_gdb:

    Registered new type: wxString
    Registered new type: STL String
    Registered new type: STL Vector
    Setting breakpoints

    [debug]Reading symbols from D:/cppclasstest/bin/Debug/cppclasstest.exe...done.
    [debug](gdb) >>>>>>cb_gdb:
    [debug]> show version
    [debug]GNU gdb (GDB) 7.4.1
    [debug]Copyright (C) 2012 Free Software Foundation, Inc.
    [debug]License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    [debug]This is free software: you are free to change and redistribute it.
    [debug]There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
    [debug]and "show warranty" for details.
    [debug]This GDB was configured as "i686-w64-mingw32".
    [debug]For bug reporting instructions, please see:
    [debug]<http://www.gnu.org/software/gdb/bugs/>.
    [debug]>>>>>>cb_gdb:
    [debug]> set confirm off

    Debugger name and version: GNU gdb (GDB) 7.4.1

    [debug]>>>>>>cb_gdb:
    [debug]> set width 0
    [debug]>>>>>>cb_gdb:
    [debug]> set height 0
    [debug]>>>>>>cb_gdb:
    [debug]> set breakpoint pending on
    [debug]>>>>>>cb_gdb:
    [debug]> set print asm-demangle on
    [debug]>>>>>>cb_gdb:
    [debug]> set unwindonsignal on
    [debug]>>>>>>cb_gdb:
    [debug]> set print elements 0
    [debug]>>>>>>cb_gdb:
    [debug]> set new-console on
    [debug]>>>>>>cb_gdb:
    [debug]> set disassembly-flavor att
    [debug]>>>>>>cb_gdb:
    [debug]> catch throw
    [debug]Function "__cxa_throw" not defined.
    [debug]Catchpoint 1 (throw)
    [debug]>>>>>>cb_gdb:
    [debug]> source D:\CB_Portable\share\codeblocks/scripts/stl-views-1.0.3.gdb
    [debug]>>>>>>cb_gdb:
    [debug]> directory D:/cppclasstest/
    [debug]>>>>>>cb_gdb:
    [debug]> break "D:/cppclasstest/main.cpp:17"
    [debug]Breakpoint 2 at 0x401638: file D:\cppclasstest\main.cpp, line 17.
    [debug]>>>>>>cb_gdb:
    [debug]> run

    Child process PID: 4380

    [debug][New Thread 4380.0x11b0]
    [debug]Breakpoint 2, main () at D:\cppclasstest\main.cpp:17
    [debug]D:\cppclasstest\main.cpp:17:214:beg:0x401638
    [debug]>>>>>>cb_gdb:

    At D:\cppclasstest\main.cpp:17

    [debug]> bt 30
    [debug]#0  main () at D:\cppclasstest\main.cpp:17
    [debug]>>>>>>cb_gdb:
    [debug]> whatis s
    [debug]type = std::string
    [debug]>>>>>>cb_gdb:
    [debug]> output &s
    [debug](std::string *) 0x22fe80>>>>>>cb_gdb:
    [debug]> output s.c_str()[0]@s.size()
    [debug]Cannot evaluate function -- may be inlined
    [debug]>>>>>>cb_gdb:

    Cannot evaluate function -- may be inlined
    > p s.c_str()

    [debug]> p s.c_str()
    [debug]Cannot evaluate function -- may be inlined
    [debug]>>>>>>cb_gdb:

    Cannot evaluate function -- may be inlined
    Cannot evaluate function -- may be inlined
    > p s.size()

    [debug]> p s.size()
    [debug]Cannot evaluate function -- may be inlined
    [debug]>>>>>>cb_gdb:

    Cannot evaluate function -- may be inlined

    Hope this helps.

    Offline ollydbg

    • Developer
    • Lives here!
    • *****
    • Posts: 5247
    • OpenCV and Robotics
      • Chinese OpenCV forum moderator
    Re: The 25 August 2012 build (8248) is out.
    « Reply #11 on: August 27, 2012, 03:22:42 pm »
    @Agetian, I think it is a gdb bug or gcc bug, as you can see, print a value/expression does not work under the command line.
    If some piece of memory should be reused, turn them to variables (or const variables).
    If some piece of operations should be reused, turn them to functions.
    If they happened together, then turn them to classes.

    Offline Agetian

    • Multiple posting newcomer
    • *
    • Posts: 16
    Re: The 25 August 2012 build (8248) is out.
    « Reply #12 on: August 27, 2012, 03:57:42 pm »
    @Agetian, I think it is a gdb bug or gcc bug, as you can see, print a value/expression does not work under the command line.

    Yeah, it might as well be - I'll retry with some older revisions of MinGW (I have old binaries for 4.5 and 4.6 series) and see if that solves the issue, I'll keep you posted. Thanks!
    EDIT: Yeah, definitely works after reverting to MinGW v4.6.1 - so, could be related to some gdb bug in the 4.7 series. Looks like this is not C::B-related.
    « Last Edit: August 27, 2012, 04:01:14 pm by Agetian »

    Offline xunxun

    • Almost regular
    • **
    • Posts: 187
    Re: The 25 August 2012 build (8248) is out.
    « Reply #13 on: August 27, 2012, 04:20:36 pm »
    @Agetian, I think it is a gdb bug or gcc bug, as you can see, print a value/expression does not work under the command line.

    Yeah, it might as well be - I'll retry with some older revisions of MinGW (I have old binaries for 4.5 and 4.6 series) and see if that solves the issue, I'll keep you posted. Thanks!
    EDIT: Yeah, definitely works after reverting to MinGW v4.6.1 - so, could be related to some gdb bug in the 4.7 series. Looks like this is not C::B-related.

    Can you provide your project (maybe put it on some web space)?
    I will look into the issue to see whether its related with gcc/gdb.
    Regards,
    xunxun

    Offline Agetian

    • Multiple posting newcomer
    • *
    • Posts: 16
    Re: The 25 August 2012 build (8248) is out.
    « Reply #14 on: August 27, 2012, 04:29:34 pm »
    @Agetian, I think it is a gdb bug or gcc bug, as you can see, print a value/expression does not work under the command line.

    Yeah, it might as well be - I'll retry with some older revisions of MinGW (I have old binaries for 4.5 and 4.6 series) and see if that solves the issue, I'll keep you posted. Thanks!
    EDIT: Yeah, definitely works after reverting to MinGW v4.6.1 - so, could be related to some gdb bug in the 4.7 series. Looks like this is not C::B-related.

    Can you provide your project (maybe put it on some web space)?
    I will look into the issue to see whether its related with gcc/gdb.

    Sure thing, it's really a very simple test though, the entire test project that works as a test case consists of one file which is as follows:

    Code: [Select]
    #include <iostream>

    using namespace std;

    int main()
    {
        string s = "Test";
        cout << s << endl;
        return 0;
    }

    The breakpoint is set on the "cout << s << endl" line. I think it most surely is a gcc/gdb/mingw issue though, cause 4.6.1 works fine and 4.7.1 doesn't. I have, in addition to everything else, made double sure that I'm generating debugging symbols and that no optimizations are set, so it looks like a bug in gcc/gdb... Thanks for your desire to look into it!
    « Last Edit: August 27, 2012, 04:34:48 pm by Agetian »