---
name: "m3gdb"
section: "1"
platform: "linux"
package: "m3gdb"
version: "1.1.13-11"
release: "Debian 2.2 (Potato)"
platforms: ["linux"]
url: "https://new.carta.tech/m3gdb"
---

# m3gdb(1)

The GNU Debugger, with Modula-3 support

## Name

m3gdb - The GNU Debugger, with Modula-3 support

## Description

**m3gdb** is a modified version of [**gdb**(1)](/gdb/1.md) with support for the Modula-3 language.

If the current language is  **m3** (in the gdb sense), then all expressions are interpreted using the Modula-3 syntax.  All values which have a Modula-3 type are printed according to that type. In addition,  **m3gdb** supports two new commands.  The command **threads** lists the threads that exist in the program, with the first thread being the most recently active one.  The command **switch** *n* switches the current context to the thread identified as *n,* by the **threads** command.  If you use the **switch** command, you **must** use it again to switch back to the thread that was interrupted before you can continue the execution of the program (i.e. the first thread listed by the **threads** command).  If the  **switch** command is interrupted, the state of **m3gdb** is essentially random and most likely to cause a core dump.  The current language must be  **m3** for the  **threads** and **switch** commands to work.

When **m3gdb** is started, the language is  **C.** This means that you cannot insert a breakpoint using the Modula-3 syntax.  You probably want to type **set la m3** to set the language to  **m3.**

gdb does not have a concept of statement, only expressions. Accordingly, m3gdb treats := as an expression constructor.

## See Also

[**gdb**(1)](/gdb/1.md), the gdb documentation under info.

## Bugs

Many.  Please send bug reports to  **m3-request@src.dec.com**.

This release of m3gdb is based on gdb 4.9.  We should move to gdb 4.10.

Real numbers are not parsed properly.

The comparison operators (other than =), VAL, &, IN do not work.

The = operator does not work on open arrays.

## Author Of Object

Eric Muller, for the Modula-3 extensions.

## Author Of Documentation

Eric Muller
