Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>From what I have understood from the question here, you want to break when a specific exception <code>boost::bad_function_call</code> is thrown in your application.</p> <pre><code>$&gt; gdb /path/to/binary (gdb) break boost::bad_function_call::bad_function_call() (gdb) run --some-cli-options </code></pre> <p>So when the temporary object <code>boost::bad_function_call</code> is constructed in preparation for the <code>throw</code>; gdb will break out!</p> <p>I have tested this and it does work. If you precisely know the way the exception object is being constructed then you can set breakpoint on the specific constructor, otherwise as shown in the example below, you can omit the arguments prototype list, and <code>gdb</code> will set break points on all different flavours of the constructor.</p> <pre><code>$ gdb /path/to/binary (gdb) break boost::bad_function_call::bad_function_call Breakpoint 1 at 0x850f7bf: boost::bad_function_call::bad_function_call. (4 locations) (gdb) info breakpoints Num Type Disp Enb Address What 1 breakpoint keep y &lt;MULTIPLE&gt; 1.1 y 0x0850f7bf in boost::bad_function_call::bad_function_call() at /usr/include/boost/function/function_base.hpp:742 1.2 y 0x0850fdd5 in boost::bad_function_call::bad_function_call(boost::bad_function_call const&amp;) at /usr/include/boost/function/function_base.hpp:739 1.3 y 0x0863b7d2 &lt;boost::bad_function_call::bad_function_call()+4&gt; 1.4 y 0x086490ee &lt;boost::bad_function_call::bad_function_call(boost::bad_function_call const&amp;)+6&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload