Files
swift-mirror/test/expr/primary/literal/boolean.swift
David Farler b7d17b25ba Rename -parse flag to -typecheck
A parse-only option is needed for parse performance tracking and the
current option also includes semantic analysis.
2016-11-28 10:50:55 -08:00

28 lines
386 B
Swift

// RUN: %target-typecheck-verify-swift
func boolLiterals() {
var b: Bool = false
b = true
_ = b
}
func defaultBoolLiterals() {
let b = false
var _: Bool = b
}
struct CustomBool : ExpressibleByBooleanLiteral {
let value: Bool
init(booleanLiteral value: Bool) {
self.value = value
}
}
func customBoolLiterals() {
var b: CustomBool = false
b = true
_ = b
}