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">
12 Node:
<a name=
"Languages">Languages
</a>,
13 Next:
<a rel=
"next" accesskey=
"n" href=
"Symbols.html#Symbols">Symbols
</a>,
14 Previous:
<a rel=
"previous" accesskey=
"p" href=
"Overlays.html#Overlays">Overlays
</a>,
15 Up:
<a rel=
"up" accesskey=
"u" href=
"index.html#Top">Top
</a>
19 <h2 class=
"chapter">Using GDB with Different Languages
</h2>
21 <p>Although programming languages generally have common aspects, they are
22 rarely expressed in the same manner. For instance, in ANSI C,
23 dereferencing a pointer
<code>p
</code> is accomplished by
<code>*p
</code>, but in
24 Modula-
2, it is accomplished by
<code>p^
</code>. Values can also be
25 represented (and displayed) differently. Hex numbers in C appear as
26 <code>0x1ae</code>, while in Modula-
2 they appear as
<code>1AEH
</code>.
28 <p>Language-specific information is built into GDB for some languages,
29 allowing you to express operations like the above in your program's
30 native language, and allowing GDB to output values in a manner
31 consistent with the syntax of your program's native language. The
32 language you use to build expressions is called the
<dfn>working
36 <li><a accesskey=
"1" href=
"Setting.html#Setting">Setting
</a>: Switching between source languages
37 <li><a accesskey=
"2" href=
"Show.html#Show">Show
</a>: Displaying the language
38 <li><a accesskey=
"3" href=
"Checks.html#Checks">Checks
</a>: Type and range checks
39 <li><a accesskey=
"4" href=
"Support.html#Support">Support
</a>: Supported languages