Open momo-youngg opened 3 months ago
I've also encountered this error when using Xcode 16 (swiftlang-6.0.0.9.10 clang-1600.0.26.2
).
@hborla are there any other pointers to this? Any known workarounds? 😄 Thank you.
@kevinrpb it looks like macros just don't work at all for lazy vars. Here's some other examples from the forums: https://forums.swift.org/t/macros-with-lazy-var/69747
Description
After create a macro that adds the same name, the same type, and the same initialization value, an unknown compilation error occurs.
Because it is macro, declaring and implementing this macro does not cause compilation errors, but compilation errors occur in actual use.
It works without lazy keyword, so I think lazy makes problem.
Reproduction
This is a macro declaration.
This is a test case which is passed
This is an implementation
and this is a client code which causing compiler crash
Stack dump
Expected behavior
No compiler crash
Environment
swift-driver version: 1.90.11.1 Apple Swift version 5.10 (swiftlang-5.10.0.13 clang-1500.3.9.4) Target: x86_64-apple-macosx14.0
Additional information
No response