WatchpointLocation's tid

I was working on a patch that experimentally adds attribute(format(printf, …))) annotations to the various logging and printing functions and cleaning up some of the warnings that that generated. In doing so, I noticed that this code:

WatchpointLocation::WatchpointLocation (lldb::addr_t addr, lldb::tid_t tid, bool hardware) :

StoppointLocation (GetNextID(), addr, tid, hardware),

Seems a bit wrong …

It is taking the tid and passing it to StoppointLocation, but StoppointLocation’s constructor interprets that as a size parameter instead. (Then, later, WatchpointLocation has a log message that should include the TID, but it doesn’t, resulting in too few arguments to the printf statement.)

  • Bruce

The Watchpoint code is a sketch I put in quite early on that, as you can tell, doesn't actually do anything. So it's not too surprising that it has bit-rotted.

I'll fix all this when I get around to implementing watchpoints, but feel free to do anything you need to the WatchpointLocation classes to shut them up for now.