Is this a bug in gdb

Volker Weißmann <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <[email protected]>
Hello,

The help text of the watch command claims that the -l option watches the
memory of the variable. When I tried this, I was surprised by the
outcome (reproducible):


(gdb) watch this->v_
Hardware watchpoint 2: this->v_
(gdb) watch -l this->v_
A syntax error in expression, near `restrict *) 0x00007fffffffd398'.
(gdb)

Note: Using print &(this->v_) and  watch (char[8])
*outputoftheprintcommand worked.


I am asking you whether this is a bug in gdb or not, because if it is a
bug in gdb, I will try to make a minimal example an file a bug report.


Greetings

Volker Weißmann
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.