You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: resolve debug build linker issues and macro test failures
- Pin swift-syntax to development snapshot (2025-10-09-a) to fix linker errors
- Fix TableMacro Selection struct to use conditional nonisolated keyword
- Update macro test snapshots to match corrected output
- Remove build requirement warnings from documentation
Changes:
- TableMacro.swift: Change hardcoded 'nonisolated' to '\(nonisolated)' variable
- Package.resolved: Update swift-syntax to pinned snapshot
- README.md: Remove debug build warnings, update test count to 558
- All macro tests: Re-record snapshots with correct output
Result: All 573 tests now passing in both debug and release modes
WIP
WIP
Since the package's creation, debug builds consistently failed with SwiftSyntax linker errors:
858
+
```
859
+
Undefined symbols for architecture arm64:
860
+
"SwiftSyntax.SyntaxRewriter.(visitationFunc in _F0C5D882E9301122F145EADC4573BFC8)..."
861
+
ld: symbol(s) not found for architecture arm64
862
+
```
863
+
864
+
This forced all development to use release mode (`swift build -c release`, `swift test -c release`), which was slower and less convenient for development.
865
+
866
+
### Root Cause
867
+
868
+
The swift-syntax package version range specified in Package.swift had compatibility issues with the macros in this package, causing linker errors specifically in debug builds.
869
+
870
+
### Solution
871
+
872
+
Pinned swift-syntax dependency to a specific development snapshot that resolves the linker issues:
- 🔌 **Built for [swift-records](https://github.com/coenttb/swift-records)**: High-level database operations with connection pooling, transactions, and migrations
15
+
- 🔌 **Built for [swift-records](https://github.com/coenttb/swift-records)**: The swift Postgres database package
16
16
- ⚡ **Swift 6.1+** with strict concurrency
17
-
- 🧪 **467 tests** with SQL snapshot testing
17
+
- 🧪 **573 tests** with SQL snapshot testing
18
18
19
19
## Quick Start
20
20
@@ -49,17 +49,6 @@ dependencies: [
49
49
]
50
50
```
51
51
52
-
### Critical: Build Requirement
53
-
54
-
**Always use release mode** for building and testing:
55
-
56
-
```bash
57
-
swift build -c release
58
-
swift test -c release
59
-
```
60
-
61
-
Debug builds have Swift 6.x compiler linker issues. This is a known Swift compiler bug, not a package issue. Xcode debug builds work fine.
0 commit comments