Skip to content

[25536] Fix some warnings in generated code#593

Merged
MiguelCompany merged 4 commits into
masterfrom
backport/25536/master
Jul 21, 2026
Merged

[25536] Fix some warnings in generated code#593
MiguelCompany merged 4 commits into
masterfrom
backport/25536/master

Conversation

@MiguelCompany

@MiguelCompany MiguelCompany commented Jul 20, 2026

Copy link
Copy Markdown
Member

Description

This fixes some warnings in the generated code introduced by #569.

It adds f after default values in float primitive types and removes unnecessary braces around default values when used in setter methods before deserialization.

Will do the first backport manually due to the submodule update.

Contributor Checklist

  • Commit messages follow the project guidelines.
  • N/A: Tests that thoroughly check the new feature have been added/Regression tests checking the bug and its fix have been added; the added tests pass locally
  • N/A: New feature has been documented/Current behavior is correctly described in the documentation.
  • Applicable backports have been included in the description.

Reviewer Checklist

  • The PR has a milestone assigned.
  • The title and description correctly express the PR's purpose.
  • Check contributor checklist is correct.
  • Check CI results: changes do not issue any warning.
  • Check CI results: failing tests are unrelated with the changes.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
@MiguelCompany MiguelCompany added this to the v4.3.1 milestone Jul 20, 2026
@github-actions github-actions Bot added the ci-pending PR which CI is running label Jul 20, 2026
Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
@MiguelCompany MiguelCompany changed the title [25536] Fix warning in generated code for members annotated with @default [25536] Fix some warnings in generated code Jul 20, 2026
@MiguelCompany
MiguelCompany requested review from cferreiragonz and removed request for cferreiragonz July 20, 2026 12:48
Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
@MiguelCompany
MiguelCompany force-pushed the backport/25536/master branch from bdee0aa to fca5d99 Compare July 20, 2026 14:33
@MiguelCompany
MiguelCompany requested review from cferreiragonz and removed request for cferreiragonz July 20, 2026 14:36

@cferreiragonz cferreiragonz left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. CI passed in eProsima/Fast-DDS#6480

@mergify

mergify Bot commented Jul 21, 2026

Copy link
Copy Markdown

Tick the box to add this pull request to the merge queue (same as @mergifyio queue).

  • Queue this pull request

@MiguelCompany
MiguelCompany merged commit 9b6e981 into master Jul 21, 2026
6 checks passed
@MiguelCompany
MiguelCompany deleted the backport/25536/master branch July 21, 2026 05:48
MiguelCompany added a commit that referenced this pull request Jul 21, 2026
* Refs #25536. Add `f` for default values in float types.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Remove unnecessary braces.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Remove more unnecessary braces.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Add braces for array types.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

---------

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
MiguelCompany added a commit that referenced this pull request Jul 21, 2026
* Fix some warnings in generated code (#593) (#594)

* Refs #25536. Add `f` for default values in float types.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Remove unnecessary braces.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Remove more unnecessary braces.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

* Refs #25536. Add braces for array types.

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

---------

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
(cherry picked from commit 49cb136)

# Conflicts:
#	src/main/java/com/eprosima/fastcdr/idl/templates/FastCdrCommon.stg
#	src/main/java/com/eprosima/fastdds/idl/templates/eprosima.stg

* Fix conflicts

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>

---------

Signed-off-by: Miguel Company <miguelcompany@eprosima.com>
Co-authored-by: Miguel Company <miguelcompany@eprosima.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-pending PR which CI is running

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants