diff options
author | Tom Tromey <tom@tromey.com> | 2022-06-01 15:31:15 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2022-08-04 13:28:04 -0600 |
commit | cb275538dbddfbb3c2c372a665ac48e6f617ea33 (patch) | |
tree | 7bc54ff4fc92c9b1cee74c2d7b9ae452b5ffec8b /gdb/d-lang.h | |
parent | 8b1540430107b0752485ab9e6a841dbbacd45681 (diff) | |
download | gdb-cb275538dbddfbb3c2c372a665ac48e6f617ea33.zip gdb-cb275538dbddfbb3c2c372a665ac48e6f617ea33.tar.gz gdb-cb275538dbddfbb3c2c372a665ac48e6f617ea33.tar.bz2 |
Use registry in gdbarch
gdbarch implements its own registry-like approach. This patch changes
it to instead use registry.h. It's a rather large patch but largely
uninteresting -- it's mostly a straightforward conversion from the old
approach to the new one.
The main benefit of this change is that it introduces type safety to
the gdbarch registry. It also removes a bunch of code.
One possible drawback is that, previously, the gdbarch registry
differentiated between pre- and post-initialization setup. This
doesn't seem very important to me, though.
Diffstat (limited to 'gdb/d-lang.h')
-rw-r--r-- | gdb/d-lang.h | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/gdb/d-lang.h b/gdb/d-lang.h index 56e418d..967a9b4 100644 --- a/gdb/d-lang.h +++ b/gdb/d-lang.h @@ -28,30 +28,30 @@ struct builtin_d_type { - struct type *builtin_void; - struct type *builtin_bool; - struct type *builtin_byte; - struct type *builtin_ubyte; - struct type *builtin_short; - struct type *builtin_ushort; - struct type *builtin_int; - struct type *builtin_uint; - struct type *builtin_long; - struct type *builtin_ulong; - struct type *builtin_cent; - struct type *builtin_ucent; - struct type *builtin_float; - struct type *builtin_double; - struct type *builtin_real; - struct type *builtin_ifloat; - struct type *builtin_idouble; - struct type *builtin_ireal; - struct type *builtin_cfloat; - struct type *builtin_cdouble; - struct type *builtin_creal; - struct type *builtin_char; - struct type *builtin_wchar; - struct type *builtin_dchar; + struct type *builtin_void = nullptr; + struct type *builtin_bool = nullptr; + struct type *builtin_byte = nullptr; + struct type *builtin_ubyte = nullptr; + struct type *builtin_short = nullptr; + struct type *builtin_ushort = nullptr; + struct type *builtin_int = nullptr; + struct type *builtin_uint = nullptr; + struct type *builtin_long = nullptr; + struct type *builtin_ulong = nullptr; + struct type *builtin_cent = nullptr; + struct type *builtin_ucent = nullptr; + struct type *builtin_float = nullptr; + struct type *builtin_double = nullptr; + struct type *builtin_real = nullptr; + struct type *builtin_ifloat = nullptr; + struct type *builtin_idouble = nullptr; + struct type *builtin_ireal = nullptr; + struct type *builtin_cfloat = nullptr; + struct type *builtin_cdouble = nullptr; + struct type *builtin_creal = nullptr; + struct type *builtin_char = nullptr; + struct type *builtin_wchar = nullptr; + struct type *builtin_dchar = nullptr; }; /* Defined in d-exp.y. */ |