[Development] Allowed C++11 features [was: Re: Re: MSVC2012 in CI]

Marc Mutz marc.mutz at kdab.com
Mon Mar 21 11:57:53 CET 2016


On Monday 21 March 2016 10:46:40 Sean Harmer wrote:
> On Sunday 20 March 2016 18:28:37 Thiago Macieira wrote:
> > On domingo, 20 de março de 2016 12:07:01 GMT Sean Harmer wrote:
> > > Hi,
> > > 
> > > Can MSVC 2012 configurations be removed from the CI please? My
> > > understanding is that this compiler was only kept around to support
> > > Windows EC but that this is now removed from 5.7. In particular this
> > > compiler is a blocker to using a using declaration such as:
> > > 
> > > template<typename T>
> > > using QNodeCreatedChangePtr = QSharedPointer<QNodeCreatedChange<T>>;
> > 
> > We haven't yet done a re-evaluation of which C++11 features are allowed
> > in our code without #ifndef. For the moment, template aliases are not
> > permitted.
> > 
> > Or, put another way, can someone do that evaluation and post to the list?
> 
> Dropping MSVC2012 as per
> 
> http://lists.qt-project.org/pipermail/development/2016-March/025129.html
> 
> would remove the block from being able to use template aliases according to
> 
> https://msdn.microsoft.com/en-us/library/hh567368.aspx
> 
> I don't have ready access to all the other compilers and versions we
> support but I think this would allow potential use of:
> 
> * template aliases
> * raw string literals
> * delegating ctors
> 
> Marc, you likely know compiler limitations much better than I do, do you
> have any inputs on this please?

This has been discussed in the context of 5.8 already:

Thiago's list of additional features that dropping MSVS 2012 would enable:

http://lists.qt-project.org/pipermail/development/2016-February/024902.html

And my quick evaluation of each:

http://lists.qt-project.org/pipermail/development/2016-February/024910.html

I said then and I repeat it now that imho template aliases are not interesting 
for library development. In particular, I don't think something like

> > > template<typename T>
> > > using QNodeCreatedChangePtr = QSharedPointer<QNodeCreatedChange<T>>;

should be part of an API of a library. We have auto to avoid having to type 
this type. The typedefs just hide the (essential) fact that this is a shared 
pointer type.

Thanks,
Marc

-- 
Marc Mutz <marc.mutz at kdab.com> | Senior Software Engineer
KDAB (Deutschland) GmbH & Co.KG, a KDAB Group Company
Tel: +49-30-521325470
KDAB - The Qt Experts



More information about the Development mailing list