Enhancement for @list()

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
DoubleDutch
Addict
Addict
Posts: 3220
Joined: Thu Aug 07, 2003 7:01 pm
Location: United Kingdom
Contact:

Enhancement for @list()

Post by DoubleDutch »

Could it be made so that @list() will return 0 if the list doesn't have a current element - currently it reports an error.
Likewise, could ChangeCurrentElement(LinkedList(), 0) set the list not to have a current element.

This would make code surrounding temp alteration of lists less complicated and not lead to crashes if you dont check the listindex first.
https://deluxepixel.com <- My Business website
https://reportcomplete.com <- School end of term reports system