Skip to content

fix, remove duplicate impl::data() overloads for std::array<T,N> in H5Mstl.hpp #218

@steven-varga

Description

@steven-varga

Problem

PR #214 (issue #11) added impl::data() overloads for std::array<T,N> at lines 123–128 of h5cpp/H5Mstl.hpp, but identical overloads already existed at lines 105–108 from a prior commit. This causes a redefinition error on every TU that includes h5cpp/all:

H5Mstl.hpp:124: error: redefinition of 'template<class T, long unsigned int N> const T* h5::impl::data(const std::array<_Tp, _Nm>&)'
H5Mstl.hpp:105: note: previously declared here

Affects all platforms (Linux/macOS/Windows), all compilers (gcc-13/14, clang-17–20, MSVC).

Fix

Remove the duplicate block at lines 123–130 (the second data() pair added by #11, including its comment). The overloads at lines 105–108 are correct and sufficient.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions