On Mon, May 29, 2023 at 8:26 AM Sam Varshavchik <mr...@courier-mta.com> wrote:
> Richard Shaw writes: > > > error: possibly dangling reference to a temporary [-Werror=dangling- > > reference] > > 315 | const auto & parents = > > dae.root().selectNodes("//*[@sid]/.."); > > The quickest solution is just add a pragma to shut it up. > > > The code in question[2] is: > > // InstanceWithExtra and other <instance_*> with "url" attribute > > const auto & instances = root().selectNodes( > > Find where selectNodes() is defined. Add > > #pragma GCC diagnostic push > #pragma GCC diagnostic ignored "-Wdangling-reference" > > before the definition, and > > #pragma GCC diagnostic pop > > after it. > That's what I ended up doing, it turns out there were structures like this in about 7 places in that file and several more in another, it just got through two before the build failed previously. I ended up using the approach for the whole file and then fixed a couple of #include <cstdint> since you don't get it for free anymore and the build completed. Thanks! Richard
_______________________________________________ devel mailing list -- devel@lists.fedoraproject.org To unsubscribe send an email to devel-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue