Post Reply 
A little CHOICE bug/enhancement
09-14-2015, 06:17 PM
Post: #3
RE: A little CHOICE bug/enhancement
I imagine many reading this post would assume most user programs would check the size of a list before presenting the user with a list and that this bug is of little consequence.

Whilst the bug can easily be avoided, if one takes a look at a practical example program - my Z editor - you will see several cases (annotated WA.CHOOSE) where it was necessary to surround a CHOOSE with an IF - basically, if the file directory is empty, or if no search strings are found.

if These IFs are omitted, the Android calculator is likely to require a Calculator virtual Menu/Exit. The consequence on the real calculator is unknown.

Whilst this example program might not be typical, it does suggest that dealing with empty choice lists might not be as rare an occurrence as first thought.

The usage in my program suggests that the best response is for CHOOSE to display the title and wait for a user response (as opposed to returning without displaying anything).

Stephen Lewkowicz (G1CMZ)
https://my.numworks.com/python/steveg1cmz
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: A little CHOICE bug/enhancement - StephenG1CMZ - 09-14-2015 06:17 PM



User(s) browsing this thread: 1 Guest(s)