Swift 2, warning: could not load any Objective-C class information from the dyld shared cache

For anyone coming across this in the future, I just ran into this problem myself and it turned out that I was actually getting a stack overflow from a recursive function.

Apparently calling setValue:forKey: on an NSObject calls the respective set[Key] function, where [Key] is the (capitalized) name you gave to the forKey section.

So, if like me, you have code that looks like the following, it will cause an infinite loop and crash.

func setName(name: String) {
    self.setValue(name, forKey: "name")
}

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)