Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SWIFT

Swift Guard statement

func testFunction() {
	let someValue:Int? = 5
	guard let temp = someValue else {
		return
	}
	print("It has some value (temp)")
}

testFunction()
 
PREVIOUS NEXT
Tagged: #Swift #Guard #statement
ADD COMMENT
Topic
Name
5+2 =