[obv] compile-print.exp: xfail->kfail for '@' GDB array operator
Yao Qi
qiyaoltc@gmail.com
Fri Jun 5 09:35:00 GMT 2015
Jan Kratochvil <jan.kratochvil@redhat.com> writes:
Hi, Jan,
This patch isn't obvious to me... see my question below,
> Patch implementing '@' GDB array operator in GCC has been rejected:
> https://gcc.gnu.org/ml/gcc-patches/2015-06/msg00414.html
> and so there is now a GDB tracker to implement it just in GDB:
> https://sourceware.org/bugzilla/show_bug.cgi?id=18489
If '@' is rejected in GCC, why do we need to support it in "compile"
feature in GDB? The manual of command "compile print" says:
Compile and execute expr with the compiler language found as the
current language in GDB
'@' isn't a valid operator for C language, we should emit error here.
IMO, "compile" feature should *only* accept valid source code according
to the language spec and the compiler. It will be really confusing if
we add some other things (like '@' in this case) which is out of the
scope of the language.
> @@ -38,7 +38,7 @@ gdb_test_multiple $test $test {
> pass $test
> }
> -re ": error: stray '@' in program\r\n.*\r\n$gdb_prompt $" {
> - xfail "$test (gcc does not support '@')"
> + kfail compile/18489 "$test"
> }
> }
I think xfail is correct as gcc doesn't support '@'.
--
Yao (齐尧)
More information about the Gdb-patches
mailing list