public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug tui/17823] New: gdb TUI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8
@ 2015-01-09 19:25 georgezhu at yandex dot com
  2015-01-09 19:31 ` [Bug tui/17823] gdb CLI " georgezhu at yandex dot com
  2015-01-09 19:31 ` [Bug cli/17823] " georgezhu at yandex dot com
  0 siblings, 2 replies; 3+ messages in thread
From: georgezhu at yandex dot com @ 2015-01-09 19:25 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17823

            Bug ID: 17823
           Summary: gdb TUI cannot recognize floating point numbers if
                    LC_NUMERIC environment variable is set to nl_NL.UTF-8
           Product: gdb
           Version: 7.7
            Status: NEW
          Severity: normal
          Priority: P2
         Component: tui
          Assignee: unassigned at sourceware dot org
          Reporter: georgezhu at yandex dot com

See: http://pastebin.com/srH0Ug4k

My environment variable LC_NUMERIC is set to nl_NL.UTF-8, and this causes 2
things:

First, doubles and floats are printed with a comma instead of a dot(0,5, 0,1,
etc.) This is correct Dutch numeric style but in the context of programming
this is bad and somewhat confusing, since you're using dots in the source code
and they come out as commas.

Second, and more importantly, I can't seem to be able to print or type in
floats at all in the interface. Whenever I type 0.5 or 0.5f it tells me it's an
"Invalid number", and if I type to type "0,5" it seems to just ignore the 0 and
just interpret it as 5.

This is annoying because I'd like to do some floating point calculations in
gdb, which is made a lot harder with it not interpeting my floats correctly.

My suggested solution would be to ignore LC_NUMERIC and always use English
numbers. That's what I'll be using in the source code anyway for any
programming language I know.

My current workaround is of course to just call gdb with
`LC_NUMERIC=en_US.UTF-8 gdb'

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug tui/17823] gdb CLI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8
  2015-01-09 19:25 [Bug tui/17823] New: gdb TUI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8 georgezhu at yandex dot com
@ 2015-01-09 19:31 ` georgezhu at yandex dot com
  2015-01-09 19:31 ` [Bug cli/17823] " georgezhu at yandex dot com
  1 sibling, 0 replies; 3+ messages in thread
From: georgezhu at yandex dot com @ 2015-01-09 19:31 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17823

georgezhu at yandex dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|gdb TUI cannot recognize    |gdb CLI cannot recognize
                   |floating point numbers if   |floating point numbers if
                   |LC_NUMERIC environment      |LC_NUMERIC environment
                   |variable is set to          |variable is set to
                   |nl_NL.UTF-8                 |nl_NL.UTF-8

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug cli/17823] gdb CLI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8
  2015-01-09 19:25 [Bug tui/17823] New: gdb TUI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8 georgezhu at yandex dot com
  2015-01-09 19:31 ` [Bug tui/17823] gdb CLI " georgezhu at yandex dot com
@ 2015-01-09 19:31 ` georgezhu at yandex dot com
  1 sibling, 0 replies; 3+ messages in thread
From: georgezhu at yandex dot com @ 2015-01-09 19:31 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=17823

georgezhu at yandex dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|tui                         |cli

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-01-09 19:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-09 19:25 [Bug tui/17823] New: gdb TUI cannot recognize floating point numbers if LC_NUMERIC environment variable is set to nl_NL.UTF-8 georgezhu at yandex dot com
2015-01-09 19:31 ` [Bug tui/17823] gdb CLI " georgezhu at yandex dot com
2015-01-09 19:31 ` [Bug cli/17823] " georgezhu at yandex dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).