RFR: 6206780 (str) Forwarding append methods in String{Buffer, Builder} are inconsistent (original) (raw)
Chris Hegarty chris.hegarty at oracle.com
Tue Oct 2 08:48:58 UTC 2012
- Previous message: RFR: 6206780 (str) Forwarding append methods in String{Buffer, Builder} are inconsistent
- Next message: RFR: 6206780 (str) Forwarding append methods in String{Buffer, Builder} are inconsistent
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 01/10/12 22:46, Martin Buchholz wrote:
On Mon, Oct 1, 2012 at 2:22 PM, Jim Gish <jim.gish at oracle.com> wrote:
Alan & Chris,
However, let me propose something else. How about /all /the methods in StringBuffer be synchronized? Although this is not strictly necessary, it works because reentrant synchronization is allowed. Reentrant lock acquisition is not free. In core libraries like StringBuffer we should prefer the lesser evil of code duplication to the loss of performance.
I have to agree with Martin here. There may still be some minor clean up that makes sense here, but I believe the existing synchronization and delegation is most appropriate.
-Chris.
- Previous message: RFR: 6206780 (str) Forwarding append methods in String{Buffer, Builder} are inconsistent
- Next message: RFR: 6206780 (str) Forwarding append methods in String{Buffer, Builder} are inconsistent
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]