[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Which ObjC2.0 features are missing in the latest GCC?
From: |
Matt Rice |
Subject: |
Re: Which ObjC2.0 features are missing in the latest GCC? |
Date: |
Mon, 25 Nov 2019 11:19:12 +0000 |
On Mon, Nov 25, 2019 at 10:53 AM David Chisnall
<gnustep@theravensnest.org> wrote:
>
> On 25 Nov 2019, at 09:37, Gregory Casamento <greg.casamento@gmail.com> wrote:
> >
> > * C++, while this is not exclusive to clang, gcc doesn't support the latest
> > version of C++. Clang is extraordinarily good at optimization.
>
> I don’t think this is true. We have a C++17 project that we test in CI with
> GCC. The only times that we experience problems are when we use some
> non-standard attributes that GCC doesn’t support (but we also build with
> Visual Studio, so we rarely find anything that we need that those two support
> but GCC doesn’t, it’s only when we have something ELF-specific that’s a
> problem).
>
> I don’t know how good GCC’s Objective-C++ support is (as I recall,
> Objective-C and Objective-C++ in GCC aren’t just base-language + Objective-*,
> so it isn’t necessarily a given that you get full C++17 support in GCC’s
> Objective-C++), but using C++ smart pointers you can get a lot of ARC (at the
> very least - and prior to ARC support, I did - you can implement smart
> pointers that manage Objective-C retain / release and use them to hold
> Objective-C objects in collections.
I had used ObjC++ before when embedding a c++ rendering engine in an
NSOpenGLView,
many years ago, but I don't recall anything specifically in the objc++
frontend that did anything but punt to either the objc or c++ backend.
What I do remember is that the debugging support is terrible!
It implements Dwarf with the language ObjC++, and then in the
debuginfo Classes in objc are mapped to dwarf's Object/Class thing,
and classes in C++ are mapped to the same Object/Class thing.
Apple's debugger tells the difference by looking at symbol mangling,
In particular their objc symbols contain +-[()]: characters, and it
can tell from the first character if it's objective-c or not.
A solution like that was never really acceptable for gdb.
So you generally had to set language to c++, or objc at every step.
This is very unlikely to have changed for gcc, is it any better on clang?
- Re: Which ObjC2.0 features are missing in the latest GCC?, (continued)
- Re: Which ObjC2.0 features are missing in the latest GCC?, Ivan Vučica, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Gregory Casamento, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Gregory Casamento, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, David Chisnall, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Gregory Casamento, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?,
Matt Rice <=
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Andreas Fink, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Maxthon Chan, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Maxthon Chan, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Gregory Casamento, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, H. Nikolaus Schaller, 2019/11/25
- Re: Which ObjC2.0 features are missing in the latest GCC?, Gregory Casamento, 2019/11/25