mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
This is useful for ArrowExpr when the sub-expressions aren't valid TypeExprs. Rather than throwing away the AST, attach it to the ErrorTypeRepr to ensure we can still type-check it. This ensures semantic functionality still works correctly, and fixes a crash where we'd stop visiting an invalid binding pattern, losing track of the nested VarDecl.
5 lines
407 B
Swift
5 lines
407 B
Swift
// {"kind":"complete","original":"2ad6764c","signature":"swift::constraints::Solution::getType(swift::KeyPathExpr const*, unsigned int) const","signatureAssert":"Assertion failed: (hasType(KP, I) && \"Expected type to have been set!\"), function getType"}
|
|
// RUN: %target-swift-ide-test -code-completion -batch-code-completion -skip-filecheck -code-completion-diagnostics -source-filename %s
|
|
0 -> \ a#^^#
|
|
!
|