Code view:

A painting is a person's account of this edit as text, recorded independently of the node mapping - a rendering often has several equally defensible answers where the mapping has one. Deletions and insertions carry no position on the opposite side in a painting, so that panel draws no caret for them.

Before

1// RUN: %target-typecheck-verify-swift -solver-scope-threshold=1000 -solver-enable-performance-hacks
2// RUN: %target-typecheck-verify-swift -solver-scope-threshold=15000 -solver-disable-performance-hacks
3// REQUIRES: tools-release,no_asan
4
5// UNSUPPORTED: OS=linux-gnu
6
7// rdar://170773776
8// XFAIL: OS=freebsd
9
10let a: [Double] = []
11_ = a.map { $0 - 1.0 }
12 .map { $0 * $0 }
13 .reduce(0, +) / Double(a.count)
14

After

1// RUN: %target-typecheck-verify-swift -solver-scope-threshold=1000 -solver-enable-performance-hacks
2// RUN: %target-typecheck-verify-swift -solver-scope-threshold=15000 -solver-disable-performance-hacks
3// REQUIRES: tools-release,no_asan
4
5// UNSUPPORTED: OS=linux-gnu
6
7// FIXME: this test is flaky (expression too complex to typecheck) on FreeBSD
8// (very infrequent failure) rdar://170773776
9// ALLOW_RETRIES: 1
10
11let a: [Double] = []
12_ = a.map { $0 - 1.0 }
13 .map { $0 * $0 }
14 .reduce(0, +) / Double(a.count)
15

Before

source_file
comment "// RUN: %target-typecheck-verify-swift -solver-scope-thresho"...
comment "// RUN: %target-typecheck-verify-swift -solver-scope-thresho"...
comment "// REQUIRES: tools-release,no_asan"
comment "// UNSUPPORTED: OS=linux-gnu"
comment "// rdar://170773776"
comment "// XFAIL: OS=freebsd"
property_declaration
value_binding_pattern
let "let"
pattern
simple_identifier "a"
type_annotation
: ":"
array_type
[ "["
user_type
type_identifier "Double"
] "]"
= "="
array_literal
[ "["
] "]"
assignment (+61 nodes collapsed)

After

source_file
comment "// RUN: %target-typecheck-verify-swift -solver-scope-thresho"...
comment "// RUN: %target-typecheck-verify-swift -solver-scope-thresho"...
comment "// REQUIRES: tools-release,no_asan"
comment "// UNSUPPORTED: OS=linux-gnu"
comment "// FIXME: this test is flaky (expression too complex to type"...
comment "// (very infrequent failure) rdar://170773776"
comment "// ALLOW_RETRIES: 1"
property_declaration
value_binding_pattern
let "let"
pattern
simple_identifier "a"
type_annotation
: ":"
array_type
[ "["
user_type
type_identifier "Double"
] "]"
= "="
array_literal
[ "["
] "]"
assignment (+61 nodes collapsed)