示例工程 40-windows-scenes-macos
40-windows-scenes-macos/Diagnostics/README.md
# Diagnostics
三个文件**故意编译失败**,用来复现第 40 章「报错现场」的真实诊断。
```bash
swiftc -typecheck Diagnostics/OpenWindowInt.swift # error: cannot convert 'Int' to 'String'
swiftc -typecheck Diagnostics/WindowWithoutID.swift # error: missing argument for parameter 'id'
swiftc -typecheck Diagnostics/DefaultSizeString.swift # error: cannot convert 'String' to 'CGFloat'
```