diff options
author | Tom Tromey <tom@tromey.com> | 2021-03-08 07:27:57 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2021-03-08 07:28:30 -0700 |
commit | e967770468cd029b0cf0da4099eea40106aa16a3 (patch) | |
tree | e3c150b92e34cb2128be14653eede14e940a045b /gdb/opencl-lang.c | |
parent | f403a4e4a5d6413cf58f7a9ad004b1086fd2254a (diff) | |
download | gdb-e967770468cd029b0cf0da4099eea40106aa16a3.zip gdb-e967770468cd029b0cf0da4099eea40106aa16a3.tar.gz gdb-e967770468cd029b0cf0da4099eea40106aa16a3.tar.bz2 |
Introduce opencl_cast_type_operation
This adds class opencl_cast_type_operation, which implements
UNOP_CAST_TYPE for OpenCL.
gdb/ChangeLog
2021-03-08 Tom Tromey <tom@tromey.com>
* opencl-lang.c (opencl_value_cast): No longer static.
* c-exp.h (opencl_cast_type_operation): New typedef.
Diffstat (limited to 'gdb/opencl-lang.c')
-rw-r--r-- | gdb/opencl-lang.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gdb/opencl-lang.c b/gdb/opencl-lang.c index b45e47e..c31eb51 100644 --- a/gdb/opencl-lang.c +++ b/gdb/opencl-lang.c @@ -27,6 +27,7 @@ #include "varobj.h" #include "c-lang.h" #include "gdbarch.h" +#include "c-exp.h" /* Returns the corresponding OpenCL vector type from the given type code, the length of the element type, the unsigned flag and the amount of @@ -581,7 +582,7 @@ vector_relop (struct expression *exp, struct value *val1, struct value *val2, behaviour of scalar to vector casting. As far as possibly we're going to try and delegate back to the standard value_cast function. */ -static struct value * +struct value * opencl_value_cast (struct type *type, struct value *arg) { if (type != value_type (arg)) |