diff options
| author | Eugen Wissner <belka@caraus.de> | 2026-07-19 17:09:40 +0200 |
|---|---|---|
| committer | Eugen Wissner <belka@caraus.de> | 2026-07-19 18:30:21 +0200 |
| commit | cdbc1695a93910df5729779de31912a3b4b4172b (patch) | |
| tree | 43a4c5a192df7060f8a36c75d339be7ac5722f72 /boot/name_analysis.cc | |
| parent | cd2ee0c97348444779a155909b7ec78d89cfd2e0 (diff) | |
| download | elna-cdbc1695a93910df5729779de31912a3b4b4172b.tar.gz | |
Support unary plus operation
Diffstat (limited to 'boot/name_analysis.cc')
| -rw-r--r-- | boot/name_analysis.cc | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/boot/name_analysis.cc b/boot/name_analysis.cc index 5255878..b13c043 100644 --- a/boot/name_analysis.cc +++ b/boot/name_analysis.cc @@ -538,14 +538,8 @@ namespace elna::boot { type resolved = resolve_underlying_type(trait->type_decoration); bool is_enum = resolved.get<enumeration_type>() != nullptr; - bool is_integral = false; - if (auto prim = resolved.get<primitive_type>()) - { - is_integral = prim->identifier == "Int" || prim->identifier == "Word" - || prim->identifier == "Bool" || prim->identifier == "Char"; - } - if (!is_enum && !is_integral) + if (!is_enum && !is_discrete_type(resolved)) { add_error<unsupported_trait_type_error>(trait->name, trait->type_decoration); |
