[Development] QML: Why C++11 scoped enums are not scoped in QML?

BogDan Vatra bogdan at kdab.com
Wed Jul 27 10:47:03 CEST 2016


On miercuri, 27 iulie 2016 10:35:01 EEST André Somers wrote:
> Op 27/07/2016 om 09:53 schreef BogDan Vatra:
> >> That said, it would be a behavior change not to allow anymore the
> >> previous
> >> (unscoped) syntax to work with QML
> > 
> > The unscoped enums should work as they are woring now, just the scoped
> > ones
> > should be scoped in QML as well.
> > 
> > Based on your patch, I'll try to prepare a patch for QML.
> 
> Would that not break existing QML applications that now use enums backed
> by scoped enums in C++?
> 

It will, but personaly I can't see a better solution ... 
So, either we break the existing QML apps that used scoped enums in C++ (which 
is useless, because in QML side you'll get name clashing) or we keep it as it 
is now and never "fix" it. I'd like the first option :). 
Of course if we can find a better solution to have them both is even better !

Cheers,
BogDan.




More information about the Development mailing list