QDBusIntrospection: fix position of Annotation definition

When 2e8a48c1cd made
Annotations::mapped_type a struct Annotation instead of just QString,
it inserted the Annotation definition after the first inline user of
Annotations (struct Method).

I don't know why this compiled in the first place, but it did,
probably because of the re-parse-everything-at-closing-of-class rule,
but there's no reason to not move it to before the first users, so do
that.

Found while trying to make QDBusIntrospection a namespace instead of a
struct.

Amends 2e8a48c1cd.

Pick-to: 6.7
Change-Id: I316cb5e49f3476adc5ff5abb023b9d74303ab640
Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
bb10
Marc Mutz 2024-02-20 08:27:28 +01:00 committed by Ivan Solovev
parent 211e51b81e
commit 448d4f847a
1 changed files with 12 additions and 12 deletions

View File

@ -67,6 +67,18 @@ public:
Q_ATTRIBUTE_FORMAT_PRINTF(3, 4) = 0;
};
struct Annotation
{
SourceLocation location;
QString name;
QString value;
inline bool operator==(const Annotation &other) const
{
return name == other.name && value == other.value;
}
};
struct Argument
{
SourceLocation location;
@ -116,18 +128,6 @@ public:
annotations == other.annotations && type == other.type; }
};
struct Annotation
{
SourceLocation location;
QString name;
QString value;
inline bool operator==(const Annotation &other) const
{
return name == other.name && value == other.value;
}
};
struct Interface: public QSharedData
{
SourceLocation location;