This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [rfa][testsuite] Consolidade Python test functions in lib/gdb.exp.


>>>>> "Thiago" == Thiago Jung Bauermann <bauerman@br.ibm.com> writes:

Thiago> This is a cleanup on the testcases in gdb.python. Currently,
Thiago> they define the same test functions in each .exp. I put them
Thiago> in lib/gdb.exp instead.

It looks like the GDB style is to put specific support functions into
a new file, e.g., "mi-support.exp".  So perhaps we should add
"python-support.exp"... WDYT?

Thiago> +# Return 1 if Python scripting is supported in GDB, 0 if not.
Thiago> +proc python_supported { } {
Thiago> +  global gdb_prompt

I think this proc should do the test only once per runtest invocation,
and just return a cached result in subsequent calls.

Otherwise this looks reasonable to me.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]