Files
swift-mirror/test/Constraints/diag_ambiguities_module.swift
Dmitri Gribenko 486cab447d tests: replace 'rm -rf %t && mkdir -p %t' with '%empty-directory(%t)'
These changes were made using a script.
2017-06-04 11:08:39 -07:00

16 lines
521 B
Swift

// RUN: %empty-directory(%t)
// RUN: %target-swift-frontend -emit-module -o %t %S/Inputs/has_ambiguities.swift
// RUN: not %target-swift-frontend -typecheck %s -I %t 2>&1 | %FileCheck %s
import has_ambiguities
maybeTrans(0) // expected-error{{ambiguous use of 'maybeTrans'}}
// CHECK: ambiguous use of 'maybeTrans'
// CHECK: maybeTrans(0)
// CHECK: found this candidate
// CHECK-NOT: transparent
// CHECK: maybeTrans(_ i: Int16)
// CHECK: found this candidate
// CHECK-NOT: transparent
// CHECK: maybeTrans(_ i: Int32)