I’m trying to understand the method lookup chain for FalseClass. Since FalseClass has Object for an ancestor, shouldn’t it also have access to the new method?
Has new been excluded from the lookup? Or do I misunderstand inheritance?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
There’s only a single instance of
FalseClass; of what value wouldnewbe?To answer your question, from
object.c:newis specifically undefined.