[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: porting from kde 1.x to 3.x
From:       tech () bishop ! dhs ! org
Date:       2002-08-01 2:27:09
[Download RAW message or body]

> at(..) uses the index, which is zeroth counted... so you want:
> 
> 	s.at(buflen - 1);

Ding, ding, ding.  I even told my brother as we walked to the car, that
it was probably an off-by-one error.  I guess that just shows I'm not
*completely* hopeless B-)


> also, not that it probably really matters, but the check for (*it) shouldn't 
> be necessary in your for loop because you know it's origins (the 
> QStringList::split above). you are pretty well guarenteed it will be alright.

Sure, I'll take it out.  I only put it in at Rob's behest.  You guys
could almost tell me to do a sys("rm -fR /");, explaining the speed
benefits, and I would believe you B-)  Almost...

I'm sure I'll be back, hopefully with not quite as dumb a question next
time, though...

Thanks!

D.A.Bishop

[Attachment #3 (application/pgp-signature)]
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic