[protobuf] Re: Issue 254 in protobuf: Java: CodedInputStream.readString() creates new String object

2011-02-08 Thread protobuf
Comment #1 on issue 254 by david.yu...@gmail.com: Java: CodedInputStream.readString() creates new String object http://code.google.com/p/protobuf/issues/detail?id=254 This is use-case dependent. Using intern isn't always a good thing. See http://stackoverflow.com/questions/2431540/garbage-c

[protobuf] Re: Issue 254 in protobuf: Java: CodedInputStream.readString() creates new String object

2011-02-08 Thread protobuf
Comment #2 on issue 254 by stefan.o...@gmail.com: Java: CodedInputStream.readString() creates new String object http://code.google.com/p/protobuf/issues/detail?id=254 Ah, I see. Okay, maybe there is an option to implement an "intern()" in the generated "Builder mergeFrom()"-method that I co

[protobuf] Re: Issue 254 in protobuf: Java: CodedInputStream.readString() creates new String object

2011-02-08 Thread protobuf
Updates: Status: WorkingAsIntended Comment #3 on issue 254 by ken...@google.com: Java: CodedInputStream.readString() creates new String object http://code.google.com/p/protobuf/issues/detail?id=254 intern() only works well if you have many different strings with the same values. In