[8u] RFR: 8072722: add stream support to Scanner

Alex Kashchenko akashche at redhat.com
Tue Jun 2 19:03:52 UTC 2020


Note: the subject is misleading regarding 8u, there are no intentions to 
actually change public API of Scanner in 8u, only internal changes are 

Please review the backport of JDK-8072722 to 8u:

Jira issue: https://bugs.openjdk.java.net/browse/JDK-8072722

RFC thread: 

9 commit: https://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/b997ba72d8d4

8u-dev webrev: https://cr.openjdk.java.net/~akasko/jdk8u/8072722/webrev.00/

Backport depends on JDK-8132206 and JDK-8132745, that apply cleanly to 8u.

Change to Scanner includes only changes to private methods 
findPatternInBuffer and matchPatternInBuffer and their usage. These impl 
changes should allow to do the following Scanner backports more easy. 
New methods for stream support, modCount counter and spec changes are 

Change to ScanTest includes everything except streamCloseTest() and 
streamComodTest() methods.

Testing: checked that ScanTest passes, ran relevant subset of JCK.


More information about the jdk8u-dev mailing list