On Tue, Apr 29, 2014 at 7:03 PM, Ralf Rottmann wrote:
We're working on a pretty complex backend in Go running on App Engine.
Exploring the gdb debugging options, we can't get gdb to print variables.
Here's what we do:

ps | grep _go_app
sudo gdb attach 1734 -d $GOPATH/projectfolder

(gdb) i var Active
All variables matching regular expression "Active":

File _go_main.go:
<data variable, no debug info> myapp.getUsersActive·f;
struct []string myapp/config.ActiveForUids;
(gdb) p config.ActiveForUids
No symbol "config" in current context.

Any idea, why the p command fails?
I don't know if this is the only issue, but I know that you need to
use single quotes:

p 'config.ActiveForUids'

Otherwise gdb thinks you are referring to a field in a struct named

See http://golang.org/doc/gdb .


You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts


Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 3 | next ›
Discussion Overview
groupgolang-nuts @
postedApr 29, '14 at 11:03p
activeApr 29, '14 at 11:49p

2 users in discussion

Ralf Rottmann: 2 posts Ian Lance Taylor: 1 post



site design / logo © 2022 Grokbase