LGTM

https://codereview.chromium.org/441983002/diff/40001/src/serialize.cc
File src/serialize.cc (right):

https://codereview.chromium.org/441983002/diff/40001/src/serialize.cc#newcode566
src/serialize.cc:566: for (int i = 0; i < refs_.length() - 1; i++)
CHECK(code(i) != code(i + 1));
With a little reordering of the TypeCode enum, you could guarantee
ascending (and, hence, unique) codes in linear time without sorting:

int last_seen = -1;
for(int i = 0; i < refs.length(); i++) {
  CHECK(code(i) > last_seen);
  last_seen = code(i);
}

Just for your consideration, I'm fine with either approach.

https://codereview.chromium.org/441983002/

--
--
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.

Reply via email to