Skip to content

Prevent symbol conflicts when using accessLevel: public across multiple packages #131

@markst

Description

@markst

Describe the problem

When using XCStringsToolPlugin across multiple Swift packages, setting accessLevel: public in just one package's xcstrings-tool-config.yml causes a conflict if other packages also generate a Localizable symbol (even with default internal access level).

The compiler reports:

'Localizable' is ambiguous for type lookup in this context

This happens because one module exports Localizable publicly, while others still generate the same symbol internally — leading to ambiguity when multiple modules are imported into the same target.

Steps to Reproduce

  1. Add .xcstrings files to two Swift packages: PackageA and PackageB
  2. Set accessLevel: public in PackageA’s config only
  3. Leave PackageB with default or internal
  4. Import both packages into an app target
  5. Use Localizable.someString

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions