[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GLR C++ Variants
From: |
Frank Heckenbach |
Subject: |
Re: GLR C++ Variants |
Date: |
Mon, 13 Jan 2020 19:03:23 +0100 |
Valentin Tolmer wrote:
> I've been mostly changing the glr.c code (copied to glr.cc) to look
> like C++, with classes, methods, and modern containers. Last I
> remember, I hit a snag trying to update an arena-style container with
> internal pointers to std::vector, due to the potentially moving
> memory.
Just a quick idea without knowing details: Might std::deque help
here? It doesn't move on reallocation. OTOH, it doesn't guarantee
contiguous storage in case you need that.
Regards,
Frank