Move struct declaration out of the union to avoid a compiler warning.

Clang 3.3+ warns about this being an extension:
qsqlerror.h:101: warning: anonymous types declared in an anonymous union are an extension [-Wnested-anon-types]

Change-Id: I0350b977ff85558338b3b9db53d3fce7facb7635
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
bb10
Marcel Krems 2013-12-24 15:31:28 +01:00 committed by The Qt Project
parent b276f4e5e8
commit 6c4c2b752c
1 changed files with 5 additions and 4 deletions

View File

@ -96,12 +96,13 @@ private:
// ### Qt6: Keep the pointer and remove the rest.
QString unused1;
QString unused2;
struct Unused {
ErrorType unused3;
int unused4;
};
union {
QSqlErrorPrivate *d;
struct {
ErrorType unused3;
int unused4;
} unused5;
Unused unused5;
};
};