diff options
author | Per Bothner <per@bothner.com> | 1995-01-23 21:20:58 +0000 |
---|---|---|
committer | Per Bothner <per@bothner.com> | 1995-01-23 21:20:58 +0000 |
commit | 6d34c23688b9d441b6daba6dff56d6a4389bc058 (patch) | |
tree | f2acf81c173f32cd8b679d92911f4298440f896d /gdb/eval.c | |
parent | ce51845b10a95dc54e30c5df90706a3902d6d1ed (diff) | |
download | gdb-6d34c23688b9d441b6daba6dff56d6a4389bc058.zip gdb-6d34c23688b9d441b6daba6dff56d6a4389bc058.tar.gz gdb-6d34c23688b9d441b6daba6dff56d6a4389bc058.tar.bz2 |
Add support for Chill bitstring literals (e.h. H'FF00').
* ch-exp.y (match_bitstring_literal): Fix for proper endianness.
* expprint.c (print_subexp): Don't call error on OP_BITSTRING,
just print B'<unimlemented>'.
* gdbtypes.c (create_set_type): Fix bug in length calculation.
* valops.c, value.h (value_bitstring): New function.
* eval.c (evaluate_subexp): Implement support for OP_BITSTRING.
* ch-typeprint.c (chill_type_print_base): For TYPE_CODE_FUNC,
check that return type is non-void, and print in proper Chill syntax.
Diffstat (limited to 'gdb/eval.c')
-rw-r--r-- | gdb/eval.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -346,7 +346,12 @@ evaluate_subexp (expect_type, exp, pos, noside) return value_string (&exp->elts[pc + 2].string, tem); case OP_BITSTRING: - error ("support for OP_BITSTRING unimplemented"); + tem = longest_to_int (exp->elts[pc + 1].longconst); + (*pos) + += 3 + BYTES_TO_EXP_ELEM ((tem + HOST_CHAR_BIT - 1) / HOST_CHAR_BIT); + if (noside == EVAL_SKIP) + goto nosideret; + return value_bitstring (&exp->elts[pc + 2].string, tem); break; case OP_ARRAY: |