Thanks, that clarifies a few things in my mind. So then it should be trivial for the engine to remove duplication of identical string literals.
Stuart. On Jun 27, 4:30 am, Stephan Beal <[email protected]> wrote: > On Jun 26, 4:19 am, "[email protected]" > > <[email protected]> wrote: > > Specifically, if I assign identical string literals to many variables, > > do all those variables reference the same string instance? > > > I assume yes and that modification of one of those variable triggers a > > copy (except when the method creates a new string anyway)? > > Strings are immutable in v8, so you can't modify them, making copy-on- > write unnecessary. -- v8-users mailing list [email protected] http://groups.google.com/group/v8-users
