[NFC][Coroutines] Use structured binding with llvm::enumerate in CoroSplit (#116879)
[llvm-project.git] / lldb / source / ValueObject / ValueObjectConstResultChild.cpp
blobb1c800dfe8c33a6f0a92599cf9ef89a27852f4eb
1 //===-- ValueObjectConstResultChild.cpp -----------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #include "lldb/ValueObject/ValueObjectConstResultChild.h"
11 #include "lldb/lldb-private-enumerations.h"
12 namespace lldb_private {
13 class DataExtractor;
15 namespace lldb_private {
16 class Status;
18 namespace lldb_private {
19 class ValueObject;
22 using namespace lldb_private;
24 ValueObjectConstResultChild::ValueObjectConstResultChild(
25 ValueObject &parent, const CompilerType &compiler_type, ConstString name,
26 uint32_t byte_size, int32_t byte_offset, uint32_t bitfield_bit_size,
27 uint32_t bitfield_bit_offset, bool is_base_class, bool is_deref_of_parent,
28 lldb::addr_t live_address, uint64_t language_flags)
29 : ValueObjectChild(parent, compiler_type, name, byte_size, byte_offset,
30 bitfield_bit_size, bitfield_bit_offset, is_base_class,
31 is_deref_of_parent, eAddressTypeLoad, language_flags),
32 m_impl(this, live_address) {
33 m_name = name;
36 ValueObjectConstResultChild::~ValueObjectConstResultChild() = default;
38 lldb::ValueObjectSP ValueObjectConstResultChild::Dereference(Status &error) {
39 return m_impl.Dereference(error);
42 lldb::ValueObjectSP ValueObjectConstResultChild::GetSyntheticChildAtOffset(
43 uint32_t offset, const CompilerType &type, bool can_create,
44 ConstString name_const_str) {
45 return m_impl.GetSyntheticChildAtOffset(offset, type, can_create,
46 name_const_str);
49 lldb::ValueObjectSP ValueObjectConstResultChild::AddressOf(Status &error) {
50 return m_impl.AddressOf(error);
53 lldb::addr_t
54 ValueObjectConstResultChild::GetAddressOf(bool scalar_is_load_address,
55 AddressType *address_type) {
56 return m_impl.GetAddressOf(scalar_is_load_address, address_type);
59 size_t ValueObjectConstResultChild::GetPointeeData(DataExtractor &data,
60 uint32_t item_idx,
61 uint32_t item_count) {
62 return m_impl.GetPointeeData(data, item_idx, item_count);
65 lldb::ValueObjectSP
66 ValueObjectConstResultChild::DoCast(const CompilerType &compiler_type) {
67 return m_impl.Cast(compiler_type);