Remove some gotos from Python
authorTom Tromey <tom@tromey.com>
Thu, 12 Jan 2017 15:59:26 +0000 (08:59 -0700)
committerTom Tromey <tom@tromey.com>
Fri, 10 Feb 2017 19:24:34 +0000 (12:24 -0700)
commit2bb8f231957e2beecfb689a896252b8d9fb67e23
tree5f6758d1a942b1012bdaa99f5e8edee604038c0e
parent1bdfaf42ac152bb30e2b3ae3ab67b241835bba44
Remove some gotos from Python

This patch slightly refactors a couple of spots in the Python code to
avoid some gotos.

gdb/ChangeLog
2017-02-10  Tom Tromey  <tom@tromey.com>

* python/python.c (do_start_initialization): New function, from
_initialize_python.
(_initialize_python): Call do_start_initialization.
* python/py-linetable.c (ltpy_iternext): Use explicit returns, not
goto.
gdb/ChangeLog
gdb/python/py-linetable.c
gdb/python/python.c