From: James Coglan Date: 2008-09-16T19:11:50+09:00 Subject: Re: Precedence of Private and Public methods ------=_Part_4593_21473570.1221560348825 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline > Hi! > > Does anyone know what's the precedence between private and public > methods. > > Doing some tests I found that private methods have higher precendence > than public ones , but I don't understand why.Any sugesstions? > > Example: > class Class > > def inherited(child) > p "public inherited" > end > > private > def inherited(child) > p "private inherited" > end > end This isn't a precedence issue -- the second method simply overwrites the first since it comes later. Try moving the public one after the private one (and preface it with 'public') and see what happens. ------=_Part_4593_21473570.1221560348825--