help with clang error: array initializer must be an initializer list

Mojca Miklavec mojca at macports.org
Thu Sep 5 07:36:02 PDT 2013


On Thu, Sep 5, 2013 at 11:24 AM, Titus von Boxberg wrote:
>
> Hi Mojca,
>
> you could try
>
> #include <algorithm>
>
>
> LibrariesDlg::LibrariesDlg(wxWindow* parent, TypedResults& knownLibraries)
>     : m_KnownLibraries(knownLibraries)
> // do no use    , m_WorkingCopy(knownLibraries)
> // ...
>
> {
> std::copy(m_KnownLibraries,
> m_KnownLibraries+sizeof(m_WorkingCopy)/sizeof(m_WorkingCopy[0]),
> m_WorkingCopy);
> // ...
> }

Dear Titus,

Thank you. I don't understand how that differentiates between whether
or not the user specified m_KnownLibraries when calling LibrariesDlg,
but the compilation succeeded with that patch.

Mojca


More information about the macports-dev mailing list