BugFix Challenge

Started by Zlatko Vid, April 02, 2026, 12:00:10 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Theo Gottwald

@Zlatko Vid
1. Is the source code of the actual Oxygen release anywhere downloadable?
2. What exact is the problem that needs to be fixed?
At least these Informations you must give the KI.
Then try again with Qwen 3.6 - it should find the problem.

Charles Pegge

Hi Theo,

The source code for the OxygenBasic compiler DLLs is in inc\self. The complete system is here. It is all that I use.

Hi Aurel,
Case strings are restricted to the first 4 bytes because the key string is converted into a dword. It's close to the bare metal :)

Zlatko Vid

Quote2. What exact is the problem that needs to be fixed?

Hi Theo

Exact problem is in function call and execution
for example :
add(1,2)
should be 3 but stupid interpreter constantly throw 0
that is why i said that in console type of programs is hard to follow
or track errors it is much easier with message box aka print in GUI version of o2.
I hope that you understand it now
yeah sorry maybe looks confusing...

Hi Charles
yeah you many times explain this to me
what confuses me is ..is ir 4 bytes or 4 first characters
uff..

  •  

Charles Pegge

#18
Hi Aurel,
I'ts the first 4 bytes. which could be only 2 wide characters (unicode)

I checked these direct string cases. Unfortunately this hack will no longer work. However, you can use any ascii combo of any string character to use in your cases:

string s="abc" 'test case
'
select asc(s,2)
  case "a" : print "A"
  case "b" : print "B"
  case "c" : print "C"
  case else : print "no match"
end select

Charles Pegge

#19
To digress a little:

As of March 2024, OxygenBasic supports the combination of CASE and full conditional expressions in one block. You can use this facility to case-evaluate strings of any length:

string s
s="abcd"
select asc s
  'embedded conditional expressions
  case s="abcde" : print "ABCDE"
  case s="abcd"  : print "ABCD"
  case s="abc"   : print "ABC"
  'normal cases
  case "a" : print "A"
  case "b" : print "B"
  '
  case else : print "no match"
end select