stephencelis / SQLite.swift

A type-safe, Swift-language layer over SQLite3.
MIT License
9.57k stars 1.54k forks source link

Expression - name space conflict with Xcode 16/iOS 18 #1269

Open neodave opened 2 weeks ago

neodave commented 2 weeks ago

Build Information

0.15.3 Xcode Beta 16 iOS 18/macOS 15 Using Swift Package

When updating to the latest Xcode beta 16 there is a name space conflict between the SGLite struct Expression and the new Expression found in Apple's Foundation framework. Attached are screenshots of both. I will attempt to fix this and if I do I will submit a PR

Screenshot 2024-06-13 at 10 33 24 AM Screenshot 2024-06-13 at 10 27 07 AM
JohnnyTseng commented 2 weeks ago

To anyone who is having this issue, a temporary fix would be adding SQLite namespace before the Expression to let Xcode know we are referring to SQLite's Expression instead of Foundation's.

Example:

This would fix this issue

neodave commented 4 days ago

Thank you JohnnyTseng, great info

tcollins590 commented 3 days ago

Any ideas how to solve this without refactoring our entire codebase to explicitly call SQLite?

kaiwinter commented 3 days ago

@tcollins590 You could define a typealias at file level which makes it globally visible:

typealias Expression = SQLite.Expression