diff --git a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.hex.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.hex.pass.cpp new file mode 100644 --- /dev/null +++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.hex.pass.cpp @@ -0,0 +1,3636 @@ +//===----------------------------------------------------------------------===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +// + +// class num_put + +// iter_type put(iter_type s, ios_base& iob, char_type fill, double v) const; + +// With the Microsoft UCRT, printf("%a", 0.0) produces "0x0.0000000000000p+0" +// while other C runtimes produce just "0x0p+0". +// https://developercommunity.visualstudio.com/t/Printf-formatting-of-float-as-hex-prints/1660844 +// XFAIL: msvc + +// XFAIL: LIBCXX-AIX-FIXME + +#include +#include +#include +#include +#include +#include "test_macros.h" +#include "test_iterators.h" + +typedef std::num_put > F; + +class my_facet + : public F +{ +public: + explicit my_facet(std::size_t refs = 0) + : F(refs) {} +}; + +class my_numpunct + : public std::numpunct +{ +public: + my_numpunct() : std::numpunct() {} + +protected: + virtual char_type do_decimal_point() const {return ';';} + virtual char_type do_thousands_sep() const {return '_';} + virtual std::string do_grouping() const {return std::string("\1\2\3");} +}; + +void test1() +{ + char str[200]; + std::locale lc = std::locale::classic(); + std::locale lg(lc, new my_numpunct); + const my_facet f(1); + { + double v = -0.; + std::ios ios(0); + std::hexfloat(ios); + // %a + { + ios.precision(0); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(1); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(6); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(16); + { + } + ios.precision(60); + { + } + } + } +} + +void test2() +{ + char str[200]; + std::locale lc = std::locale::classic(); + std::locale lg(lc, new my_numpunct); + const my_facet f(1); + { + double v = 1234567890.125; + std::ios ios(0); + std::hexfloat(ios); + // %a + { + ios.precision(0); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(1); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(6); + { + } + ios.precision(16); + { + } + ios.precision(60); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1.26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x1;26580b488p+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x********1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1.26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1.26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1.26580b488p+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x1;26580b488p+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0x1;26580b488p+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0x1;26580b488p+30"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1.26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X1;26580B488P+30********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X********1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1.26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1.26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1.26580B488P+30"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X1;26580B488P+30*******"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*******+0X1;26580B488P+30"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+*******0X1;26580B488P+30"); + assert(ios.width() == 0); + } + } + } + } + } + } + } + } +} + +int main(int, char**) +{ + test1(); + test2(); + + return 0; +} diff --git a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.pass.cpp --- a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.pass.cpp +++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_double.pass.cpp @@ -12,23 +12,7 @@ // iter_type put(iter_type s, ios_base& iob, char_type fill, double v) const; -// FIXME: The printf functions in Microsoft's CRT have a couple quirks in -// corner cases, failing this test: -// - With the Microsoft UCRT, printf("%#.*g", 0, 0.0) produces "0.0" while -// other C runtimes produce "0.". For other precisions than 0, Microsoft's -// consistently produce one digit more than others. In the MinGW test setups, -// the code is built with __USE_MINGW_ANSI_STDIO=1, which uses MinGW's own -// reimplementation of stdio functions, which doesn't have this issue. -// This bug requires excluding everything that runs with showpoint() enabled. -// https://developercommunity.visualstudio.com/t/printf-formatting-with-g-outputs-too/1660837 -// This issue is fixed in newer UCRT versions, since 10.0.19041.0. -// - With the Microsoft UCRT, printf("%a", 0.0) produces "0x0.0000000000000p+0" -// while other C runtimes produce just "0x0p+0". This requires omitting all -// tests of hex float formatting. -// https://developercommunity.visualstudio.com/t/Printf-formatting-of-float-as-hex-prints/1660844 -// XFAIL: msvc - -// XFAIL: LIBCXX-AIX-FIXME +// XFAIL: win32-broken-printf-g-precision #include #include @@ -14306,3584 +14290,6 @@ } } -void test7() -{ - char str[200]; - std::locale lc = std::locale::classic(); - std::locale lg(lc, new my_numpunct); - const my_facet f(1); - { - double v = -0.; - std::ios ios(0); - std::hexfloat(ios); - // %a - { - ios.precision(0); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(1); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(6); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(16); - { - } - ios.precision(60); - { - } - } - } -} - -void test8() -{ - char str[200]; - std::locale lc = std::locale::classic(); - std::locale lg(lc, new my_numpunct); - const my_facet f(1); - { - double v = 1234567890.125; - std::ios ios(0); - std::hexfloat(ios); - // %a - { - ios.precision(0); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(1); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(6); - { - } - ios.precision(16); - { - } - ios.precision(60); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1.26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x1;26580b488p+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x********1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1.26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1.26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1.26580b488p+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x1;26580b488p+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0x1;26580b488p+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0x1;26580b488p+30"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1.26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X1;26580B488P+30********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X********1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1.26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1.26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1.26580B488P+30"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X1;26580B488P+30*******"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*******+0X1;26580B488P+30"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+*******0X1;26580B488P+30"); - assert(ios.width() == 0); - } - } - } - } - } - } - } - } -} - int main(int, char**) { test1(); @@ -17892,8 +14298,6 @@ test4(); test5(); test6(); - test7(); - test8(); return 0; } diff --git a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.hex.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.hex.pass.cpp new file mode 100644 --- /dev/null +++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.hex.pass.cpp @@ -0,0 +1,3642 @@ +//===----------------------------------------------------------------------===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +// + +// class num_put + +// iter_type put(iter_type s, ios_base& iob, char_type fill, long double v) const; + +// With the Microsoft UCRT, printf("%a", 0.0) produces "0x0.0000000000000p+0" +// while other C runtimes produce just "0x0p+0". +// https://developercommunity.visualstudio.com/t/Printf-formatting-of-float-as-hex-prints/1660844 +// XFAIL: msvc + +// XFAIL: LIBCXX-AIX-FIXME + +#include +#include +#include +#include +#include +#include "test_macros.h" +#include "test_iterators.h" + +typedef std::num_put > F; + +class my_facet + : public F +{ +public: + explicit my_facet(std::size_t refs = 0) + : F(refs) {} +}; + +class my_numpunct + : public std::numpunct +{ +public: + my_numpunct() : std::numpunct() {} + +protected: + virtual char_type do_decimal_point() const {return ';';} + virtual char_type do_thousands_sep() const {return '_';} + virtual std::string do_grouping() const {return std::string("\1\2\3");} +}; + +void test1() +{ + char str[200]; + std::locale lc = std::locale::classic(); + std::locale lg(lc, new my_numpunct); + const my_facet f(1); + { + long double v = -0.; + std::ios ios(0); + std::hexfloat(ios); + // %a + { + ios.precision(0); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(1); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(6); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0p+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0x0p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0x0p+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0.p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0.p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0.p+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0x0;p+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0x0;p+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0x0;p+0"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0P+0******************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "******************-0X0P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-******************0X0P+0"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0.P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0.P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0.P+0"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-0X0;P+0*****************"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*****************-0X0;P+0"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "-*****************0X0;P+0"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(16); + { + } + ios.precision(60); + { + } + } + } +} + +void test2() +{ + std::locale lc = std::locale::classic(); + std::locale lg(lc, new my_numpunct); +#if (defined(__APPLE__) || defined(TEST_HAS_GLIBC) || defined(__MINGW32__)) && defined(__x86_64__) +// This test is failing on FreeBSD, possibly due to different representations +// of the floating point numbers. +// This test is failing in MSVC environments, where long double is equal to regular +// double, and instead of "0x9.32c05a44p+27", this prints "0x1.26580b4880000p+30". + const my_facet f(1); + char str[200]; + { + long double v = 1234567890.125; + std::ios ios(0); + std::hexfloat(ios); + // %a + { + ios.precision(0); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.width(0); + ios.imbue(lc); + { + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(1); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + } + } + ios.precision(6); + { + } + ios.precision(16); + { + } + ios.precision(60); + { + std::nouppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9.32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x9;32c05a44p+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0x*********9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9.32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9.32c05a44p+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0x9;32c05a44p+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0x9;32c05a44p+27"); + assert(ios.width() == 0); + } + } + } + } + } + std::uppercase(ios); + { + std::noshowpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9.32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X9;32C05A44P+27*********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "*********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "0X*********9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + std::showpos(ios); + { + std::noshowpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + std::showpoint(ios); + { + ios.imbue(lc); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9.32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9.32C05A44P+27"); + assert(ios.width() == 0); + } + } + ios.imbue(lg); + { + ios.width(0); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::left(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+0X9;32C05A44P+27********"); + assert(ios.width() == 0); + } + ios.width(25); + std::right(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "********+0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + ios.width(25); + std::internal(ios); + { + cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); + std::string ex(str, iter.base()); + assert(ex == "+********0X9;32C05A44P+27"); + assert(ios.width() == 0); + } + } + } + } + } + } + } + } +#endif +} + +int main(int, char**) +{ + test1(); + test2(); + + return 0; +} diff --git a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp --- a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp +++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp @@ -12,22 +12,7 @@ // iter_type put(iter_type s, ios_base& iob, char_type fill, long double v) const; -// FIXME: The printf functions in Microsoft's CRT have a couple quirks in -// corner cases, failing this test: -// - With the Microsoft UCRT, printf("%#.*g", 0, 0.0) produces "0.0" while -// other C runtimes produce "0.". For other precisions than 0, Microsoft's -// consistently produce one digit more than others. In the MinGW test setups, -// the code is built with __USE_MINGW_ANSI_STDIO=1, which uses MinGW's own -// reimplementation of stdio functions, which doesn't have this issue. -// This bug requires excluding everything that runs with showpoint() enabled. -// https://developercommunity.visualstudio.com/t/printf-formatting-with-g-outputs-too/1660837 -// This issue is fixed in newer UCRT versions, since 10.0.19041.0. -// - With the Microsoft UCRT, printf("%a", 0.0) produces "0x0.0000000000000p+0" -// while other C runtimes produce just "0x0p+0". This requires omitting all -// tests of hex float formatting. -// https://developercommunity.visualstudio.com/t/Printf-formatting-of-float-as-hex-prints/1660844 -// XFAIL: msvc - +// XFAIL: win32-broken-printf-g-precision // XFAIL: LIBCXX-AIX-FIXME #include @@ -22632,3588 +22617,6 @@ } } -void test11() -{ - char str[200]; - std::locale lc = std::locale::classic(); - std::locale lg(lc, new my_numpunct); - const my_facet f(1); - { - long double v = -0.; - std::ios ios(0); - std::hexfloat(ios); - // %a - { - ios.precision(0); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(1); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(6); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0p+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0x0p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0x0p+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0.p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0.p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0.p+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0x0;p+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0x0;p+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0x0;p+0"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0P+0******************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "******************-0X0P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-******************0X0P+0"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0.P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0.P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0.P+0"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-0X0;P+0*****************"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*****************-0X0;P+0"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "-*****************0X0;P+0"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(16); - { - } - ios.precision(60); - { - } - } - } -} - -void test12() -{ - std::locale lc = std::locale::classic(); - std::locale lg(lc, new my_numpunct); -#if (defined(__APPLE__) || defined(TEST_HAS_GLIBC) || defined(__MINGW32__)) && defined(__x86_64__) -// This test is failing on FreeBSD, possibly due to different representations -// of the floating point numbers. - const my_facet f(1); - char str[200]; - { - long double v = 1234567890.125; - std::ios ios(0); - std::hexfloat(ios); - // %a - { - ios.precision(0); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.width(0); - ios.imbue(lc); - { - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(1); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - } - } - ios.precision(6); - { - } - ios.precision(16); - { - } - ios.precision(60); - { - std::nouppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9.32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x9;32c05a44p+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0x*********9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9.32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9.32c05a44p+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0x9;32c05a44p+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0x9;32c05a44p+27"); - assert(ios.width() == 0); - } - } - } - } - } - std::uppercase(ios); - { - std::noshowpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9.32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X9;32C05A44P+27*********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "*********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "0X*********9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - std::showpos(ios); - { - std::noshowpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - std::showpoint(ios); - { - ios.imbue(lc); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9.32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9.32C05A44P+27"); - assert(ios.width() == 0); - } - } - ios.imbue(lg); - { - ios.width(0); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::left(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+0X9;32C05A44P+27********"); - assert(ios.width() == 0); - } - ios.width(25); - std::right(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "********+0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - ios.width(25); - std::internal(ios); - { - cpp17_output_iterator iter = f.put(cpp17_output_iterator(str), ios, '*', v); - std::string ex(str, iter.base()); - assert(ex == "+********0X9;32C05A44P+27"); - assert(ios.width() == 0); - } - } - } - } - } - } - } - } -#endif -} - int main(int, char**) { test1(); @@ -26226,8 +22629,6 @@ test8(); test9(); test10(); - test11(); - test12(); std::locale lc = std::locale::classic(); std::locale lg(lc, new my_numpunct); const my_facet f(1); diff --git a/libcxx/utils/libcxx/test/features.py b/libcxx/utils/libcxx/test/features.py --- a/libcxx/utils/libcxx/test/features.py +++ b/libcxx/utils/libcxx/test/features.py @@ -85,6 +85,19 @@ } """)), + # Check for a Windows UCRT bug (fixed in UCRT/Windows 10.0.19041.0). + # https://developercommunity.visualstudio.com/t/printf-formatting-with-g-outputs-too/1660837 + Feature(name='win32-broken-printf-g-precision', + when=lambda cfg: '_WIN32' in compilerMacros(cfg) and not programSucceeds(cfg, """ + #include + #include + int main(int, char**) { + char buf[100]; + snprintf(buf, sizeof(buf), "%#.*g", 0, 0.0); + return strcmp(buf, "0."); + } + """)), + # Whether Bash can run on the executor. # This is not always the case, for example when running on embedded systems. #