This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: Python coding style
>>>>> "Doug" == Doug Evans <dje@google.com> writes:
Doug> I think Google's guide specifies more, and specifies the reasons more.
Doug> We *could* reference both, and a blanket statement that X wins when
Doug> there's a conflict.
Doug> And then provide a supplement for gdb-specifics.
Doug> Easier than writing our own from scratch.
Works for me.
Tom> * We shouldn't use the #!/usr/bin/env thing
Doug> For my own education, why not?
Doug> [So I can document it in the style guide.]
I think that is there so that a given module can be run standalone.
That won't work with a typical gdb-specific module, since they can't
typically even be imported when using the plain python executable.
Doug> We should provide an emacs py mode that specifies our style.
We could check a .dir-locals.el file into the tree. I'm using this
right now:
((tcl-mode . ((tcl-indent-level . 4)
(tcl-continued-indent-level . 4)))
(nil . ((bug-reference-url-format . "http://sourceware.org/bugzilla/show_bug.cgi?id=%s"))))
Tom