From 346dcc696bb2b1431a3a38f8d830d030334f1924 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antti=20M=C3=A4=C3=A4tt=C3=A4?= Date: Tue, 25 Apr 2023 13:59:10 +0300 Subject: [PATCH] Create unique names for QSize and QRect types for lttng Task-number: QTBUG-113161 Pick-to: 6.5 Change-Id: Icc47af16b73dd9ad4e203c3bd55833587435be5c Reviewed-by: Hatem ElKharashy Reviewed-by: Janne Koskinen --- src/tools/tracegen/lttng.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/tools/tracegen/lttng.cpp b/src/tools/tracegen/lttng.cpp index c37e3dd9a8..c368376c4c 100644 --- a/src/tools/tracegen/lttng.cpp +++ b/src/tools/tracegen/lttng.cpp @@ -67,24 +67,24 @@ static void writeCtfMacro(QTextStream &stream, const Provider &provider, const T stream << "ctf_string(" << name << ", " << name << ".toString().toUtf8().constData())"; return; case Tracepoint::Field::QtRect: - stream << "ctf_integer(int, x, " << name << ".x()) " - << "ctf_integer(int, y, " << name << ".y()) " - << "ctf_integer(int, width, " << name << ".width()) " - << "ctf_integer(int, height, " << name << ".height()) "; + stream << "ctf_integer(int, QRect_" << name << "_x, " << name << ".x()) " + << "ctf_integer(int, QRect_" << name << "_y, " << name << ".y()) " + << "ctf_integer(int, QRect_" << name << "_width, " << name << ".width()) " + << "ctf_integer(int, QRect_" << name << "_height, " << name << ".height()) "; return; case Tracepoint::Field::QtSizeF: - stream << "ctf_float(int, width, " << name << ".width()) " - << "ctf_float(int, height, " << name << ".height()) "; + stream << "ctf_float(double, QSizeF_" << name << "_width, " << name << ".width()) " + << "ctf_float(double, QSizeF_" << name << "_height, " << name << ".height()) "; return; case Tracepoint::Field::QtRectF: - stream << "ctf_float(int, x, " << name << ".x()) " - << "ctf_float(int, y, " << name << ".y()) " - << "ctf_float(int, width, " << name << ".width()) " - << "ctf_float(int, height, " << name << ".height()) "; + stream << "ctf_float(double, QRectF_" << name << "_x, " << name << ".x()) " + << "ctf_float(double, QRectF_" << name << "_y, " << name << ".y()) " + << "ctf_float(double, QRectF_" << name << "_width, " << name << ".width()) " + << "ctf_float(double, QRectF_" << name << "_height, " << name << ".height()) "; return; case Tracepoint::Field::QtSize: - stream << "ctf_integer(int, width, " << name << ".width()) " - << "ctf_integer(int, height, " << name << ".height()) "; + stream << "ctf_integer(int, QSize_" << name << "_width, " << name << ".width()) " + << "ctf_integer(int, QSize_" << name << "_height, " << name << ".height()) "; return; case Tracepoint::Field::EnumeratedType: stream << "ctf_enum(" << provider.name << ", " << typeToTypeName(paramType) << ", int, " << name << ", " << name << ") ";