I am using bison + flex to write a parser now.
For bison and flex, the generated parser and scanner manage their memory with malloc, realloc and free.
But I want to use my own implementation for malloc, realloc and free inside bison + flex.
According to another post:
Being C, the generated parser and scanner manage their memory with
malloc
,realloc
andfree
. They are good enough to expose hooks allowing me to submit my own implementations of these functions.
Where are those hooks and how do I use them?