Qbasicnews.com

Full Version: ENUM problem?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Code:
enum testvals
  one = 1,
  two,
  three,
  four
end enum

print one, two, three, four

The above test code outputs 1 3 5 7 instead of 1 2 3 4.

I ran across this problem when working on a simple database of objects and kept seeing odd results in the output.
Try this (I've never seen commas in an EMU bit)

Code:
enum testvals
  one = 1
  two
  three
  four
end enum

print one, two, three, four
True, fixed.. i added the commas support in 0.13 but didn't test it, sorry.. changes are in CVS.