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: [PATCH v2 1/2] Fixed indentation for printing Fortran types with pointers


>>>>> "Christoph" == Christoph Weinmann <christoph.t.weinmann@intel.com> writes:

Christoph> Printing the prefix "PTR TO -> (" resp. "REF TO ->(" ignored the
Christoph> active indentation level. This caused inconsistent appearance of
Christoph> user-defined Fortran types containing pointers. Fixed by using
Christoph> "fprintfi_filtered" with the current indentation level for
Christoph> outputting the prefix string. Added test case ptr-indentation.

Thanks once again.

Christoph> +# Check the indentation when using ptype on pointers in user-defined types.
Christoph> +set test "type-printing for type with pointers"
Christoph> +gdb_test_multiple "whatis ta" $test {
Christoph> +	-re "type = tudf.*$gdb_prompt $" {
Christoph> +		pass $test
Christoph> +	}
Christoph> +}
Christoph> +gdb_test_multiple "ptype ta" $test {
Christoph> +	-re ".*type = Type tudf\r\n *${int4} :: i\r\n    PTR TO \-\> \\( tudf :: ptr\\)\r\n.*End Type tudf.*$gdb_prompt $" {

I think these tests are better written using plain old "gdb_test".

Tom


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