... now you can decide which patch set you like better... :)
https://codereview.chromium.org/490173002/diff/60001/src/ast.h
File src/ast.h (right):
https://codereview.chromium.org/490173002/diff/60001/src/ast.h#newcode197
src/ast.h:197: void set_id(int id) { id_ = id; }
On 2014/08/21 12:21:04, rossberg wrote:
Hm, instead of exposing the internal state like this, can't you have a
copy
constructor for IdGen, and then save and restore the id_gen object as
a whole
where necessary, instead of its internal state?
Sure I can, but it's pretty horrible IMO (see the latest patch set). :)
Also, having a copy ctor and assignment operator public (they should've
been private in my original version) creates an opportunity for bugs
where somebody passes AstNode::IdGens by value which usually doesn't
make sense...
https://codereview.chromium.org/490173002/
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.