string length

BlitzPlus Forums/BlitzPlus Programming/string length

how long can the longest string be?

Mr Brine

I believe Blitz stores string length as an integer, so it should be something like 2^32 (4 billion +) characters.

(Of course long before you reached that limitation, you'd probably have run out of memory...)

cheerz man

I thought blitz had a limit of 64k on strings........

I'll have to try a test

I thought blitz had a limit of 64k on strings


No, they are pretty much just limited to the amount of available memory you have.

I believe string length is limited to 2^31-1 characters in length since Blitz does not support unsigned integers. You can conceivably create a string this large. Windows would begin to start using virtual memory (hard disk) once available physical RAM was exhausted. The other possibility is that Blitz implements it's own a memory management routines internally, which would be known only by Mark and those with enough free time and patience to test the limits.