Changing the decimal separator in GDB

Is there a way to change the decimal separator in gdb without changing it throughout the system?

I have a French ubuntu 14.04 (with a decimal separator comma). But in gdb, any floating point written with a dot (for example, p 2.0 ) results in an "invalid number" message; and the comma is interpreted as a list separator ...

I tried creating a gdbinit file with set environment LC_NUMERIC="C" inside, but that did not work ...

+4
source share

Source: https://habr.com/ru/post/985895/


All Articles