Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
String Addition (Optimization)
#11
(04-29-2024, 08:30 PM)DSMan195276 Wrote:
(04-26-2024, 02:19 AM)TerryRitchie Wrote: Holy cow. Can anything be done to improve QB64's string manipulation?
There are many improvements that could be made, the existing system has some pretty significant bugs as well as not being the most performant it could be. It requires someone to take the time to fix it though, that tends to be the limiting factor for a lot of things related to QB64 Big Grin

That said, there are some trade-offs that mean concatenation will always be slow. Many languages have this problem and introduce a kind of 'string builder' API to efficiently create strings, `MID$()` in QB64 like Steve used it is probably the closest thing to that.
Definitely hats off to the people that update and maintain the QB64 source code. When I first discovered QB64 I was immediately drawn to the source code hoping I could contribute in some way or the other. Then I looked at the code. I couldn't believe my eyes. I had no idea spaghetti and soup could be combined in such a manner. Sad 

I have not looked at the source code in ages. I'm sure it has improved over the years.
There are two ways to write error-free programs; only the third one works.
QB64 Tutorial
Reply




Users browsing this thread: 1 Guest(s)