]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
Merge GCC producer parsers. Allow digits in identifiers.
authorMark Wielaard <mjw@redhat.com>
Sun, 25 Jan 2015 10:20:39 +0000 (11:20 +0100)
committerMark Wielaard <mjw@redhat.com>
Thu, 29 Jan 2015 12:39:01 +0000 (13:39 +0100)
commit38360086aea4f956dcd4ba406318595ea11f7dea
tree7cab1d6ca85a5eb23cbc4f22e22a473b025dbb3c
parent0f81d3f0a799c6e8c2a89d7f519916e3c9c0f65e
Merge GCC producer parsers. Allow digits in identifiers.

Both dwarf2read.c (checkproducer) and utils.c (producer_is_gcc_ge_4)
implemented a GCC producer parser that tried to extract the major and minor
version of GCC. Merge them into one GCC producer parser used by both. Also
allow digits in the identifier after "GNU " such as used by GCC5 like:
"GNU C11 5.0.0 20150123 (experimental) -mtune=generic -march=x86-64 -gdwarf-5"

gdb/ChangeLog:

* dwarf2read.c (checkproducer): Call producer_is_gcc.
* utils.c (producer_is_gcc_ge_4): Likewise.
(producer_is_gcc): New function.
* utils.h (producer_is_gcc): New declaration.
gdb/ChangeLog
gdb/dwarf2read.c
gdb/utils.c
gdb/utils.h