Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
MemSound has a deficiency :)
#6
Honestly, I wouldn't want to see it implemented as a double-bit type just for the havoc that it could put on already existing code.  

IF m.TYPE AND 1 THEN 'It's one byte
...
ELSEIF m.TYPE AND 2 THEN 'It's two bytes
...
ELSEIF...  'check the other types

You'll see a lot of code written in the above syntax, and a Type 3 type would fall into both categories, throwing that existing code off.  Instead, I'd rather stick to the documentation that has existed for mem's syntax since the swap from SDL to GL, and honor the "Note: If a future integer, float or other type doesn't have a size that is 1,2,4,8,16,32,64,128 or 256 it won't have a size-bit set."  

I'd give it a TYPE value of 0 for size (undefined by our existing syntax rules), but then mem.ELEMENTSIZE could still easily define it as being 3 bytes in size.   Such a change then shouldn't break anything that exists now, I wouldn't think, and if it did, it would probably be the smallest of changes needed to update the user's code so that the end of their code doesn't end in ELSE .... 'It's a float (or whatever other else logic that have which didn't take in a 0 value return as a possibility for size).
Reply


Messages In This Thread
MemSound has a deficiency :) - by Petr - 04-24-2023, 06:37 PM
RE: MemSound has a deficiency :) - by a740g - 04-25-2023, 08:35 AM
RE: MemSound has a deficiency :) - by RhoSigma - 04-25-2023, 12:09 PM
RE: MemSound has a deficiency :) - by DSMan195276 - 04-25-2023, 01:40 PM
RE: MemSound has a deficiency :) - by mnrvovrfc - 04-25-2023, 09:17 AM
RE: MemSound has a deficiency :) - by SMcNeill - 04-25-2023, 04:16 PM
RE: MemSound has a deficiency :) - by DSMan195276 - 04-25-2023, 06:09 PM
RE: MemSound has a deficiency :) - by SMcNeill - 04-25-2023, 06:42 PM
RE: MemSound has a deficiency :) - by mnrvovrfc - 04-26-2023, 02:51 AM
RE: MemSound has a deficiency :) - by a740g - 04-25-2023, 08:58 PM



Users browsing this thread: 3 Guest(s)