Skip to content

polish: refactor functions exceeding 50-line soft limit in codegen modules #1948

@krystophny

Description

@krystophny

Several functions in the new codegen modules exceed the 50-line soft limit (though all are under the 100-line hard limit):

codegen_character_normalization.f90:

  • extract_character_length: 54 lines

codegen_declaration_grouping.f90:

  • can_group_declarations: 53 lines
  • can_group_declarations_with_params: 58 lines

codegen_grouped_body.f90:

  • process_grouped_declarations: 84 lines
  • process_grouped_parameters: 59 lines

Recommendation

Consider further refactoring to split these into smaller helper functions when convenient. This is a style polish item, not a blocker - all functions are well under the 100-line hard limit and tests pass.

Context

These modules were created in PR #1947 to split the monolithic codegen_declarations_programs.f90 file and comply with module size limits. The hard limit compliance was enforced in commit 71ede28.

Metadata

Metadata

Assignees

No one assigned

    Labels

    polishCode quality and style improvements

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions