Files
swift-mirror/validation-test/stdlib/AssertDiagnostics.swift
Joe Pamer dc338c2a71 Update wording of some new diagnostics.
Swift SVN r23783
2014-12-08 21:56:52 +00:00

8 lines
537 B
Swift

// RUN: %swift -verify -parse %s
func rejectsStringLiteral() {
assert("foo") // expected-error {{cannot invoke 'assert' with an argument list of type '(String)'}} expected-note{{expected an argument list of type '(@autoclosure () -> Bool, @autoclosure () -> String, StaticString, UWord)'}}
precondition("foo") // expected-error {{cannot invoke 'precondition' with an argument list of type '(String)'}} expected-note{{expected an argument list of type '(@autoclosure () -> Bool, @autoclosure () -> String, StaticString, UWord)'}}
}