[PATCH 2/2] don't allocate serial_ops

Tom Tromey tromey@redhat.com
Tue Dec 10 20:29:00 GMT 2013


Tom> Now that struct serial_ops is const everywhere, we can easily turn the
Tom> instances into globals.  This patch implements this idea.

Yao> Is it better to turn them into static locals of _initialize_ser_XXX
Yao> functions?

I tend to avoid static locals.  I don't know that I have a particularly
good reason for it, though.

Yao> The patched code is still quite readable to me.

Thanks.

Tom



More information about the Gdb-patches mailing list