Re: How to write to stderr/stdout of debuggee
Tom Tromey <[email protected]>
| Newsgroups | gmane.comp.gdb.devel |
|---|---|
| Message-ID | <[email protected]> |
>>>>> Konstantin Kharlamov via Gdb <[email protected]> writes: > My usecase is I'm debugging some plugin written in Go, and I don't have > anything language related in the visibility scope to be able to write > to stderr/stdout. Though apparently gdb does see a `write` function > (which I presume is a C write function, not Go), but executing a > p (int) write(2, "Hello", 6) > gives me a `syntax error in expression`. So anyway, I'm just wondering > if there's some built-in way to do that. I don't see a built-in $_write > function in gdb :( It's possible you have gdb in 'go' language mode. Try 'set language c' before that print. It might help. Tom