Changeset bf1cbde for tests


Ignore:
Timestamp:
Oct 5, 2023, 1:50:35 PM (7 months ago)
Author:
Michael Brooks <mlbrooks@…>
Branches:
master
Children:
8cffa4f
Parents:
04db9f6
Message:

Implement "scanset" semantics for manipulator skip, in place of exact-match.

That is, sin | skip("abc") now consumes all input before the "+" on input "cccccb+".

Exact-match semantics is available with just sin | "abc".

(Prior exact-match semantics was discovered by surprise, while debugging a test program for an upcoming commit.)

Location:
tests
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • tests/collections/.in/string-istream-manip.txt

    r04db9f6 rbf1cbde  
    11abc
    2 abc
     2cccccb
    33xx
    44abcxxx
     
    66aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwww
    77abc
    8 abc
     8cccccb
    99xx
    1010abcxxx
  • tests/io/.in/manipulatorsInput.txt

    r04db9f6 rbf1cbde  
    22123456789
    33abc
    4 abc
     4cccccb
    55xx
    66abcxxx
     
    88aaaaaaaaxxxxxxxxaabbccbbdddwwwbbbbbbbbwwwwwwwwaaaaaaaawwwwwwww
    99abc
    10 abc
     10cccccb
    1111xx
    1212abcxxx
  • tests/io/manipulatorsInput.cfa

    r04db9f6 rbf1cbde  
    5252        {
    5353                char s[] = "yyyyyyyyyyyyyyyyyyyy";
    54                 const char sk[] = "abc";
    55                 scanf( "abc " ); scanf( sk ); for ( 5 ) scanf( "%*c" ); printf( "1 %s\n", s );
     54                const char sk_fmt[] = "%*[abc]";
     55                scanf( "abc " ); scanf( sk_fmt ); for ( 5 ) scanf( "%*c" ); printf( "1 %s\n", s );
    5656                scanf( "%s", s );                                                               printf( "2 %s\n", s );
    5757                scanf( "%*s" );                                                                 printf( "3 %s\n", s );
Note: See TracChangeset for help on using the changeset viewer.