set language (gdb mode only)

Set the source language.

Syntax

set language name

Parameters

name

The source language to set.

Possible values are:

c

TableBulletauto (Default)

Description

This command sets the current source language.

By default, the debugger gets the source languange from the debuggee, and the debugger parses expressions the same way in the debugger interface and in the debuggee.

You may want to set the debugger interface language to be different from the source language. For example, if you are debugging a Fortran program and want to see where a pointer in a register actually points, you can switch to C syntax to do the cast ("p *(int *)$r4"), which is more difficult to express in Fortran.

When you set the language manually and then step or continue the debuggee, thereby creating a new context, the debugger sets the language back.

Example

(idb) set language c++
(idb) show language
The current source language is "c++"

See Also


Submit feedback on this help topic

Copyright © 1996-2010, Intel Corporation. All rights reserved.