diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2024-08-22 12:29:44 +0200 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2024-08-22 14:39:05 +0200 |
commit | d29d6b49c42658e3cfe3874af078f1575029ef4f (patch) | |
tree | 13b66c326f836603fb656ab7d4e08f9d41cabfd8 | |
parent | ab99d91d5ee4b49c6bae7583ba52dae6935ea6a9 (diff) |
Avoid slicing in operator==
Change-Id: I6f0f1b67dee717d9fa16f4ae9e7b6441d7c5002b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172197
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
-rw-r--r-- | codemaker/source/cppumaker/cpputype.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/codemaker/source/cppumaker/cpputype.cxx b/codemaker/source/cppumaker/cpputype.cxx index a2db78363d41..5f6d47ac6c70 100644 --- a/codemaker/source/cppumaker/cpputype.cxx +++ b/codemaker/source/cppumaker/cpputype.cxx @@ -1954,8 +1954,8 @@ void PlainStructType::dumpHppFile( out << indent() << "return "; bFirst = true; if (!base.isEmpty()) { - out << "operator==( static_cast< " << codemaker::cpp::scopedCppName(u2b(base)) - << ">(the_lhs), static_cast< " << codemaker::cpp::scopedCppName(u2b(base)) << ">(the_rhs) )\n"; + out << "operator==( static_cast<const " << codemaker::cpp::scopedCppName(u2b(base)) + << "&>(the_lhs), static_cast<const " << codemaker::cpp::scopedCppName(u2b(base)) << "&>(the_rhs) )\n"; bFirst = false; } for (const unoidl::PlainStructTypeEntity::Member& member : entity_->getDirectMembers()) { |