I came accross this article and found it to be interesting. Here's it's summary:
The C programming language defines two standard memory management functions: malloc() and free(). C programmers frequently use those functions to allocate buffers at run time to pass data between functions. In many situations, however, you cannot predetermine the actual sizes required for the buffers, which may cause several fundamental problems for constructing complex C programs. In this article, Xiaoming Zhang advocates a self-managing, abstract data buffer. He outlines a pseudo-C implementation of the abstract buffer and details the advantages of adopting this mechanism.
Self-manage data buffer memory in C
Started by Dia, Jan 11 2004 09:48 PM
2 replies to this topic
#1
Posted 11 January 2004 - 09:48 PM
#2
Posted 12 January 2004 - 10:54 AM
The idea was nice but the execution was quite horrible.
Really a C program using that approach would be slower sometimes a lot so compared to an eqvivalent C++ program using std::vector so really it needs quite some work.
Really a C program using that approach would be slower sometimes a lot so compared to an eqvivalent C++ program using std::vector so really it needs quite some work.
#3
Posted 12 January 2004 - 05:22 PM
it's not really complete in it's design. you'd have to extend it's functionality somewhat to make it useful...
If Prolog is the answer, what is the question ?
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












