On 05/30/2012 11:33 AM, John Cummings wrote:
> I uncovered a bug with the latest Shiboken when passing an enum by reference.
> Like Nathan, I have a bug report ready to go when the system comes back up.
>
> In previous versions, you could pass an enum by reference to a method like so:
>
> class Val
> {
> enum ValEnum { One, Other };
> ValEnum oneOrTheOtherEnumValue(ValEnum& enumValue) { return enumValue == One
> ?
> Other : One; }
> }
>
> You get compilation errors with version 1.1.1 and with HEAD. The generated
> code
> is trying to use a pointer instead of reference. Previous version of Shiboken
> worked just fine (specifically, 1.0.7 worked, I'm not sure about other
> versions
> until 1.1.1).
>
> Unlike Nathan, I don't have a patch ready. The workaround is obviously to pass
> an enum by value not by reference (which is admittedly a bit overkill anyway).
> If someone knows of a better solution, I'm willing to try it.
>
> John Cummings
Just submitted the bug as PYSIDE-71.
_______________________________________________
PySide mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/pyside