How can we check if a parameter passed in a function is a value or a reference type? For example
func isReferenceType(toTest: Any) { return true // or fa
Swift 5
func isReferenceType(_ toTest: Any) -> Bool { return type(of: toTest) is AnyClass }