This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: NEW TEST checks whether sync_with_stdio(true) (i.e. default case) works


On Wed, Jan 17, 2001 at 09:43:22PM -0800, Benjamin Kosnik wrote:
> 
> hey loren thanks for the test. I'm going to check it as part of 
> 
> 27_io/ios_base_members_static.cc
> 
> though, is that ok? The testsuite names, although appearing random, 
> actually are named after the standard's section names for the bits they 
> are testing....

At one point during the extended and discontinuous sync_with_stdio
discussion, somebody pointed out that "re-synching," e.g.,

    sync_with_stdio (false);
    ...
    sync_with_stdio (true);

was unsupported.  Well, that's what we're now doing in the
ios_base_members_static test:

    test01()
    {
        s_w_s();
        s_w_s(false);
        ... the tests ...
    }

    test02()
    {
        s_w_s();
        ... the tests ...
    }

Since the current implementation doesn't do anything for the case when the
parameter is true, all the testing code in test02 (Loren's test) is still
running in non-sync'ed mode from the call in test01(), thus defeating the
whole "make certain the default case works" purpose.

I'll reverse the order of the tests unless there's a good reason not to.


Phil

-- 
pedwards at disaster dot jaj dot com  |  pme at sources dot redhat dot com
devphil at several other less interesting addresses in various dot domains
The gods do not protect fools.  Fools are protected by more capable fools.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]