Re: Error Compiling on macOS
Denis Corbin <[email protected]> Wed, 1 May 2024 18:56:35 +0200
| Newsgroups | gmane.comp.sysutils.backup.dar.support |
|---|---|
| Message-ID | <[email protected]> |
Hi James, OK super, thanks for your help! Regards, Denis On 01/05/2024 18:46, James Pedersen wrote: > Denis, > > This error was not present when I compiled dar 2.7.15.RC1 on my other > MacOS Mojave laptop today. > > James Pedersen > > On Tue, Apr 30, 2024 at 6:20 AM Rolf Gebhardt <[email protected] > <mailto:[email protected]>> wrote: > > Hi Denis, hi James, > > first of all, I totally agree that adding the noexcept specification to > the smart_xxx class templates can not be a solution for the future. > It's > no more than a patch to get dar/libdar compiled on an outdated compiler > with outdated standard libraries on an outdateted operating system. > > And because - as I told you - I'm not very familiar with exception > specification and the ways they are used in C++ - as far as I > understood, the meaning "it's impossible that this function throws" is > not the only one - I can not contribute much to this discussion. > > The only thing I want to say was already mentioned in the first sentenc > above: It's a problem with an outdated compiler with outdated standard > libraries on an outdateted operating system. MacOS Mojave is not > supported by apple any more and Apples development tools and libraries > either won't get any updates any more. The only reason to use it, is if > you have an old Mac that cannot be updated to newer MacOs-Versions. > > On the current version MacOS with the corresponding tools and libraries > dar compiles fine. > > @Denis: Just to prevent you from spending hours or days of your > valuable > time to solve problems of the past. > > Kind regards to all, > > Rolf > > > Am 27.04.24 um 21:15 schrieb Denis Corbin: > > On 25/04/2024 01:39, James Pedersen wrote: > >> Hi Denis and Rolf, > > > > Hi James, > > > >> > >> Thank you for getting back to me about this as well as for > suggesting > >> some solutions to this issue. > >> > >> Denis, following your advice, I removed the "noexcept" statement > from > >> the move assignment operator definition in a bunch of the .hpp > files > >> in src/libdar/, and then the errors went away. > >> > >> Rolf, I think that you have made a good observation here. In the > >> definition of the smart_pointer move assignment operator in > >> smart_pointer.hpp, it seems that it can throw exceptions because > >> /del_ref() /can throw exceptions. cat_nomme.hpp and cat_detruit.hpp > >> are subclasses of cat_entree.hpp, and hence it seems that they > would > >> both inherit the smart_pointer variable pdesc of cat_entree.hpp. > >> Since the move assignment operator of smart_pointer can throw > >> exception/s/, I would like to suggest that maybe the right solution > >> to this is to just remove the "noexcept" keyword for any move > >> assignment operator of a subclass of cat_entree.hpp? > > > > Yes, I agree with your analysis, smart_pointer/smart_node may throw > > exception thus the absence of noexcept keyword here is normal. > > > > I will go that way. first I have to reproduce the problem (which I > > failed under Devuan using clang, will try other distro/clang > version) > > to be sure the fix to be exhaustive. > > > >> > >> Anyways, thank you both for helping me with this, > >> James Pedersen > >> > > > > Regards, > > Denis > >> > > > >> > >> > >> > >> > >> > > > >
OpenPGP_signature.asc
(application/pgp-signature, 840 B)
-----BEGIN PGP SIGNATURE----- wsF5BAABCAAjFiEEVeSEpqXFvH9T9/cuqLFBYNNrO6cFAmYydEMFAwAAAAAACgkQqLFBYNNrO6cP YBAAruVvpxaIvbTKFSW3Myn7Ynt/YB8JTcEo41rNqb3w+t098uz253/ZdWAduPB8b9zjOV0hIBsV tg6AJBSrYr65JvJgv2PbMnh2hdwJGBj2Ay6xVI9aeyd2HC/A6YcfEAL6W2MZDnJ55VLiGEr5IRxl oA9nimvw2bkRrxdXxGIrK36UqQZ6zHQMrz3S1U47wtQkQaRV7tDOXa5qh+d/Kma8EISTfSeGhhFC kPZjgA/NAdFkvIPqNuGGprGqhcpRtJT+TcBqn6Nv9sd5725eFGo77WeAmALvoCxJE0zRbUwu0/Oq hgrwEiONHCYzlNZqgj6BaPmxMZyQ4fNXjmIWjDJ8nRAKNCMnccDAkaqqUrTTfIKi2o+8S5igqIyd 6N8oN2jEQPJDiFmj4jyV1mU9FZr2qkJ7Qyrm0TJ+YzzBQ1n08rSooUT0M9rv/DGsqdiDJqpDwLxC y2kS978pKgw9LmsyLQxmnhyo6WonKBAbyFh5XzgjG1YncpxWzP/40K8ASxFuAXB6XjCyG09467Iw C2LqwRTjBVde2aaksDMwdzxkCFNwbdPYnuy/gJ9xDvqLY8IWF01MX91/QHXHZdo9RJdyaGSBBGYw 82rJfwPkmLYWnHP2VQ0dTLhmQbt4j8RyKf5cytlig7pFnTq1P3/VTywJcGVq/y+lwXgh6NqP24C5 Wr4= =l3SU -----END PGP SIGNATURE-----