Navigation Menu

Skip to content

Commit

Permalink
8261301: StringWriter.flush() is NOOP but documentation does not indi…
Browse files Browse the repository at this point in the history
…cate it

Reviewed-by: naoto, rriggs
  • Loading branch information
Brian Burkhalter committed Apr 15, 2021
1 parent 0b1b5c8 commit e89fd15
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/java.base/share/classes/java/io/CharArrayWriter.java
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2019, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -276,6 +276,8 @@ public String toString() {

/**
* Flush the stream.
*
* <p> The {@code flush} method of {@code CharArrayWriter} does nothing.
*/
public void flush() { }

Expand Down
4 changes: 3 additions & 1 deletion src/java.base/share/classes/java/io/StringWriter.java
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -229,6 +229,8 @@ public StringBuffer getBuffer() {

/**
* Flush the stream.
*
* <p> The {@code flush} method of {@code StringWriter} does nothing.
*/
public void flush() {
}
Expand Down

1 comment on commit e89fd15

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.