Uploaded image for project: 'Swift'
  1. Swift
  2. SR-5110

Name collision not solved with namespacing

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Medium
    • Resolution: Duplicate
    • Component/s: Compiler
    • Labels:
      None
    • Environment:

      Xcode 9 beta 1

      Description

      Having a name collision in Xcode 9/Swift 3.2 is not solved by prefixing the module name in some cases.

      I have a iOS project that has a dependency named `Decodable` which has a protocol you could adopt named the same way. Since Swift 3.2 also added a protocol name `Decodable`, there's a name collision.

      I instantly thought of namespacing the protocol conformace to remove the error. But it did not work.

      ```
      class MyClass: Decodable -> class MyClass: Decodable.Decodable
      ```

      However, namespacing with `Swift`, does work, but does not solve the issue

      ```
      class MyClass: Decodable -> class MyClass: Swift.Decodable
      ```

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              Quintana Pol Quintana
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: