Hi all,
I have been handed a legacy application to imrpove. This does a huge amount of text and string manipulation and it uses the STRING type throughout. It uses very large arrays of strings and the maximum capacity of the program is limited by available memory.
My first thought is to switch all strings to ansistrings. As I understand it, an ARRAY [1..100] OF STRING will immediately consume 25,600 bytes (?), but an ARRAY [1..100] OF ANSISTRING will consume nothing until a value is assigned to one of the array indices. Also, it will only consume what it requires (i.e. governed by the string length) rather than assuming the full 256 bytes.
Is that a correct interpretation? Is this a reasonable thing to do to quickly lower the memory usage? or am I deluding myself here?