Skip to content

Commit

Permalink
TileDB: avoid -Wshadow-field (master only)
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Nov 4, 2023
1 parent c1aa9da commit 473a828
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions frmts/tiledb/tiledbmultidim.h
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ class TileDBGroup final : public GDALGroup, public TileDBAttributeHolder
{
std::shared_ptr<TileDBSharedResource> m_poSharedResource{};
const std::string m_osPath;
std::weak_ptr<TileDBGroup> m_pSelf{};
mutable std::unique_ptr<tiledb::Group> m_poTileDBGroup{};
mutable std::map<std::string, std::shared_ptr<TileDBGroup>> m_oMapGroups{};
mutable std::map<std::string, std::shared_ptr<TileDBArray>> m_oMapArrays{};
Expand All @@ -183,7 +182,7 @@ class TileDBGroup final : public GDALGroup, public TileDBAttributeHolder
{
auto poGroup = std::shared_ptr<TileDBGroup>(
new TileDBGroup(poSharedResource, osParentName, osName, osPath));
poGroup->m_pSelf = poGroup;
poGroup->SetSelf(poGroup);
return poGroup;
}

Expand Down
2 changes: 1 addition & 1 deletion frmts/tiledb/tiledbmultidimgroup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ std::shared_ptr<GDALMDArray> TileDBGroup::CreateMDArray(
if (!EnsureOpenAs(TILEDB_WRITE))
return nullptr;

auto poSelf = m_pSelf.lock();
auto poSelf = std::dynamic_pointer_cast<TileDBGroup>(m_pSelf.lock());
CPLAssert(poSelf);
auto poArray =
TileDBArray::CreateOnDisk(m_poSharedResource, poSelf, osName,
Expand Down

0 comments on commit 473a828

Please sign in to comment.