Initial bulk commit for "Git on MSys"
[msysgit/historical-msysgit.git] / mingw / info / gdb / C.html
blob5a6c174a237de5de9d75bafbebc64f26d7a6e630
1 <html lang="en">
2 <head>
3 <title>Debugging with GDB</title>
4 <meta http-equiv="Content-Type" content="text/html">
5 <meta name="description" content="Debugging with GDB">
6 <meta name="generator" content="makeinfo 4.3">
7 <link href="http://www.gnu.org/software/texinfo/" rel="generator-home">
8 </head>
9 <body>
10 <div class="node">
11 <p>
12 Node:<a name="C">C</a>,
13 Next:<a rel="next" accesskey="n" href="Modula-2.html#Modula-2">Modula-2</a>,
14 Up:<a rel="up" accesskey="u" href="Support.html#Support">Support</a>
15 <hr><br>
16 </div>
18 <h4 class="subsection">C and C<tt>++</tt></h4>
20 <p>Since C and C<tt>++</tt> are so closely related, many features of GDB apply
21 to both languages. Whenever this is the case, we discuss those languages
22 together.
24 <p>The C<tt>++</tt> debugging facilities are jointly implemented by the C<tt>++</tt>
25 compiler and GDB. Therefore, to debug your C<tt>++</tt> code
26 effectively, you must compile your C<tt>++</tt> programs with a supported
27 C<tt>++</tt> compiler, such as <small>GNU</small> <code>g++</code>, or the HP ANSI C<tt>++</tt>
28 compiler (<code>aCC</code>).
30 <p>For best results when using <small>GNU</small> C<tt>++</tt>, use the stabs debugging
31 format. You can select that format explicitly with the <code>g++</code>
32 command-line options <code>-gstabs</code> or <code>-gstabs+</code>. See
33 <a href="../gcc.info/Debugging-Options.html#Debugging%20Options">Options for Debugging Your Program or <small>GNU</small> CC</a>, for more information.
35 <ul class="menu">
36 <li><a accesskey="1" href="C-Operators.html#C%20Operators">C Operators</a>: C and C<tt>++</tt> operators
37 <li><a accesskey="2" href="C-Constants.html#C%20Constants">C Constants</a>: C and C<tt>++</tt> constants
38 <li><a accesskey="3" href="C-plus-plus-expressions.html#C%20plus%20plus%20expressions">C plus plus expressions</a>: C<tt>++</tt> expressions
39 <li><a accesskey="4" href="C-Defaults.html#C%20Defaults">C Defaults</a>: Default settings for C and C<tt>++</tt>
40 <li><a accesskey="5" href="C-Checks.html#C%20Checks">C Checks</a>: C and C<tt>++</tt> type and range checks
41 <li><a accesskey="6" href="Debugging-C.html#Debugging%20C">Debugging C</a>: GDB and C
42 <li><a accesskey="7" href="Debugging-C-plus-plus.html#Debugging%20C%20plus%20plus">Debugging C plus plus</a>: GDB features for C<tt>++</tt>
43 </ul>
45 </body></html>