summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/lang/cpp/call-function/main.cpp
diff options
context:
space:
mode:
authorPavel Labath <pavel@labath.sk>2019-03-11 09:06:18 +0000
committerPavel Labath <pavel@labath.sk>2019-03-11 09:06:18 +0000
commit8b911934f3dedb1802edc62009a13aec067e98ef (patch)
treefd2e2728034a903cfb1eef866de7a9fc3aaf5987 /lldb/packages/Python/lldbsuite/test/lang/cpp/call-function/main.cpp
parent5bca7ff98a103968ac63f9248b0d7b07e472f006 (diff)
downloadbcm5719-llvm-8b911934f3dedb1802edc62009a13aec067e98ef.tar.gz
bcm5719-llvm-8b911934f3dedb1802edc62009a13aec067e98ef.zip
[Support/Endian] Add support for endian-specific enums
Summary: Binary formats often include various enumerations or bitsets, but using endian-specific types for accessing them is tricky because they currently only support integral types. This is particularly true for scoped enums (enum class), as these are not implicitly convertible to integral types, and so one has to perform two casts just to read the enum value. This fixes that support by adding first-class support for enumeration types to endian-specific types. The support for them was already almost working -- all I needed to do was overload getSwappedBytes for enumeration types (which casts the enum to its underlying type and performs the conversion there). I also add some convenience template aliases to simplify declaring endian-specific enums. Reviewers: Bigcheese, zturner Subscribers: kristina, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D59141 llvm-svn: 355812
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/lang/cpp/call-function/main.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud