mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
Update DiagnosticVerifier to respect color flags Improve DiagnosticVerifier test coverage verifier updates to support new llvm stable branch
15 lines
578 B
Plaintext
15 lines
578 B
Plaintext
// RUN: not %target-sil-opt -enable-sil-verify-all %s -definite-init -verify 2>&1 | %FileCheck %s
|
|
|
|
import Builtin
|
|
import Swift
|
|
|
|
// main
|
|
sil [ossa] @main : $@convention(c) (Int32, UnsafeMutablePointer<Optional<UnsafeMutablePointer<Int8>>>) -> Int32 {
|
|
bb0(%0 : $Int32, %1 : $UnsafeMutablePointer<Optional<UnsafeMutablePointer<Int8>>>):
|
|
%2 = integer_literal $Builtin.Int32, 0
|
|
%3 = struct $Int32 (%2 : $Builtin.Int32)
|
|
return %4 : $Int32 // expected-error {{use of undefined value '%5'}}
|
|
// CHECK-NOT: error: use of undefined value '%4'
|
|
// CHECK: incorrect message found
|
|
}
|