Releases: harrypower/Gforth-Objects
Additions of stuff I use!
I have added here a few objects that i use over and over. There is the double linked list, some SVG tools, and the resent multidimensional cell array. The SVG objects use stringobj.fs. The multidimensional cell array is simple to use and allocates memory from heap at construct time. The double linked list allows varying size memory items to be put together in a list that can be used in forward or backward or both directions.
I have decided to keep the constructor simple in these objects meaning if you construct an object and then call the constructor again there will be memory leaking happening. This means simply call the destructor to deallocate memory and then call the constructor again to reuse the object if need be! This strategy means no complex state storage or rules are needed for the constructor or destructor!
I have updated the constructor for the string objects to use the above mentioned simplified constructor and destructor strategy. Code using these string objects should not have any issues though because of this change!
First objects release
At this release is the stringobj.fs object and the original objects.fs gforth code to make it work. I make this a release because i will use this tag from time to time but i also intend to update stringobj.fs.
The update will most likely break current words used in stringobj.fs and i will possibly change objects.fs to the new one included in gforth 0.7.9.
Currently stringobj.fs creates two types of objects string and strings. String is for single string storage and manipulation. Strings is for a dynamically allocated strings storage and manipulation. Note strings use string inside the object and is maintained as a linked list but the object handles all allocation and deallocation of memory.