Errm so what does "if (object)" and "Assert(object)" do??

Max Samukha samukha at voliacable.com
Sat Mar 10 11:37:23 PST 2007


On Sat, 10 Mar 2007 12:43:22 -0500, "Jarrett Billingsley"
<kb3ctd2 at yahoo.com> wrote:

>"torhu" <fake at address.dude> wrote in message 
>news:estvsu$2pd9$1 at digitalmars.com...
>> I think assert(obj) being the same as assert(obj !is null), and then being 
>> able to do 'obj.invariant' if you really want to explicitly check the 
>> invariant would a lot clearer.  Or even 'invariant(obj)'.
>
>votes = votes + 1; // add one to votes 
>
vote++ for obj.invariant 


More information about the Digitalmars-d-learn mailing list