1//===----------------------------------------------------------------------===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is dual licensed under the MIT and the University of Illinois Open 6// Source Licenses. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 10// <locale> 11 12// class num_put<charT, OutputIterator> 13 14// iter_type put(iter_type s, ios_base& iob, char_type fill, double v) const; 15 16#include <locale> 17#include <ios> 18#include <cassert> 19#include <streambuf> 20#include <cmath> 21#include "test_iterators.h" 22 23typedef std::num_put<char, output_iterator<char*> > F; 24 25class my_facet 26 : public F 27{ 28public: 29 explicit my_facet(std::size_t refs = 0) 30 : F(refs) {} 31}; 32 33class my_numpunct 34 : public std::numpunct<char> 35{ 36public: 37 my_numpunct() : std::numpunct<char>() {} 38 39protected: 40 virtual char_type do_decimal_point() const {return ';';} 41 virtual char_type do_thousands_sep() const {return '_';} 42 virtual std::string do_grouping() const {return std::string("\1\2\3");} 43}; 44 45void test1() 46{ 47 char str[200]; 48 output_iterator<char*> iter; 49 std::locale lc = std::locale::classic(); 50 std::locale lg(lc, new my_numpunct); 51 const my_facet f(1); 52 { 53 double v = +0.; 54 std::ios ios(0); 55 // %g 56 { 57 ios.precision(0); 58 { 59 nouppercase(ios); 60 { 61 noshowpos(ios); 62 { 63 noshowpoint(ios); 64 { 65 ios.imbue(lc); 66 { 67 ios.width(0); 68 { 69 iter = f.put(output_iterator<char*>(str), ios, '*', v); 70 std::string ex(str, iter.base()); 71 assert(ex == "0"); 72 assert(ios.width() == 0); 73 } 74 ios.width(25); 75 left(ios); 76 { 77 iter = f.put(output_iterator<char*>(str), ios, '*', v); 78 std::string ex(str, iter.base()); 79 assert(ex == "0************************"); 80 assert(ios.width() == 0); 81 } 82 ios.width(25); 83 right(ios); 84 { 85 iter = f.put(output_iterator<char*>(str), ios, '*', v); 86 std::string ex(str, iter.base()); 87 assert(ex == "************************0"); 88 assert(ios.width() == 0); 89 } 90 ios.width(25); 91 internal(ios); 92 { 93 iter = f.put(output_iterator<char*>(str), ios, '*', v); 94 std::string ex(str, iter.base()); 95 assert(ex == "************************0"); 96 assert(ios.width() == 0); 97 } 98 } 99 ios.imbue(lg); 100 { 101 ios.width(0); 102 { 103 iter = f.put(output_iterator<char*>(str), ios, '*', v); 104 std::string ex(str, iter.base()); 105 assert(ex == "0"); 106 assert(ios.width() == 0); 107 } 108 ios.width(25); 109 left(ios); 110 { 111 iter = f.put(output_iterator<char*>(str), ios, '*', v); 112 std::string ex(str, iter.base()); 113 assert(ex == "0************************"); 114 assert(ios.width() == 0); 115 } 116 ios.width(25); 117 right(ios); 118 { 119 iter = f.put(output_iterator<char*>(str), ios, '*', v); 120 std::string ex(str, iter.base()); 121 assert(ex == "************************0"); 122 assert(ios.width() == 0); 123 } 124 ios.width(25); 125 internal(ios); 126 { 127 iter = f.put(output_iterator<char*>(str), ios, '*', v); 128 std::string ex(str, iter.base()); 129 assert(ex == "************************0"); 130 assert(ios.width() == 0); 131 } 132 } 133 } 134 showpoint(ios); 135 { 136 ios.imbue(lc); 137 { 138 ios.width(0); 139 { 140 iter = f.put(output_iterator<char*>(str), ios, '*', v); 141 std::string ex(str, iter.base()); 142 assert(ex == "0."); 143 assert(ios.width() == 0); 144 } 145 ios.width(25); 146 left(ios); 147 { 148 iter = f.put(output_iterator<char*>(str), ios, '*', v); 149 std::string ex(str, iter.base()); 150 assert(ex == "0.***********************"); 151 assert(ios.width() == 0); 152 } 153 ios.width(25); 154 right(ios); 155 { 156 iter = f.put(output_iterator<char*>(str), ios, '*', v); 157 std::string ex(str, iter.base()); 158 assert(ex == "***********************0."); 159 assert(ios.width() == 0); 160 } 161 ios.width(25); 162 internal(ios); 163 { 164 iter = f.put(output_iterator<char*>(str), ios, '*', v); 165 std::string ex(str, iter.base()); 166 assert(ex == "***********************0."); 167 assert(ios.width() == 0); 168 } 169 } 170 ios.imbue(lg); 171 { 172 ios.width(0); 173 { 174 iter = f.put(output_iterator<char*>(str), ios, '*', v); 175 std::string ex(str, iter.base()); 176 assert(ex == "0;"); 177 assert(ios.width() == 0); 178 } 179 ios.width(25); 180 left(ios); 181 { 182 iter = f.put(output_iterator<char*>(str), ios, '*', v); 183 std::string ex(str, iter.base()); 184 assert(ex == "0;***********************"); 185 assert(ios.width() == 0); 186 } 187 ios.width(25); 188 right(ios); 189 { 190 iter = f.put(output_iterator<char*>(str), ios, '*', v); 191 std::string ex(str, iter.base()); 192 assert(ex == "***********************0;"); 193 assert(ios.width() == 0); 194 } 195 ios.width(25); 196 internal(ios); 197 { 198 iter = f.put(output_iterator<char*>(str), ios, '*', v); 199 std::string ex(str, iter.base()); 200 assert(ex == "***********************0;"); 201 assert(ios.width() == 0); 202 } 203 } 204 } 205 } 206 showpos(ios); 207 { 208 noshowpoint(ios); 209 { 210 ios.imbue(lc); 211 { 212 ios.width(0); 213 { 214 iter = f.put(output_iterator<char*>(str), ios, '*', v); 215 std::string ex(str, iter.base()); 216 assert(ex == "+0"); 217 assert(ios.width() == 0); 218 } 219 ios.width(25); 220 left(ios); 221 { 222 iter = f.put(output_iterator<char*>(str), ios, '*', v); 223 std::string ex(str, iter.base()); 224 assert(ex == "+0***********************"); 225 assert(ios.width() == 0); 226 } 227 ios.width(25); 228 right(ios); 229 { 230 iter = f.put(output_iterator<char*>(str), ios, '*', v); 231 std::string ex(str, iter.base()); 232 assert(ex == "***********************+0"); 233 assert(ios.width() == 0); 234 } 235 ios.width(25); 236 internal(ios); 237 { 238 iter = f.put(output_iterator<char*>(str), ios, '*', v); 239 std::string ex(str, iter.base()); 240 assert(ex == "+***********************0"); 241 assert(ios.width() == 0); 242 } 243 } 244 ios.imbue(lg); 245 { 246 ios.width(0); 247 { 248 iter = f.put(output_iterator<char*>(str), ios, '*', v); 249 std::string ex(str, iter.base()); 250 assert(ex == "+0"); 251 assert(ios.width() == 0); 252 } 253 ios.width(25); 254 left(ios); 255 { 256 iter = f.put(output_iterator<char*>(str), ios, '*', v); 257 std::string ex(str, iter.base()); 258 assert(ex == "+0***********************"); 259 assert(ios.width() == 0); 260 } 261 ios.width(25); 262 right(ios); 263 { 264 iter = f.put(output_iterator<char*>(str), ios, '*', v); 265 std::string ex(str, iter.base()); 266 assert(ex == "***********************+0"); 267 assert(ios.width() == 0); 268 } 269 ios.width(25); 270 internal(ios); 271 { 272 iter = f.put(output_iterator<char*>(str), ios, '*', v); 273 std::string ex(str, iter.base()); 274 assert(ex == "+***********************0"); 275 assert(ios.width() == 0); 276 } 277 } 278 } 279 showpoint(ios); 280 { 281 ios.imbue(lc); 282 { 283 ios.width(0); 284 { 285 iter = f.put(output_iterator<char*>(str), ios, '*', v); 286 std::string ex(str, iter.base()); 287 assert(ex == "+0."); 288 assert(ios.width() == 0); 289 } 290 ios.width(25); 291 left(ios); 292 { 293 iter = f.put(output_iterator<char*>(str), ios, '*', v); 294 std::string ex(str, iter.base()); 295 assert(ex == "+0.**********************"); 296 assert(ios.width() == 0); 297 } 298 ios.width(25); 299 right(ios); 300 { 301 iter = f.put(output_iterator<char*>(str), ios, '*', v); 302 std::string ex(str, iter.base()); 303 assert(ex == "**********************+0."); 304 assert(ios.width() == 0); 305 } 306 ios.width(25); 307 internal(ios); 308 { 309 iter = f.put(output_iterator<char*>(str), ios, '*', v); 310 std::string ex(str, iter.base()); 311 assert(ex == "+**********************0."); 312 assert(ios.width() == 0); 313 } 314 } 315 ios.imbue(lg); 316 { 317 ios.width(0); 318 { 319 iter = f.put(output_iterator<char*>(str), ios, '*', v); 320 std::string ex(str, iter.base()); 321 assert(ex == "+0;"); 322 assert(ios.width() == 0); 323 } 324 ios.width(25); 325 left(ios); 326 { 327 iter = f.put(output_iterator<char*>(str), ios, '*', v); 328 std::string ex(str, iter.base()); 329 assert(ex == "+0;**********************"); 330 assert(ios.width() == 0); 331 } 332 ios.width(25); 333 right(ios); 334 { 335 iter = f.put(output_iterator<char*>(str), ios, '*', v); 336 std::string ex(str, iter.base()); 337 assert(ex == "**********************+0;"); 338 assert(ios.width() == 0); 339 } 340 ios.width(25); 341 internal(ios); 342 { 343 iter = f.put(output_iterator<char*>(str), ios, '*', v); 344 std::string ex(str, iter.base()); 345 assert(ex == "+**********************0;"); 346 assert(ios.width() == 0); 347 } 348 } 349 } 350 } 351 } 352 uppercase(ios); 353 { 354 noshowpos(ios); 355 { 356 noshowpoint(ios); 357 { 358 ios.imbue(lc); 359 { 360 ios.width(0); 361 { 362 iter = f.put(output_iterator<char*>(str), ios, '*', v); 363 std::string ex(str, iter.base()); 364 assert(ex == "0"); 365 assert(ios.width() == 0); 366 } 367 ios.width(25); 368 left(ios); 369 { 370 iter = f.put(output_iterator<char*>(str), ios, '*', v); 371 std::string ex(str, iter.base()); 372 assert(ex == "0************************"); 373 assert(ios.width() == 0); 374 } 375 ios.width(25); 376 right(ios); 377 { 378 iter = f.put(output_iterator<char*>(str), ios, '*', v); 379 std::string ex(str, iter.base()); 380 assert(ex == "************************0"); 381 assert(ios.width() == 0); 382 } 383 ios.width(25); 384 internal(ios); 385 { 386 iter = f.put(output_iterator<char*>(str), ios, '*', v); 387 std::string ex(str, iter.base()); 388 assert(ex == "************************0"); 389 assert(ios.width() == 0); 390 } 391 } 392 ios.imbue(lg); 393 { 394 ios.width(0); 395 { 396 iter = f.put(output_iterator<char*>(str), ios, '*', v); 397 std::string ex(str, iter.base()); 398 assert(ex == "0"); 399 assert(ios.width() == 0); 400 } 401 ios.width(25); 402 left(ios); 403 { 404 iter = f.put(output_iterator<char*>(str), ios, '*', v); 405 std::string ex(str, iter.base()); 406 assert(ex == "0************************"); 407 assert(ios.width() == 0); 408 } 409 ios.width(25); 410 right(ios); 411 { 412 iter = f.put(output_iterator<char*>(str), ios, '*', v); 413 std::string ex(str, iter.base()); 414 assert(ex == "************************0"); 415 assert(ios.width() == 0); 416 } 417 ios.width(25); 418 internal(ios); 419 { 420 iter = f.put(output_iterator<char*>(str), ios, '*', v); 421 std::string ex(str, iter.base()); 422 assert(ex == "************************0"); 423 assert(ios.width() == 0); 424 } 425 } 426 } 427 showpoint(ios); 428 { 429 ios.imbue(lc); 430 { 431 ios.width(0); 432 { 433 iter = f.put(output_iterator<char*>(str), ios, '*', v); 434 std::string ex(str, iter.base()); 435 assert(ex == "0."); 436 assert(ios.width() == 0); 437 } 438 ios.width(25); 439 left(ios); 440 { 441 iter = f.put(output_iterator<char*>(str), ios, '*', v); 442 std::string ex(str, iter.base()); 443 assert(ex == "0.***********************"); 444 assert(ios.width() == 0); 445 } 446 ios.width(25); 447 right(ios); 448 { 449 iter = f.put(output_iterator<char*>(str), ios, '*', v); 450 std::string ex(str, iter.base()); 451 assert(ex == "***********************0."); 452 assert(ios.width() == 0); 453 } 454 ios.width(25); 455 internal(ios); 456 { 457 iter = f.put(output_iterator<char*>(str), ios, '*', v); 458 std::string ex(str, iter.base()); 459 assert(ex == "***********************0."); 460 assert(ios.width() == 0); 461 } 462 } 463 ios.imbue(lg); 464 { 465 ios.width(0); 466 { 467 iter = f.put(output_iterator<char*>(str), ios, '*', v); 468 std::string ex(str, iter.base()); 469 assert(ex == "0;"); 470 assert(ios.width() == 0); 471 } 472 ios.width(25); 473 left(ios); 474 { 475 iter = f.put(output_iterator<char*>(str), ios, '*', v); 476 std::string ex(str, iter.base()); 477 assert(ex == "0;***********************"); 478 assert(ios.width() == 0); 479 } 480 ios.width(25); 481 right(ios); 482 { 483 iter = f.put(output_iterator<char*>(str), ios, '*', v); 484 std::string ex(str, iter.base()); 485 assert(ex == "***********************0;"); 486 assert(ios.width() == 0); 487 } 488 ios.width(25); 489 internal(ios); 490 { 491 iter = f.put(output_iterator<char*>(str), ios, '*', v); 492 std::string ex(str, iter.base()); 493 assert(ex == "***********************0;"); 494 assert(ios.width() == 0); 495 } 496 } 497 } 498 } 499 showpos(ios); 500 { 501 noshowpoint(ios); 502 { 503 ios.imbue(lc); 504 { 505 ios.width(0); 506 { 507 iter = f.put(output_iterator<char*>(str), ios, '*', v); 508 std::string ex(str, iter.base()); 509 assert(ex == "+0"); 510 assert(ios.width() == 0); 511 } 512 ios.width(25); 513 left(ios); 514 { 515 iter = f.put(output_iterator<char*>(str), ios, '*', v); 516 std::string ex(str, iter.base()); 517 assert(ex == "+0***********************"); 518 assert(ios.width() == 0); 519 } 520 ios.width(25); 521 right(ios); 522 { 523 iter = f.put(output_iterator<char*>(str), ios, '*', v); 524 std::string ex(str, iter.base()); 525 assert(ex == "***********************+0"); 526 assert(ios.width() == 0); 527 } 528 ios.width(25); 529 internal(ios); 530 { 531 iter = f.put(output_iterator<char*>(str), ios, '*', v); 532 std::string ex(str, iter.base()); 533 assert(ex == "+***********************0"); 534 assert(ios.width() == 0); 535 } 536 } 537 ios.imbue(lg); 538 { 539 ios.width(0); 540 { 541 iter = f.put(output_iterator<char*>(str), ios, '*', v); 542 std::string ex(str, iter.base()); 543 assert(ex == "+0"); 544 assert(ios.width() == 0); 545 } 546 ios.width(25); 547 left(ios); 548 { 549 iter = f.put(output_iterator<char*>(str), ios, '*', v); 550 std::string ex(str, iter.base()); 551 assert(ex == "+0***********************"); 552 assert(ios.width() == 0); 553 } 554 ios.width(25); 555 right(ios); 556 { 557 iter = f.put(output_iterator<char*>(str), ios, '*', v); 558 std::string ex(str, iter.base()); 559 assert(ex == "***********************+0"); 560 assert(ios.width() == 0); 561 } 562 ios.width(25); 563 internal(ios); 564 { 565 iter = f.put(output_iterator<char*>(str), ios, '*', v); 566 std::string ex(str, iter.base()); 567 assert(ex == "+***********************0"); 568 assert(ios.width() == 0); 569 } 570 } 571 } 572 showpoint(ios); 573 { 574 ios.imbue(lc); 575 { 576 ios.width(0); 577 { 578 iter = f.put(output_iterator<char*>(str), ios, '*', v); 579 std::string ex(str, iter.base()); 580 assert(ex == "+0."); 581 assert(ios.width() == 0); 582 } 583 ios.width(25); 584 left(ios); 585 { 586 iter = f.put(output_iterator<char*>(str), ios, '*', v); 587 std::string ex(str, iter.base()); 588 assert(ex == "+0.**********************"); 589 assert(ios.width() == 0); 590 } 591 ios.width(25); 592 right(ios); 593 { 594 iter = f.put(output_iterator<char*>(str), ios, '*', v); 595 std::string ex(str, iter.base()); 596 assert(ex == "**********************+0."); 597 assert(ios.width() == 0); 598 } 599 ios.width(25); 600 internal(ios); 601 { 602 iter = f.put(output_iterator<char*>(str), ios, '*', v); 603 std::string ex(str, iter.base()); 604 assert(ex == "+**********************0."); 605 assert(ios.width() == 0); 606 } 607 } 608 ios.imbue(lg); 609 { 610 ios.width(0); 611 { 612 iter = f.put(output_iterator<char*>(str), ios, '*', v); 613 std::string ex(str, iter.base()); 614 assert(ex == "+0;"); 615 assert(ios.width() == 0); 616 } 617 ios.width(25); 618 left(ios); 619 { 620 iter = f.put(output_iterator<char*>(str), ios, '*', v); 621 std::string ex(str, iter.base()); 622 assert(ex == "+0;**********************"); 623 assert(ios.width() == 0); 624 } 625 ios.width(25); 626 right(ios); 627 { 628 iter = f.put(output_iterator<char*>(str), ios, '*', v); 629 std::string ex(str, iter.base()); 630 assert(ex == "**********************+0;"); 631 assert(ios.width() == 0); 632 } 633 ios.width(25); 634 internal(ios); 635 { 636 iter = f.put(output_iterator<char*>(str), ios, '*', v); 637 std::string ex(str, iter.base()); 638 assert(ex == "+**********************0;"); 639 assert(ios.width() == 0); 640 } 641 } 642 } 643 } 644 } 645 } 646 ios.precision(1); 647 { 648 nouppercase(ios); 649 { 650 noshowpos(ios); 651 { 652 noshowpoint(ios); 653 { 654 ios.imbue(lc); 655 { 656 ios.width(0); 657 { 658 iter = f.put(output_iterator<char*>(str), ios, '*', v); 659 std::string ex(str, iter.base()); 660 assert(ex == "0"); 661 assert(ios.width() == 0); 662 } 663 ios.width(25); 664 left(ios); 665 { 666 iter = f.put(output_iterator<char*>(str), ios, '*', v); 667 std::string ex(str, iter.base()); 668 assert(ex == "0************************"); 669 assert(ios.width() == 0); 670 } 671 ios.width(25); 672 right(ios); 673 { 674 iter = f.put(output_iterator<char*>(str), ios, '*', v); 675 std::string ex(str, iter.base()); 676 assert(ex == "************************0"); 677 assert(ios.width() == 0); 678 } 679 ios.width(25); 680 internal(ios); 681 { 682 iter = f.put(output_iterator<char*>(str), ios, '*', v); 683 std::string ex(str, iter.base()); 684 assert(ex == "************************0"); 685 assert(ios.width() == 0); 686 } 687 } 688 ios.imbue(lg); 689 { 690 ios.width(0); 691 { 692 iter = f.put(output_iterator<char*>(str), ios, '*', v); 693 std::string ex(str, iter.base()); 694 assert(ex == "0"); 695 assert(ios.width() == 0); 696 } 697 ios.width(25); 698 left(ios); 699 { 700 iter = f.put(output_iterator<char*>(str), ios, '*', v); 701 std::string ex(str, iter.base()); 702 assert(ex == "0************************"); 703 assert(ios.width() == 0); 704 } 705 ios.width(25); 706 right(ios); 707 { 708 iter = f.put(output_iterator<char*>(str), ios, '*', v); 709 std::string ex(str, iter.base()); 710 assert(ex == "************************0"); 711 assert(ios.width() == 0); 712 } 713 ios.width(25); 714 internal(ios); 715 { 716 iter = f.put(output_iterator<char*>(str), ios, '*', v); 717 std::string ex(str, iter.base()); 718 assert(ex == "************************0"); 719 assert(ios.width() == 0); 720 } 721 } 722 } 723 showpoint(ios); 724 { 725 ios.imbue(lc); 726 { 727 ios.width(0); 728 { 729 iter = f.put(output_iterator<char*>(str), ios, '*', v); 730 std::string ex(str, iter.base()); 731 assert(ex == "0."); 732 assert(ios.width() == 0); 733 } 734 ios.width(25); 735 left(ios); 736 { 737 iter = f.put(output_iterator<char*>(str), ios, '*', v); 738 std::string ex(str, iter.base()); 739 assert(ex == "0.***********************"); 740 assert(ios.width() == 0); 741 } 742 ios.width(25); 743 right(ios); 744 { 745 iter = f.put(output_iterator<char*>(str), ios, '*', v); 746 std::string ex(str, iter.base()); 747 assert(ex == "***********************0."); 748 assert(ios.width() == 0); 749 } 750 ios.width(25); 751 internal(ios); 752 { 753 iter = f.put(output_iterator<char*>(str), ios, '*', v); 754 std::string ex(str, iter.base()); 755 assert(ex == "***********************0."); 756 assert(ios.width() == 0); 757 } 758 } 759 ios.imbue(lg); 760 { 761 ios.width(0); 762 { 763 iter = f.put(output_iterator<char*>(str), ios, '*', v); 764 std::string ex(str, iter.base()); 765 assert(ex == "0;"); 766 assert(ios.width() == 0); 767 } 768 ios.width(25); 769 left(ios); 770 { 771 iter = f.put(output_iterator<char*>(str), ios, '*', v); 772 std::string ex(str, iter.base()); 773 assert(ex == "0;***********************"); 774 assert(ios.width() == 0); 775 } 776 ios.width(25); 777 right(ios); 778 { 779 iter = f.put(output_iterator<char*>(str), ios, '*', v); 780 std::string ex(str, iter.base()); 781 assert(ex == "***********************0;"); 782 assert(ios.width() == 0); 783 } 784 ios.width(25); 785 internal(ios); 786 { 787 iter = f.put(output_iterator<char*>(str), ios, '*', v); 788 std::string ex(str, iter.base()); 789 assert(ex == "***********************0;"); 790 assert(ios.width() == 0); 791 } 792 } 793 } 794 } 795 showpos(ios); 796 { 797 noshowpoint(ios); 798 { 799 ios.imbue(lc); 800 { 801 ios.width(0); 802 { 803 iter = f.put(output_iterator<char*>(str), ios, '*', v); 804 std::string ex(str, iter.base()); 805 assert(ex == "+0"); 806 assert(ios.width() == 0); 807 } 808 ios.width(25); 809 left(ios); 810 { 811 iter = f.put(output_iterator<char*>(str), ios, '*', v); 812 std::string ex(str, iter.base()); 813 assert(ex == "+0***********************"); 814 assert(ios.width() == 0); 815 } 816 ios.width(25); 817 right(ios); 818 { 819 iter = f.put(output_iterator<char*>(str), ios, '*', v); 820 std::string ex(str, iter.base()); 821 assert(ex == "***********************+0"); 822 assert(ios.width() == 0); 823 } 824 ios.width(25); 825 internal(ios); 826 { 827 iter = f.put(output_iterator<char*>(str), ios, '*', v); 828 std::string ex(str, iter.base()); 829 assert(ex == "+***********************0"); 830 assert(ios.width() == 0); 831 } 832 } 833 ios.imbue(lg); 834 { 835 ios.width(0); 836 { 837 iter = f.put(output_iterator<char*>(str), ios, '*', v); 838 std::string ex(str, iter.base()); 839 assert(ex == "+0"); 840 assert(ios.width() == 0); 841 } 842 ios.width(25); 843 left(ios); 844 { 845 iter = f.put(output_iterator<char*>(str), ios, '*', v); 846 std::string ex(str, iter.base()); 847 assert(ex == "+0***********************"); 848 assert(ios.width() == 0); 849 } 850 ios.width(25); 851 right(ios); 852 { 853 iter = f.put(output_iterator<char*>(str), ios, '*', v); 854 std::string ex(str, iter.base()); 855 assert(ex == "***********************+0"); 856 assert(ios.width() == 0); 857 } 858 ios.width(25); 859 internal(ios); 860 { 861 iter = f.put(output_iterator<char*>(str), ios, '*', v); 862 std::string ex(str, iter.base()); 863 assert(ex == "+***********************0"); 864 assert(ios.width() == 0); 865 } 866 } 867 } 868 showpoint(ios); 869 { 870 ios.imbue(lc); 871 { 872 ios.width(0); 873 { 874 iter = f.put(output_iterator<char*>(str), ios, '*', v); 875 std::string ex(str, iter.base()); 876 assert(ex == "+0."); 877 assert(ios.width() == 0); 878 } 879 ios.width(25); 880 left(ios); 881 { 882 iter = f.put(output_iterator<char*>(str), ios, '*', v); 883 std::string ex(str, iter.base()); 884 assert(ex == "+0.**********************"); 885 assert(ios.width() == 0); 886 } 887 ios.width(25); 888 right(ios); 889 { 890 iter = f.put(output_iterator<char*>(str), ios, '*', v); 891 std::string ex(str, iter.base()); 892 assert(ex == "**********************+0."); 893 assert(ios.width() == 0); 894 } 895 ios.width(25); 896 internal(ios); 897 { 898 iter = f.put(output_iterator<char*>(str), ios, '*', v); 899 std::string ex(str, iter.base()); 900 assert(ex == "+**********************0."); 901 assert(ios.width() == 0); 902 } 903 } 904 ios.imbue(lg); 905 { 906 ios.width(0); 907 { 908 iter = f.put(output_iterator<char*>(str), ios, '*', v); 909 std::string ex(str, iter.base()); 910 assert(ex == "+0;"); 911 assert(ios.width() == 0); 912 } 913 ios.width(25); 914 left(ios); 915 { 916 iter = f.put(output_iterator<char*>(str), ios, '*', v); 917 std::string ex(str, iter.base()); 918 assert(ex == "+0;**********************"); 919 assert(ios.width() == 0); 920 } 921 ios.width(25); 922 right(ios); 923 { 924 iter = f.put(output_iterator<char*>(str), ios, '*', v); 925 std::string ex(str, iter.base()); 926 assert(ex == "**********************+0;"); 927 assert(ios.width() == 0); 928 } 929 ios.width(25); 930 internal(ios); 931 { 932 iter = f.put(output_iterator<char*>(str), ios, '*', v); 933 std::string ex(str, iter.base()); 934 assert(ex == "+**********************0;"); 935 assert(ios.width() == 0); 936 } 937 } 938 } 939 } 940 } 941 uppercase(ios); 942 { 943 noshowpos(ios); 944 { 945 noshowpoint(ios); 946 { 947 ios.imbue(lc); 948 { 949 ios.width(0); 950 { 951 iter = f.put(output_iterator<char*>(str), ios, '*', v); 952 std::string ex(str, iter.base()); 953 assert(ex == "0"); 954 assert(ios.width() == 0); 955 } 956 ios.width(25); 957 left(ios); 958 { 959 iter = f.put(output_iterator<char*>(str), ios, '*', v); 960 std::string ex(str, iter.base()); 961 assert(ex == "0************************"); 962 assert(ios.width() == 0); 963 } 964 ios.width(25); 965 right(ios); 966 { 967 iter = f.put(output_iterator<char*>(str), ios, '*', v); 968 std::string ex(str, iter.base()); 969 assert(ex == "************************0"); 970 assert(ios.width() == 0); 971 } 972 ios.width(25); 973 internal(ios); 974 { 975 iter = f.put(output_iterator<char*>(str), ios, '*', v); 976 std::string ex(str, iter.base()); 977 assert(ex == "************************0"); 978 assert(ios.width() == 0); 979 } 980 } 981 ios.imbue(lg); 982 { 983 ios.width(0); 984 { 985 iter = f.put(output_iterator<char*>(str), ios, '*', v); 986 std::string ex(str, iter.base()); 987 assert(ex == "0"); 988 assert(ios.width() == 0); 989 } 990 ios.width(25); 991 left(ios); 992 { 993 iter = f.put(output_iterator<char*>(str), ios, '*', v); 994 std::string ex(str, iter.base()); 995 assert(ex == "0************************"); 996 assert(ios.width() == 0); 997 } 998 ios.width(25); 999 right(ios); 1000 { 1001 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1002 std::string ex(str, iter.base()); 1003 assert(ex == "************************0"); 1004 assert(ios.width() == 0); 1005 } 1006 ios.width(25); 1007 internal(ios); 1008 { 1009 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1010 std::string ex(str, iter.base()); 1011 assert(ex == "************************0"); 1012 assert(ios.width() == 0); 1013 } 1014 } 1015 } 1016 showpoint(ios); 1017 { 1018 ios.imbue(lc); 1019 { 1020 ios.width(0); 1021 { 1022 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1023 std::string ex(str, iter.base()); 1024 assert(ex == "0."); 1025 assert(ios.width() == 0); 1026 } 1027 ios.width(25); 1028 left(ios); 1029 { 1030 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1031 std::string ex(str, iter.base()); 1032 assert(ex == "0.***********************"); 1033 assert(ios.width() == 0); 1034 } 1035 ios.width(25); 1036 right(ios); 1037 { 1038 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1039 std::string ex(str, iter.base()); 1040 assert(ex == "***********************0."); 1041 assert(ios.width() == 0); 1042 } 1043 ios.width(25); 1044 internal(ios); 1045 { 1046 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1047 std::string ex(str, iter.base()); 1048 assert(ex == "***********************0."); 1049 assert(ios.width() == 0); 1050 } 1051 } 1052 ios.imbue(lg); 1053 { 1054 ios.width(0); 1055 { 1056 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1057 std::string ex(str, iter.base()); 1058 assert(ex == "0;"); 1059 assert(ios.width() == 0); 1060 } 1061 ios.width(25); 1062 left(ios); 1063 { 1064 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1065 std::string ex(str, iter.base()); 1066 assert(ex == "0;***********************"); 1067 assert(ios.width() == 0); 1068 } 1069 ios.width(25); 1070 right(ios); 1071 { 1072 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1073 std::string ex(str, iter.base()); 1074 assert(ex == "***********************0;"); 1075 assert(ios.width() == 0); 1076 } 1077 ios.width(25); 1078 internal(ios); 1079 { 1080 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1081 std::string ex(str, iter.base()); 1082 assert(ex == "***********************0;"); 1083 assert(ios.width() == 0); 1084 } 1085 } 1086 } 1087 } 1088 showpos(ios); 1089 { 1090 noshowpoint(ios); 1091 { 1092 ios.imbue(lc); 1093 { 1094 ios.width(0); 1095 { 1096 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1097 std::string ex(str, iter.base()); 1098 assert(ex == "+0"); 1099 assert(ios.width() == 0); 1100 } 1101 ios.width(25); 1102 left(ios); 1103 { 1104 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1105 std::string ex(str, iter.base()); 1106 assert(ex == "+0***********************"); 1107 assert(ios.width() == 0); 1108 } 1109 ios.width(25); 1110 right(ios); 1111 { 1112 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1113 std::string ex(str, iter.base()); 1114 assert(ex == "***********************+0"); 1115 assert(ios.width() == 0); 1116 } 1117 ios.width(25); 1118 internal(ios); 1119 { 1120 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1121 std::string ex(str, iter.base()); 1122 assert(ex == "+***********************0"); 1123 assert(ios.width() == 0); 1124 } 1125 } 1126 ios.imbue(lg); 1127 { 1128 ios.width(0); 1129 { 1130 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1131 std::string ex(str, iter.base()); 1132 assert(ex == "+0"); 1133 assert(ios.width() == 0); 1134 } 1135 ios.width(25); 1136 left(ios); 1137 { 1138 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1139 std::string ex(str, iter.base()); 1140 assert(ex == "+0***********************"); 1141 assert(ios.width() == 0); 1142 } 1143 ios.width(25); 1144 right(ios); 1145 { 1146 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1147 std::string ex(str, iter.base()); 1148 assert(ex == "***********************+0"); 1149 assert(ios.width() == 0); 1150 } 1151 ios.width(25); 1152 internal(ios); 1153 { 1154 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1155 std::string ex(str, iter.base()); 1156 assert(ex == "+***********************0"); 1157 assert(ios.width() == 0); 1158 } 1159 } 1160 } 1161 showpoint(ios); 1162 { 1163 ios.imbue(lc); 1164 { 1165 ios.width(0); 1166 { 1167 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1168 std::string ex(str, iter.base()); 1169 assert(ex == "+0."); 1170 assert(ios.width() == 0); 1171 } 1172 ios.width(25); 1173 left(ios); 1174 { 1175 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1176 std::string ex(str, iter.base()); 1177 assert(ex == "+0.**********************"); 1178 assert(ios.width() == 0); 1179 } 1180 ios.width(25); 1181 right(ios); 1182 { 1183 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1184 std::string ex(str, iter.base()); 1185 assert(ex == "**********************+0."); 1186 assert(ios.width() == 0); 1187 } 1188 ios.width(25); 1189 internal(ios); 1190 { 1191 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1192 std::string ex(str, iter.base()); 1193 assert(ex == "+**********************0."); 1194 assert(ios.width() == 0); 1195 } 1196 } 1197 ios.imbue(lg); 1198 { 1199 ios.width(0); 1200 { 1201 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1202 std::string ex(str, iter.base()); 1203 assert(ex == "+0;"); 1204 assert(ios.width() == 0); 1205 } 1206 ios.width(25); 1207 left(ios); 1208 { 1209 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1210 std::string ex(str, iter.base()); 1211 assert(ex == "+0;**********************"); 1212 assert(ios.width() == 0); 1213 } 1214 ios.width(25); 1215 right(ios); 1216 { 1217 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1218 std::string ex(str, iter.base()); 1219 assert(ex == "**********************+0;"); 1220 assert(ios.width() == 0); 1221 } 1222 ios.width(25); 1223 internal(ios); 1224 { 1225 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1226 std::string ex(str, iter.base()); 1227 assert(ex == "+**********************0;"); 1228 assert(ios.width() == 0); 1229 } 1230 } 1231 } 1232 } 1233 } 1234 } 1235 ios.precision(6); 1236 { 1237 nouppercase(ios); 1238 { 1239 noshowpos(ios); 1240 { 1241 noshowpoint(ios); 1242 { 1243 ios.imbue(lc); 1244 { 1245 ios.width(0); 1246 { 1247 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1248 std::string ex(str, iter.base()); 1249 assert(ex == "0"); 1250 assert(ios.width() == 0); 1251 } 1252 ios.width(25); 1253 left(ios); 1254 { 1255 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1256 std::string ex(str, iter.base()); 1257 assert(ex == "0************************"); 1258 assert(ios.width() == 0); 1259 } 1260 ios.width(25); 1261 right(ios); 1262 { 1263 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1264 std::string ex(str, iter.base()); 1265 assert(ex == "************************0"); 1266 assert(ios.width() == 0); 1267 } 1268 ios.width(25); 1269 internal(ios); 1270 { 1271 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1272 std::string ex(str, iter.base()); 1273 assert(ex == "************************0"); 1274 assert(ios.width() == 0); 1275 } 1276 } 1277 ios.imbue(lg); 1278 { 1279 ios.width(0); 1280 { 1281 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1282 std::string ex(str, iter.base()); 1283 assert(ex == "0"); 1284 assert(ios.width() == 0); 1285 } 1286 ios.width(25); 1287 left(ios); 1288 { 1289 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1290 std::string ex(str, iter.base()); 1291 assert(ex == "0************************"); 1292 assert(ios.width() == 0); 1293 } 1294 ios.width(25); 1295 right(ios); 1296 { 1297 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1298 std::string ex(str, iter.base()); 1299 assert(ex == "************************0"); 1300 assert(ios.width() == 0); 1301 } 1302 ios.width(25); 1303 internal(ios); 1304 { 1305 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1306 std::string ex(str, iter.base()); 1307 assert(ex == "************************0"); 1308 assert(ios.width() == 0); 1309 } 1310 } 1311 } 1312 showpoint(ios); 1313 { 1314 ios.imbue(lc); 1315 { 1316 ios.width(0); 1317 { 1318 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1319 std::string ex(str, iter.base()); 1320 assert(ex == "0.00000"); 1321 assert(ios.width() == 0); 1322 } 1323 ios.width(25); 1324 left(ios); 1325 { 1326 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1327 std::string ex(str, iter.base()); 1328 assert(ex == "0.00000******************"); 1329 assert(ios.width() == 0); 1330 } 1331 ios.width(25); 1332 right(ios); 1333 { 1334 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1335 std::string ex(str, iter.base()); 1336 assert(ex == "******************0.00000"); 1337 assert(ios.width() == 0); 1338 } 1339 ios.width(25); 1340 internal(ios); 1341 { 1342 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1343 std::string ex(str, iter.base()); 1344 assert(ex == "******************0.00000"); 1345 assert(ios.width() == 0); 1346 } 1347 } 1348 ios.imbue(lg); 1349 { 1350 ios.width(0); 1351 { 1352 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1353 std::string ex(str, iter.base()); 1354 assert(ex == "0;00000"); 1355 assert(ios.width() == 0); 1356 } 1357 ios.width(25); 1358 left(ios); 1359 { 1360 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1361 std::string ex(str, iter.base()); 1362 assert(ex == "0;00000******************"); 1363 assert(ios.width() == 0); 1364 } 1365 ios.width(25); 1366 right(ios); 1367 { 1368 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1369 std::string ex(str, iter.base()); 1370 assert(ex == "******************0;00000"); 1371 assert(ios.width() == 0); 1372 } 1373 ios.width(25); 1374 internal(ios); 1375 { 1376 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1377 std::string ex(str, iter.base()); 1378 assert(ex == "******************0;00000"); 1379 assert(ios.width() == 0); 1380 } 1381 } 1382 } 1383 } 1384 showpos(ios); 1385 { 1386 noshowpoint(ios); 1387 { 1388 ios.imbue(lc); 1389 { 1390 ios.width(0); 1391 { 1392 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1393 std::string ex(str, iter.base()); 1394 assert(ex == "+0"); 1395 assert(ios.width() == 0); 1396 } 1397 ios.width(25); 1398 left(ios); 1399 { 1400 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1401 std::string ex(str, iter.base()); 1402 assert(ex == "+0***********************"); 1403 assert(ios.width() == 0); 1404 } 1405 ios.width(25); 1406 right(ios); 1407 { 1408 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1409 std::string ex(str, iter.base()); 1410 assert(ex == "***********************+0"); 1411 assert(ios.width() == 0); 1412 } 1413 ios.width(25); 1414 internal(ios); 1415 { 1416 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1417 std::string ex(str, iter.base()); 1418 assert(ex == "+***********************0"); 1419 assert(ios.width() == 0); 1420 } 1421 } 1422 ios.imbue(lg); 1423 { 1424 ios.width(0); 1425 { 1426 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1427 std::string ex(str, iter.base()); 1428 assert(ex == "+0"); 1429 assert(ios.width() == 0); 1430 } 1431 ios.width(25); 1432 left(ios); 1433 { 1434 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1435 std::string ex(str, iter.base()); 1436 assert(ex == "+0***********************"); 1437 assert(ios.width() == 0); 1438 } 1439 ios.width(25); 1440 right(ios); 1441 { 1442 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1443 std::string ex(str, iter.base()); 1444 assert(ex == "***********************+0"); 1445 assert(ios.width() == 0); 1446 } 1447 ios.width(25); 1448 internal(ios); 1449 { 1450 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1451 std::string ex(str, iter.base()); 1452 assert(ex == "+***********************0"); 1453 assert(ios.width() == 0); 1454 } 1455 } 1456 } 1457 showpoint(ios); 1458 { 1459 ios.imbue(lc); 1460 { 1461 ios.width(0); 1462 { 1463 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1464 std::string ex(str, iter.base()); 1465 assert(ex == "+0.00000"); 1466 assert(ios.width() == 0); 1467 } 1468 ios.width(25); 1469 left(ios); 1470 { 1471 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1472 std::string ex(str, iter.base()); 1473 assert(ex == "+0.00000*****************"); 1474 assert(ios.width() == 0); 1475 } 1476 ios.width(25); 1477 right(ios); 1478 { 1479 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1480 std::string ex(str, iter.base()); 1481 assert(ex == "*****************+0.00000"); 1482 assert(ios.width() == 0); 1483 } 1484 ios.width(25); 1485 internal(ios); 1486 { 1487 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1488 std::string ex(str, iter.base()); 1489 assert(ex == "+*****************0.00000"); 1490 assert(ios.width() == 0); 1491 } 1492 } 1493 ios.imbue(lg); 1494 { 1495 ios.width(0); 1496 { 1497 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1498 std::string ex(str, iter.base()); 1499 assert(ex == "+0;00000"); 1500 assert(ios.width() == 0); 1501 } 1502 ios.width(25); 1503 left(ios); 1504 { 1505 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1506 std::string ex(str, iter.base()); 1507 assert(ex == "+0;00000*****************"); 1508 assert(ios.width() == 0); 1509 } 1510 ios.width(25); 1511 right(ios); 1512 { 1513 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1514 std::string ex(str, iter.base()); 1515 assert(ex == "*****************+0;00000"); 1516 assert(ios.width() == 0); 1517 } 1518 ios.width(25); 1519 internal(ios); 1520 { 1521 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1522 std::string ex(str, iter.base()); 1523 assert(ex == "+*****************0;00000"); 1524 assert(ios.width() == 0); 1525 } 1526 } 1527 } 1528 } 1529 } 1530 uppercase(ios); 1531 { 1532 noshowpos(ios); 1533 { 1534 noshowpoint(ios); 1535 { 1536 ios.imbue(lc); 1537 { 1538 ios.width(0); 1539 { 1540 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1541 std::string ex(str, iter.base()); 1542 assert(ex == "0"); 1543 assert(ios.width() == 0); 1544 } 1545 ios.width(25); 1546 left(ios); 1547 { 1548 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1549 std::string ex(str, iter.base()); 1550 assert(ex == "0************************"); 1551 assert(ios.width() == 0); 1552 } 1553 ios.width(25); 1554 right(ios); 1555 { 1556 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1557 std::string ex(str, iter.base()); 1558 assert(ex == "************************0"); 1559 assert(ios.width() == 0); 1560 } 1561 ios.width(25); 1562 internal(ios); 1563 { 1564 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1565 std::string ex(str, iter.base()); 1566 assert(ex == "************************0"); 1567 assert(ios.width() == 0); 1568 } 1569 } 1570 ios.imbue(lg); 1571 { 1572 ios.width(0); 1573 { 1574 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1575 std::string ex(str, iter.base()); 1576 assert(ex == "0"); 1577 assert(ios.width() == 0); 1578 } 1579 ios.width(25); 1580 left(ios); 1581 { 1582 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1583 std::string ex(str, iter.base()); 1584 assert(ex == "0************************"); 1585 assert(ios.width() == 0); 1586 } 1587 ios.width(25); 1588 right(ios); 1589 { 1590 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1591 std::string ex(str, iter.base()); 1592 assert(ex == "************************0"); 1593 assert(ios.width() == 0); 1594 } 1595 ios.width(25); 1596 internal(ios); 1597 { 1598 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1599 std::string ex(str, iter.base()); 1600 assert(ex == "************************0"); 1601 assert(ios.width() == 0); 1602 } 1603 } 1604 } 1605 showpoint(ios); 1606 { 1607 ios.imbue(lc); 1608 { 1609 ios.width(0); 1610 { 1611 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1612 std::string ex(str, iter.base()); 1613 assert(ex == "0.00000"); 1614 assert(ios.width() == 0); 1615 } 1616 ios.width(25); 1617 left(ios); 1618 { 1619 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1620 std::string ex(str, iter.base()); 1621 assert(ex == "0.00000******************"); 1622 assert(ios.width() == 0); 1623 } 1624 ios.width(25); 1625 right(ios); 1626 { 1627 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1628 std::string ex(str, iter.base()); 1629 assert(ex == "******************0.00000"); 1630 assert(ios.width() == 0); 1631 } 1632 ios.width(25); 1633 internal(ios); 1634 { 1635 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1636 std::string ex(str, iter.base()); 1637 assert(ex == "******************0.00000"); 1638 assert(ios.width() == 0); 1639 } 1640 } 1641 ios.imbue(lg); 1642 { 1643 ios.width(0); 1644 { 1645 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1646 std::string ex(str, iter.base()); 1647 assert(ex == "0;00000"); 1648 assert(ios.width() == 0); 1649 } 1650 ios.width(25); 1651 left(ios); 1652 { 1653 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1654 std::string ex(str, iter.base()); 1655 assert(ex == "0;00000******************"); 1656 assert(ios.width() == 0); 1657 } 1658 ios.width(25); 1659 right(ios); 1660 { 1661 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1662 std::string ex(str, iter.base()); 1663 assert(ex == "******************0;00000"); 1664 assert(ios.width() == 0); 1665 } 1666 ios.width(25); 1667 internal(ios); 1668 { 1669 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1670 std::string ex(str, iter.base()); 1671 assert(ex == "******************0;00000"); 1672 assert(ios.width() == 0); 1673 } 1674 } 1675 } 1676 } 1677 showpos(ios); 1678 { 1679 noshowpoint(ios); 1680 { 1681 ios.imbue(lc); 1682 { 1683 ios.width(0); 1684 { 1685 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1686 std::string ex(str, iter.base()); 1687 assert(ex == "+0"); 1688 assert(ios.width() == 0); 1689 } 1690 ios.width(25); 1691 left(ios); 1692 { 1693 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1694 std::string ex(str, iter.base()); 1695 assert(ex == "+0***********************"); 1696 assert(ios.width() == 0); 1697 } 1698 ios.width(25); 1699 right(ios); 1700 { 1701 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1702 std::string ex(str, iter.base()); 1703 assert(ex == "***********************+0"); 1704 assert(ios.width() == 0); 1705 } 1706 ios.width(25); 1707 internal(ios); 1708 { 1709 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1710 std::string ex(str, iter.base()); 1711 assert(ex == "+***********************0"); 1712 assert(ios.width() == 0); 1713 } 1714 } 1715 ios.imbue(lg); 1716 { 1717 ios.width(0); 1718 { 1719 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1720 std::string ex(str, iter.base()); 1721 assert(ex == "+0"); 1722 assert(ios.width() == 0); 1723 } 1724 ios.width(25); 1725 left(ios); 1726 { 1727 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1728 std::string ex(str, iter.base()); 1729 assert(ex == "+0***********************"); 1730 assert(ios.width() == 0); 1731 } 1732 ios.width(25); 1733 right(ios); 1734 { 1735 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1736 std::string ex(str, iter.base()); 1737 assert(ex == "***********************+0"); 1738 assert(ios.width() == 0); 1739 } 1740 ios.width(25); 1741 internal(ios); 1742 { 1743 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1744 std::string ex(str, iter.base()); 1745 assert(ex == "+***********************0"); 1746 assert(ios.width() == 0); 1747 } 1748 } 1749 } 1750 showpoint(ios); 1751 { 1752 ios.imbue(lc); 1753 { 1754 ios.width(0); 1755 { 1756 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1757 std::string ex(str, iter.base()); 1758 assert(ex == "+0.00000"); 1759 assert(ios.width() == 0); 1760 } 1761 ios.width(25); 1762 left(ios); 1763 { 1764 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1765 std::string ex(str, iter.base()); 1766 assert(ex == "+0.00000*****************"); 1767 assert(ios.width() == 0); 1768 } 1769 ios.width(25); 1770 right(ios); 1771 { 1772 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1773 std::string ex(str, iter.base()); 1774 assert(ex == "*****************+0.00000"); 1775 assert(ios.width() == 0); 1776 } 1777 ios.width(25); 1778 internal(ios); 1779 { 1780 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1781 std::string ex(str, iter.base()); 1782 assert(ex == "+*****************0.00000"); 1783 assert(ios.width() == 0); 1784 } 1785 } 1786 ios.imbue(lg); 1787 { 1788 ios.width(0); 1789 { 1790 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1791 std::string ex(str, iter.base()); 1792 assert(ex == "+0;00000"); 1793 assert(ios.width() == 0); 1794 } 1795 ios.width(25); 1796 left(ios); 1797 { 1798 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1799 std::string ex(str, iter.base()); 1800 assert(ex == "+0;00000*****************"); 1801 assert(ios.width() == 0); 1802 } 1803 ios.width(25); 1804 right(ios); 1805 { 1806 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1807 std::string ex(str, iter.base()); 1808 assert(ex == "*****************+0;00000"); 1809 assert(ios.width() == 0); 1810 } 1811 ios.width(25); 1812 internal(ios); 1813 { 1814 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1815 std::string ex(str, iter.base()); 1816 assert(ex == "+*****************0;00000"); 1817 assert(ios.width() == 0); 1818 } 1819 } 1820 } 1821 } 1822 } 1823 } 1824 ios.precision(16); 1825 { 1826 nouppercase(ios); 1827 { 1828 noshowpos(ios); 1829 { 1830 noshowpoint(ios); 1831 { 1832 ios.imbue(lc); 1833 { 1834 ios.width(0); 1835 { 1836 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1837 std::string ex(str, iter.base()); 1838 assert(ex == "0"); 1839 assert(ios.width() == 0); 1840 } 1841 ios.width(25); 1842 left(ios); 1843 { 1844 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1845 std::string ex(str, iter.base()); 1846 assert(ex == "0************************"); 1847 assert(ios.width() == 0); 1848 } 1849 ios.width(25); 1850 right(ios); 1851 { 1852 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1853 std::string ex(str, iter.base()); 1854 assert(ex == "************************0"); 1855 assert(ios.width() == 0); 1856 } 1857 ios.width(25); 1858 internal(ios); 1859 { 1860 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1861 std::string ex(str, iter.base()); 1862 assert(ex == "************************0"); 1863 assert(ios.width() == 0); 1864 } 1865 } 1866 ios.imbue(lg); 1867 { 1868 ios.width(0); 1869 { 1870 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1871 std::string ex(str, iter.base()); 1872 assert(ex == "0"); 1873 assert(ios.width() == 0); 1874 } 1875 ios.width(25); 1876 left(ios); 1877 { 1878 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1879 std::string ex(str, iter.base()); 1880 assert(ex == "0************************"); 1881 assert(ios.width() == 0); 1882 } 1883 ios.width(25); 1884 right(ios); 1885 { 1886 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1887 std::string ex(str, iter.base()); 1888 assert(ex == "************************0"); 1889 assert(ios.width() == 0); 1890 } 1891 ios.width(25); 1892 internal(ios); 1893 { 1894 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1895 std::string ex(str, iter.base()); 1896 assert(ex == "************************0"); 1897 assert(ios.width() == 0); 1898 } 1899 } 1900 } 1901 showpoint(ios); 1902 { 1903 ios.imbue(lc); 1904 { 1905 ios.width(0); 1906 { 1907 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1908 std::string ex(str, iter.base()); 1909 assert(ex == "0.000000000000000"); 1910 assert(ios.width() == 0); 1911 } 1912 ios.width(25); 1913 left(ios); 1914 { 1915 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1916 std::string ex(str, iter.base()); 1917 assert(ex == "0.000000000000000********"); 1918 assert(ios.width() == 0); 1919 } 1920 ios.width(25); 1921 right(ios); 1922 { 1923 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1924 std::string ex(str, iter.base()); 1925 assert(ex == "********0.000000000000000"); 1926 assert(ios.width() == 0); 1927 } 1928 ios.width(25); 1929 internal(ios); 1930 { 1931 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1932 std::string ex(str, iter.base()); 1933 assert(ex == "********0.000000000000000"); 1934 assert(ios.width() == 0); 1935 } 1936 } 1937 ios.imbue(lg); 1938 { 1939 ios.width(0); 1940 { 1941 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1942 std::string ex(str, iter.base()); 1943 assert(ex == "0;000000000000000"); 1944 assert(ios.width() == 0); 1945 } 1946 ios.width(25); 1947 left(ios); 1948 { 1949 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1950 std::string ex(str, iter.base()); 1951 assert(ex == "0;000000000000000********"); 1952 assert(ios.width() == 0); 1953 } 1954 ios.width(25); 1955 right(ios); 1956 { 1957 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1958 std::string ex(str, iter.base()); 1959 assert(ex == "********0;000000000000000"); 1960 assert(ios.width() == 0); 1961 } 1962 ios.width(25); 1963 internal(ios); 1964 { 1965 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1966 std::string ex(str, iter.base()); 1967 assert(ex == "********0;000000000000000"); 1968 assert(ios.width() == 0); 1969 } 1970 } 1971 } 1972 } 1973 showpos(ios); 1974 { 1975 noshowpoint(ios); 1976 { 1977 ios.imbue(lc); 1978 { 1979 ios.width(0); 1980 { 1981 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1982 std::string ex(str, iter.base()); 1983 assert(ex == "+0"); 1984 assert(ios.width() == 0); 1985 } 1986 ios.width(25); 1987 left(ios); 1988 { 1989 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1990 std::string ex(str, iter.base()); 1991 assert(ex == "+0***********************"); 1992 assert(ios.width() == 0); 1993 } 1994 ios.width(25); 1995 right(ios); 1996 { 1997 iter = f.put(output_iterator<char*>(str), ios, '*', v); 1998 std::string ex(str, iter.base()); 1999 assert(ex == "***********************+0"); 2000 assert(ios.width() == 0); 2001 } 2002 ios.width(25); 2003 internal(ios); 2004 { 2005 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2006 std::string ex(str, iter.base()); 2007 assert(ex == "+***********************0"); 2008 assert(ios.width() == 0); 2009 } 2010 } 2011 ios.imbue(lg); 2012 { 2013 ios.width(0); 2014 { 2015 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2016 std::string ex(str, iter.base()); 2017 assert(ex == "+0"); 2018 assert(ios.width() == 0); 2019 } 2020 ios.width(25); 2021 left(ios); 2022 { 2023 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2024 std::string ex(str, iter.base()); 2025 assert(ex == "+0***********************"); 2026 assert(ios.width() == 0); 2027 } 2028 ios.width(25); 2029 right(ios); 2030 { 2031 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2032 std::string ex(str, iter.base()); 2033 assert(ex == "***********************+0"); 2034 assert(ios.width() == 0); 2035 } 2036 ios.width(25); 2037 internal(ios); 2038 { 2039 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2040 std::string ex(str, iter.base()); 2041 assert(ex == "+***********************0"); 2042 assert(ios.width() == 0); 2043 } 2044 } 2045 } 2046 showpoint(ios); 2047 { 2048 ios.imbue(lc); 2049 { 2050 ios.width(0); 2051 { 2052 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2053 std::string ex(str, iter.base()); 2054 assert(ex == "+0.000000000000000"); 2055 assert(ios.width() == 0); 2056 } 2057 ios.width(25); 2058 left(ios); 2059 { 2060 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2061 std::string ex(str, iter.base()); 2062 assert(ex == "+0.000000000000000*******"); 2063 assert(ios.width() == 0); 2064 } 2065 ios.width(25); 2066 right(ios); 2067 { 2068 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2069 std::string ex(str, iter.base()); 2070 assert(ex == "*******+0.000000000000000"); 2071 assert(ios.width() == 0); 2072 } 2073 ios.width(25); 2074 internal(ios); 2075 { 2076 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2077 std::string ex(str, iter.base()); 2078 assert(ex == "+*******0.000000000000000"); 2079 assert(ios.width() == 0); 2080 } 2081 } 2082 ios.imbue(lg); 2083 { 2084 ios.width(0); 2085 { 2086 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2087 std::string ex(str, iter.base()); 2088 assert(ex == "+0;000000000000000"); 2089 assert(ios.width() == 0); 2090 } 2091 ios.width(25); 2092 left(ios); 2093 { 2094 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2095 std::string ex(str, iter.base()); 2096 assert(ex == "+0;000000000000000*******"); 2097 assert(ios.width() == 0); 2098 } 2099 ios.width(25); 2100 right(ios); 2101 { 2102 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2103 std::string ex(str, iter.base()); 2104 assert(ex == "*******+0;000000000000000"); 2105 assert(ios.width() == 0); 2106 } 2107 ios.width(25); 2108 internal(ios); 2109 { 2110 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2111 std::string ex(str, iter.base()); 2112 assert(ex == "+*******0;000000000000000"); 2113 assert(ios.width() == 0); 2114 } 2115 } 2116 } 2117 } 2118 } 2119 uppercase(ios); 2120 { 2121 noshowpos(ios); 2122 { 2123 noshowpoint(ios); 2124 { 2125 ios.imbue(lc); 2126 { 2127 ios.width(0); 2128 { 2129 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2130 std::string ex(str, iter.base()); 2131 assert(ex == "0"); 2132 assert(ios.width() == 0); 2133 } 2134 ios.width(25); 2135 left(ios); 2136 { 2137 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2138 std::string ex(str, iter.base()); 2139 assert(ex == "0************************"); 2140 assert(ios.width() == 0); 2141 } 2142 ios.width(25); 2143 right(ios); 2144 { 2145 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2146 std::string ex(str, iter.base()); 2147 assert(ex == "************************0"); 2148 assert(ios.width() == 0); 2149 } 2150 ios.width(25); 2151 internal(ios); 2152 { 2153 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2154 std::string ex(str, iter.base()); 2155 assert(ex == "************************0"); 2156 assert(ios.width() == 0); 2157 } 2158 } 2159 ios.imbue(lg); 2160 { 2161 ios.width(0); 2162 { 2163 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2164 std::string ex(str, iter.base()); 2165 assert(ex == "0"); 2166 assert(ios.width() == 0); 2167 } 2168 ios.width(25); 2169 left(ios); 2170 { 2171 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2172 std::string ex(str, iter.base()); 2173 assert(ex == "0************************"); 2174 assert(ios.width() == 0); 2175 } 2176 ios.width(25); 2177 right(ios); 2178 { 2179 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2180 std::string ex(str, iter.base()); 2181 assert(ex == "************************0"); 2182 assert(ios.width() == 0); 2183 } 2184 ios.width(25); 2185 internal(ios); 2186 { 2187 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2188 std::string ex(str, iter.base()); 2189 assert(ex == "************************0"); 2190 assert(ios.width() == 0); 2191 } 2192 } 2193 } 2194 showpoint(ios); 2195 { 2196 ios.imbue(lc); 2197 { 2198 ios.width(0); 2199 { 2200 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2201 std::string ex(str, iter.base()); 2202 assert(ex == "0.000000000000000"); 2203 assert(ios.width() == 0); 2204 } 2205 ios.width(25); 2206 left(ios); 2207 { 2208 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2209 std::string ex(str, iter.base()); 2210 assert(ex == "0.000000000000000********"); 2211 assert(ios.width() == 0); 2212 } 2213 ios.width(25); 2214 right(ios); 2215 { 2216 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2217 std::string ex(str, iter.base()); 2218 assert(ex == "********0.000000000000000"); 2219 assert(ios.width() == 0); 2220 } 2221 ios.width(25); 2222 internal(ios); 2223 { 2224 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2225 std::string ex(str, iter.base()); 2226 assert(ex == "********0.000000000000000"); 2227 assert(ios.width() == 0); 2228 } 2229 } 2230 ios.imbue(lg); 2231 { 2232 ios.width(0); 2233 { 2234 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2235 std::string ex(str, iter.base()); 2236 assert(ex == "0;000000000000000"); 2237 assert(ios.width() == 0); 2238 } 2239 ios.width(25); 2240 left(ios); 2241 { 2242 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2243 std::string ex(str, iter.base()); 2244 assert(ex == "0;000000000000000********"); 2245 assert(ios.width() == 0); 2246 } 2247 ios.width(25); 2248 right(ios); 2249 { 2250 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2251 std::string ex(str, iter.base()); 2252 assert(ex == "********0;000000000000000"); 2253 assert(ios.width() == 0); 2254 } 2255 ios.width(25); 2256 internal(ios); 2257 { 2258 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2259 std::string ex(str, iter.base()); 2260 assert(ex == "********0;000000000000000"); 2261 assert(ios.width() == 0); 2262 } 2263 } 2264 } 2265 } 2266 showpos(ios); 2267 { 2268 noshowpoint(ios); 2269 { 2270 ios.imbue(lc); 2271 { 2272 ios.width(0); 2273 { 2274 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2275 std::string ex(str, iter.base()); 2276 assert(ex == "+0"); 2277 assert(ios.width() == 0); 2278 } 2279 ios.width(25); 2280 left(ios); 2281 { 2282 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2283 std::string ex(str, iter.base()); 2284 assert(ex == "+0***********************"); 2285 assert(ios.width() == 0); 2286 } 2287 ios.width(25); 2288 right(ios); 2289 { 2290 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2291 std::string ex(str, iter.base()); 2292 assert(ex == "***********************+0"); 2293 assert(ios.width() == 0); 2294 } 2295 ios.width(25); 2296 internal(ios); 2297 { 2298 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2299 std::string ex(str, iter.base()); 2300 assert(ex == "+***********************0"); 2301 assert(ios.width() == 0); 2302 } 2303 } 2304 ios.imbue(lg); 2305 { 2306 ios.width(0); 2307 { 2308 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2309 std::string ex(str, iter.base()); 2310 assert(ex == "+0"); 2311 assert(ios.width() == 0); 2312 } 2313 ios.width(25); 2314 left(ios); 2315 { 2316 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2317 std::string ex(str, iter.base()); 2318 assert(ex == "+0***********************"); 2319 assert(ios.width() == 0); 2320 } 2321 ios.width(25); 2322 right(ios); 2323 { 2324 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2325 std::string ex(str, iter.base()); 2326 assert(ex == "***********************+0"); 2327 assert(ios.width() == 0); 2328 } 2329 ios.width(25); 2330 internal(ios); 2331 { 2332 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2333 std::string ex(str, iter.base()); 2334 assert(ex == "+***********************0"); 2335 assert(ios.width() == 0); 2336 } 2337 } 2338 } 2339 showpoint(ios); 2340 { 2341 ios.imbue(lc); 2342 { 2343 ios.width(0); 2344 { 2345 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2346 std::string ex(str, iter.base()); 2347 assert(ex == "+0.000000000000000"); 2348 assert(ios.width() == 0); 2349 } 2350 ios.width(25); 2351 left(ios); 2352 { 2353 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2354 std::string ex(str, iter.base()); 2355 assert(ex == "+0.000000000000000*******"); 2356 assert(ios.width() == 0); 2357 } 2358 ios.width(25); 2359 right(ios); 2360 { 2361 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2362 std::string ex(str, iter.base()); 2363 assert(ex == "*******+0.000000000000000"); 2364 assert(ios.width() == 0); 2365 } 2366 ios.width(25); 2367 internal(ios); 2368 { 2369 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2370 std::string ex(str, iter.base()); 2371 assert(ex == "+*******0.000000000000000"); 2372 assert(ios.width() == 0); 2373 } 2374 } 2375 ios.imbue(lg); 2376 { 2377 ios.width(0); 2378 { 2379 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2380 std::string ex(str, iter.base()); 2381 assert(ex == "+0;000000000000000"); 2382 assert(ios.width() == 0); 2383 } 2384 ios.width(25); 2385 left(ios); 2386 { 2387 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2388 std::string ex(str, iter.base()); 2389 assert(ex == "+0;000000000000000*******"); 2390 assert(ios.width() == 0); 2391 } 2392 ios.width(25); 2393 right(ios); 2394 { 2395 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2396 std::string ex(str, iter.base()); 2397 assert(ex == "*******+0;000000000000000"); 2398 assert(ios.width() == 0); 2399 } 2400 ios.width(25); 2401 internal(ios); 2402 { 2403 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2404 std::string ex(str, iter.base()); 2405 assert(ex == "+*******0;000000000000000"); 2406 assert(ios.width() == 0); 2407 } 2408 } 2409 } 2410 } 2411 } 2412 } 2413 ios.precision(60); 2414 { 2415 nouppercase(ios); 2416 { 2417 noshowpos(ios); 2418 { 2419 noshowpoint(ios); 2420 { 2421 ios.imbue(lc); 2422 { 2423 ios.width(0); 2424 { 2425 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2426 std::string ex(str, iter.base()); 2427 assert(ex == "0"); 2428 assert(ios.width() == 0); 2429 } 2430 ios.width(25); 2431 left(ios); 2432 { 2433 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2434 std::string ex(str, iter.base()); 2435 assert(ex == "0************************"); 2436 assert(ios.width() == 0); 2437 } 2438 ios.width(25); 2439 right(ios); 2440 { 2441 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2442 std::string ex(str, iter.base()); 2443 assert(ex == "************************0"); 2444 assert(ios.width() == 0); 2445 } 2446 ios.width(25); 2447 internal(ios); 2448 { 2449 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2450 std::string ex(str, iter.base()); 2451 assert(ex == "************************0"); 2452 assert(ios.width() == 0); 2453 } 2454 } 2455 ios.imbue(lg); 2456 { 2457 ios.width(0); 2458 { 2459 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2460 std::string ex(str, iter.base()); 2461 assert(ex == "0"); 2462 assert(ios.width() == 0); 2463 } 2464 ios.width(25); 2465 left(ios); 2466 { 2467 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2468 std::string ex(str, iter.base()); 2469 assert(ex == "0************************"); 2470 assert(ios.width() == 0); 2471 } 2472 ios.width(25); 2473 right(ios); 2474 { 2475 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2476 std::string ex(str, iter.base()); 2477 assert(ex == "************************0"); 2478 assert(ios.width() == 0); 2479 } 2480 ios.width(25); 2481 internal(ios); 2482 { 2483 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2484 std::string ex(str, iter.base()); 2485 assert(ex == "************************0"); 2486 assert(ios.width() == 0); 2487 } 2488 } 2489 } 2490 showpoint(ios); 2491 { 2492 ios.imbue(lc); 2493 { 2494 ios.width(0); 2495 { 2496 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2497 std::string ex(str, iter.base()); 2498 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2499 assert(ios.width() == 0); 2500 } 2501 ios.width(25); 2502 left(ios); 2503 { 2504 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2505 std::string ex(str, iter.base()); 2506 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2507 assert(ios.width() == 0); 2508 } 2509 ios.width(25); 2510 right(ios); 2511 { 2512 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2513 std::string ex(str, iter.base()); 2514 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2515 assert(ios.width() == 0); 2516 } 2517 ios.width(25); 2518 internal(ios); 2519 { 2520 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2521 std::string ex(str, iter.base()); 2522 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2523 assert(ios.width() == 0); 2524 } 2525 } 2526 ios.imbue(lg); 2527 { 2528 ios.width(0); 2529 { 2530 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2531 std::string ex(str, iter.base()); 2532 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2533 assert(ios.width() == 0); 2534 } 2535 ios.width(25); 2536 left(ios); 2537 { 2538 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2539 std::string ex(str, iter.base()); 2540 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2541 assert(ios.width() == 0); 2542 } 2543 ios.width(25); 2544 right(ios); 2545 { 2546 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2547 std::string ex(str, iter.base()); 2548 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2549 assert(ios.width() == 0); 2550 } 2551 ios.width(25); 2552 internal(ios); 2553 { 2554 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2555 std::string ex(str, iter.base()); 2556 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2557 assert(ios.width() == 0); 2558 } 2559 } 2560 } 2561 } 2562 showpos(ios); 2563 { 2564 noshowpoint(ios); 2565 { 2566 ios.imbue(lc); 2567 { 2568 ios.width(0); 2569 { 2570 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2571 std::string ex(str, iter.base()); 2572 assert(ex == "+0"); 2573 assert(ios.width() == 0); 2574 } 2575 ios.width(25); 2576 left(ios); 2577 { 2578 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2579 std::string ex(str, iter.base()); 2580 assert(ex == "+0***********************"); 2581 assert(ios.width() == 0); 2582 } 2583 ios.width(25); 2584 right(ios); 2585 { 2586 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2587 std::string ex(str, iter.base()); 2588 assert(ex == "***********************+0"); 2589 assert(ios.width() == 0); 2590 } 2591 ios.width(25); 2592 internal(ios); 2593 { 2594 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2595 std::string ex(str, iter.base()); 2596 assert(ex == "+***********************0"); 2597 assert(ios.width() == 0); 2598 } 2599 } 2600 ios.imbue(lg); 2601 { 2602 ios.width(0); 2603 { 2604 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2605 std::string ex(str, iter.base()); 2606 assert(ex == "+0"); 2607 assert(ios.width() == 0); 2608 } 2609 ios.width(25); 2610 left(ios); 2611 { 2612 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2613 std::string ex(str, iter.base()); 2614 assert(ex == "+0***********************"); 2615 assert(ios.width() == 0); 2616 } 2617 ios.width(25); 2618 right(ios); 2619 { 2620 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2621 std::string ex(str, iter.base()); 2622 assert(ex == "***********************+0"); 2623 assert(ios.width() == 0); 2624 } 2625 ios.width(25); 2626 internal(ios); 2627 { 2628 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2629 std::string ex(str, iter.base()); 2630 assert(ex == "+***********************0"); 2631 assert(ios.width() == 0); 2632 } 2633 } 2634 } 2635 showpoint(ios); 2636 { 2637 ios.imbue(lc); 2638 { 2639 ios.width(0); 2640 { 2641 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2642 std::string ex(str, iter.base()); 2643 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2644 assert(ios.width() == 0); 2645 } 2646 ios.width(25); 2647 left(ios); 2648 { 2649 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2650 std::string ex(str, iter.base()); 2651 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2652 assert(ios.width() == 0); 2653 } 2654 ios.width(25); 2655 right(ios); 2656 { 2657 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2658 std::string ex(str, iter.base()); 2659 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2660 assert(ios.width() == 0); 2661 } 2662 ios.width(25); 2663 internal(ios); 2664 { 2665 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2666 std::string ex(str, iter.base()); 2667 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2668 assert(ios.width() == 0); 2669 } 2670 } 2671 ios.imbue(lg); 2672 { 2673 ios.width(0); 2674 { 2675 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2676 std::string ex(str, iter.base()); 2677 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2678 assert(ios.width() == 0); 2679 } 2680 ios.width(25); 2681 left(ios); 2682 { 2683 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2684 std::string ex(str, iter.base()); 2685 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2686 assert(ios.width() == 0); 2687 } 2688 ios.width(25); 2689 right(ios); 2690 { 2691 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2692 std::string ex(str, iter.base()); 2693 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2694 assert(ios.width() == 0); 2695 } 2696 ios.width(25); 2697 internal(ios); 2698 { 2699 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2700 std::string ex(str, iter.base()); 2701 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2702 assert(ios.width() == 0); 2703 } 2704 } 2705 } 2706 } 2707 } 2708 uppercase(ios); 2709 { 2710 noshowpos(ios); 2711 { 2712 noshowpoint(ios); 2713 { 2714 ios.imbue(lc); 2715 { 2716 ios.width(0); 2717 { 2718 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2719 std::string ex(str, iter.base()); 2720 assert(ex == "0"); 2721 assert(ios.width() == 0); 2722 } 2723 ios.width(25); 2724 left(ios); 2725 { 2726 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2727 std::string ex(str, iter.base()); 2728 assert(ex == "0************************"); 2729 assert(ios.width() == 0); 2730 } 2731 ios.width(25); 2732 right(ios); 2733 { 2734 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2735 std::string ex(str, iter.base()); 2736 assert(ex == "************************0"); 2737 assert(ios.width() == 0); 2738 } 2739 ios.width(25); 2740 internal(ios); 2741 { 2742 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2743 std::string ex(str, iter.base()); 2744 assert(ex == "************************0"); 2745 assert(ios.width() == 0); 2746 } 2747 } 2748 ios.imbue(lg); 2749 { 2750 ios.width(0); 2751 { 2752 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2753 std::string ex(str, iter.base()); 2754 assert(ex == "0"); 2755 assert(ios.width() == 0); 2756 } 2757 ios.width(25); 2758 left(ios); 2759 { 2760 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2761 std::string ex(str, iter.base()); 2762 assert(ex == "0************************"); 2763 assert(ios.width() == 0); 2764 } 2765 ios.width(25); 2766 right(ios); 2767 { 2768 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2769 std::string ex(str, iter.base()); 2770 assert(ex == "************************0"); 2771 assert(ios.width() == 0); 2772 } 2773 ios.width(25); 2774 internal(ios); 2775 { 2776 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2777 std::string ex(str, iter.base()); 2778 assert(ex == "************************0"); 2779 assert(ios.width() == 0); 2780 } 2781 } 2782 } 2783 showpoint(ios); 2784 { 2785 ios.imbue(lc); 2786 { 2787 ios.width(0); 2788 { 2789 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2790 std::string ex(str, iter.base()); 2791 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2792 assert(ios.width() == 0); 2793 } 2794 ios.width(25); 2795 left(ios); 2796 { 2797 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2798 std::string ex(str, iter.base()); 2799 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2800 assert(ios.width() == 0); 2801 } 2802 ios.width(25); 2803 right(ios); 2804 { 2805 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2806 std::string ex(str, iter.base()); 2807 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2808 assert(ios.width() == 0); 2809 } 2810 ios.width(25); 2811 internal(ios); 2812 { 2813 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2814 std::string ex(str, iter.base()); 2815 assert(ex == "0.00000000000000000000000000000000000000000000000000000000000"); 2816 assert(ios.width() == 0); 2817 } 2818 } 2819 ios.imbue(lg); 2820 { 2821 ios.width(0); 2822 { 2823 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2824 std::string ex(str, iter.base()); 2825 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2826 assert(ios.width() == 0); 2827 } 2828 ios.width(25); 2829 left(ios); 2830 { 2831 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2832 std::string ex(str, iter.base()); 2833 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2834 assert(ios.width() == 0); 2835 } 2836 ios.width(25); 2837 right(ios); 2838 { 2839 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2840 std::string ex(str, iter.base()); 2841 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2842 assert(ios.width() == 0); 2843 } 2844 ios.width(25); 2845 internal(ios); 2846 { 2847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2848 std::string ex(str, iter.base()); 2849 assert(ex == "0;00000000000000000000000000000000000000000000000000000000000"); 2850 assert(ios.width() == 0); 2851 } 2852 } 2853 } 2854 } 2855 showpos(ios); 2856 { 2857 noshowpoint(ios); 2858 { 2859 ios.imbue(lc); 2860 { 2861 ios.width(0); 2862 { 2863 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2864 std::string ex(str, iter.base()); 2865 assert(ex == "+0"); 2866 assert(ios.width() == 0); 2867 } 2868 ios.width(25); 2869 left(ios); 2870 { 2871 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2872 std::string ex(str, iter.base()); 2873 assert(ex == "+0***********************"); 2874 assert(ios.width() == 0); 2875 } 2876 ios.width(25); 2877 right(ios); 2878 { 2879 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2880 std::string ex(str, iter.base()); 2881 assert(ex == "***********************+0"); 2882 assert(ios.width() == 0); 2883 } 2884 ios.width(25); 2885 internal(ios); 2886 { 2887 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2888 std::string ex(str, iter.base()); 2889 assert(ex == "+***********************0"); 2890 assert(ios.width() == 0); 2891 } 2892 } 2893 ios.imbue(lg); 2894 { 2895 ios.width(0); 2896 { 2897 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2898 std::string ex(str, iter.base()); 2899 assert(ex == "+0"); 2900 assert(ios.width() == 0); 2901 } 2902 ios.width(25); 2903 left(ios); 2904 { 2905 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2906 std::string ex(str, iter.base()); 2907 assert(ex == "+0***********************"); 2908 assert(ios.width() == 0); 2909 } 2910 ios.width(25); 2911 right(ios); 2912 { 2913 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2914 std::string ex(str, iter.base()); 2915 assert(ex == "***********************+0"); 2916 assert(ios.width() == 0); 2917 } 2918 ios.width(25); 2919 internal(ios); 2920 { 2921 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2922 std::string ex(str, iter.base()); 2923 assert(ex == "+***********************0"); 2924 assert(ios.width() == 0); 2925 } 2926 } 2927 } 2928 showpoint(ios); 2929 { 2930 ios.imbue(lc); 2931 { 2932 ios.width(0); 2933 { 2934 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2935 std::string ex(str, iter.base()); 2936 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2937 assert(ios.width() == 0); 2938 } 2939 ios.width(25); 2940 left(ios); 2941 { 2942 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2943 std::string ex(str, iter.base()); 2944 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2945 assert(ios.width() == 0); 2946 } 2947 ios.width(25); 2948 right(ios); 2949 { 2950 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2951 std::string ex(str, iter.base()); 2952 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2953 assert(ios.width() == 0); 2954 } 2955 ios.width(25); 2956 internal(ios); 2957 { 2958 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2959 std::string ex(str, iter.base()); 2960 assert(ex == "+0.00000000000000000000000000000000000000000000000000000000000"); 2961 assert(ios.width() == 0); 2962 } 2963 } 2964 ios.imbue(lg); 2965 { 2966 ios.width(0); 2967 { 2968 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2969 std::string ex(str, iter.base()); 2970 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2971 assert(ios.width() == 0); 2972 } 2973 ios.width(25); 2974 left(ios); 2975 { 2976 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2977 std::string ex(str, iter.base()); 2978 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2979 assert(ios.width() == 0); 2980 } 2981 ios.width(25); 2982 right(ios); 2983 { 2984 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2985 std::string ex(str, iter.base()); 2986 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2987 assert(ios.width() == 0); 2988 } 2989 ios.width(25); 2990 internal(ios); 2991 { 2992 iter = f.put(output_iterator<char*>(str), ios, '*', v); 2993 std::string ex(str, iter.base()); 2994 assert(ex == "+0;00000000000000000000000000000000000000000000000000000000000"); 2995 assert(ios.width() == 0); 2996 } 2997 } 2998 } 2999 } 3000 } 3001 } 3002 } 3003 } 3004} 3005 3006void test2() 3007{ 3008 char str[200]; 3009 output_iterator<char*> iter; 3010 std::locale lc = std::locale::classic(); 3011 std::locale lg(lc, new my_numpunct); 3012 const my_facet f(1); 3013 { 3014 double v = 1234567890.125; 3015 std::ios ios(0); 3016 // %g 3017 { 3018 ios.precision(0); 3019 { 3020 nouppercase(ios); 3021 { 3022 noshowpos(ios); 3023 { 3024 noshowpoint(ios); 3025 { 3026 ios.imbue(lc); 3027 { 3028 ios.width(0); 3029 { 3030 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3031 std::string ex(str, iter.base()); 3032 assert(ex == "1e+09"); 3033 assert(ios.width() == 0); 3034 } 3035 ios.width(25); 3036 left(ios); 3037 { 3038 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3039 std::string ex(str, iter.base()); 3040 assert(ex == "1e+09********************"); 3041 assert(ios.width() == 0); 3042 } 3043 ios.width(25); 3044 right(ios); 3045 { 3046 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3047 std::string ex(str, iter.base()); 3048 assert(ex == "********************1e+09"); 3049 assert(ios.width() == 0); 3050 } 3051 ios.width(25); 3052 internal(ios); 3053 { 3054 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3055 std::string ex(str, iter.base()); 3056 assert(ex == "********************1e+09"); 3057 assert(ios.width() == 0); 3058 } 3059 } 3060 ios.imbue(lg); 3061 { 3062 ios.width(0); 3063 { 3064 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3065 std::string ex(str, iter.base()); 3066 assert(ex == "1e+09"); 3067 assert(ios.width() == 0); 3068 } 3069 ios.width(25); 3070 left(ios); 3071 { 3072 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3073 std::string ex(str, iter.base()); 3074 assert(ex == "1e+09********************"); 3075 assert(ios.width() == 0); 3076 } 3077 ios.width(25); 3078 right(ios); 3079 { 3080 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3081 std::string ex(str, iter.base()); 3082 assert(ex == "********************1e+09"); 3083 assert(ios.width() == 0); 3084 } 3085 ios.width(25); 3086 internal(ios); 3087 { 3088 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3089 std::string ex(str, iter.base()); 3090 assert(ex == "********************1e+09"); 3091 assert(ios.width() == 0); 3092 } 3093 } 3094 } 3095 showpoint(ios); 3096 { 3097 ios.imbue(lc); 3098 { 3099 ios.width(0); 3100 { 3101 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3102 std::string ex(str, iter.base()); 3103 assert(ex == "1.e+09"); 3104 assert(ios.width() == 0); 3105 } 3106 ios.width(25); 3107 left(ios); 3108 { 3109 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3110 std::string ex(str, iter.base()); 3111 assert(ex == "1.e+09*******************"); 3112 assert(ios.width() == 0); 3113 } 3114 ios.width(25); 3115 right(ios); 3116 { 3117 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3118 std::string ex(str, iter.base()); 3119 assert(ex == "*******************1.e+09"); 3120 assert(ios.width() == 0); 3121 } 3122 ios.width(25); 3123 internal(ios); 3124 { 3125 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3126 std::string ex(str, iter.base()); 3127 assert(ex == "*******************1.e+09"); 3128 assert(ios.width() == 0); 3129 } 3130 } 3131 ios.imbue(lg); 3132 { 3133 ios.width(0); 3134 { 3135 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3136 std::string ex(str, iter.base()); 3137 assert(ex == "1;e+09"); 3138 assert(ios.width() == 0); 3139 } 3140 ios.width(25); 3141 left(ios); 3142 { 3143 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3144 std::string ex(str, iter.base()); 3145 assert(ex == "1;e+09*******************"); 3146 assert(ios.width() == 0); 3147 } 3148 ios.width(25); 3149 right(ios); 3150 { 3151 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3152 std::string ex(str, iter.base()); 3153 assert(ex == "*******************1;e+09"); 3154 assert(ios.width() == 0); 3155 } 3156 ios.width(25); 3157 internal(ios); 3158 { 3159 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3160 std::string ex(str, iter.base()); 3161 assert(ex == "*******************1;e+09"); 3162 assert(ios.width() == 0); 3163 } 3164 } 3165 } 3166 } 3167 showpos(ios); 3168 { 3169 noshowpoint(ios); 3170 { 3171 ios.imbue(lc); 3172 { 3173 ios.width(0); 3174 { 3175 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3176 std::string ex(str, iter.base()); 3177 assert(ex == "+1e+09"); 3178 assert(ios.width() == 0); 3179 } 3180 ios.width(25); 3181 left(ios); 3182 { 3183 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3184 std::string ex(str, iter.base()); 3185 assert(ex == "+1e+09*******************"); 3186 assert(ios.width() == 0); 3187 } 3188 ios.width(25); 3189 right(ios); 3190 { 3191 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3192 std::string ex(str, iter.base()); 3193 assert(ex == "*******************+1e+09"); 3194 assert(ios.width() == 0); 3195 } 3196 ios.width(25); 3197 internal(ios); 3198 { 3199 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3200 std::string ex(str, iter.base()); 3201 assert(ex == "+*******************1e+09"); 3202 assert(ios.width() == 0); 3203 } 3204 } 3205 ios.imbue(lg); 3206 { 3207 ios.width(0); 3208 { 3209 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3210 std::string ex(str, iter.base()); 3211 assert(ex == "+1e+09"); 3212 assert(ios.width() == 0); 3213 } 3214 ios.width(25); 3215 left(ios); 3216 { 3217 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3218 std::string ex(str, iter.base()); 3219 assert(ex == "+1e+09*******************"); 3220 assert(ios.width() == 0); 3221 } 3222 ios.width(25); 3223 right(ios); 3224 { 3225 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3226 std::string ex(str, iter.base()); 3227 assert(ex == "*******************+1e+09"); 3228 assert(ios.width() == 0); 3229 } 3230 ios.width(25); 3231 internal(ios); 3232 { 3233 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3234 std::string ex(str, iter.base()); 3235 assert(ex == "+*******************1e+09"); 3236 assert(ios.width() == 0); 3237 } 3238 } 3239 } 3240 showpoint(ios); 3241 { 3242 ios.imbue(lc); 3243 { 3244 ios.width(0); 3245 { 3246 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3247 std::string ex(str, iter.base()); 3248 assert(ex == "+1.e+09"); 3249 assert(ios.width() == 0); 3250 } 3251 ios.width(25); 3252 left(ios); 3253 { 3254 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3255 std::string ex(str, iter.base()); 3256 assert(ex == "+1.e+09******************"); 3257 assert(ios.width() == 0); 3258 } 3259 ios.width(25); 3260 right(ios); 3261 { 3262 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3263 std::string ex(str, iter.base()); 3264 assert(ex == "******************+1.e+09"); 3265 assert(ios.width() == 0); 3266 } 3267 ios.width(25); 3268 internal(ios); 3269 { 3270 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3271 std::string ex(str, iter.base()); 3272 assert(ex == "+******************1.e+09"); 3273 assert(ios.width() == 0); 3274 } 3275 } 3276 ios.imbue(lg); 3277 { 3278 ios.width(0); 3279 { 3280 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3281 std::string ex(str, iter.base()); 3282 assert(ex == "+1;e+09"); 3283 assert(ios.width() == 0); 3284 } 3285 ios.width(25); 3286 left(ios); 3287 { 3288 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3289 std::string ex(str, iter.base()); 3290 assert(ex == "+1;e+09******************"); 3291 assert(ios.width() == 0); 3292 } 3293 ios.width(25); 3294 right(ios); 3295 { 3296 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3297 std::string ex(str, iter.base()); 3298 assert(ex == "******************+1;e+09"); 3299 assert(ios.width() == 0); 3300 } 3301 ios.width(25); 3302 internal(ios); 3303 { 3304 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3305 std::string ex(str, iter.base()); 3306 assert(ex == "+******************1;e+09"); 3307 assert(ios.width() == 0); 3308 } 3309 } 3310 } 3311 } 3312 } 3313 uppercase(ios); 3314 { 3315 noshowpos(ios); 3316 { 3317 noshowpoint(ios); 3318 { 3319 ios.imbue(lc); 3320 { 3321 ios.width(0); 3322 { 3323 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3324 std::string ex(str, iter.base()); 3325 assert(ex == "1E+09"); 3326 assert(ios.width() == 0); 3327 } 3328 ios.width(25); 3329 left(ios); 3330 { 3331 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3332 std::string ex(str, iter.base()); 3333 assert(ex == "1E+09********************"); 3334 assert(ios.width() == 0); 3335 } 3336 ios.width(25); 3337 right(ios); 3338 { 3339 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3340 std::string ex(str, iter.base()); 3341 assert(ex == "********************1E+09"); 3342 assert(ios.width() == 0); 3343 } 3344 ios.width(25); 3345 internal(ios); 3346 { 3347 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3348 std::string ex(str, iter.base()); 3349 assert(ex == "********************1E+09"); 3350 assert(ios.width() == 0); 3351 } 3352 } 3353 ios.imbue(lg); 3354 { 3355 ios.width(0); 3356 { 3357 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3358 std::string ex(str, iter.base()); 3359 assert(ex == "1E+09"); 3360 assert(ios.width() == 0); 3361 } 3362 ios.width(25); 3363 left(ios); 3364 { 3365 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3366 std::string ex(str, iter.base()); 3367 assert(ex == "1E+09********************"); 3368 assert(ios.width() == 0); 3369 } 3370 ios.width(25); 3371 right(ios); 3372 { 3373 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3374 std::string ex(str, iter.base()); 3375 assert(ex == "********************1E+09"); 3376 assert(ios.width() == 0); 3377 } 3378 ios.width(25); 3379 internal(ios); 3380 { 3381 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3382 std::string ex(str, iter.base()); 3383 assert(ex == "********************1E+09"); 3384 assert(ios.width() == 0); 3385 } 3386 } 3387 } 3388 showpoint(ios); 3389 { 3390 ios.imbue(lc); 3391 { 3392 ios.width(0); 3393 { 3394 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3395 std::string ex(str, iter.base()); 3396 assert(ex == "1.E+09"); 3397 assert(ios.width() == 0); 3398 } 3399 ios.width(25); 3400 left(ios); 3401 { 3402 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3403 std::string ex(str, iter.base()); 3404 assert(ex == "1.E+09*******************"); 3405 assert(ios.width() == 0); 3406 } 3407 ios.width(25); 3408 right(ios); 3409 { 3410 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3411 std::string ex(str, iter.base()); 3412 assert(ex == "*******************1.E+09"); 3413 assert(ios.width() == 0); 3414 } 3415 ios.width(25); 3416 internal(ios); 3417 { 3418 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3419 std::string ex(str, iter.base()); 3420 assert(ex == "*******************1.E+09"); 3421 assert(ios.width() == 0); 3422 } 3423 } 3424 ios.imbue(lg); 3425 { 3426 ios.width(0); 3427 { 3428 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3429 std::string ex(str, iter.base()); 3430 assert(ex == "1;E+09"); 3431 assert(ios.width() == 0); 3432 } 3433 ios.width(25); 3434 left(ios); 3435 { 3436 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3437 std::string ex(str, iter.base()); 3438 assert(ex == "1;E+09*******************"); 3439 assert(ios.width() == 0); 3440 } 3441 ios.width(25); 3442 right(ios); 3443 { 3444 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3445 std::string ex(str, iter.base()); 3446 assert(ex == "*******************1;E+09"); 3447 assert(ios.width() == 0); 3448 } 3449 ios.width(25); 3450 internal(ios); 3451 { 3452 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3453 std::string ex(str, iter.base()); 3454 assert(ex == "*******************1;E+09"); 3455 assert(ios.width() == 0); 3456 } 3457 } 3458 } 3459 } 3460 showpos(ios); 3461 { 3462 noshowpoint(ios); 3463 { 3464 ios.imbue(lc); 3465 { 3466 ios.width(0); 3467 { 3468 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3469 std::string ex(str, iter.base()); 3470 assert(ex == "+1E+09"); 3471 assert(ios.width() == 0); 3472 } 3473 ios.width(25); 3474 left(ios); 3475 { 3476 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3477 std::string ex(str, iter.base()); 3478 assert(ex == "+1E+09*******************"); 3479 assert(ios.width() == 0); 3480 } 3481 ios.width(25); 3482 right(ios); 3483 { 3484 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3485 std::string ex(str, iter.base()); 3486 assert(ex == "*******************+1E+09"); 3487 assert(ios.width() == 0); 3488 } 3489 ios.width(25); 3490 internal(ios); 3491 { 3492 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3493 std::string ex(str, iter.base()); 3494 assert(ex == "+*******************1E+09"); 3495 assert(ios.width() == 0); 3496 } 3497 } 3498 ios.imbue(lg); 3499 { 3500 ios.width(0); 3501 { 3502 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3503 std::string ex(str, iter.base()); 3504 assert(ex == "+1E+09"); 3505 assert(ios.width() == 0); 3506 } 3507 ios.width(25); 3508 left(ios); 3509 { 3510 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3511 std::string ex(str, iter.base()); 3512 assert(ex == "+1E+09*******************"); 3513 assert(ios.width() == 0); 3514 } 3515 ios.width(25); 3516 right(ios); 3517 { 3518 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3519 std::string ex(str, iter.base()); 3520 assert(ex == "*******************+1E+09"); 3521 assert(ios.width() == 0); 3522 } 3523 ios.width(25); 3524 internal(ios); 3525 { 3526 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3527 std::string ex(str, iter.base()); 3528 assert(ex == "+*******************1E+09"); 3529 assert(ios.width() == 0); 3530 } 3531 } 3532 } 3533 showpoint(ios); 3534 { 3535 ios.imbue(lc); 3536 { 3537 ios.width(0); 3538 { 3539 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3540 std::string ex(str, iter.base()); 3541 assert(ex == "+1.E+09"); 3542 assert(ios.width() == 0); 3543 } 3544 ios.width(25); 3545 left(ios); 3546 { 3547 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3548 std::string ex(str, iter.base()); 3549 assert(ex == "+1.E+09******************"); 3550 assert(ios.width() == 0); 3551 } 3552 ios.width(25); 3553 right(ios); 3554 { 3555 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3556 std::string ex(str, iter.base()); 3557 assert(ex == "******************+1.E+09"); 3558 assert(ios.width() == 0); 3559 } 3560 ios.width(25); 3561 internal(ios); 3562 { 3563 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3564 std::string ex(str, iter.base()); 3565 assert(ex == "+******************1.E+09"); 3566 assert(ios.width() == 0); 3567 } 3568 } 3569 ios.imbue(lg); 3570 { 3571 ios.width(0); 3572 { 3573 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3574 std::string ex(str, iter.base()); 3575 assert(ex == "+1;E+09"); 3576 assert(ios.width() == 0); 3577 } 3578 ios.width(25); 3579 left(ios); 3580 { 3581 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3582 std::string ex(str, iter.base()); 3583 assert(ex == "+1;E+09******************"); 3584 assert(ios.width() == 0); 3585 } 3586 ios.width(25); 3587 right(ios); 3588 { 3589 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3590 std::string ex(str, iter.base()); 3591 assert(ex == "******************+1;E+09"); 3592 assert(ios.width() == 0); 3593 } 3594 ios.width(25); 3595 internal(ios); 3596 { 3597 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3598 std::string ex(str, iter.base()); 3599 assert(ex == "+******************1;E+09"); 3600 assert(ios.width() == 0); 3601 } 3602 } 3603 } 3604 } 3605 } 3606 } 3607 ios.precision(1); 3608 { 3609 nouppercase(ios); 3610 { 3611 noshowpos(ios); 3612 { 3613 noshowpoint(ios); 3614 { 3615 ios.imbue(lc); 3616 { 3617 ios.width(0); 3618 { 3619 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3620 std::string ex(str, iter.base()); 3621 assert(ex == "1e+09"); 3622 assert(ios.width() == 0); 3623 } 3624 ios.width(25); 3625 left(ios); 3626 { 3627 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3628 std::string ex(str, iter.base()); 3629 assert(ex == "1e+09********************"); 3630 assert(ios.width() == 0); 3631 } 3632 ios.width(25); 3633 right(ios); 3634 { 3635 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3636 std::string ex(str, iter.base()); 3637 assert(ex == "********************1e+09"); 3638 assert(ios.width() == 0); 3639 } 3640 ios.width(25); 3641 internal(ios); 3642 { 3643 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3644 std::string ex(str, iter.base()); 3645 assert(ex == "********************1e+09"); 3646 assert(ios.width() == 0); 3647 } 3648 } 3649 ios.imbue(lg); 3650 { 3651 ios.width(0); 3652 { 3653 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3654 std::string ex(str, iter.base()); 3655 assert(ex == "1e+09"); 3656 assert(ios.width() == 0); 3657 } 3658 ios.width(25); 3659 left(ios); 3660 { 3661 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3662 std::string ex(str, iter.base()); 3663 assert(ex == "1e+09********************"); 3664 assert(ios.width() == 0); 3665 } 3666 ios.width(25); 3667 right(ios); 3668 { 3669 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3670 std::string ex(str, iter.base()); 3671 assert(ex == "********************1e+09"); 3672 assert(ios.width() == 0); 3673 } 3674 ios.width(25); 3675 internal(ios); 3676 { 3677 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3678 std::string ex(str, iter.base()); 3679 assert(ex == "********************1e+09"); 3680 assert(ios.width() == 0); 3681 } 3682 } 3683 } 3684 showpoint(ios); 3685 { 3686 ios.imbue(lc); 3687 { 3688 ios.width(0); 3689 { 3690 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3691 std::string ex(str, iter.base()); 3692 assert(ex == "1.e+09"); 3693 assert(ios.width() == 0); 3694 } 3695 ios.width(25); 3696 left(ios); 3697 { 3698 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3699 std::string ex(str, iter.base()); 3700 assert(ex == "1.e+09*******************"); 3701 assert(ios.width() == 0); 3702 } 3703 ios.width(25); 3704 right(ios); 3705 { 3706 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3707 std::string ex(str, iter.base()); 3708 assert(ex == "*******************1.e+09"); 3709 assert(ios.width() == 0); 3710 } 3711 ios.width(25); 3712 internal(ios); 3713 { 3714 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3715 std::string ex(str, iter.base()); 3716 assert(ex == "*******************1.e+09"); 3717 assert(ios.width() == 0); 3718 } 3719 } 3720 ios.imbue(lg); 3721 { 3722 ios.width(0); 3723 { 3724 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3725 std::string ex(str, iter.base()); 3726 assert(ex == "1;e+09"); 3727 assert(ios.width() == 0); 3728 } 3729 ios.width(25); 3730 left(ios); 3731 { 3732 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3733 std::string ex(str, iter.base()); 3734 assert(ex == "1;e+09*******************"); 3735 assert(ios.width() == 0); 3736 } 3737 ios.width(25); 3738 right(ios); 3739 { 3740 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3741 std::string ex(str, iter.base()); 3742 assert(ex == "*******************1;e+09"); 3743 assert(ios.width() == 0); 3744 } 3745 ios.width(25); 3746 internal(ios); 3747 { 3748 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3749 std::string ex(str, iter.base()); 3750 assert(ex == "*******************1;e+09"); 3751 assert(ios.width() == 0); 3752 } 3753 } 3754 } 3755 } 3756 showpos(ios); 3757 { 3758 noshowpoint(ios); 3759 { 3760 ios.imbue(lc); 3761 { 3762 ios.width(0); 3763 { 3764 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3765 std::string ex(str, iter.base()); 3766 assert(ex == "+1e+09"); 3767 assert(ios.width() == 0); 3768 } 3769 ios.width(25); 3770 left(ios); 3771 { 3772 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3773 std::string ex(str, iter.base()); 3774 assert(ex == "+1e+09*******************"); 3775 assert(ios.width() == 0); 3776 } 3777 ios.width(25); 3778 right(ios); 3779 { 3780 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3781 std::string ex(str, iter.base()); 3782 assert(ex == "*******************+1e+09"); 3783 assert(ios.width() == 0); 3784 } 3785 ios.width(25); 3786 internal(ios); 3787 { 3788 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3789 std::string ex(str, iter.base()); 3790 assert(ex == "+*******************1e+09"); 3791 assert(ios.width() == 0); 3792 } 3793 } 3794 ios.imbue(lg); 3795 { 3796 ios.width(0); 3797 { 3798 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3799 std::string ex(str, iter.base()); 3800 assert(ex == "+1e+09"); 3801 assert(ios.width() == 0); 3802 } 3803 ios.width(25); 3804 left(ios); 3805 { 3806 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3807 std::string ex(str, iter.base()); 3808 assert(ex == "+1e+09*******************"); 3809 assert(ios.width() == 0); 3810 } 3811 ios.width(25); 3812 right(ios); 3813 { 3814 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3815 std::string ex(str, iter.base()); 3816 assert(ex == "*******************+1e+09"); 3817 assert(ios.width() == 0); 3818 } 3819 ios.width(25); 3820 internal(ios); 3821 { 3822 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3823 std::string ex(str, iter.base()); 3824 assert(ex == "+*******************1e+09"); 3825 assert(ios.width() == 0); 3826 } 3827 } 3828 } 3829 showpoint(ios); 3830 { 3831 ios.imbue(lc); 3832 { 3833 ios.width(0); 3834 { 3835 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3836 std::string ex(str, iter.base()); 3837 assert(ex == "+1.e+09"); 3838 assert(ios.width() == 0); 3839 } 3840 ios.width(25); 3841 left(ios); 3842 { 3843 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3844 std::string ex(str, iter.base()); 3845 assert(ex == "+1.e+09******************"); 3846 assert(ios.width() == 0); 3847 } 3848 ios.width(25); 3849 right(ios); 3850 { 3851 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3852 std::string ex(str, iter.base()); 3853 assert(ex == "******************+1.e+09"); 3854 assert(ios.width() == 0); 3855 } 3856 ios.width(25); 3857 internal(ios); 3858 { 3859 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3860 std::string ex(str, iter.base()); 3861 assert(ex == "+******************1.e+09"); 3862 assert(ios.width() == 0); 3863 } 3864 } 3865 ios.imbue(lg); 3866 { 3867 ios.width(0); 3868 { 3869 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3870 std::string ex(str, iter.base()); 3871 assert(ex == "+1;e+09"); 3872 assert(ios.width() == 0); 3873 } 3874 ios.width(25); 3875 left(ios); 3876 { 3877 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3878 std::string ex(str, iter.base()); 3879 assert(ex == "+1;e+09******************"); 3880 assert(ios.width() == 0); 3881 } 3882 ios.width(25); 3883 right(ios); 3884 { 3885 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3886 std::string ex(str, iter.base()); 3887 assert(ex == "******************+1;e+09"); 3888 assert(ios.width() == 0); 3889 } 3890 ios.width(25); 3891 internal(ios); 3892 { 3893 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3894 std::string ex(str, iter.base()); 3895 assert(ex == "+******************1;e+09"); 3896 assert(ios.width() == 0); 3897 } 3898 } 3899 } 3900 } 3901 } 3902 uppercase(ios); 3903 { 3904 noshowpos(ios); 3905 { 3906 noshowpoint(ios); 3907 { 3908 ios.imbue(lc); 3909 { 3910 ios.width(0); 3911 { 3912 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3913 std::string ex(str, iter.base()); 3914 assert(ex == "1E+09"); 3915 assert(ios.width() == 0); 3916 } 3917 ios.width(25); 3918 left(ios); 3919 { 3920 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3921 std::string ex(str, iter.base()); 3922 assert(ex == "1E+09********************"); 3923 assert(ios.width() == 0); 3924 } 3925 ios.width(25); 3926 right(ios); 3927 { 3928 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3929 std::string ex(str, iter.base()); 3930 assert(ex == "********************1E+09"); 3931 assert(ios.width() == 0); 3932 } 3933 ios.width(25); 3934 internal(ios); 3935 { 3936 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3937 std::string ex(str, iter.base()); 3938 assert(ex == "********************1E+09"); 3939 assert(ios.width() == 0); 3940 } 3941 } 3942 ios.imbue(lg); 3943 { 3944 ios.width(0); 3945 { 3946 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3947 std::string ex(str, iter.base()); 3948 assert(ex == "1E+09"); 3949 assert(ios.width() == 0); 3950 } 3951 ios.width(25); 3952 left(ios); 3953 { 3954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3955 std::string ex(str, iter.base()); 3956 assert(ex == "1E+09********************"); 3957 assert(ios.width() == 0); 3958 } 3959 ios.width(25); 3960 right(ios); 3961 { 3962 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3963 std::string ex(str, iter.base()); 3964 assert(ex == "********************1E+09"); 3965 assert(ios.width() == 0); 3966 } 3967 ios.width(25); 3968 internal(ios); 3969 { 3970 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3971 std::string ex(str, iter.base()); 3972 assert(ex == "********************1E+09"); 3973 assert(ios.width() == 0); 3974 } 3975 } 3976 } 3977 showpoint(ios); 3978 { 3979 ios.imbue(lc); 3980 { 3981 ios.width(0); 3982 { 3983 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3984 std::string ex(str, iter.base()); 3985 assert(ex == "1.E+09"); 3986 assert(ios.width() == 0); 3987 } 3988 ios.width(25); 3989 left(ios); 3990 { 3991 iter = f.put(output_iterator<char*>(str), ios, '*', v); 3992 std::string ex(str, iter.base()); 3993 assert(ex == "1.E+09*******************"); 3994 assert(ios.width() == 0); 3995 } 3996 ios.width(25); 3997 right(ios); 3998 { 3999 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4000 std::string ex(str, iter.base()); 4001 assert(ex == "*******************1.E+09"); 4002 assert(ios.width() == 0); 4003 } 4004 ios.width(25); 4005 internal(ios); 4006 { 4007 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4008 std::string ex(str, iter.base()); 4009 assert(ex == "*******************1.E+09"); 4010 assert(ios.width() == 0); 4011 } 4012 } 4013 ios.imbue(lg); 4014 { 4015 ios.width(0); 4016 { 4017 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4018 std::string ex(str, iter.base()); 4019 assert(ex == "1;E+09"); 4020 assert(ios.width() == 0); 4021 } 4022 ios.width(25); 4023 left(ios); 4024 { 4025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4026 std::string ex(str, iter.base()); 4027 assert(ex == "1;E+09*******************"); 4028 assert(ios.width() == 0); 4029 } 4030 ios.width(25); 4031 right(ios); 4032 { 4033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4034 std::string ex(str, iter.base()); 4035 assert(ex == "*******************1;E+09"); 4036 assert(ios.width() == 0); 4037 } 4038 ios.width(25); 4039 internal(ios); 4040 { 4041 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4042 std::string ex(str, iter.base()); 4043 assert(ex == "*******************1;E+09"); 4044 assert(ios.width() == 0); 4045 } 4046 } 4047 } 4048 } 4049 showpos(ios); 4050 { 4051 noshowpoint(ios); 4052 { 4053 ios.imbue(lc); 4054 { 4055 ios.width(0); 4056 { 4057 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4058 std::string ex(str, iter.base()); 4059 assert(ex == "+1E+09"); 4060 assert(ios.width() == 0); 4061 } 4062 ios.width(25); 4063 left(ios); 4064 { 4065 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4066 std::string ex(str, iter.base()); 4067 assert(ex == "+1E+09*******************"); 4068 assert(ios.width() == 0); 4069 } 4070 ios.width(25); 4071 right(ios); 4072 { 4073 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4074 std::string ex(str, iter.base()); 4075 assert(ex == "*******************+1E+09"); 4076 assert(ios.width() == 0); 4077 } 4078 ios.width(25); 4079 internal(ios); 4080 { 4081 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4082 std::string ex(str, iter.base()); 4083 assert(ex == "+*******************1E+09"); 4084 assert(ios.width() == 0); 4085 } 4086 } 4087 ios.imbue(lg); 4088 { 4089 ios.width(0); 4090 { 4091 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4092 std::string ex(str, iter.base()); 4093 assert(ex == "+1E+09"); 4094 assert(ios.width() == 0); 4095 } 4096 ios.width(25); 4097 left(ios); 4098 { 4099 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4100 std::string ex(str, iter.base()); 4101 assert(ex == "+1E+09*******************"); 4102 assert(ios.width() == 0); 4103 } 4104 ios.width(25); 4105 right(ios); 4106 { 4107 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4108 std::string ex(str, iter.base()); 4109 assert(ex == "*******************+1E+09"); 4110 assert(ios.width() == 0); 4111 } 4112 ios.width(25); 4113 internal(ios); 4114 { 4115 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4116 std::string ex(str, iter.base()); 4117 assert(ex == "+*******************1E+09"); 4118 assert(ios.width() == 0); 4119 } 4120 } 4121 } 4122 showpoint(ios); 4123 { 4124 ios.imbue(lc); 4125 { 4126 ios.width(0); 4127 { 4128 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4129 std::string ex(str, iter.base()); 4130 assert(ex == "+1.E+09"); 4131 assert(ios.width() == 0); 4132 } 4133 ios.width(25); 4134 left(ios); 4135 { 4136 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4137 std::string ex(str, iter.base()); 4138 assert(ex == "+1.E+09******************"); 4139 assert(ios.width() == 0); 4140 } 4141 ios.width(25); 4142 right(ios); 4143 { 4144 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4145 std::string ex(str, iter.base()); 4146 assert(ex == "******************+1.E+09"); 4147 assert(ios.width() == 0); 4148 } 4149 ios.width(25); 4150 internal(ios); 4151 { 4152 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4153 std::string ex(str, iter.base()); 4154 assert(ex == "+******************1.E+09"); 4155 assert(ios.width() == 0); 4156 } 4157 } 4158 ios.imbue(lg); 4159 { 4160 ios.width(0); 4161 { 4162 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4163 std::string ex(str, iter.base()); 4164 assert(ex == "+1;E+09"); 4165 assert(ios.width() == 0); 4166 } 4167 ios.width(25); 4168 left(ios); 4169 { 4170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4171 std::string ex(str, iter.base()); 4172 assert(ex == "+1;E+09******************"); 4173 assert(ios.width() == 0); 4174 } 4175 ios.width(25); 4176 right(ios); 4177 { 4178 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4179 std::string ex(str, iter.base()); 4180 assert(ex == "******************+1;E+09"); 4181 assert(ios.width() == 0); 4182 } 4183 ios.width(25); 4184 internal(ios); 4185 { 4186 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4187 std::string ex(str, iter.base()); 4188 assert(ex == "+******************1;E+09"); 4189 assert(ios.width() == 0); 4190 } 4191 } 4192 } 4193 } 4194 } 4195 } 4196 ios.precision(6); 4197 { 4198 nouppercase(ios); 4199 { 4200 noshowpos(ios); 4201 { 4202 noshowpoint(ios); 4203 { 4204 ios.imbue(lc); 4205 { 4206 ios.width(0); 4207 { 4208 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4209 std::string ex(str, iter.base()); 4210 assert(ex == "1.23457e+09"); 4211 assert(ios.width() == 0); 4212 } 4213 ios.width(25); 4214 left(ios); 4215 { 4216 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4217 std::string ex(str, iter.base()); 4218 assert(ex == "1.23457e+09**************"); 4219 assert(ios.width() == 0); 4220 } 4221 ios.width(25); 4222 right(ios); 4223 { 4224 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4225 std::string ex(str, iter.base()); 4226 assert(ex == "**************1.23457e+09"); 4227 assert(ios.width() == 0); 4228 } 4229 ios.width(25); 4230 internal(ios); 4231 { 4232 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4233 std::string ex(str, iter.base()); 4234 assert(ex == "**************1.23457e+09"); 4235 assert(ios.width() == 0); 4236 } 4237 } 4238 ios.imbue(lg); 4239 { 4240 ios.width(0); 4241 { 4242 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4243 std::string ex(str, iter.base()); 4244 assert(ex == "1;23457e+09"); 4245 assert(ios.width() == 0); 4246 } 4247 ios.width(25); 4248 left(ios); 4249 { 4250 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4251 std::string ex(str, iter.base()); 4252 assert(ex == "1;23457e+09**************"); 4253 assert(ios.width() == 0); 4254 } 4255 ios.width(25); 4256 right(ios); 4257 { 4258 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4259 std::string ex(str, iter.base()); 4260 assert(ex == "**************1;23457e+09"); 4261 assert(ios.width() == 0); 4262 } 4263 ios.width(25); 4264 internal(ios); 4265 { 4266 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4267 std::string ex(str, iter.base()); 4268 assert(ex == "**************1;23457e+09"); 4269 assert(ios.width() == 0); 4270 } 4271 } 4272 } 4273 showpoint(ios); 4274 { 4275 ios.imbue(lc); 4276 { 4277 ios.width(0); 4278 { 4279 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4280 std::string ex(str, iter.base()); 4281 assert(ex == "1.23457e+09"); 4282 assert(ios.width() == 0); 4283 } 4284 ios.width(25); 4285 left(ios); 4286 { 4287 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4288 std::string ex(str, iter.base()); 4289 assert(ex == "1.23457e+09**************"); 4290 assert(ios.width() == 0); 4291 } 4292 ios.width(25); 4293 right(ios); 4294 { 4295 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4296 std::string ex(str, iter.base()); 4297 assert(ex == "**************1.23457e+09"); 4298 assert(ios.width() == 0); 4299 } 4300 ios.width(25); 4301 internal(ios); 4302 { 4303 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4304 std::string ex(str, iter.base()); 4305 assert(ex == "**************1.23457e+09"); 4306 assert(ios.width() == 0); 4307 } 4308 } 4309 ios.imbue(lg); 4310 { 4311 ios.width(0); 4312 { 4313 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4314 std::string ex(str, iter.base()); 4315 assert(ex == "1;23457e+09"); 4316 assert(ios.width() == 0); 4317 } 4318 ios.width(25); 4319 left(ios); 4320 { 4321 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4322 std::string ex(str, iter.base()); 4323 assert(ex == "1;23457e+09**************"); 4324 assert(ios.width() == 0); 4325 } 4326 ios.width(25); 4327 right(ios); 4328 { 4329 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4330 std::string ex(str, iter.base()); 4331 assert(ex == "**************1;23457e+09"); 4332 assert(ios.width() == 0); 4333 } 4334 ios.width(25); 4335 internal(ios); 4336 { 4337 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4338 std::string ex(str, iter.base()); 4339 assert(ex == "**************1;23457e+09"); 4340 assert(ios.width() == 0); 4341 } 4342 } 4343 } 4344 } 4345 showpos(ios); 4346 { 4347 noshowpoint(ios); 4348 { 4349 ios.imbue(lc); 4350 { 4351 ios.width(0); 4352 { 4353 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4354 std::string ex(str, iter.base()); 4355 assert(ex == "+1.23457e+09"); 4356 assert(ios.width() == 0); 4357 } 4358 ios.width(25); 4359 left(ios); 4360 { 4361 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4362 std::string ex(str, iter.base()); 4363 assert(ex == "+1.23457e+09*************"); 4364 assert(ios.width() == 0); 4365 } 4366 ios.width(25); 4367 right(ios); 4368 { 4369 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4370 std::string ex(str, iter.base()); 4371 assert(ex == "*************+1.23457e+09"); 4372 assert(ios.width() == 0); 4373 } 4374 ios.width(25); 4375 internal(ios); 4376 { 4377 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4378 std::string ex(str, iter.base()); 4379 assert(ex == "+*************1.23457e+09"); 4380 assert(ios.width() == 0); 4381 } 4382 } 4383 ios.imbue(lg); 4384 { 4385 ios.width(0); 4386 { 4387 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4388 std::string ex(str, iter.base()); 4389 assert(ex == "+1;23457e+09"); 4390 assert(ios.width() == 0); 4391 } 4392 ios.width(25); 4393 left(ios); 4394 { 4395 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4396 std::string ex(str, iter.base()); 4397 assert(ex == "+1;23457e+09*************"); 4398 assert(ios.width() == 0); 4399 } 4400 ios.width(25); 4401 right(ios); 4402 { 4403 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4404 std::string ex(str, iter.base()); 4405 assert(ex == "*************+1;23457e+09"); 4406 assert(ios.width() == 0); 4407 } 4408 ios.width(25); 4409 internal(ios); 4410 { 4411 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4412 std::string ex(str, iter.base()); 4413 assert(ex == "+*************1;23457e+09"); 4414 assert(ios.width() == 0); 4415 } 4416 } 4417 } 4418 showpoint(ios); 4419 { 4420 ios.imbue(lc); 4421 { 4422 ios.width(0); 4423 { 4424 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4425 std::string ex(str, iter.base()); 4426 assert(ex == "+1.23457e+09"); 4427 assert(ios.width() == 0); 4428 } 4429 ios.width(25); 4430 left(ios); 4431 { 4432 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4433 std::string ex(str, iter.base()); 4434 assert(ex == "+1.23457e+09*************"); 4435 assert(ios.width() == 0); 4436 } 4437 ios.width(25); 4438 right(ios); 4439 { 4440 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4441 std::string ex(str, iter.base()); 4442 assert(ex == "*************+1.23457e+09"); 4443 assert(ios.width() == 0); 4444 } 4445 ios.width(25); 4446 internal(ios); 4447 { 4448 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4449 std::string ex(str, iter.base()); 4450 assert(ex == "+*************1.23457e+09"); 4451 assert(ios.width() == 0); 4452 } 4453 } 4454 ios.imbue(lg); 4455 { 4456 ios.width(0); 4457 { 4458 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4459 std::string ex(str, iter.base()); 4460 assert(ex == "+1;23457e+09"); 4461 assert(ios.width() == 0); 4462 } 4463 ios.width(25); 4464 left(ios); 4465 { 4466 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4467 std::string ex(str, iter.base()); 4468 assert(ex == "+1;23457e+09*************"); 4469 assert(ios.width() == 0); 4470 } 4471 ios.width(25); 4472 right(ios); 4473 { 4474 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4475 std::string ex(str, iter.base()); 4476 assert(ex == "*************+1;23457e+09"); 4477 assert(ios.width() == 0); 4478 } 4479 ios.width(25); 4480 internal(ios); 4481 { 4482 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4483 std::string ex(str, iter.base()); 4484 assert(ex == "+*************1;23457e+09"); 4485 assert(ios.width() == 0); 4486 } 4487 } 4488 } 4489 } 4490 } 4491 uppercase(ios); 4492 { 4493 noshowpos(ios); 4494 { 4495 noshowpoint(ios); 4496 { 4497 ios.imbue(lc); 4498 { 4499 ios.width(0); 4500 { 4501 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4502 std::string ex(str, iter.base()); 4503 assert(ex == "1.23457E+09"); 4504 assert(ios.width() == 0); 4505 } 4506 ios.width(25); 4507 left(ios); 4508 { 4509 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4510 std::string ex(str, iter.base()); 4511 assert(ex == "1.23457E+09**************"); 4512 assert(ios.width() == 0); 4513 } 4514 ios.width(25); 4515 right(ios); 4516 { 4517 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4518 std::string ex(str, iter.base()); 4519 assert(ex == "**************1.23457E+09"); 4520 assert(ios.width() == 0); 4521 } 4522 ios.width(25); 4523 internal(ios); 4524 { 4525 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4526 std::string ex(str, iter.base()); 4527 assert(ex == "**************1.23457E+09"); 4528 assert(ios.width() == 0); 4529 } 4530 } 4531 ios.imbue(lg); 4532 { 4533 ios.width(0); 4534 { 4535 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4536 std::string ex(str, iter.base()); 4537 assert(ex == "1;23457E+09"); 4538 assert(ios.width() == 0); 4539 } 4540 ios.width(25); 4541 left(ios); 4542 { 4543 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4544 std::string ex(str, iter.base()); 4545 assert(ex == "1;23457E+09**************"); 4546 assert(ios.width() == 0); 4547 } 4548 ios.width(25); 4549 right(ios); 4550 { 4551 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4552 std::string ex(str, iter.base()); 4553 assert(ex == "**************1;23457E+09"); 4554 assert(ios.width() == 0); 4555 } 4556 ios.width(25); 4557 internal(ios); 4558 { 4559 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4560 std::string ex(str, iter.base()); 4561 assert(ex == "**************1;23457E+09"); 4562 assert(ios.width() == 0); 4563 } 4564 } 4565 } 4566 showpoint(ios); 4567 { 4568 ios.imbue(lc); 4569 { 4570 ios.width(0); 4571 { 4572 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4573 std::string ex(str, iter.base()); 4574 assert(ex == "1.23457E+09"); 4575 assert(ios.width() == 0); 4576 } 4577 ios.width(25); 4578 left(ios); 4579 { 4580 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4581 std::string ex(str, iter.base()); 4582 assert(ex == "1.23457E+09**************"); 4583 assert(ios.width() == 0); 4584 } 4585 ios.width(25); 4586 right(ios); 4587 { 4588 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4589 std::string ex(str, iter.base()); 4590 assert(ex == "**************1.23457E+09"); 4591 assert(ios.width() == 0); 4592 } 4593 ios.width(25); 4594 internal(ios); 4595 { 4596 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4597 std::string ex(str, iter.base()); 4598 assert(ex == "**************1.23457E+09"); 4599 assert(ios.width() == 0); 4600 } 4601 } 4602 ios.imbue(lg); 4603 { 4604 ios.width(0); 4605 { 4606 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4607 std::string ex(str, iter.base()); 4608 assert(ex == "1;23457E+09"); 4609 assert(ios.width() == 0); 4610 } 4611 ios.width(25); 4612 left(ios); 4613 { 4614 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4615 std::string ex(str, iter.base()); 4616 assert(ex == "1;23457E+09**************"); 4617 assert(ios.width() == 0); 4618 } 4619 ios.width(25); 4620 right(ios); 4621 { 4622 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4623 std::string ex(str, iter.base()); 4624 assert(ex == "**************1;23457E+09"); 4625 assert(ios.width() == 0); 4626 } 4627 ios.width(25); 4628 internal(ios); 4629 { 4630 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4631 std::string ex(str, iter.base()); 4632 assert(ex == "**************1;23457E+09"); 4633 assert(ios.width() == 0); 4634 } 4635 } 4636 } 4637 } 4638 showpos(ios); 4639 { 4640 noshowpoint(ios); 4641 { 4642 ios.imbue(lc); 4643 { 4644 ios.width(0); 4645 { 4646 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4647 std::string ex(str, iter.base()); 4648 assert(ex == "+1.23457E+09"); 4649 assert(ios.width() == 0); 4650 } 4651 ios.width(25); 4652 left(ios); 4653 { 4654 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4655 std::string ex(str, iter.base()); 4656 assert(ex == "+1.23457E+09*************"); 4657 assert(ios.width() == 0); 4658 } 4659 ios.width(25); 4660 right(ios); 4661 { 4662 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4663 std::string ex(str, iter.base()); 4664 assert(ex == "*************+1.23457E+09"); 4665 assert(ios.width() == 0); 4666 } 4667 ios.width(25); 4668 internal(ios); 4669 { 4670 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4671 std::string ex(str, iter.base()); 4672 assert(ex == "+*************1.23457E+09"); 4673 assert(ios.width() == 0); 4674 } 4675 } 4676 ios.imbue(lg); 4677 { 4678 ios.width(0); 4679 { 4680 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4681 std::string ex(str, iter.base()); 4682 assert(ex == "+1;23457E+09"); 4683 assert(ios.width() == 0); 4684 } 4685 ios.width(25); 4686 left(ios); 4687 { 4688 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4689 std::string ex(str, iter.base()); 4690 assert(ex == "+1;23457E+09*************"); 4691 assert(ios.width() == 0); 4692 } 4693 ios.width(25); 4694 right(ios); 4695 { 4696 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4697 std::string ex(str, iter.base()); 4698 assert(ex == "*************+1;23457E+09"); 4699 assert(ios.width() == 0); 4700 } 4701 ios.width(25); 4702 internal(ios); 4703 { 4704 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4705 std::string ex(str, iter.base()); 4706 assert(ex == "+*************1;23457E+09"); 4707 assert(ios.width() == 0); 4708 } 4709 } 4710 } 4711 showpoint(ios); 4712 { 4713 ios.imbue(lc); 4714 { 4715 ios.width(0); 4716 { 4717 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4718 std::string ex(str, iter.base()); 4719 assert(ex == "+1.23457E+09"); 4720 assert(ios.width() == 0); 4721 } 4722 ios.width(25); 4723 left(ios); 4724 { 4725 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4726 std::string ex(str, iter.base()); 4727 assert(ex == "+1.23457E+09*************"); 4728 assert(ios.width() == 0); 4729 } 4730 ios.width(25); 4731 right(ios); 4732 { 4733 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4734 std::string ex(str, iter.base()); 4735 assert(ex == "*************+1.23457E+09"); 4736 assert(ios.width() == 0); 4737 } 4738 ios.width(25); 4739 internal(ios); 4740 { 4741 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4742 std::string ex(str, iter.base()); 4743 assert(ex == "+*************1.23457E+09"); 4744 assert(ios.width() == 0); 4745 } 4746 } 4747 ios.imbue(lg); 4748 { 4749 ios.width(0); 4750 { 4751 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4752 std::string ex(str, iter.base()); 4753 assert(ex == "+1;23457E+09"); 4754 assert(ios.width() == 0); 4755 } 4756 ios.width(25); 4757 left(ios); 4758 { 4759 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4760 std::string ex(str, iter.base()); 4761 assert(ex == "+1;23457E+09*************"); 4762 assert(ios.width() == 0); 4763 } 4764 ios.width(25); 4765 right(ios); 4766 { 4767 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4768 std::string ex(str, iter.base()); 4769 assert(ex == "*************+1;23457E+09"); 4770 assert(ios.width() == 0); 4771 } 4772 ios.width(25); 4773 internal(ios); 4774 { 4775 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4776 std::string ex(str, iter.base()); 4777 assert(ex == "+*************1;23457E+09"); 4778 assert(ios.width() == 0); 4779 } 4780 } 4781 } 4782 } 4783 } 4784 } 4785 ios.precision(16); 4786 { 4787 nouppercase(ios); 4788 { 4789 noshowpos(ios); 4790 { 4791 noshowpoint(ios); 4792 { 4793 ios.imbue(lc); 4794 { 4795 ios.width(0); 4796 { 4797 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4798 std::string ex(str, iter.base()); 4799 assert(ex == "1234567890.125"); 4800 assert(ios.width() == 0); 4801 } 4802 ios.width(25); 4803 left(ios); 4804 { 4805 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4806 std::string ex(str, iter.base()); 4807 assert(ex == "1234567890.125***********"); 4808 assert(ios.width() == 0); 4809 } 4810 ios.width(25); 4811 right(ios); 4812 { 4813 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4814 std::string ex(str, iter.base()); 4815 assert(ex == "***********1234567890.125"); 4816 assert(ios.width() == 0); 4817 } 4818 ios.width(25); 4819 internal(ios); 4820 { 4821 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4822 std::string ex(str, iter.base()); 4823 assert(ex == "***********1234567890.125"); 4824 assert(ios.width() == 0); 4825 } 4826 } 4827 ios.imbue(lg); 4828 { 4829 ios.width(0); 4830 { 4831 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4832 std::string ex(str, iter.base()); 4833 assert(ex == "1_234_567_89_0;125"); 4834 assert(ios.width() == 0); 4835 } 4836 ios.width(25); 4837 left(ios); 4838 { 4839 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4840 std::string ex(str, iter.base()); 4841 assert(ex == "1_234_567_89_0;125*******"); 4842 assert(ios.width() == 0); 4843 } 4844 ios.width(25); 4845 right(ios); 4846 { 4847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4848 std::string ex(str, iter.base()); 4849 assert(ex == "*******1_234_567_89_0;125"); 4850 assert(ios.width() == 0); 4851 } 4852 ios.width(25); 4853 internal(ios); 4854 { 4855 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4856 std::string ex(str, iter.base()); 4857 assert(ex == "*******1_234_567_89_0;125"); 4858 assert(ios.width() == 0); 4859 } 4860 } 4861 } 4862 showpoint(ios); 4863 { 4864 ios.imbue(lc); 4865 { 4866 ios.width(0); 4867 { 4868 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4869 std::string ex(str, iter.base()); 4870 assert(ex == "1234567890.125000"); 4871 assert(ios.width() == 0); 4872 } 4873 ios.width(25); 4874 left(ios); 4875 { 4876 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4877 std::string ex(str, iter.base()); 4878 assert(ex == "1234567890.125000********"); 4879 assert(ios.width() == 0); 4880 } 4881 ios.width(25); 4882 right(ios); 4883 { 4884 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4885 std::string ex(str, iter.base()); 4886 assert(ex == "********1234567890.125000"); 4887 assert(ios.width() == 0); 4888 } 4889 ios.width(25); 4890 internal(ios); 4891 { 4892 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4893 std::string ex(str, iter.base()); 4894 assert(ex == "********1234567890.125000"); 4895 assert(ios.width() == 0); 4896 } 4897 } 4898 ios.imbue(lg); 4899 { 4900 ios.width(0); 4901 { 4902 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4903 std::string ex(str, iter.base()); 4904 assert(ex == "1_234_567_89_0;125000"); 4905 assert(ios.width() == 0); 4906 } 4907 ios.width(25); 4908 left(ios); 4909 { 4910 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4911 std::string ex(str, iter.base()); 4912 assert(ex == "1_234_567_89_0;125000****"); 4913 assert(ios.width() == 0); 4914 } 4915 ios.width(25); 4916 right(ios); 4917 { 4918 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4919 std::string ex(str, iter.base()); 4920 assert(ex == "****1_234_567_89_0;125000"); 4921 assert(ios.width() == 0); 4922 } 4923 ios.width(25); 4924 internal(ios); 4925 { 4926 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4927 std::string ex(str, iter.base()); 4928 assert(ex == "****1_234_567_89_0;125000"); 4929 assert(ios.width() == 0); 4930 } 4931 } 4932 } 4933 } 4934 showpos(ios); 4935 { 4936 noshowpoint(ios); 4937 { 4938 ios.imbue(lc); 4939 { 4940 ios.width(0); 4941 { 4942 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4943 std::string ex(str, iter.base()); 4944 assert(ex == "+1234567890.125"); 4945 assert(ios.width() == 0); 4946 } 4947 ios.width(25); 4948 left(ios); 4949 { 4950 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4951 std::string ex(str, iter.base()); 4952 assert(ex == "+1234567890.125**********"); 4953 assert(ios.width() == 0); 4954 } 4955 ios.width(25); 4956 right(ios); 4957 { 4958 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4959 std::string ex(str, iter.base()); 4960 assert(ex == "**********+1234567890.125"); 4961 assert(ios.width() == 0); 4962 } 4963 ios.width(25); 4964 internal(ios); 4965 { 4966 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4967 std::string ex(str, iter.base()); 4968 assert(ex == "+**********1234567890.125"); 4969 assert(ios.width() == 0); 4970 } 4971 } 4972 ios.imbue(lg); 4973 { 4974 ios.width(0); 4975 { 4976 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4977 std::string ex(str, iter.base()); 4978 assert(ex == "+1_234_567_89_0;125"); 4979 assert(ios.width() == 0); 4980 } 4981 ios.width(25); 4982 left(ios); 4983 { 4984 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4985 std::string ex(str, iter.base()); 4986 assert(ex == "+1_234_567_89_0;125******"); 4987 assert(ios.width() == 0); 4988 } 4989 ios.width(25); 4990 right(ios); 4991 { 4992 iter = f.put(output_iterator<char*>(str), ios, '*', v); 4993 std::string ex(str, iter.base()); 4994 assert(ex == "******+1_234_567_89_0;125"); 4995 assert(ios.width() == 0); 4996 } 4997 ios.width(25); 4998 internal(ios); 4999 { 5000 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5001 std::string ex(str, iter.base()); 5002 assert(ex == "+******1_234_567_89_0;125"); 5003 assert(ios.width() == 0); 5004 } 5005 } 5006 } 5007 showpoint(ios); 5008 { 5009 ios.imbue(lc); 5010 { 5011 ios.width(0); 5012 { 5013 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5014 std::string ex(str, iter.base()); 5015 assert(ex == "+1234567890.125000"); 5016 assert(ios.width() == 0); 5017 } 5018 ios.width(25); 5019 left(ios); 5020 { 5021 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5022 std::string ex(str, iter.base()); 5023 assert(ex == "+1234567890.125000*******"); 5024 assert(ios.width() == 0); 5025 } 5026 ios.width(25); 5027 right(ios); 5028 { 5029 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5030 std::string ex(str, iter.base()); 5031 assert(ex == "*******+1234567890.125000"); 5032 assert(ios.width() == 0); 5033 } 5034 ios.width(25); 5035 internal(ios); 5036 { 5037 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5038 std::string ex(str, iter.base()); 5039 assert(ex == "+*******1234567890.125000"); 5040 assert(ios.width() == 0); 5041 } 5042 } 5043 ios.imbue(lg); 5044 { 5045 ios.width(0); 5046 { 5047 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5048 std::string ex(str, iter.base()); 5049 assert(ex == "+1_234_567_89_0;125000"); 5050 assert(ios.width() == 0); 5051 } 5052 ios.width(25); 5053 left(ios); 5054 { 5055 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5056 std::string ex(str, iter.base()); 5057 assert(ex == "+1_234_567_89_0;125000***"); 5058 assert(ios.width() == 0); 5059 } 5060 ios.width(25); 5061 right(ios); 5062 { 5063 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5064 std::string ex(str, iter.base()); 5065 assert(ex == "***+1_234_567_89_0;125000"); 5066 assert(ios.width() == 0); 5067 } 5068 ios.width(25); 5069 internal(ios); 5070 { 5071 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5072 std::string ex(str, iter.base()); 5073 assert(ex == "+***1_234_567_89_0;125000"); 5074 assert(ios.width() == 0); 5075 } 5076 } 5077 } 5078 } 5079 } 5080 uppercase(ios); 5081 { 5082 noshowpos(ios); 5083 { 5084 noshowpoint(ios); 5085 { 5086 ios.imbue(lc); 5087 { 5088 ios.width(0); 5089 { 5090 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5091 std::string ex(str, iter.base()); 5092 assert(ex == "1234567890.125"); 5093 assert(ios.width() == 0); 5094 } 5095 ios.width(25); 5096 left(ios); 5097 { 5098 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5099 std::string ex(str, iter.base()); 5100 assert(ex == "1234567890.125***********"); 5101 assert(ios.width() == 0); 5102 } 5103 ios.width(25); 5104 right(ios); 5105 { 5106 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5107 std::string ex(str, iter.base()); 5108 assert(ex == "***********1234567890.125"); 5109 assert(ios.width() == 0); 5110 } 5111 ios.width(25); 5112 internal(ios); 5113 { 5114 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5115 std::string ex(str, iter.base()); 5116 assert(ex == "***********1234567890.125"); 5117 assert(ios.width() == 0); 5118 } 5119 } 5120 ios.imbue(lg); 5121 { 5122 ios.width(0); 5123 { 5124 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5125 std::string ex(str, iter.base()); 5126 assert(ex == "1_234_567_89_0;125"); 5127 assert(ios.width() == 0); 5128 } 5129 ios.width(25); 5130 left(ios); 5131 { 5132 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5133 std::string ex(str, iter.base()); 5134 assert(ex == "1_234_567_89_0;125*******"); 5135 assert(ios.width() == 0); 5136 } 5137 ios.width(25); 5138 right(ios); 5139 { 5140 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5141 std::string ex(str, iter.base()); 5142 assert(ex == "*******1_234_567_89_0;125"); 5143 assert(ios.width() == 0); 5144 } 5145 ios.width(25); 5146 internal(ios); 5147 { 5148 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5149 std::string ex(str, iter.base()); 5150 assert(ex == "*******1_234_567_89_0;125"); 5151 assert(ios.width() == 0); 5152 } 5153 } 5154 } 5155 showpoint(ios); 5156 { 5157 ios.imbue(lc); 5158 { 5159 ios.width(0); 5160 { 5161 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5162 std::string ex(str, iter.base()); 5163 assert(ex == "1234567890.125000"); 5164 assert(ios.width() == 0); 5165 } 5166 ios.width(25); 5167 left(ios); 5168 { 5169 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5170 std::string ex(str, iter.base()); 5171 assert(ex == "1234567890.125000********"); 5172 assert(ios.width() == 0); 5173 } 5174 ios.width(25); 5175 right(ios); 5176 { 5177 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5178 std::string ex(str, iter.base()); 5179 assert(ex == "********1234567890.125000"); 5180 assert(ios.width() == 0); 5181 } 5182 ios.width(25); 5183 internal(ios); 5184 { 5185 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5186 std::string ex(str, iter.base()); 5187 assert(ex == "********1234567890.125000"); 5188 assert(ios.width() == 0); 5189 } 5190 } 5191 ios.imbue(lg); 5192 { 5193 ios.width(0); 5194 { 5195 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5196 std::string ex(str, iter.base()); 5197 assert(ex == "1_234_567_89_0;125000"); 5198 assert(ios.width() == 0); 5199 } 5200 ios.width(25); 5201 left(ios); 5202 { 5203 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5204 std::string ex(str, iter.base()); 5205 assert(ex == "1_234_567_89_0;125000****"); 5206 assert(ios.width() == 0); 5207 } 5208 ios.width(25); 5209 right(ios); 5210 { 5211 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5212 std::string ex(str, iter.base()); 5213 assert(ex == "****1_234_567_89_0;125000"); 5214 assert(ios.width() == 0); 5215 } 5216 ios.width(25); 5217 internal(ios); 5218 { 5219 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5220 std::string ex(str, iter.base()); 5221 assert(ex == "****1_234_567_89_0;125000"); 5222 assert(ios.width() == 0); 5223 } 5224 } 5225 } 5226 } 5227 showpos(ios); 5228 { 5229 noshowpoint(ios); 5230 { 5231 ios.imbue(lc); 5232 { 5233 ios.width(0); 5234 { 5235 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5236 std::string ex(str, iter.base()); 5237 assert(ex == "+1234567890.125"); 5238 assert(ios.width() == 0); 5239 } 5240 ios.width(25); 5241 left(ios); 5242 { 5243 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5244 std::string ex(str, iter.base()); 5245 assert(ex == "+1234567890.125**********"); 5246 assert(ios.width() == 0); 5247 } 5248 ios.width(25); 5249 right(ios); 5250 { 5251 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5252 std::string ex(str, iter.base()); 5253 assert(ex == "**********+1234567890.125"); 5254 assert(ios.width() == 0); 5255 } 5256 ios.width(25); 5257 internal(ios); 5258 { 5259 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5260 std::string ex(str, iter.base()); 5261 assert(ex == "+**********1234567890.125"); 5262 assert(ios.width() == 0); 5263 } 5264 } 5265 ios.imbue(lg); 5266 { 5267 ios.width(0); 5268 { 5269 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5270 std::string ex(str, iter.base()); 5271 assert(ex == "+1_234_567_89_0;125"); 5272 assert(ios.width() == 0); 5273 } 5274 ios.width(25); 5275 left(ios); 5276 { 5277 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5278 std::string ex(str, iter.base()); 5279 assert(ex == "+1_234_567_89_0;125******"); 5280 assert(ios.width() == 0); 5281 } 5282 ios.width(25); 5283 right(ios); 5284 { 5285 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5286 std::string ex(str, iter.base()); 5287 assert(ex == "******+1_234_567_89_0;125"); 5288 assert(ios.width() == 0); 5289 } 5290 ios.width(25); 5291 internal(ios); 5292 { 5293 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5294 std::string ex(str, iter.base()); 5295 assert(ex == "+******1_234_567_89_0;125"); 5296 assert(ios.width() == 0); 5297 } 5298 } 5299 } 5300 showpoint(ios); 5301 { 5302 ios.imbue(lc); 5303 { 5304 ios.width(0); 5305 { 5306 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5307 std::string ex(str, iter.base()); 5308 assert(ex == "+1234567890.125000"); 5309 assert(ios.width() == 0); 5310 } 5311 ios.width(25); 5312 left(ios); 5313 { 5314 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5315 std::string ex(str, iter.base()); 5316 assert(ex == "+1234567890.125000*******"); 5317 assert(ios.width() == 0); 5318 } 5319 ios.width(25); 5320 right(ios); 5321 { 5322 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5323 std::string ex(str, iter.base()); 5324 assert(ex == "*******+1234567890.125000"); 5325 assert(ios.width() == 0); 5326 } 5327 ios.width(25); 5328 internal(ios); 5329 { 5330 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5331 std::string ex(str, iter.base()); 5332 assert(ex == "+*******1234567890.125000"); 5333 assert(ios.width() == 0); 5334 } 5335 } 5336 ios.imbue(lg); 5337 { 5338 ios.width(0); 5339 { 5340 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5341 std::string ex(str, iter.base()); 5342 assert(ex == "+1_234_567_89_0;125000"); 5343 assert(ios.width() == 0); 5344 } 5345 ios.width(25); 5346 left(ios); 5347 { 5348 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5349 std::string ex(str, iter.base()); 5350 assert(ex == "+1_234_567_89_0;125000***"); 5351 assert(ios.width() == 0); 5352 } 5353 ios.width(25); 5354 right(ios); 5355 { 5356 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5357 std::string ex(str, iter.base()); 5358 assert(ex == "***+1_234_567_89_0;125000"); 5359 assert(ios.width() == 0); 5360 } 5361 ios.width(25); 5362 internal(ios); 5363 { 5364 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5365 std::string ex(str, iter.base()); 5366 assert(ex == "+***1_234_567_89_0;125000"); 5367 assert(ios.width() == 0); 5368 } 5369 } 5370 } 5371 } 5372 } 5373 } 5374 ios.precision(60); 5375 { 5376 nouppercase(ios); 5377 { 5378 noshowpos(ios); 5379 { 5380 noshowpoint(ios); 5381 { 5382 ios.imbue(lc); 5383 { 5384 ios.width(0); 5385 { 5386 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5387 std::string ex(str, iter.base()); 5388 assert(ex == "1234567890.125"); 5389 assert(ios.width() == 0); 5390 } 5391 ios.width(25); 5392 left(ios); 5393 { 5394 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5395 std::string ex(str, iter.base()); 5396 assert(ex == "1234567890.125***********"); 5397 assert(ios.width() == 0); 5398 } 5399 ios.width(25); 5400 right(ios); 5401 { 5402 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5403 std::string ex(str, iter.base()); 5404 assert(ex == "***********1234567890.125"); 5405 assert(ios.width() == 0); 5406 } 5407 ios.width(25); 5408 internal(ios); 5409 { 5410 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5411 std::string ex(str, iter.base()); 5412 assert(ex == "***********1234567890.125"); 5413 assert(ios.width() == 0); 5414 } 5415 } 5416 ios.imbue(lg); 5417 { 5418 ios.width(0); 5419 { 5420 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5421 std::string ex(str, iter.base()); 5422 assert(ex == "1_234_567_89_0;125"); 5423 assert(ios.width() == 0); 5424 } 5425 ios.width(25); 5426 left(ios); 5427 { 5428 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5429 std::string ex(str, iter.base()); 5430 assert(ex == "1_234_567_89_0;125*******"); 5431 assert(ios.width() == 0); 5432 } 5433 ios.width(25); 5434 right(ios); 5435 { 5436 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5437 std::string ex(str, iter.base()); 5438 assert(ex == "*******1_234_567_89_0;125"); 5439 assert(ios.width() == 0); 5440 } 5441 ios.width(25); 5442 internal(ios); 5443 { 5444 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5445 std::string ex(str, iter.base()); 5446 assert(ex == "*******1_234_567_89_0;125"); 5447 assert(ios.width() == 0); 5448 } 5449 } 5450 } 5451 showpoint(ios); 5452 { 5453 ios.imbue(lc); 5454 { 5455 ios.width(0); 5456 { 5457 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5458 std::string ex(str, iter.base()); 5459 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5460 assert(ios.width() == 0); 5461 } 5462 ios.width(25); 5463 left(ios); 5464 { 5465 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5466 std::string ex(str, iter.base()); 5467 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5468 assert(ios.width() == 0); 5469 } 5470 ios.width(25); 5471 right(ios); 5472 { 5473 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5474 std::string ex(str, iter.base()); 5475 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5476 assert(ios.width() == 0); 5477 } 5478 ios.width(25); 5479 internal(ios); 5480 { 5481 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5482 std::string ex(str, iter.base()); 5483 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5484 assert(ios.width() == 0); 5485 } 5486 } 5487 ios.imbue(lg); 5488 { 5489 ios.width(0); 5490 { 5491 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5492 std::string ex(str, iter.base()); 5493 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5494 assert(ios.width() == 0); 5495 } 5496 ios.width(25); 5497 left(ios); 5498 { 5499 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5500 std::string ex(str, iter.base()); 5501 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5502 assert(ios.width() == 0); 5503 } 5504 ios.width(25); 5505 right(ios); 5506 { 5507 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5508 std::string ex(str, iter.base()); 5509 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5510 assert(ios.width() == 0); 5511 } 5512 ios.width(25); 5513 internal(ios); 5514 { 5515 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5516 std::string ex(str, iter.base()); 5517 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5518 assert(ios.width() == 0); 5519 } 5520 } 5521 } 5522 } 5523 showpos(ios); 5524 { 5525 noshowpoint(ios); 5526 { 5527 ios.imbue(lc); 5528 { 5529 ios.width(0); 5530 { 5531 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5532 std::string ex(str, iter.base()); 5533 assert(ex == "+1234567890.125"); 5534 assert(ios.width() == 0); 5535 } 5536 ios.width(25); 5537 left(ios); 5538 { 5539 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5540 std::string ex(str, iter.base()); 5541 assert(ex == "+1234567890.125**********"); 5542 assert(ios.width() == 0); 5543 } 5544 ios.width(25); 5545 right(ios); 5546 { 5547 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5548 std::string ex(str, iter.base()); 5549 assert(ex == "**********+1234567890.125"); 5550 assert(ios.width() == 0); 5551 } 5552 ios.width(25); 5553 internal(ios); 5554 { 5555 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5556 std::string ex(str, iter.base()); 5557 assert(ex == "+**********1234567890.125"); 5558 assert(ios.width() == 0); 5559 } 5560 } 5561 ios.imbue(lg); 5562 { 5563 ios.width(0); 5564 { 5565 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5566 std::string ex(str, iter.base()); 5567 assert(ex == "+1_234_567_89_0;125"); 5568 assert(ios.width() == 0); 5569 } 5570 ios.width(25); 5571 left(ios); 5572 { 5573 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5574 std::string ex(str, iter.base()); 5575 assert(ex == "+1_234_567_89_0;125******"); 5576 assert(ios.width() == 0); 5577 } 5578 ios.width(25); 5579 right(ios); 5580 { 5581 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5582 std::string ex(str, iter.base()); 5583 assert(ex == "******+1_234_567_89_0;125"); 5584 assert(ios.width() == 0); 5585 } 5586 ios.width(25); 5587 internal(ios); 5588 { 5589 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5590 std::string ex(str, iter.base()); 5591 assert(ex == "+******1_234_567_89_0;125"); 5592 assert(ios.width() == 0); 5593 } 5594 } 5595 } 5596 showpoint(ios); 5597 { 5598 ios.imbue(lc); 5599 { 5600 ios.width(0); 5601 { 5602 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5603 std::string ex(str, iter.base()); 5604 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5605 assert(ios.width() == 0); 5606 } 5607 ios.width(25); 5608 left(ios); 5609 { 5610 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5611 std::string ex(str, iter.base()); 5612 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5613 assert(ios.width() == 0); 5614 } 5615 ios.width(25); 5616 right(ios); 5617 { 5618 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5619 std::string ex(str, iter.base()); 5620 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5621 assert(ios.width() == 0); 5622 } 5623 ios.width(25); 5624 internal(ios); 5625 { 5626 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5627 std::string ex(str, iter.base()); 5628 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5629 assert(ios.width() == 0); 5630 } 5631 } 5632 ios.imbue(lg); 5633 { 5634 ios.width(0); 5635 { 5636 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5637 std::string ex(str, iter.base()); 5638 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5639 assert(ios.width() == 0); 5640 } 5641 ios.width(25); 5642 left(ios); 5643 { 5644 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5645 std::string ex(str, iter.base()); 5646 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5647 assert(ios.width() == 0); 5648 } 5649 ios.width(25); 5650 right(ios); 5651 { 5652 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5653 std::string ex(str, iter.base()); 5654 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5655 assert(ios.width() == 0); 5656 } 5657 ios.width(25); 5658 internal(ios); 5659 { 5660 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5661 std::string ex(str, iter.base()); 5662 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5663 assert(ios.width() == 0); 5664 } 5665 } 5666 } 5667 } 5668 } 5669 uppercase(ios); 5670 { 5671 noshowpos(ios); 5672 { 5673 noshowpoint(ios); 5674 { 5675 ios.imbue(lc); 5676 { 5677 ios.width(0); 5678 { 5679 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5680 std::string ex(str, iter.base()); 5681 assert(ex == "1234567890.125"); 5682 assert(ios.width() == 0); 5683 } 5684 ios.width(25); 5685 left(ios); 5686 { 5687 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5688 std::string ex(str, iter.base()); 5689 assert(ex == "1234567890.125***********"); 5690 assert(ios.width() == 0); 5691 } 5692 ios.width(25); 5693 right(ios); 5694 { 5695 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5696 std::string ex(str, iter.base()); 5697 assert(ex == "***********1234567890.125"); 5698 assert(ios.width() == 0); 5699 } 5700 ios.width(25); 5701 internal(ios); 5702 { 5703 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5704 std::string ex(str, iter.base()); 5705 assert(ex == "***********1234567890.125"); 5706 assert(ios.width() == 0); 5707 } 5708 } 5709 ios.imbue(lg); 5710 { 5711 ios.width(0); 5712 { 5713 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5714 std::string ex(str, iter.base()); 5715 assert(ex == "1_234_567_89_0;125"); 5716 assert(ios.width() == 0); 5717 } 5718 ios.width(25); 5719 left(ios); 5720 { 5721 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5722 std::string ex(str, iter.base()); 5723 assert(ex == "1_234_567_89_0;125*******"); 5724 assert(ios.width() == 0); 5725 } 5726 ios.width(25); 5727 right(ios); 5728 { 5729 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5730 std::string ex(str, iter.base()); 5731 assert(ex == "*******1_234_567_89_0;125"); 5732 assert(ios.width() == 0); 5733 } 5734 ios.width(25); 5735 internal(ios); 5736 { 5737 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5738 std::string ex(str, iter.base()); 5739 assert(ex == "*******1_234_567_89_0;125"); 5740 assert(ios.width() == 0); 5741 } 5742 } 5743 } 5744 showpoint(ios); 5745 { 5746 ios.imbue(lc); 5747 { 5748 ios.width(0); 5749 { 5750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5751 std::string ex(str, iter.base()); 5752 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5753 assert(ios.width() == 0); 5754 } 5755 ios.width(25); 5756 left(ios); 5757 { 5758 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5759 std::string ex(str, iter.base()); 5760 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5761 assert(ios.width() == 0); 5762 } 5763 ios.width(25); 5764 right(ios); 5765 { 5766 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5767 std::string ex(str, iter.base()); 5768 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5769 assert(ios.width() == 0); 5770 } 5771 ios.width(25); 5772 internal(ios); 5773 { 5774 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5775 std::string ex(str, iter.base()); 5776 assert(ex == "1234567890.12500000000000000000000000000000000000000000000000"); 5777 assert(ios.width() == 0); 5778 } 5779 } 5780 ios.imbue(lg); 5781 { 5782 ios.width(0); 5783 { 5784 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5785 std::string ex(str, iter.base()); 5786 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5787 assert(ios.width() == 0); 5788 } 5789 ios.width(25); 5790 left(ios); 5791 { 5792 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5793 std::string ex(str, iter.base()); 5794 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5795 assert(ios.width() == 0); 5796 } 5797 ios.width(25); 5798 right(ios); 5799 { 5800 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5801 std::string ex(str, iter.base()); 5802 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5803 assert(ios.width() == 0); 5804 } 5805 ios.width(25); 5806 internal(ios); 5807 { 5808 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5809 std::string ex(str, iter.base()); 5810 assert(ex == "1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5811 assert(ios.width() == 0); 5812 } 5813 } 5814 } 5815 } 5816 showpos(ios); 5817 { 5818 noshowpoint(ios); 5819 { 5820 ios.imbue(lc); 5821 { 5822 ios.width(0); 5823 { 5824 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5825 std::string ex(str, iter.base()); 5826 assert(ex == "+1234567890.125"); 5827 assert(ios.width() == 0); 5828 } 5829 ios.width(25); 5830 left(ios); 5831 { 5832 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5833 std::string ex(str, iter.base()); 5834 assert(ex == "+1234567890.125**********"); 5835 assert(ios.width() == 0); 5836 } 5837 ios.width(25); 5838 right(ios); 5839 { 5840 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5841 std::string ex(str, iter.base()); 5842 assert(ex == "**********+1234567890.125"); 5843 assert(ios.width() == 0); 5844 } 5845 ios.width(25); 5846 internal(ios); 5847 { 5848 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5849 std::string ex(str, iter.base()); 5850 assert(ex == "+**********1234567890.125"); 5851 assert(ios.width() == 0); 5852 } 5853 } 5854 ios.imbue(lg); 5855 { 5856 ios.width(0); 5857 { 5858 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5859 std::string ex(str, iter.base()); 5860 assert(ex == "+1_234_567_89_0;125"); 5861 assert(ios.width() == 0); 5862 } 5863 ios.width(25); 5864 left(ios); 5865 { 5866 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5867 std::string ex(str, iter.base()); 5868 assert(ex == "+1_234_567_89_0;125******"); 5869 assert(ios.width() == 0); 5870 } 5871 ios.width(25); 5872 right(ios); 5873 { 5874 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5875 std::string ex(str, iter.base()); 5876 assert(ex == "******+1_234_567_89_0;125"); 5877 assert(ios.width() == 0); 5878 } 5879 ios.width(25); 5880 internal(ios); 5881 { 5882 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5883 std::string ex(str, iter.base()); 5884 assert(ex == "+******1_234_567_89_0;125"); 5885 assert(ios.width() == 0); 5886 } 5887 } 5888 } 5889 showpoint(ios); 5890 { 5891 ios.imbue(lc); 5892 { 5893 ios.width(0); 5894 { 5895 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5896 std::string ex(str, iter.base()); 5897 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5898 assert(ios.width() == 0); 5899 } 5900 ios.width(25); 5901 left(ios); 5902 { 5903 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5904 std::string ex(str, iter.base()); 5905 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5906 assert(ios.width() == 0); 5907 } 5908 ios.width(25); 5909 right(ios); 5910 { 5911 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5912 std::string ex(str, iter.base()); 5913 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5914 assert(ios.width() == 0); 5915 } 5916 ios.width(25); 5917 internal(ios); 5918 { 5919 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5920 std::string ex(str, iter.base()); 5921 assert(ex == "+1234567890.12500000000000000000000000000000000000000000000000"); 5922 assert(ios.width() == 0); 5923 } 5924 } 5925 ios.imbue(lg); 5926 { 5927 ios.width(0); 5928 { 5929 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5930 std::string ex(str, iter.base()); 5931 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5932 assert(ios.width() == 0); 5933 } 5934 ios.width(25); 5935 left(ios); 5936 { 5937 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5938 std::string ex(str, iter.base()); 5939 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5940 assert(ios.width() == 0); 5941 } 5942 ios.width(25); 5943 right(ios); 5944 { 5945 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5946 std::string ex(str, iter.base()); 5947 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5948 assert(ios.width() == 0); 5949 } 5950 ios.width(25); 5951 internal(ios); 5952 { 5953 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5954 std::string ex(str, iter.base()); 5955 assert(ex == "+1_234_567_89_0;12500000000000000000000000000000000000000000000000"); 5956 assert(ios.width() == 0); 5957 } 5958 } 5959 } 5960 } 5961 } 5962 } 5963 } 5964 } 5965} 5966 5967void test3() 5968{ 5969 char str[200]; 5970 output_iterator<char*> iter; 5971 std::locale lc = std::locale::classic(); 5972 std::locale lg(lc, new my_numpunct); 5973 const my_facet f(1); 5974 { 5975 double v = +0.; 5976 std::ios ios(0); 5977 fixed(ios); 5978 // %f 5979 { 5980 ios.precision(0); 5981 { 5982 nouppercase(ios); 5983 { 5984 noshowpos(ios); 5985 { 5986 noshowpoint(ios); 5987 { 5988 ios.imbue(lc); 5989 { 5990 ios.width(0); 5991 { 5992 iter = f.put(output_iterator<char*>(str), ios, '*', v); 5993 std::string ex(str, iter.base()); 5994 assert(ex == "0"); 5995 assert(ios.width() == 0); 5996 } 5997 ios.width(25); 5998 left(ios); 5999 { 6000 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6001 std::string ex(str, iter.base()); 6002 assert(ex == "0************************"); 6003 assert(ios.width() == 0); 6004 } 6005 ios.width(25); 6006 right(ios); 6007 { 6008 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6009 std::string ex(str, iter.base()); 6010 assert(ex == "************************0"); 6011 assert(ios.width() == 0); 6012 } 6013 ios.width(25); 6014 internal(ios); 6015 { 6016 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6017 std::string ex(str, iter.base()); 6018 assert(ex == "************************0"); 6019 assert(ios.width() == 0); 6020 } 6021 } 6022 ios.imbue(lg); 6023 { 6024 ios.width(0); 6025 { 6026 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6027 std::string ex(str, iter.base()); 6028 assert(ex == "0"); 6029 assert(ios.width() == 0); 6030 } 6031 ios.width(25); 6032 left(ios); 6033 { 6034 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6035 std::string ex(str, iter.base()); 6036 assert(ex == "0************************"); 6037 assert(ios.width() == 0); 6038 } 6039 ios.width(25); 6040 right(ios); 6041 { 6042 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6043 std::string ex(str, iter.base()); 6044 assert(ex == "************************0"); 6045 assert(ios.width() == 0); 6046 } 6047 ios.width(25); 6048 internal(ios); 6049 { 6050 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6051 std::string ex(str, iter.base()); 6052 assert(ex == "************************0"); 6053 assert(ios.width() == 0); 6054 } 6055 } 6056 } 6057 showpoint(ios); 6058 { 6059 ios.imbue(lc); 6060 { 6061 ios.width(0); 6062 { 6063 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6064 std::string ex(str, iter.base()); 6065 assert(ex == "0."); 6066 assert(ios.width() == 0); 6067 } 6068 ios.width(25); 6069 left(ios); 6070 { 6071 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6072 std::string ex(str, iter.base()); 6073 assert(ex == "0.***********************"); 6074 assert(ios.width() == 0); 6075 } 6076 ios.width(25); 6077 right(ios); 6078 { 6079 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6080 std::string ex(str, iter.base()); 6081 assert(ex == "***********************0."); 6082 assert(ios.width() == 0); 6083 } 6084 ios.width(25); 6085 internal(ios); 6086 { 6087 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6088 std::string ex(str, iter.base()); 6089 assert(ex == "***********************0."); 6090 assert(ios.width() == 0); 6091 } 6092 } 6093 ios.imbue(lg); 6094 { 6095 ios.width(0); 6096 { 6097 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6098 std::string ex(str, iter.base()); 6099 assert(ex == "0;"); 6100 assert(ios.width() == 0); 6101 } 6102 ios.width(25); 6103 left(ios); 6104 { 6105 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6106 std::string ex(str, iter.base()); 6107 assert(ex == "0;***********************"); 6108 assert(ios.width() == 0); 6109 } 6110 ios.width(25); 6111 right(ios); 6112 { 6113 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6114 std::string ex(str, iter.base()); 6115 assert(ex == "***********************0;"); 6116 assert(ios.width() == 0); 6117 } 6118 ios.width(25); 6119 internal(ios); 6120 { 6121 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6122 std::string ex(str, iter.base()); 6123 assert(ex == "***********************0;"); 6124 assert(ios.width() == 0); 6125 } 6126 } 6127 } 6128 } 6129 showpos(ios); 6130 { 6131 noshowpoint(ios); 6132 { 6133 ios.imbue(lc); 6134 { 6135 ios.width(0); 6136 { 6137 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6138 std::string ex(str, iter.base()); 6139 assert(ex == "+0"); 6140 assert(ios.width() == 0); 6141 } 6142 ios.width(25); 6143 left(ios); 6144 { 6145 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6146 std::string ex(str, iter.base()); 6147 assert(ex == "+0***********************"); 6148 assert(ios.width() == 0); 6149 } 6150 ios.width(25); 6151 right(ios); 6152 { 6153 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6154 std::string ex(str, iter.base()); 6155 assert(ex == "***********************+0"); 6156 assert(ios.width() == 0); 6157 } 6158 ios.width(25); 6159 internal(ios); 6160 { 6161 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6162 std::string ex(str, iter.base()); 6163 assert(ex == "+***********************0"); 6164 assert(ios.width() == 0); 6165 } 6166 } 6167 ios.imbue(lg); 6168 { 6169 ios.width(0); 6170 { 6171 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6172 std::string ex(str, iter.base()); 6173 assert(ex == "+0"); 6174 assert(ios.width() == 0); 6175 } 6176 ios.width(25); 6177 left(ios); 6178 { 6179 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6180 std::string ex(str, iter.base()); 6181 assert(ex == "+0***********************"); 6182 assert(ios.width() == 0); 6183 } 6184 ios.width(25); 6185 right(ios); 6186 { 6187 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6188 std::string ex(str, iter.base()); 6189 assert(ex == "***********************+0"); 6190 assert(ios.width() == 0); 6191 } 6192 ios.width(25); 6193 internal(ios); 6194 { 6195 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6196 std::string ex(str, iter.base()); 6197 assert(ex == "+***********************0"); 6198 assert(ios.width() == 0); 6199 } 6200 } 6201 } 6202 showpoint(ios); 6203 { 6204 ios.imbue(lc); 6205 { 6206 ios.width(0); 6207 { 6208 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6209 std::string ex(str, iter.base()); 6210 assert(ex == "+0."); 6211 assert(ios.width() == 0); 6212 } 6213 ios.width(25); 6214 left(ios); 6215 { 6216 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6217 std::string ex(str, iter.base()); 6218 assert(ex == "+0.**********************"); 6219 assert(ios.width() == 0); 6220 } 6221 ios.width(25); 6222 right(ios); 6223 { 6224 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6225 std::string ex(str, iter.base()); 6226 assert(ex == "**********************+0."); 6227 assert(ios.width() == 0); 6228 } 6229 ios.width(25); 6230 internal(ios); 6231 { 6232 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6233 std::string ex(str, iter.base()); 6234 assert(ex == "+**********************0."); 6235 assert(ios.width() == 0); 6236 } 6237 } 6238 ios.imbue(lg); 6239 { 6240 ios.width(0); 6241 { 6242 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6243 std::string ex(str, iter.base()); 6244 assert(ex == "+0;"); 6245 assert(ios.width() == 0); 6246 } 6247 ios.width(25); 6248 left(ios); 6249 { 6250 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6251 std::string ex(str, iter.base()); 6252 assert(ex == "+0;**********************"); 6253 assert(ios.width() == 0); 6254 } 6255 ios.width(25); 6256 right(ios); 6257 { 6258 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6259 std::string ex(str, iter.base()); 6260 assert(ex == "**********************+0;"); 6261 assert(ios.width() == 0); 6262 } 6263 ios.width(25); 6264 internal(ios); 6265 { 6266 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6267 std::string ex(str, iter.base()); 6268 assert(ex == "+**********************0;"); 6269 assert(ios.width() == 0); 6270 } 6271 } 6272 } 6273 } 6274 } 6275 uppercase(ios); 6276 { 6277 noshowpos(ios); 6278 { 6279 noshowpoint(ios); 6280 { 6281 ios.imbue(lc); 6282 { 6283 ios.width(0); 6284 { 6285 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6286 std::string ex(str, iter.base()); 6287 assert(ex == "0"); 6288 assert(ios.width() == 0); 6289 } 6290 ios.width(25); 6291 left(ios); 6292 { 6293 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6294 std::string ex(str, iter.base()); 6295 assert(ex == "0************************"); 6296 assert(ios.width() == 0); 6297 } 6298 ios.width(25); 6299 right(ios); 6300 { 6301 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6302 std::string ex(str, iter.base()); 6303 assert(ex == "************************0"); 6304 assert(ios.width() == 0); 6305 } 6306 ios.width(25); 6307 internal(ios); 6308 { 6309 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6310 std::string ex(str, iter.base()); 6311 assert(ex == "************************0"); 6312 assert(ios.width() == 0); 6313 } 6314 } 6315 ios.imbue(lg); 6316 { 6317 ios.width(0); 6318 { 6319 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6320 std::string ex(str, iter.base()); 6321 assert(ex == "0"); 6322 assert(ios.width() == 0); 6323 } 6324 ios.width(25); 6325 left(ios); 6326 { 6327 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6328 std::string ex(str, iter.base()); 6329 assert(ex == "0************************"); 6330 assert(ios.width() == 0); 6331 } 6332 ios.width(25); 6333 right(ios); 6334 { 6335 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6336 std::string ex(str, iter.base()); 6337 assert(ex == "************************0"); 6338 assert(ios.width() == 0); 6339 } 6340 ios.width(25); 6341 internal(ios); 6342 { 6343 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6344 std::string ex(str, iter.base()); 6345 assert(ex == "************************0"); 6346 assert(ios.width() == 0); 6347 } 6348 } 6349 } 6350 showpoint(ios); 6351 { 6352 ios.imbue(lc); 6353 { 6354 ios.width(0); 6355 { 6356 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6357 std::string ex(str, iter.base()); 6358 assert(ex == "0."); 6359 assert(ios.width() == 0); 6360 } 6361 ios.width(25); 6362 left(ios); 6363 { 6364 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6365 std::string ex(str, iter.base()); 6366 assert(ex == "0.***********************"); 6367 assert(ios.width() == 0); 6368 } 6369 ios.width(25); 6370 right(ios); 6371 { 6372 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6373 std::string ex(str, iter.base()); 6374 assert(ex == "***********************0."); 6375 assert(ios.width() == 0); 6376 } 6377 ios.width(25); 6378 internal(ios); 6379 { 6380 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6381 std::string ex(str, iter.base()); 6382 assert(ex == "***********************0."); 6383 assert(ios.width() == 0); 6384 } 6385 } 6386 ios.imbue(lg); 6387 { 6388 ios.width(0); 6389 { 6390 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6391 std::string ex(str, iter.base()); 6392 assert(ex == "0;"); 6393 assert(ios.width() == 0); 6394 } 6395 ios.width(25); 6396 left(ios); 6397 { 6398 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6399 std::string ex(str, iter.base()); 6400 assert(ex == "0;***********************"); 6401 assert(ios.width() == 0); 6402 } 6403 ios.width(25); 6404 right(ios); 6405 { 6406 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6407 std::string ex(str, iter.base()); 6408 assert(ex == "***********************0;"); 6409 assert(ios.width() == 0); 6410 } 6411 ios.width(25); 6412 internal(ios); 6413 { 6414 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6415 std::string ex(str, iter.base()); 6416 assert(ex == "***********************0;"); 6417 assert(ios.width() == 0); 6418 } 6419 } 6420 } 6421 } 6422 showpos(ios); 6423 { 6424 noshowpoint(ios); 6425 { 6426 ios.imbue(lc); 6427 { 6428 ios.width(0); 6429 { 6430 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6431 std::string ex(str, iter.base()); 6432 assert(ex == "+0"); 6433 assert(ios.width() == 0); 6434 } 6435 ios.width(25); 6436 left(ios); 6437 { 6438 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6439 std::string ex(str, iter.base()); 6440 assert(ex == "+0***********************"); 6441 assert(ios.width() == 0); 6442 } 6443 ios.width(25); 6444 right(ios); 6445 { 6446 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6447 std::string ex(str, iter.base()); 6448 assert(ex == "***********************+0"); 6449 assert(ios.width() == 0); 6450 } 6451 ios.width(25); 6452 internal(ios); 6453 { 6454 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6455 std::string ex(str, iter.base()); 6456 assert(ex == "+***********************0"); 6457 assert(ios.width() == 0); 6458 } 6459 } 6460 ios.imbue(lg); 6461 { 6462 ios.width(0); 6463 { 6464 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6465 std::string ex(str, iter.base()); 6466 assert(ex == "+0"); 6467 assert(ios.width() == 0); 6468 } 6469 ios.width(25); 6470 left(ios); 6471 { 6472 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6473 std::string ex(str, iter.base()); 6474 assert(ex == "+0***********************"); 6475 assert(ios.width() == 0); 6476 } 6477 ios.width(25); 6478 right(ios); 6479 { 6480 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6481 std::string ex(str, iter.base()); 6482 assert(ex == "***********************+0"); 6483 assert(ios.width() == 0); 6484 } 6485 ios.width(25); 6486 internal(ios); 6487 { 6488 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6489 std::string ex(str, iter.base()); 6490 assert(ex == "+***********************0"); 6491 assert(ios.width() == 0); 6492 } 6493 } 6494 } 6495 showpoint(ios); 6496 { 6497 ios.imbue(lc); 6498 { 6499 ios.width(0); 6500 { 6501 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6502 std::string ex(str, iter.base()); 6503 assert(ex == "+0."); 6504 assert(ios.width() == 0); 6505 } 6506 ios.width(25); 6507 left(ios); 6508 { 6509 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6510 std::string ex(str, iter.base()); 6511 assert(ex == "+0.**********************"); 6512 assert(ios.width() == 0); 6513 } 6514 ios.width(25); 6515 right(ios); 6516 { 6517 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6518 std::string ex(str, iter.base()); 6519 assert(ex == "**********************+0."); 6520 assert(ios.width() == 0); 6521 } 6522 ios.width(25); 6523 internal(ios); 6524 { 6525 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6526 std::string ex(str, iter.base()); 6527 assert(ex == "+**********************0."); 6528 assert(ios.width() == 0); 6529 } 6530 } 6531 ios.imbue(lg); 6532 { 6533 ios.width(0); 6534 { 6535 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6536 std::string ex(str, iter.base()); 6537 assert(ex == "+0;"); 6538 assert(ios.width() == 0); 6539 } 6540 ios.width(25); 6541 left(ios); 6542 { 6543 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6544 std::string ex(str, iter.base()); 6545 assert(ex == "+0;**********************"); 6546 assert(ios.width() == 0); 6547 } 6548 ios.width(25); 6549 right(ios); 6550 { 6551 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6552 std::string ex(str, iter.base()); 6553 assert(ex == "**********************+0;"); 6554 assert(ios.width() == 0); 6555 } 6556 ios.width(25); 6557 internal(ios); 6558 { 6559 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6560 std::string ex(str, iter.base()); 6561 assert(ex == "+**********************0;"); 6562 assert(ios.width() == 0); 6563 } 6564 } 6565 } 6566 } 6567 } 6568 } 6569 ios.precision(1); 6570 { 6571 nouppercase(ios); 6572 { 6573 noshowpos(ios); 6574 { 6575 noshowpoint(ios); 6576 { 6577 ios.imbue(lc); 6578 { 6579 ios.width(0); 6580 { 6581 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6582 std::string ex(str, iter.base()); 6583 assert(ex == "0.0"); 6584 assert(ios.width() == 0); 6585 } 6586 ios.width(25); 6587 left(ios); 6588 { 6589 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6590 std::string ex(str, iter.base()); 6591 assert(ex == "0.0**********************"); 6592 assert(ios.width() == 0); 6593 } 6594 ios.width(25); 6595 right(ios); 6596 { 6597 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6598 std::string ex(str, iter.base()); 6599 assert(ex == "**********************0.0"); 6600 assert(ios.width() == 0); 6601 } 6602 ios.width(25); 6603 internal(ios); 6604 { 6605 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6606 std::string ex(str, iter.base()); 6607 assert(ex == "**********************0.0"); 6608 assert(ios.width() == 0); 6609 } 6610 } 6611 ios.imbue(lg); 6612 { 6613 ios.width(0); 6614 { 6615 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6616 std::string ex(str, iter.base()); 6617 assert(ex == "0;0"); 6618 assert(ios.width() == 0); 6619 } 6620 ios.width(25); 6621 left(ios); 6622 { 6623 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6624 std::string ex(str, iter.base()); 6625 assert(ex == "0;0**********************"); 6626 assert(ios.width() == 0); 6627 } 6628 ios.width(25); 6629 right(ios); 6630 { 6631 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6632 std::string ex(str, iter.base()); 6633 assert(ex == "**********************0;0"); 6634 assert(ios.width() == 0); 6635 } 6636 ios.width(25); 6637 internal(ios); 6638 { 6639 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6640 std::string ex(str, iter.base()); 6641 assert(ex == "**********************0;0"); 6642 assert(ios.width() == 0); 6643 } 6644 } 6645 } 6646 showpoint(ios); 6647 { 6648 ios.imbue(lc); 6649 { 6650 ios.width(0); 6651 { 6652 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6653 std::string ex(str, iter.base()); 6654 assert(ex == "0.0"); 6655 assert(ios.width() == 0); 6656 } 6657 ios.width(25); 6658 left(ios); 6659 { 6660 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6661 std::string ex(str, iter.base()); 6662 assert(ex == "0.0**********************"); 6663 assert(ios.width() == 0); 6664 } 6665 ios.width(25); 6666 right(ios); 6667 { 6668 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6669 std::string ex(str, iter.base()); 6670 assert(ex == "**********************0.0"); 6671 assert(ios.width() == 0); 6672 } 6673 ios.width(25); 6674 internal(ios); 6675 { 6676 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6677 std::string ex(str, iter.base()); 6678 assert(ex == "**********************0.0"); 6679 assert(ios.width() == 0); 6680 } 6681 } 6682 ios.imbue(lg); 6683 { 6684 ios.width(0); 6685 { 6686 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6687 std::string ex(str, iter.base()); 6688 assert(ex == "0;0"); 6689 assert(ios.width() == 0); 6690 } 6691 ios.width(25); 6692 left(ios); 6693 { 6694 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6695 std::string ex(str, iter.base()); 6696 assert(ex == "0;0**********************"); 6697 assert(ios.width() == 0); 6698 } 6699 ios.width(25); 6700 right(ios); 6701 { 6702 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6703 std::string ex(str, iter.base()); 6704 assert(ex == "**********************0;0"); 6705 assert(ios.width() == 0); 6706 } 6707 ios.width(25); 6708 internal(ios); 6709 { 6710 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6711 std::string ex(str, iter.base()); 6712 assert(ex == "**********************0;0"); 6713 assert(ios.width() == 0); 6714 } 6715 } 6716 } 6717 } 6718 showpos(ios); 6719 { 6720 noshowpoint(ios); 6721 { 6722 ios.imbue(lc); 6723 { 6724 ios.width(0); 6725 { 6726 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6727 std::string ex(str, iter.base()); 6728 assert(ex == "+0.0"); 6729 assert(ios.width() == 0); 6730 } 6731 ios.width(25); 6732 left(ios); 6733 { 6734 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6735 std::string ex(str, iter.base()); 6736 assert(ex == "+0.0*********************"); 6737 assert(ios.width() == 0); 6738 } 6739 ios.width(25); 6740 right(ios); 6741 { 6742 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6743 std::string ex(str, iter.base()); 6744 assert(ex == "*********************+0.0"); 6745 assert(ios.width() == 0); 6746 } 6747 ios.width(25); 6748 internal(ios); 6749 { 6750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6751 std::string ex(str, iter.base()); 6752 assert(ex == "+*********************0.0"); 6753 assert(ios.width() == 0); 6754 } 6755 } 6756 ios.imbue(lg); 6757 { 6758 ios.width(0); 6759 { 6760 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6761 std::string ex(str, iter.base()); 6762 assert(ex == "+0;0"); 6763 assert(ios.width() == 0); 6764 } 6765 ios.width(25); 6766 left(ios); 6767 { 6768 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6769 std::string ex(str, iter.base()); 6770 assert(ex == "+0;0*********************"); 6771 assert(ios.width() == 0); 6772 } 6773 ios.width(25); 6774 right(ios); 6775 { 6776 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6777 std::string ex(str, iter.base()); 6778 assert(ex == "*********************+0;0"); 6779 assert(ios.width() == 0); 6780 } 6781 ios.width(25); 6782 internal(ios); 6783 { 6784 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6785 std::string ex(str, iter.base()); 6786 assert(ex == "+*********************0;0"); 6787 assert(ios.width() == 0); 6788 } 6789 } 6790 } 6791 showpoint(ios); 6792 { 6793 ios.imbue(lc); 6794 { 6795 ios.width(0); 6796 { 6797 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6798 std::string ex(str, iter.base()); 6799 assert(ex == "+0.0"); 6800 assert(ios.width() == 0); 6801 } 6802 ios.width(25); 6803 left(ios); 6804 { 6805 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6806 std::string ex(str, iter.base()); 6807 assert(ex == "+0.0*********************"); 6808 assert(ios.width() == 0); 6809 } 6810 ios.width(25); 6811 right(ios); 6812 { 6813 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6814 std::string ex(str, iter.base()); 6815 assert(ex == "*********************+0.0"); 6816 assert(ios.width() == 0); 6817 } 6818 ios.width(25); 6819 internal(ios); 6820 { 6821 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6822 std::string ex(str, iter.base()); 6823 assert(ex == "+*********************0.0"); 6824 assert(ios.width() == 0); 6825 } 6826 } 6827 ios.imbue(lg); 6828 { 6829 ios.width(0); 6830 { 6831 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6832 std::string ex(str, iter.base()); 6833 assert(ex == "+0;0"); 6834 assert(ios.width() == 0); 6835 } 6836 ios.width(25); 6837 left(ios); 6838 { 6839 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6840 std::string ex(str, iter.base()); 6841 assert(ex == "+0;0*********************"); 6842 assert(ios.width() == 0); 6843 } 6844 ios.width(25); 6845 right(ios); 6846 { 6847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6848 std::string ex(str, iter.base()); 6849 assert(ex == "*********************+0;0"); 6850 assert(ios.width() == 0); 6851 } 6852 ios.width(25); 6853 internal(ios); 6854 { 6855 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6856 std::string ex(str, iter.base()); 6857 assert(ex == "+*********************0;0"); 6858 assert(ios.width() == 0); 6859 } 6860 } 6861 } 6862 } 6863 } 6864 uppercase(ios); 6865 { 6866 noshowpos(ios); 6867 { 6868 noshowpoint(ios); 6869 { 6870 ios.imbue(lc); 6871 { 6872 ios.width(0); 6873 { 6874 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6875 std::string ex(str, iter.base()); 6876 assert(ex == "0.0"); 6877 assert(ios.width() == 0); 6878 } 6879 ios.width(25); 6880 left(ios); 6881 { 6882 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6883 std::string ex(str, iter.base()); 6884 assert(ex == "0.0**********************"); 6885 assert(ios.width() == 0); 6886 } 6887 ios.width(25); 6888 right(ios); 6889 { 6890 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6891 std::string ex(str, iter.base()); 6892 assert(ex == "**********************0.0"); 6893 assert(ios.width() == 0); 6894 } 6895 ios.width(25); 6896 internal(ios); 6897 { 6898 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6899 std::string ex(str, iter.base()); 6900 assert(ex == "**********************0.0"); 6901 assert(ios.width() == 0); 6902 } 6903 } 6904 ios.imbue(lg); 6905 { 6906 ios.width(0); 6907 { 6908 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6909 std::string ex(str, iter.base()); 6910 assert(ex == "0;0"); 6911 assert(ios.width() == 0); 6912 } 6913 ios.width(25); 6914 left(ios); 6915 { 6916 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6917 std::string ex(str, iter.base()); 6918 assert(ex == "0;0**********************"); 6919 assert(ios.width() == 0); 6920 } 6921 ios.width(25); 6922 right(ios); 6923 { 6924 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6925 std::string ex(str, iter.base()); 6926 assert(ex == "**********************0;0"); 6927 assert(ios.width() == 0); 6928 } 6929 ios.width(25); 6930 internal(ios); 6931 { 6932 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6933 std::string ex(str, iter.base()); 6934 assert(ex == "**********************0;0"); 6935 assert(ios.width() == 0); 6936 } 6937 } 6938 } 6939 showpoint(ios); 6940 { 6941 ios.imbue(lc); 6942 { 6943 ios.width(0); 6944 { 6945 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6946 std::string ex(str, iter.base()); 6947 assert(ex == "0.0"); 6948 assert(ios.width() == 0); 6949 } 6950 ios.width(25); 6951 left(ios); 6952 { 6953 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6954 std::string ex(str, iter.base()); 6955 assert(ex == "0.0**********************"); 6956 assert(ios.width() == 0); 6957 } 6958 ios.width(25); 6959 right(ios); 6960 { 6961 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6962 std::string ex(str, iter.base()); 6963 assert(ex == "**********************0.0"); 6964 assert(ios.width() == 0); 6965 } 6966 ios.width(25); 6967 internal(ios); 6968 { 6969 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6970 std::string ex(str, iter.base()); 6971 assert(ex == "**********************0.0"); 6972 assert(ios.width() == 0); 6973 } 6974 } 6975 ios.imbue(lg); 6976 { 6977 ios.width(0); 6978 { 6979 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6980 std::string ex(str, iter.base()); 6981 assert(ex == "0;0"); 6982 assert(ios.width() == 0); 6983 } 6984 ios.width(25); 6985 left(ios); 6986 { 6987 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6988 std::string ex(str, iter.base()); 6989 assert(ex == "0;0**********************"); 6990 assert(ios.width() == 0); 6991 } 6992 ios.width(25); 6993 right(ios); 6994 { 6995 iter = f.put(output_iterator<char*>(str), ios, '*', v); 6996 std::string ex(str, iter.base()); 6997 assert(ex == "**********************0;0"); 6998 assert(ios.width() == 0); 6999 } 7000 ios.width(25); 7001 internal(ios); 7002 { 7003 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7004 std::string ex(str, iter.base()); 7005 assert(ex == "**********************0;0"); 7006 assert(ios.width() == 0); 7007 } 7008 } 7009 } 7010 } 7011 showpos(ios); 7012 { 7013 noshowpoint(ios); 7014 { 7015 ios.imbue(lc); 7016 { 7017 ios.width(0); 7018 { 7019 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7020 std::string ex(str, iter.base()); 7021 assert(ex == "+0.0"); 7022 assert(ios.width() == 0); 7023 } 7024 ios.width(25); 7025 left(ios); 7026 { 7027 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7028 std::string ex(str, iter.base()); 7029 assert(ex == "+0.0*********************"); 7030 assert(ios.width() == 0); 7031 } 7032 ios.width(25); 7033 right(ios); 7034 { 7035 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7036 std::string ex(str, iter.base()); 7037 assert(ex == "*********************+0.0"); 7038 assert(ios.width() == 0); 7039 } 7040 ios.width(25); 7041 internal(ios); 7042 { 7043 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7044 std::string ex(str, iter.base()); 7045 assert(ex == "+*********************0.0"); 7046 assert(ios.width() == 0); 7047 } 7048 } 7049 ios.imbue(lg); 7050 { 7051 ios.width(0); 7052 { 7053 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7054 std::string ex(str, iter.base()); 7055 assert(ex == "+0;0"); 7056 assert(ios.width() == 0); 7057 } 7058 ios.width(25); 7059 left(ios); 7060 { 7061 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7062 std::string ex(str, iter.base()); 7063 assert(ex == "+0;0*********************"); 7064 assert(ios.width() == 0); 7065 } 7066 ios.width(25); 7067 right(ios); 7068 { 7069 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7070 std::string ex(str, iter.base()); 7071 assert(ex == "*********************+0;0"); 7072 assert(ios.width() == 0); 7073 } 7074 ios.width(25); 7075 internal(ios); 7076 { 7077 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7078 std::string ex(str, iter.base()); 7079 assert(ex == "+*********************0;0"); 7080 assert(ios.width() == 0); 7081 } 7082 } 7083 } 7084 showpoint(ios); 7085 { 7086 ios.imbue(lc); 7087 { 7088 ios.width(0); 7089 { 7090 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7091 std::string ex(str, iter.base()); 7092 assert(ex == "+0.0"); 7093 assert(ios.width() == 0); 7094 } 7095 ios.width(25); 7096 left(ios); 7097 { 7098 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7099 std::string ex(str, iter.base()); 7100 assert(ex == "+0.0*********************"); 7101 assert(ios.width() == 0); 7102 } 7103 ios.width(25); 7104 right(ios); 7105 { 7106 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7107 std::string ex(str, iter.base()); 7108 assert(ex == "*********************+0.0"); 7109 assert(ios.width() == 0); 7110 } 7111 ios.width(25); 7112 internal(ios); 7113 { 7114 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7115 std::string ex(str, iter.base()); 7116 assert(ex == "+*********************0.0"); 7117 assert(ios.width() == 0); 7118 } 7119 } 7120 ios.imbue(lg); 7121 { 7122 ios.width(0); 7123 { 7124 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7125 std::string ex(str, iter.base()); 7126 assert(ex == "+0;0"); 7127 assert(ios.width() == 0); 7128 } 7129 ios.width(25); 7130 left(ios); 7131 { 7132 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7133 std::string ex(str, iter.base()); 7134 assert(ex == "+0;0*********************"); 7135 assert(ios.width() == 0); 7136 } 7137 ios.width(25); 7138 right(ios); 7139 { 7140 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7141 std::string ex(str, iter.base()); 7142 assert(ex == "*********************+0;0"); 7143 assert(ios.width() == 0); 7144 } 7145 ios.width(25); 7146 internal(ios); 7147 { 7148 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7149 std::string ex(str, iter.base()); 7150 assert(ex == "+*********************0;0"); 7151 assert(ios.width() == 0); 7152 } 7153 } 7154 } 7155 } 7156 } 7157 } 7158 ios.precision(6); 7159 { 7160 nouppercase(ios); 7161 { 7162 noshowpos(ios); 7163 { 7164 noshowpoint(ios); 7165 { 7166 ios.imbue(lc); 7167 { 7168 ios.width(0); 7169 { 7170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7171 std::string ex(str, iter.base()); 7172 assert(ex == "0.000000"); 7173 assert(ios.width() == 0); 7174 } 7175 ios.width(25); 7176 left(ios); 7177 { 7178 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7179 std::string ex(str, iter.base()); 7180 assert(ex == "0.000000*****************"); 7181 assert(ios.width() == 0); 7182 } 7183 ios.width(25); 7184 right(ios); 7185 { 7186 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7187 std::string ex(str, iter.base()); 7188 assert(ex == "*****************0.000000"); 7189 assert(ios.width() == 0); 7190 } 7191 ios.width(25); 7192 internal(ios); 7193 { 7194 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7195 std::string ex(str, iter.base()); 7196 assert(ex == "*****************0.000000"); 7197 assert(ios.width() == 0); 7198 } 7199 } 7200 ios.imbue(lg); 7201 { 7202 ios.width(0); 7203 { 7204 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7205 std::string ex(str, iter.base()); 7206 assert(ex == "0;000000"); 7207 assert(ios.width() == 0); 7208 } 7209 ios.width(25); 7210 left(ios); 7211 { 7212 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7213 std::string ex(str, iter.base()); 7214 assert(ex == "0;000000*****************"); 7215 assert(ios.width() == 0); 7216 } 7217 ios.width(25); 7218 right(ios); 7219 { 7220 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7221 std::string ex(str, iter.base()); 7222 assert(ex == "*****************0;000000"); 7223 assert(ios.width() == 0); 7224 } 7225 ios.width(25); 7226 internal(ios); 7227 { 7228 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7229 std::string ex(str, iter.base()); 7230 assert(ex == "*****************0;000000"); 7231 assert(ios.width() == 0); 7232 } 7233 } 7234 } 7235 showpoint(ios); 7236 { 7237 ios.imbue(lc); 7238 { 7239 ios.width(0); 7240 { 7241 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7242 std::string ex(str, iter.base()); 7243 assert(ex == "0.000000"); 7244 assert(ios.width() == 0); 7245 } 7246 ios.width(25); 7247 left(ios); 7248 { 7249 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7250 std::string ex(str, iter.base()); 7251 assert(ex == "0.000000*****************"); 7252 assert(ios.width() == 0); 7253 } 7254 ios.width(25); 7255 right(ios); 7256 { 7257 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7258 std::string ex(str, iter.base()); 7259 assert(ex == "*****************0.000000"); 7260 assert(ios.width() == 0); 7261 } 7262 ios.width(25); 7263 internal(ios); 7264 { 7265 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7266 std::string ex(str, iter.base()); 7267 assert(ex == "*****************0.000000"); 7268 assert(ios.width() == 0); 7269 } 7270 } 7271 ios.imbue(lg); 7272 { 7273 ios.width(0); 7274 { 7275 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7276 std::string ex(str, iter.base()); 7277 assert(ex == "0;000000"); 7278 assert(ios.width() == 0); 7279 } 7280 ios.width(25); 7281 left(ios); 7282 { 7283 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7284 std::string ex(str, iter.base()); 7285 assert(ex == "0;000000*****************"); 7286 assert(ios.width() == 0); 7287 } 7288 ios.width(25); 7289 right(ios); 7290 { 7291 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7292 std::string ex(str, iter.base()); 7293 assert(ex == "*****************0;000000"); 7294 assert(ios.width() == 0); 7295 } 7296 ios.width(25); 7297 internal(ios); 7298 { 7299 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7300 std::string ex(str, iter.base()); 7301 assert(ex == "*****************0;000000"); 7302 assert(ios.width() == 0); 7303 } 7304 } 7305 } 7306 } 7307 showpos(ios); 7308 { 7309 noshowpoint(ios); 7310 { 7311 ios.imbue(lc); 7312 { 7313 ios.width(0); 7314 { 7315 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7316 std::string ex(str, iter.base()); 7317 assert(ex == "+0.000000"); 7318 assert(ios.width() == 0); 7319 } 7320 ios.width(25); 7321 left(ios); 7322 { 7323 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7324 std::string ex(str, iter.base()); 7325 assert(ex == "+0.000000****************"); 7326 assert(ios.width() == 0); 7327 } 7328 ios.width(25); 7329 right(ios); 7330 { 7331 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7332 std::string ex(str, iter.base()); 7333 assert(ex == "****************+0.000000"); 7334 assert(ios.width() == 0); 7335 } 7336 ios.width(25); 7337 internal(ios); 7338 { 7339 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7340 std::string ex(str, iter.base()); 7341 assert(ex == "+****************0.000000"); 7342 assert(ios.width() == 0); 7343 } 7344 } 7345 ios.imbue(lg); 7346 { 7347 ios.width(0); 7348 { 7349 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7350 std::string ex(str, iter.base()); 7351 assert(ex == "+0;000000"); 7352 assert(ios.width() == 0); 7353 } 7354 ios.width(25); 7355 left(ios); 7356 { 7357 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7358 std::string ex(str, iter.base()); 7359 assert(ex == "+0;000000****************"); 7360 assert(ios.width() == 0); 7361 } 7362 ios.width(25); 7363 right(ios); 7364 { 7365 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7366 std::string ex(str, iter.base()); 7367 assert(ex == "****************+0;000000"); 7368 assert(ios.width() == 0); 7369 } 7370 ios.width(25); 7371 internal(ios); 7372 { 7373 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7374 std::string ex(str, iter.base()); 7375 assert(ex == "+****************0;000000"); 7376 assert(ios.width() == 0); 7377 } 7378 } 7379 } 7380 showpoint(ios); 7381 { 7382 ios.imbue(lc); 7383 { 7384 ios.width(0); 7385 { 7386 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7387 std::string ex(str, iter.base()); 7388 assert(ex == "+0.000000"); 7389 assert(ios.width() == 0); 7390 } 7391 ios.width(25); 7392 left(ios); 7393 { 7394 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7395 std::string ex(str, iter.base()); 7396 assert(ex == "+0.000000****************"); 7397 assert(ios.width() == 0); 7398 } 7399 ios.width(25); 7400 right(ios); 7401 { 7402 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7403 std::string ex(str, iter.base()); 7404 assert(ex == "****************+0.000000"); 7405 assert(ios.width() == 0); 7406 } 7407 ios.width(25); 7408 internal(ios); 7409 { 7410 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7411 std::string ex(str, iter.base()); 7412 assert(ex == "+****************0.000000"); 7413 assert(ios.width() == 0); 7414 } 7415 } 7416 ios.imbue(lg); 7417 { 7418 ios.width(0); 7419 { 7420 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7421 std::string ex(str, iter.base()); 7422 assert(ex == "+0;000000"); 7423 assert(ios.width() == 0); 7424 } 7425 ios.width(25); 7426 left(ios); 7427 { 7428 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7429 std::string ex(str, iter.base()); 7430 assert(ex == "+0;000000****************"); 7431 assert(ios.width() == 0); 7432 } 7433 ios.width(25); 7434 right(ios); 7435 { 7436 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7437 std::string ex(str, iter.base()); 7438 assert(ex == "****************+0;000000"); 7439 assert(ios.width() == 0); 7440 } 7441 ios.width(25); 7442 internal(ios); 7443 { 7444 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7445 std::string ex(str, iter.base()); 7446 assert(ex == "+****************0;000000"); 7447 assert(ios.width() == 0); 7448 } 7449 } 7450 } 7451 } 7452 } 7453 uppercase(ios); 7454 { 7455 noshowpos(ios); 7456 { 7457 noshowpoint(ios); 7458 { 7459 ios.imbue(lc); 7460 { 7461 ios.width(0); 7462 { 7463 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7464 std::string ex(str, iter.base()); 7465 assert(ex == "0.000000"); 7466 assert(ios.width() == 0); 7467 } 7468 ios.width(25); 7469 left(ios); 7470 { 7471 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7472 std::string ex(str, iter.base()); 7473 assert(ex == "0.000000*****************"); 7474 assert(ios.width() == 0); 7475 } 7476 ios.width(25); 7477 right(ios); 7478 { 7479 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7480 std::string ex(str, iter.base()); 7481 assert(ex == "*****************0.000000"); 7482 assert(ios.width() == 0); 7483 } 7484 ios.width(25); 7485 internal(ios); 7486 { 7487 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7488 std::string ex(str, iter.base()); 7489 assert(ex == "*****************0.000000"); 7490 assert(ios.width() == 0); 7491 } 7492 } 7493 ios.imbue(lg); 7494 { 7495 ios.width(0); 7496 { 7497 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7498 std::string ex(str, iter.base()); 7499 assert(ex == "0;000000"); 7500 assert(ios.width() == 0); 7501 } 7502 ios.width(25); 7503 left(ios); 7504 { 7505 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7506 std::string ex(str, iter.base()); 7507 assert(ex == "0;000000*****************"); 7508 assert(ios.width() == 0); 7509 } 7510 ios.width(25); 7511 right(ios); 7512 { 7513 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7514 std::string ex(str, iter.base()); 7515 assert(ex == "*****************0;000000"); 7516 assert(ios.width() == 0); 7517 } 7518 ios.width(25); 7519 internal(ios); 7520 { 7521 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7522 std::string ex(str, iter.base()); 7523 assert(ex == "*****************0;000000"); 7524 assert(ios.width() == 0); 7525 } 7526 } 7527 } 7528 showpoint(ios); 7529 { 7530 ios.imbue(lc); 7531 { 7532 ios.width(0); 7533 { 7534 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7535 std::string ex(str, iter.base()); 7536 assert(ex == "0.000000"); 7537 assert(ios.width() == 0); 7538 } 7539 ios.width(25); 7540 left(ios); 7541 { 7542 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7543 std::string ex(str, iter.base()); 7544 assert(ex == "0.000000*****************"); 7545 assert(ios.width() == 0); 7546 } 7547 ios.width(25); 7548 right(ios); 7549 { 7550 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7551 std::string ex(str, iter.base()); 7552 assert(ex == "*****************0.000000"); 7553 assert(ios.width() == 0); 7554 } 7555 ios.width(25); 7556 internal(ios); 7557 { 7558 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7559 std::string ex(str, iter.base()); 7560 assert(ex == "*****************0.000000"); 7561 assert(ios.width() == 0); 7562 } 7563 } 7564 ios.imbue(lg); 7565 { 7566 ios.width(0); 7567 { 7568 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7569 std::string ex(str, iter.base()); 7570 assert(ex == "0;000000"); 7571 assert(ios.width() == 0); 7572 } 7573 ios.width(25); 7574 left(ios); 7575 { 7576 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7577 std::string ex(str, iter.base()); 7578 assert(ex == "0;000000*****************"); 7579 assert(ios.width() == 0); 7580 } 7581 ios.width(25); 7582 right(ios); 7583 { 7584 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7585 std::string ex(str, iter.base()); 7586 assert(ex == "*****************0;000000"); 7587 assert(ios.width() == 0); 7588 } 7589 ios.width(25); 7590 internal(ios); 7591 { 7592 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7593 std::string ex(str, iter.base()); 7594 assert(ex == "*****************0;000000"); 7595 assert(ios.width() == 0); 7596 } 7597 } 7598 } 7599 } 7600 showpos(ios); 7601 { 7602 noshowpoint(ios); 7603 { 7604 ios.imbue(lc); 7605 { 7606 ios.width(0); 7607 { 7608 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7609 std::string ex(str, iter.base()); 7610 assert(ex == "+0.000000"); 7611 assert(ios.width() == 0); 7612 } 7613 ios.width(25); 7614 left(ios); 7615 { 7616 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7617 std::string ex(str, iter.base()); 7618 assert(ex == "+0.000000****************"); 7619 assert(ios.width() == 0); 7620 } 7621 ios.width(25); 7622 right(ios); 7623 { 7624 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7625 std::string ex(str, iter.base()); 7626 assert(ex == "****************+0.000000"); 7627 assert(ios.width() == 0); 7628 } 7629 ios.width(25); 7630 internal(ios); 7631 { 7632 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7633 std::string ex(str, iter.base()); 7634 assert(ex == "+****************0.000000"); 7635 assert(ios.width() == 0); 7636 } 7637 } 7638 ios.imbue(lg); 7639 { 7640 ios.width(0); 7641 { 7642 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7643 std::string ex(str, iter.base()); 7644 assert(ex == "+0;000000"); 7645 assert(ios.width() == 0); 7646 } 7647 ios.width(25); 7648 left(ios); 7649 { 7650 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7651 std::string ex(str, iter.base()); 7652 assert(ex == "+0;000000****************"); 7653 assert(ios.width() == 0); 7654 } 7655 ios.width(25); 7656 right(ios); 7657 { 7658 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7659 std::string ex(str, iter.base()); 7660 assert(ex == "****************+0;000000"); 7661 assert(ios.width() == 0); 7662 } 7663 ios.width(25); 7664 internal(ios); 7665 { 7666 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7667 std::string ex(str, iter.base()); 7668 assert(ex == "+****************0;000000"); 7669 assert(ios.width() == 0); 7670 } 7671 } 7672 } 7673 showpoint(ios); 7674 { 7675 ios.imbue(lc); 7676 { 7677 ios.width(0); 7678 { 7679 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7680 std::string ex(str, iter.base()); 7681 assert(ex == "+0.000000"); 7682 assert(ios.width() == 0); 7683 } 7684 ios.width(25); 7685 left(ios); 7686 { 7687 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7688 std::string ex(str, iter.base()); 7689 assert(ex == "+0.000000****************"); 7690 assert(ios.width() == 0); 7691 } 7692 ios.width(25); 7693 right(ios); 7694 { 7695 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7696 std::string ex(str, iter.base()); 7697 assert(ex == "****************+0.000000"); 7698 assert(ios.width() == 0); 7699 } 7700 ios.width(25); 7701 internal(ios); 7702 { 7703 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7704 std::string ex(str, iter.base()); 7705 assert(ex == "+****************0.000000"); 7706 assert(ios.width() == 0); 7707 } 7708 } 7709 ios.imbue(lg); 7710 { 7711 ios.width(0); 7712 { 7713 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7714 std::string ex(str, iter.base()); 7715 assert(ex == "+0;000000"); 7716 assert(ios.width() == 0); 7717 } 7718 ios.width(25); 7719 left(ios); 7720 { 7721 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7722 std::string ex(str, iter.base()); 7723 assert(ex == "+0;000000****************"); 7724 assert(ios.width() == 0); 7725 } 7726 ios.width(25); 7727 right(ios); 7728 { 7729 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7730 std::string ex(str, iter.base()); 7731 assert(ex == "****************+0;000000"); 7732 assert(ios.width() == 0); 7733 } 7734 ios.width(25); 7735 internal(ios); 7736 { 7737 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7738 std::string ex(str, iter.base()); 7739 assert(ex == "+****************0;000000"); 7740 assert(ios.width() == 0); 7741 } 7742 } 7743 } 7744 } 7745 } 7746 } 7747 ios.precision(16); 7748 { 7749 nouppercase(ios); 7750 { 7751 noshowpos(ios); 7752 { 7753 noshowpoint(ios); 7754 { 7755 ios.imbue(lc); 7756 { 7757 ios.width(0); 7758 { 7759 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7760 std::string ex(str, iter.base()); 7761 assert(ex == "0.0000000000000000"); 7762 assert(ios.width() == 0); 7763 } 7764 ios.width(25); 7765 left(ios); 7766 { 7767 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7768 std::string ex(str, iter.base()); 7769 assert(ex == "0.0000000000000000*******"); 7770 assert(ios.width() == 0); 7771 } 7772 ios.width(25); 7773 right(ios); 7774 { 7775 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7776 std::string ex(str, iter.base()); 7777 assert(ex == "*******0.0000000000000000"); 7778 assert(ios.width() == 0); 7779 } 7780 ios.width(25); 7781 internal(ios); 7782 { 7783 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7784 std::string ex(str, iter.base()); 7785 assert(ex == "*******0.0000000000000000"); 7786 assert(ios.width() == 0); 7787 } 7788 } 7789 ios.imbue(lg); 7790 { 7791 ios.width(0); 7792 { 7793 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7794 std::string ex(str, iter.base()); 7795 assert(ex == "0;0000000000000000"); 7796 assert(ios.width() == 0); 7797 } 7798 ios.width(25); 7799 left(ios); 7800 { 7801 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7802 std::string ex(str, iter.base()); 7803 assert(ex == "0;0000000000000000*******"); 7804 assert(ios.width() == 0); 7805 } 7806 ios.width(25); 7807 right(ios); 7808 { 7809 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7810 std::string ex(str, iter.base()); 7811 assert(ex == "*******0;0000000000000000"); 7812 assert(ios.width() == 0); 7813 } 7814 ios.width(25); 7815 internal(ios); 7816 { 7817 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7818 std::string ex(str, iter.base()); 7819 assert(ex == "*******0;0000000000000000"); 7820 assert(ios.width() == 0); 7821 } 7822 } 7823 } 7824 showpoint(ios); 7825 { 7826 ios.imbue(lc); 7827 { 7828 ios.width(0); 7829 { 7830 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7831 std::string ex(str, iter.base()); 7832 assert(ex == "0.0000000000000000"); 7833 assert(ios.width() == 0); 7834 } 7835 ios.width(25); 7836 left(ios); 7837 { 7838 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7839 std::string ex(str, iter.base()); 7840 assert(ex == "0.0000000000000000*******"); 7841 assert(ios.width() == 0); 7842 } 7843 ios.width(25); 7844 right(ios); 7845 { 7846 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7847 std::string ex(str, iter.base()); 7848 assert(ex == "*******0.0000000000000000"); 7849 assert(ios.width() == 0); 7850 } 7851 ios.width(25); 7852 internal(ios); 7853 { 7854 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7855 std::string ex(str, iter.base()); 7856 assert(ex == "*******0.0000000000000000"); 7857 assert(ios.width() == 0); 7858 } 7859 } 7860 ios.imbue(lg); 7861 { 7862 ios.width(0); 7863 { 7864 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7865 std::string ex(str, iter.base()); 7866 assert(ex == "0;0000000000000000"); 7867 assert(ios.width() == 0); 7868 } 7869 ios.width(25); 7870 left(ios); 7871 { 7872 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7873 std::string ex(str, iter.base()); 7874 assert(ex == "0;0000000000000000*******"); 7875 assert(ios.width() == 0); 7876 } 7877 ios.width(25); 7878 right(ios); 7879 { 7880 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7881 std::string ex(str, iter.base()); 7882 assert(ex == "*******0;0000000000000000"); 7883 assert(ios.width() == 0); 7884 } 7885 ios.width(25); 7886 internal(ios); 7887 { 7888 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7889 std::string ex(str, iter.base()); 7890 assert(ex == "*******0;0000000000000000"); 7891 assert(ios.width() == 0); 7892 } 7893 } 7894 } 7895 } 7896 showpos(ios); 7897 { 7898 noshowpoint(ios); 7899 { 7900 ios.imbue(lc); 7901 { 7902 ios.width(0); 7903 { 7904 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7905 std::string ex(str, iter.base()); 7906 assert(ex == "+0.0000000000000000"); 7907 assert(ios.width() == 0); 7908 } 7909 ios.width(25); 7910 left(ios); 7911 { 7912 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7913 std::string ex(str, iter.base()); 7914 assert(ex == "+0.0000000000000000******"); 7915 assert(ios.width() == 0); 7916 } 7917 ios.width(25); 7918 right(ios); 7919 { 7920 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7921 std::string ex(str, iter.base()); 7922 assert(ex == "******+0.0000000000000000"); 7923 assert(ios.width() == 0); 7924 } 7925 ios.width(25); 7926 internal(ios); 7927 { 7928 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7929 std::string ex(str, iter.base()); 7930 assert(ex == "+******0.0000000000000000"); 7931 assert(ios.width() == 0); 7932 } 7933 } 7934 ios.imbue(lg); 7935 { 7936 ios.width(0); 7937 { 7938 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7939 std::string ex(str, iter.base()); 7940 assert(ex == "+0;0000000000000000"); 7941 assert(ios.width() == 0); 7942 } 7943 ios.width(25); 7944 left(ios); 7945 { 7946 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7947 std::string ex(str, iter.base()); 7948 assert(ex == "+0;0000000000000000******"); 7949 assert(ios.width() == 0); 7950 } 7951 ios.width(25); 7952 right(ios); 7953 { 7954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7955 std::string ex(str, iter.base()); 7956 assert(ex == "******+0;0000000000000000"); 7957 assert(ios.width() == 0); 7958 } 7959 ios.width(25); 7960 internal(ios); 7961 { 7962 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7963 std::string ex(str, iter.base()); 7964 assert(ex == "+******0;0000000000000000"); 7965 assert(ios.width() == 0); 7966 } 7967 } 7968 } 7969 showpoint(ios); 7970 { 7971 ios.imbue(lc); 7972 { 7973 ios.width(0); 7974 { 7975 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7976 std::string ex(str, iter.base()); 7977 assert(ex == "+0.0000000000000000"); 7978 assert(ios.width() == 0); 7979 } 7980 ios.width(25); 7981 left(ios); 7982 { 7983 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7984 std::string ex(str, iter.base()); 7985 assert(ex == "+0.0000000000000000******"); 7986 assert(ios.width() == 0); 7987 } 7988 ios.width(25); 7989 right(ios); 7990 { 7991 iter = f.put(output_iterator<char*>(str), ios, '*', v); 7992 std::string ex(str, iter.base()); 7993 assert(ex == "******+0.0000000000000000"); 7994 assert(ios.width() == 0); 7995 } 7996 ios.width(25); 7997 internal(ios); 7998 { 7999 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8000 std::string ex(str, iter.base()); 8001 assert(ex == "+******0.0000000000000000"); 8002 assert(ios.width() == 0); 8003 } 8004 } 8005 ios.imbue(lg); 8006 { 8007 ios.width(0); 8008 { 8009 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8010 std::string ex(str, iter.base()); 8011 assert(ex == "+0;0000000000000000"); 8012 assert(ios.width() == 0); 8013 } 8014 ios.width(25); 8015 left(ios); 8016 { 8017 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8018 std::string ex(str, iter.base()); 8019 assert(ex == "+0;0000000000000000******"); 8020 assert(ios.width() == 0); 8021 } 8022 ios.width(25); 8023 right(ios); 8024 { 8025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8026 std::string ex(str, iter.base()); 8027 assert(ex == "******+0;0000000000000000"); 8028 assert(ios.width() == 0); 8029 } 8030 ios.width(25); 8031 internal(ios); 8032 { 8033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8034 std::string ex(str, iter.base()); 8035 assert(ex == "+******0;0000000000000000"); 8036 assert(ios.width() == 0); 8037 } 8038 } 8039 } 8040 } 8041 } 8042 uppercase(ios); 8043 { 8044 noshowpos(ios); 8045 { 8046 noshowpoint(ios); 8047 { 8048 ios.imbue(lc); 8049 { 8050 ios.width(0); 8051 { 8052 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8053 std::string ex(str, iter.base()); 8054 assert(ex == "0.0000000000000000"); 8055 assert(ios.width() == 0); 8056 } 8057 ios.width(25); 8058 left(ios); 8059 { 8060 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8061 std::string ex(str, iter.base()); 8062 assert(ex == "0.0000000000000000*******"); 8063 assert(ios.width() == 0); 8064 } 8065 ios.width(25); 8066 right(ios); 8067 { 8068 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8069 std::string ex(str, iter.base()); 8070 assert(ex == "*******0.0000000000000000"); 8071 assert(ios.width() == 0); 8072 } 8073 ios.width(25); 8074 internal(ios); 8075 { 8076 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8077 std::string ex(str, iter.base()); 8078 assert(ex == "*******0.0000000000000000"); 8079 assert(ios.width() == 0); 8080 } 8081 } 8082 ios.imbue(lg); 8083 { 8084 ios.width(0); 8085 { 8086 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8087 std::string ex(str, iter.base()); 8088 assert(ex == "0;0000000000000000"); 8089 assert(ios.width() == 0); 8090 } 8091 ios.width(25); 8092 left(ios); 8093 { 8094 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8095 std::string ex(str, iter.base()); 8096 assert(ex == "0;0000000000000000*******"); 8097 assert(ios.width() == 0); 8098 } 8099 ios.width(25); 8100 right(ios); 8101 { 8102 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8103 std::string ex(str, iter.base()); 8104 assert(ex == "*******0;0000000000000000"); 8105 assert(ios.width() == 0); 8106 } 8107 ios.width(25); 8108 internal(ios); 8109 { 8110 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8111 std::string ex(str, iter.base()); 8112 assert(ex == "*******0;0000000000000000"); 8113 assert(ios.width() == 0); 8114 } 8115 } 8116 } 8117 showpoint(ios); 8118 { 8119 ios.imbue(lc); 8120 { 8121 ios.width(0); 8122 { 8123 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8124 std::string ex(str, iter.base()); 8125 assert(ex == "0.0000000000000000"); 8126 assert(ios.width() == 0); 8127 } 8128 ios.width(25); 8129 left(ios); 8130 { 8131 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8132 std::string ex(str, iter.base()); 8133 assert(ex == "0.0000000000000000*******"); 8134 assert(ios.width() == 0); 8135 } 8136 ios.width(25); 8137 right(ios); 8138 { 8139 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8140 std::string ex(str, iter.base()); 8141 assert(ex == "*******0.0000000000000000"); 8142 assert(ios.width() == 0); 8143 } 8144 ios.width(25); 8145 internal(ios); 8146 { 8147 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8148 std::string ex(str, iter.base()); 8149 assert(ex == "*******0.0000000000000000"); 8150 assert(ios.width() == 0); 8151 } 8152 } 8153 ios.imbue(lg); 8154 { 8155 ios.width(0); 8156 { 8157 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8158 std::string ex(str, iter.base()); 8159 assert(ex == "0;0000000000000000"); 8160 assert(ios.width() == 0); 8161 } 8162 ios.width(25); 8163 left(ios); 8164 { 8165 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8166 std::string ex(str, iter.base()); 8167 assert(ex == "0;0000000000000000*******"); 8168 assert(ios.width() == 0); 8169 } 8170 ios.width(25); 8171 right(ios); 8172 { 8173 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8174 std::string ex(str, iter.base()); 8175 assert(ex == "*******0;0000000000000000"); 8176 assert(ios.width() == 0); 8177 } 8178 ios.width(25); 8179 internal(ios); 8180 { 8181 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8182 std::string ex(str, iter.base()); 8183 assert(ex == "*******0;0000000000000000"); 8184 assert(ios.width() == 0); 8185 } 8186 } 8187 } 8188 } 8189 showpos(ios); 8190 { 8191 noshowpoint(ios); 8192 { 8193 ios.imbue(lc); 8194 { 8195 ios.width(0); 8196 { 8197 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8198 std::string ex(str, iter.base()); 8199 assert(ex == "+0.0000000000000000"); 8200 assert(ios.width() == 0); 8201 } 8202 ios.width(25); 8203 left(ios); 8204 { 8205 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8206 std::string ex(str, iter.base()); 8207 assert(ex == "+0.0000000000000000******"); 8208 assert(ios.width() == 0); 8209 } 8210 ios.width(25); 8211 right(ios); 8212 { 8213 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8214 std::string ex(str, iter.base()); 8215 assert(ex == "******+0.0000000000000000"); 8216 assert(ios.width() == 0); 8217 } 8218 ios.width(25); 8219 internal(ios); 8220 { 8221 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8222 std::string ex(str, iter.base()); 8223 assert(ex == "+******0.0000000000000000"); 8224 assert(ios.width() == 0); 8225 } 8226 } 8227 ios.imbue(lg); 8228 { 8229 ios.width(0); 8230 { 8231 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8232 std::string ex(str, iter.base()); 8233 assert(ex == "+0;0000000000000000"); 8234 assert(ios.width() == 0); 8235 } 8236 ios.width(25); 8237 left(ios); 8238 { 8239 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8240 std::string ex(str, iter.base()); 8241 assert(ex == "+0;0000000000000000******"); 8242 assert(ios.width() == 0); 8243 } 8244 ios.width(25); 8245 right(ios); 8246 { 8247 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8248 std::string ex(str, iter.base()); 8249 assert(ex == "******+0;0000000000000000"); 8250 assert(ios.width() == 0); 8251 } 8252 ios.width(25); 8253 internal(ios); 8254 { 8255 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8256 std::string ex(str, iter.base()); 8257 assert(ex == "+******0;0000000000000000"); 8258 assert(ios.width() == 0); 8259 } 8260 } 8261 } 8262 showpoint(ios); 8263 { 8264 ios.imbue(lc); 8265 { 8266 ios.width(0); 8267 { 8268 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8269 std::string ex(str, iter.base()); 8270 assert(ex == "+0.0000000000000000"); 8271 assert(ios.width() == 0); 8272 } 8273 ios.width(25); 8274 left(ios); 8275 { 8276 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8277 std::string ex(str, iter.base()); 8278 assert(ex == "+0.0000000000000000******"); 8279 assert(ios.width() == 0); 8280 } 8281 ios.width(25); 8282 right(ios); 8283 { 8284 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8285 std::string ex(str, iter.base()); 8286 assert(ex == "******+0.0000000000000000"); 8287 assert(ios.width() == 0); 8288 } 8289 ios.width(25); 8290 internal(ios); 8291 { 8292 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8293 std::string ex(str, iter.base()); 8294 assert(ex == "+******0.0000000000000000"); 8295 assert(ios.width() == 0); 8296 } 8297 } 8298 ios.imbue(lg); 8299 { 8300 ios.width(0); 8301 { 8302 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8303 std::string ex(str, iter.base()); 8304 assert(ex == "+0;0000000000000000"); 8305 assert(ios.width() == 0); 8306 } 8307 ios.width(25); 8308 left(ios); 8309 { 8310 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8311 std::string ex(str, iter.base()); 8312 assert(ex == "+0;0000000000000000******"); 8313 assert(ios.width() == 0); 8314 } 8315 ios.width(25); 8316 right(ios); 8317 { 8318 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8319 std::string ex(str, iter.base()); 8320 assert(ex == "******+0;0000000000000000"); 8321 assert(ios.width() == 0); 8322 } 8323 ios.width(25); 8324 internal(ios); 8325 { 8326 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8327 std::string ex(str, iter.base()); 8328 assert(ex == "+******0;0000000000000000"); 8329 assert(ios.width() == 0); 8330 } 8331 } 8332 } 8333 } 8334 } 8335 } 8336 ios.precision(60); 8337 { 8338 nouppercase(ios); 8339 { 8340 noshowpos(ios); 8341 { 8342 noshowpoint(ios); 8343 { 8344 ios.imbue(lc); 8345 { 8346 ios.width(0); 8347 { 8348 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8349 std::string ex(str, iter.base()); 8350 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8351 assert(ios.width() == 0); 8352 } 8353 ios.width(25); 8354 left(ios); 8355 { 8356 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8357 std::string ex(str, iter.base()); 8358 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8359 assert(ios.width() == 0); 8360 } 8361 ios.width(25); 8362 right(ios); 8363 { 8364 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8365 std::string ex(str, iter.base()); 8366 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8367 assert(ios.width() == 0); 8368 } 8369 ios.width(25); 8370 internal(ios); 8371 { 8372 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8373 std::string ex(str, iter.base()); 8374 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8375 assert(ios.width() == 0); 8376 } 8377 } 8378 ios.imbue(lg); 8379 { 8380 ios.width(0); 8381 { 8382 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8383 std::string ex(str, iter.base()); 8384 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8385 assert(ios.width() == 0); 8386 } 8387 ios.width(25); 8388 left(ios); 8389 { 8390 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8391 std::string ex(str, iter.base()); 8392 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8393 assert(ios.width() == 0); 8394 } 8395 ios.width(25); 8396 right(ios); 8397 { 8398 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8399 std::string ex(str, iter.base()); 8400 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8401 assert(ios.width() == 0); 8402 } 8403 ios.width(25); 8404 internal(ios); 8405 { 8406 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8407 std::string ex(str, iter.base()); 8408 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8409 assert(ios.width() == 0); 8410 } 8411 } 8412 } 8413 showpoint(ios); 8414 { 8415 ios.imbue(lc); 8416 { 8417 ios.width(0); 8418 { 8419 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8420 std::string ex(str, iter.base()); 8421 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8422 assert(ios.width() == 0); 8423 } 8424 ios.width(25); 8425 left(ios); 8426 { 8427 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8428 std::string ex(str, iter.base()); 8429 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8430 assert(ios.width() == 0); 8431 } 8432 ios.width(25); 8433 right(ios); 8434 { 8435 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8436 std::string ex(str, iter.base()); 8437 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8438 assert(ios.width() == 0); 8439 } 8440 ios.width(25); 8441 internal(ios); 8442 { 8443 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8444 std::string ex(str, iter.base()); 8445 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8446 assert(ios.width() == 0); 8447 } 8448 } 8449 ios.imbue(lg); 8450 { 8451 ios.width(0); 8452 { 8453 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8454 std::string ex(str, iter.base()); 8455 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8456 assert(ios.width() == 0); 8457 } 8458 ios.width(25); 8459 left(ios); 8460 { 8461 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8462 std::string ex(str, iter.base()); 8463 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8464 assert(ios.width() == 0); 8465 } 8466 ios.width(25); 8467 right(ios); 8468 { 8469 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8470 std::string ex(str, iter.base()); 8471 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8472 assert(ios.width() == 0); 8473 } 8474 ios.width(25); 8475 internal(ios); 8476 { 8477 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8478 std::string ex(str, iter.base()); 8479 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8480 assert(ios.width() == 0); 8481 } 8482 } 8483 } 8484 } 8485 showpos(ios); 8486 { 8487 noshowpoint(ios); 8488 { 8489 ios.imbue(lc); 8490 { 8491 ios.width(0); 8492 { 8493 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8494 std::string ex(str, iter.base()); 8495 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8496 assert(ios.width() == 0); 8497 } 8498 ios.width(25); 8499 left(ios); 8500 { 8501 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8502 std::string ex(str, iter.base()); 8503 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8504 assert(ios.width() == 0); 8505 } 8506 ios.width(25); 8507 right(ios); 8508 { 8509 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8510 std::string ex(str, iter.base()); 8511 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8512 assert(ios.width() == 0); 8513 } 8514 ios.width(25); 8515 internal(ios); 8516 { 8517 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8518 std::string ex(str, iter.base()); 8519 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8520 assert(ios.width() == 0); 8521 } 8522 } 8523 ios.imbue(lg); 8524 { 8525 ios.width(0); 8526 { 8527 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8528 std::string ex(str, iter.base()); 8529 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8530 assert(ios.width() == 0); 8531 } 8532 ios.width(25); 8533 left(ios); 8534 { 8535 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8536 std::string ex(str, iter.base()); 8537 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8538 assert(ios.width() == 0); 8539 } 8540 ios.width(25); 8541 right(ios); 8542 { 8543 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8544 std::string ex(str, iter.base()); 8545 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8546 assert(ios.width() == 0); 8547 } 8548 ios.width(25); 8549 internal(ios); 8550 { 8551 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8552 std::string ex(str, iter.base()); 8553 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8554 assert(ios.width() == 0); 8555 } 8556 } 8557 } 8558 showpoint(ios); 8559 { 8560 ios.imbue(lc); 8561 { 8562 ios.width(0); 8563 { 8564 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8565 std::string ex(str, iter.base()); 8566 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8567 assert(ios.width() == 0); 8568 } 8569 ios.width(25); 8570 left(ios); 8571 { 8572 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8573 std::string ex(str, iter.base()); 8574 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8575 assert(ios.width() == 0); 8576 } 8577 ios.width(25); 8578 right(ios); 8579 { 8580 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8581 std::string ex(str, iter.base()); 8582 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8583 assert(ios.width() == 0); 8584 } 8585 ios.width(25); 8586 internal(ios); 8587 { 8588 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8589 std::string ex(str, iter.base()); 8590 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8591 assert(ios.width() == 0); 8592 } 8593 } 8594 ios.imbue(lg); 8595 { 8596 ios.width(0); 8597 { 8598 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8599 std::string ex(str, iter.base()); 8600 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8601 assert(ios.width() == 0); 8602 } 8603 ios.width(25); 8604 left(ios); 8605 { 8606 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8607 std::string ex(str, iter.base()); 8608 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8609 assert(ios.width() == 0); 8610 } 8611 ios.width(25); 8612 right(ios); 8613 { 8614 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8615 std::string ex(str, iter.base()); 8616 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8617 assert(ios.width() == 0); 8618 } 8619 ios.width(25); 8620 internal(ios); 8621 { 8622 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8623 std::string ex(str, iter.base()); 8624 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8625 assert(ios.width() == 0); 8626 } 8627 } 8628 } 8629 } 8630 } 8631 uppercase(ios); 8632 { 8633 noshowpos(ios); 8634 { 8635 noshowpoint(ios); 8636 { 8637 ios.imbue(lc); 8638 { 8639 ios.width(0); 8640 { 8641 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8642 std::string ex(str, iter.base()); 8643 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8644 assert(ios.width() == 0); 8645 } 8646 ios.width(25); 8647 left(ios); 8648 { 8649 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8650 std::string ex(str, iter.base()); 8651 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8652 assert(ios.width() == 0); 8653 } 8654 ios.width(25); 8655 right(ios); 8656 { 8657 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8658 std::string ex(str, iter.base()); 8659 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8660 assert(ios.width() == 0); 8661 } 8662 ios.width(25); 8663 internal(ios); 8664 { 8665 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8666 std::string ex(str, iter.base()); 8667 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8668 assert(ios.width() == 0); 8669 } 8670 } 8671 ios.imbue(lg); 8672 { 8673 ios.width(0); 8674 { 8675 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8676 std::string ex(str, iter.base()); 8677 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8678 assert(ios.width() == 0); 8679 } 8680 ios.width(25); 8681 left(ios); 8682 { 8683 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8684 std::string ex(str, iter.base()); 8685 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8686 assert(ios.width() == 0); 8687 } 8688 ios.width(25); 8689 right(ios); 8690 { 8691 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8692 std::string ex(str, iter.base()); 8693 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8694 assert(ios.width() == 0); 8695 } 8696 ios.width(25); 8697 internal(ios); 8698 { 8699 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8700 std::string ex(str, iter.base()); 8701 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8702 assert(ios.width() == 0); 8703 } 8704 } 8705 } 8706 showpoint(ios); 8707 { 8708 ios.imbue(lc); 8709 { 8710 ios.width(0); 8711 { 8712 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8713 std::string ex(str, iter.base()); 8714 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8715 assert(ios.width() == 0); 8716 } 8717 ios.width(25); 8718 left(ios); 8719 { 8720 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8721 std::string ex(str, iter.base()); 8722 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8723 assert(ios.width() == 0); 8724 } 8725 ios.width(25); 8726 right(ios); 8727 { 8728 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8729 std::string ex(str, iter.base()); 8730 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8731 assert(ios.width() == 0); 8732 } 8733 ios.width(25); 8734 internal(ios); 8735 { 8736 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8737 std::string ex(str, iter.base()); 8738 assert(ex == "0.000000000000000000000000000000000000000000000000000000000000"); 8739 assert(ios.width() == 0); 8740 } 8741 } 8742 ios.imbue(lg); 8743 { 8744 ios.width(0); 8745 { 8746 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8747 std::string ex(str, iter.base()); 8748 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8749 assert(ios.width() == 0); 8750 } 8751 ios.width(25); 8752 left(ios); 8753 { 8754 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8755 std::string ex(str, iter.base()); 8756 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8757 assert(ios.width() == 0); 8758 } 8759 ios.width(25); 8760 right(ios); 8761 { 8762 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8763 std::string ex(str, iter.base()); 8764 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8765 assert(ios.width() == 0); 8766 } 8767 ios.width(25); 8768 internal(ios); 8769 { 8770 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8771 std::string ex(str, iter.base()); 8772 assert(ex == "0;000000000000000000000000000000000000000000000000000000000000"); 8773 assert(ios.width() == 0); 8774 } 8775 } 8776 } 8777 } 8778 showpos(ios); 8779 { 8780 noshowpoint(ios); 8781 { 8782 ios.imbue(lc); 8783 { 8784 ios.width(0); 8785 { 8786 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8787 std::string ex(str, iter.base()); 8788 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8789 assert(ios.width() == 0); 8790 } 8791 ios.width(25); 8792 left(ios); 8793 { 8794 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8795 std::string ex(str, iter.base()); 8796 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8797 assert(ios.width() == 0); 8798 } 8799 ios.width(25); 8800 right(ios); 8801 { 8802 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8803 std::string ex(str, iter.base()); 8804 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8805 assert(ios.width() == 0); 8806 } 8807 ios.width(25); 8808 internal(ios); 8809 { 8810 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8811 std::string ex(str, iter.base()); 8812 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8813 assert(ios.width() == 0); 8814 } 8815 } 8816 ios.imbue(lg); 8817 { 8818 ios.width(0); 8819 { 8820 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8821 std::string ex(str, iter.base()); 8822 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8823 assert(ios.width() == 0); 8824 } 8825 ios.width(25); 8826 left(ios); 8827 { 8828 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8829 std::string ex(str, iter.base()); 8830 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8831 assert(ios.width() == 0); 8832 } 8833 ios.width(25); 8834 right(ios); 8835 { 8836 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8837 std::string ex(str, iter.base()); 8838 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8839 assert(ios.width() == 0); 8840 } 8841 ios.width(25); 8842 internal(ios); 8843 { 8844 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8845 std::string ex(str, iter.base()); 8846 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8847 assert(ios.width() == 0); 8848 } 8849 } 8850 } 8851 showpoint(ios); 8852 { 8853 ios.imbue(lc); 8854 { 8855 ios.width(0); 8856 { 8857 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8858 std::string ex(str, iter.base()); 8859 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8860 assert(ios.width() == 0); 8861 } 8862 ios.width(25); 8863 left(ios); 8864 { 8865 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8866 std::string ex(str, iter.base()); 8867 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8868 assert(ios.width() == 0); 8869 } 8870 ios.width(25); 8871 right(ios); 8872 { 8873 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8874 std::string ex(str, iter.base()); 8875 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8876 assert(ios.width() == 0); 8877 } 8878 ios.width(25); 8879 internal(ios); 8880 { 8881 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8882 std::string ex(str, iter.base()); 8883 assert(ex == "+0.000000000000000000000000000000000000000000000000000000000000"); 8884 assert(ios.width() == 0); 8885 } 8886 } 8887 ios.imbue(lg); 8888 { 8889 ios.width(0); 8890 { 8891 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8892 std::string ex(str, iter.base()); 8893 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8894 assert(ios.width() == 0); 8895 } 8896 ios.width(25); 8897 left(ios); 8898 { 8899 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8900 std::string ex(str, iter.base()); 8901 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8902 assert(ios.width() == 0); 8903 } 8904 ios.width(25); 8905 right(ios); 8906 { 8907 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8908 std::string ex(str, iter.base()); 8909 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8910 assert(ios.width() == 0); 8911 } 8912 ios.width(25); 8913 internal(ios); 8914 { 8915 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8916 std::string ex(str, iter.base()); 8917 assert(ex == "+0;000000000000000000000000000000000000000000000000000000000000"); 8918 assert(ios.width() == 0); 8919 } 8920 } 8921 } 8922 } 8923 } 8924 } 8925 } 8926 } 8927} 8928 8929void test4() 8930{ 8931 char str[200]; 8932 output_iterator<char*> iter; 8933 std::locale lc = std::locale::classic(); 8934 std::locale lg(lc, new my_numpunct); 8935 const my_facet f(1); 8936 { 8937 double v = 1234567890.125; 8938 std::ios ios(0); 8939 fixed(ios); 8940 // %f 8941 { 8942 ios.precision(0); 8943 { 8944 nouppercase(ios); 8945 { 8946 noshowpos(ios); 8947 { 8948 noshowpoint(ios); 8949 { 8950 ios.imbue(lc); 8951 { 8952 ios.width(0); 8953 { 8954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8955 std::string ex(str, iter.base()); 8956 assert(ex == "1234567890"); 8957 assert(ios.width() == 0); 8958 } 8959 ios.width(25); 8960 left(ios); 8961 { 8962 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8963 std::string ex(str, iter.base()); 8964 assert(ex == "1234567890***************"); 8965 assert(ios.width() == 0); 8966 } 8967 ios.width(25); 8968 right(ios); 8969 { 8970 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8971 std::string ex(str, iter.base()); 8972 assert(ex == "***************1234567890"); 8973 assert(ios.width() == 0); 8974 } 8975 ios.width(25); 8976 internal(ios); 8977 { 8978 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8979 std::string ex(str, iter.base()); 8980 assert(ex == "***************1234567890"); 8981 assert(ios.width() == 0); 8982 } 8983 } 8984 ios.imbue(lg); 8985 { 8986 ios.width(0); 8987 { 8988 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8989 std::string ex(str, iter.base()); 8990 assert(ex == "1_234_567_89_0"); 8991 assert(ios.width() == 0); 8992 } 8993 ios.width(25); 8994 left(ios); 8995 { 8996 iter = f.put(output_iterator<char*>(str), ios, '*', v); 8997 std::string ex(str, iter.base()); 8998 assert(ex == "1_234_567_89_0***********"); 8999 assert(ios.width() == 0); 9000 } 9001 ios.width(25); 9002 right(ios); 9003 { 9004 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9005 std::string ex(str, iter.base()); 9006 assert(ex == "***********1_234_567_89_0"); 9007 assert(ios.width() == 0); 9008 } 9009 ios.width(25); 9010 internal(ios); 9011 { 9012 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9013 std::string ex(str, iter.base()); 9014 assert(ex == "***********1_234_567_89_0"); 9015 assert(ios.width() == 0); 9016 } 9017 } 9018 } 9019 showpoint(ios); 9020 { 9021 ios.imbue(lc); 9022 { 9023 ios.width(0); 9024 { 9025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9026 std::string ex(str, iter.base()); 9027 assert(ex == "1234567890."); 9028 assert(ios.width() == 0); 9029 } 9030 ios.width(25); 9031 left(ios); 9032 { 9033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9034 std::string ex(str, iter.base()); 9035 assert(ex == "1234567890.**************"); 9036 assert(ios.width() == 0); 9037 } 9038 ios.width(25); 9039 right(ios); 9040 { 9041 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9042 std::string ex(str, iter.base()); 9043 assert(ex == "**************1234567890."); 9044 assert(ios.width() == 0); 9045 } 9046 ios.width(25); 9047 internal(ios); 9048 { 9049 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9050 std::string ex(str, iter.base()); 9051 assert(ex == "**************1234567890."); 9052 assert(ios.width() == 0); 9053 } 9054 } 9055 ios.imbue(lg); 9056 { 9057 ios.width(0); 9058 { 9059 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9060 std::string ex(str, iter.base()); 9061 assert(ex == "1_234_567_89_0;"); 9062 assert(ios.width() == 0); 9063 } 9064 ios.width(25); 9065 left(ios); 9066 { 9067 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9068 std::string ex(str, iter.base()); 9069 assert(ex == "1_234_567_89_0;**********"); 9070 assert(ios.width() == 0); 9071 } 9072 ios.width(25); 9073 right(ios); 9074 { 9075 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9076 std::string ex(str, iter.base()); 9077 assert(ex == "**********1_234_567_89_0;"); 9078 assert(ios.width() == 0); 9079 } 9080 ios.width(25); 9081 internal(ios); 9082 { 9083 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9084 std::string ex(str, iter.base()); 9085 assert(ex == "**********1_234_567_89_0;"); 9086 assert(ios.width() == 0); 9087 } 9088 } 9089 } 9090 } 9091 showpos(ios); 9092 { 9093 noshowpoint(ios); 9094 { 9095 ios.imbue(lc); 9096 { 9097 ios.width(0); 9098 { 9099 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9100 std::string ex(str, iter.base()); 9101 assert(ex == "+1234567890"); 9102 assert(ios.width() == 0); 9103 } 9104 ios.width(25); 9105 left(ios); 9106 { 9107 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9108 std::string ex(str, iter.base()); 9109 assert(ex == "+1234567890**************"); 9110 assert(ios.width() == 0); 9111 } 9112 ios.width(25); 9113 right(ios); 9114 { 9115 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9116 std::string ex(str, iter.base()); 9117 assert(ex == "**************+1234567890"); 9118 assert(ios.width() == 0); 9119 } 9120 ios.width(25); 9121 internal(ios); 9122 { 9123 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9124 std::string ex(str, iter.base()); 9125 assert(ex == "+**************1234567890"); 9126 assert(ios.width() == 0); 9127 } 9128 } 9129 ios.imbue(lg); 9130 { 9131 ios.width(0); 9132 { 9133 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9134 std::string ex(str, iter.base()); 9135 assert(ex == "+1_234_567_89_0"); 9136 assert(ios.width() == 0); 9137 } 9138 ios.width(25); 9139 left(ios); 9140 { 9141 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9142 std::string ex(str, iter.base()); 9143 assert(ex == "+1_234_567_89_0**********"); 9144 assert(ios.width() == 0); 9145 } 9146 ios.width(25); 9147 right(ios); 9148 { 9149 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9150 std::string ex(str, iter.base()); 9151 assert(ex == "**********+1_234_567_89_0"); 9152 assert(ios.width() == 0); 9153 } 9154 ios.width(25); 9155 internal(ios); 9156 { 9157 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9158 std::string ex(str, iter.base()); 9159 assert(ex == "+**********1_234_567_89_0"); 9160 assert(ios.width() == 0); 9161 } 9162 } 9163 } 9164 showpoint(ios); 9165 { 9166 ios.imbue(lc); 9167 { 9168 ios.width(0); 9169 { 9170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9171 std::string ex(str, iter.base()); 9172 assert(ex == "+1234567890."); 9173 assert(ios.width() == 0); 9174 } 9175 ios.width(25); 9176 left(ios); 9177 { 9178 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9179 std::string ex(str, iter.base()); 9180 assert(ex == "+1234567890.*************"); 9181 assert(ios.width() == 0); 9182 } 9183 ios.width(25); 9184 right(ios); 9185 { 9186 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9187 std::string ex(str, iter.base()); 9188 assert(ex == "*************+1234567890."); 9189 assert(ios.width() == 0); 9190 } 9191 ios.width(25); 9192 internal(ios); 9193 { 9194 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9195 std::string ex(str, iter.base()); 9196 assert(ex == "+*************1234567890."); 9197 assert(ios.width() == 0); 9198 } 9199 } 9200 ios.imbue(lg); 9201 { 9202 ios.width(0); 9203 { 9204 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9205 std::string ex(str, iter.base()); 9206 assert(ex == "+1_234_567_89_0;"); 9207 assert(ios.width() == 0); 9208 } 9209 ios.width(25); 9210 left(ios); 9211 { 9212 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9213 std::string ex(str, iter.base()); 9214 assert(ex == "+1_234_567_89_0;*********"); 9215 assert(ios.width() == 0); 9216 } 9217 ios.width(25); 9218 right(ios); 9219 { 9220 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9221 std::string ex(str, iter.base()); 9222 assert(ex == "*********+1_234_567_89_0;"); 9223 assert(ios.width() == 0); 9224 } 9225 ios.width(25); 9226 internal(ios); 9227 { 9228 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9229 std::string ex(str, iter.base()); 9230 assert(ex == "+*********1_234_567_89_0;"); 9231 assert(ios.width() == 0); 9232 } 9233 } 9234 } 9235 } 9236 } 9237 uppercase(ios); 9238 { 9239 noshowpos(ios); 9240 { 9241 noshowpoint(ios); 9242 { 9243 ios.imbue(lc); 9244 { 9245 ios.width(0); 9246 { 9247 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9248 std::string ex(str, iter.base()); 9249 assert(ex == "1234567890"); 9250 assert(ios.width() == 0); 9251 } 9252 ios.width(25); 9253 left(ios); 9254 { 9255 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9256 std::string ex(str, iter.base()); 9257 assert(ex == "1234567890***************"); 9258 assert(ios.width() == 0); 9259 } 9260 ios.width(25); 9261 right(ios); 9262 { 9263 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9264 std::string ex(str, iter.base()); 9265 assert(ex == "***************1234567890"); 9266 assert(ios.width() == 0); 9267 } 9268 ios.width(25); 9269 internal(ios); 9270 { 9271 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9272 std::string ex(str, iter.base()); 9273 assert(ex == "***************1234567890"); 9274 assert(ios.width() == 0); 9275 } 9276 } 9277 ios.imbue(lg); 9278 { 9279 ios.width(0); 9280 { 9281 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9282 std::string ex(str, iter.base()); 9283 assert(ex == "1_234_567_89_0"); 9284 assert(ios.width() == 0); 9285 } 9286 ios.width(25); 9287 left(ios); 9288 { 9289 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9290 std::string ex(str, iter.base()); 9291 assert(ex == "1_234_567_89_0***********"); 9292 assert(ios.width() == 0); 9293 } 9294 ios.width(25); 9295 right(ios); 9296 { 9297 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9298 std::string ex(str, iter.base()); 9299 assert(ex == "***********1_234_567_89_0"); 9300 assert(ios.width() == 0); 9301 } 9302 ios.width(25); 9303 internal(ios); 9304 { 9305 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9306 std::string ex(str, iter.base()); 9307 assert(ex == "***********1_234_567_89_0"); 9308 assert(ios.width() == 0); 9309 } 9310 } 9311 } 9312 showpoint(ios); 9313 { 9314 ios.imbue(lc); 9315 { 9316 ios.width(0); 9317 { 9318 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9319 std::string ex(str, iter.base()); 9320 assert(ex == "1234567890."); 9321 assert(ios.width() == 0); 9322 } 9323 ios.width(25); 9324 left(ios); 9325 { 9326 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9327 std::string ex(str, iter.base()); 9328 assert(ex == "1234567890.**************"); 9329 assert(ios.width() == 0); 9330 } 9331 ios.width(25); 9332 right(ios); 9333 { 9334 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9335 std::string ex(str, iter.base()); 9336 assert(ex == "**************1234567890."); 9337 assert(ios.width() == 0); 9338 } 9339 ios.width(25); 9340 internal(ios); 9341 { 9342 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9343 std::string ex(str, iter.base()); 9344 assert(ex == "**************1234567890."); 9345 assert(ios.width() == 0); 9346 } 9347 } 9348 ios.imbue(lg); 9349 { 9350 ios.width(0); 9351 { 9352 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9353 std::string ex(str, iter.base()); 9354 assert(ex == "1_234_567_89_0;"); 9355 assert(ios.width() == 0); 9356 } 9357 ios.width(25); 9358 left(ios); 9359 { 9360 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9361 std::string ex(str, iter.base()); 9362 assert(ex == "1_234_567_89_0;**********"); 9363 assert(ios.width() == 0); 9364 } 9365 ios.width(25); 9366 right(ios); 9367 { 9368 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9369 std::string ex(str, iter.base()); 9370 assert(ex == "**********1_234_567_89_0;"); 9371 assert(ios.width() == 0); 9372 } 9373 ios.width(25); 9374 internal(ios); 9375 { 9376 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9377 std::string ex(str, iter.base()); 9378 assert(ex == "**********1_234_567_89_0;"); 9379 assert(ios.width() == 0); 9380 } 9381 } 9382 } 9383 } 9384 showpos(ios); 9385 { 9386 noshowpoint(ios); 9387 { 9388 ios.imbue(lc); 9389 { 9390 ios.width(0); 9391 { 9392 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9393 std::string ex(str, iter.base()); 9394 assert(ex == "+1234567890"); 9395 assert(ios.width() == 0); 9396 } 9397 ios.width(25); 9398 left(ios); 9399 { 9400 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9401 std::string ex(str, iter.base()); 9402 assert(ex == "+1234567890**************"); 9403 assert(ios.width() == 0); 9404 } 9405 ios.width(25); 9406 right(ios); 9407 { 9408 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9409 std::string ex(str, iter.base()); 9410 assert(ex == "**************+1234567890"); 9411 assert(ios.width() == 0); 9412 } 9413 ios.width(25); 9414 internal(ios); 9415 { 9416 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9417 std::string ex(str, iter.base()); 9418 assert(ex == "+**************1234567890"); 9419 assert(ios.width() == 0); 9420 } 9421 } 9422 ios.imbue(lg); 9423 { 9424 ios.width(0); 9425 { 9426 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9427 std::string ex(str, iter.base()); 9428 assert(ex == "+1_234_567_89_0"); 9429 assert(ios.width() == 0); 9430 } 9431 ios.width(25); 9432 left(ios); 9433 { 9434 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9435 std::string ex(str, iter.base()); 9436 assert(ex == "+1_234_567_89_0**********"); 9437 assert(ios.width() == 0); 9438 } 9439 ios.width(25); 9440 right(ios); 9441 { 9442 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9443 std::string ex(str, iter.base()); 9444 assert(ex == "**********+1_234_567_89_0"); 9445 assert(ios.width() == 0); 9446 } 9447 ios.width(25); 9448 internal(ios); 9449 { 9450 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9451 std::string ex(str, iter.base()); 9452 assert(ex == "+**********1_234_567_89_0"); 9453 assert(ios.width() == 0); 9454 } 9455 } 9456 } 9457 showpoint(ios); 9458 { 9459 ios.imbue(lc); 9460 { 9461 ios.width(0); 9462 { 9463 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9464 std::string ex(str, iter.base()); 9465 assert(ex == "+1234567890."); 9466 assert(ios.width() == 0); 9467 } 9468 ios.width(25); 9469 left(ios); 9470 { 9471 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9472 std::string ex(str, iter.base()); 9473 assert(ex == "+1234567890.*************"); 9474 assert(ios.width() == 0); 9475 } 9476 ios.width(25); 9477 right(ios); 9478 { 9479 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9480 std::string ex(str, iter.base()); 9481 assert(ex == "*************+1234567890."); 9482 assert(ios.width() == 0); 9483 } 9484 ios.width(25); 9485 internal(ios); 9486 { 9487 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9488 std::string ex(str, iter.base()); 9489 assert(ex == "+*************1234567890."); 9490 assert(ios.width() == 0); 9491 } 9492 } 9493 ios.imbue(lg); 9494 { 9495 ios.width(0); 9496 { 9497 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9498 std::string ex(str, iter.base()); 9499 assert(ex == "+1_234_567_89_0;"); 9500 assert(ios.width() == 0); 9501 } 9502 ios.width(25); 9503 left(ios); 9504 { 9505 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9506 std::string ex(str, iter.base()); 9507 assert(ex == "+1_234_567_89_0;*********"); 9508 assert(ios.width() == 0); 9509 } 9510 ios.width(25); 9511 right(ios); 9512 { 9513 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9514 std::string ex(str, iter.base()); 9515 assert(ex == "*********+1_234_567_89_0;"); 9516 assert(ios.width() == 0); 9517 } 9518 ios.width(25); 9519 internal(ios); 9520 { 9521 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9522 std::string ex(str, iter.base()); 9523 assert(ex == "+*********1_234_567_89_0;"); 9524 assert(ios.width() == 0); 9525 } 9526 } 9527 } 9528 } 9529 } 9530 } 9531 ios.precision(1); 9532 { 9533 nouppercase(ios); 9534 { 9535 noshowpos(ios); 9536 { 9537 noshowpoint(ios); 9538 { 9539 ios.imbue(lc); 9540 { 9541 ios.width(0); 9542 { 9543 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9544 std::string ex(str, iter.base()); 9545 assert(ex == "1234567890.1"); 9546 assert(ios.width() == 0); 9547 } 9548 ios.width(25); 9549 left(ios); 9550 { 9551 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9552 std::string ex(str, iter.base()); 9553 assert(ex == "1234567890.1*************"); 9554 assert(ios.width() == 0); 9555 } 9556 ios.width(25); 9557 right(ios); 9558 { 9559 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9560 std::string ex(str, iter.base()); 9561 assert(ex == "*************1234567890.1"); 9562 assert(ios.width() == 0); 9563 } 9564 ios.width(25); 9565 internal(ios); 9566 { 9567 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9568 std::string ex(str, iter.base()); 9569 assert(ex == "*************1234567890.1"); 9570 assert(ios.width() == 0); 9571 } 9572 } 9573 ios.imbue(lg); 9574 { 9575 ios.width(0); 9576 { 9577 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9578 std::string ex(str, iter.base()); 9579 assert(ex == "1_234_567_89_0;1"); 9580 assert(ios.width() == 0); 9581 } 9582 ios.width(25); 9583 left(ios); 9584 { 9585 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9586 std::string ex(str, iter.base()); 9587 assert(ex == "1_234_567_89_0;1*********"); 9588 assert(ios.width() == 0); 9589 } 9590 ios.width(25); 9591 right(ios); 9592 { 9593 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9594 std::string ex(str, iter.base()); 9595 assert(ex == "*********1_234_567_89_0;1"); 9596 assert(ios.width() == 0); 9597 } 9598 ios.width(25); 9599 internal(ios); 9600 { 9601 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9602 std::string ex(str, iter.base()); 9603 assert(ex == "*********1_234_567_89_0;1"); 9604 assert(ios.width() == 0); 9605 } 9606 } 9607 } 9608 showpoint(ios); 9609 { 9610 ios.imbue(lc); 9611 { 9612 ios.width(0); 9613 { 9614 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9615 std::string ex(str, iter.base()); 9616 assert(ex == "1234567890.1"); 9617 assert(ios.width() == 0); 9618 } 9619 ios.width(25); 9620 left(ios); 9621 { 9622 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9623 std::string ex(str, iter.base()); 9624 assert(ex == "1234567890.1*************"); 9625 assert(ios.width() == 0); 9626 } 9627 ios.width(25); 9628 right(ios); 9629 { 9630 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9631 std::string ex(str, iter.base()); 9632 assert(ex == "*************1234567890.1"); 9633 assert(ios.width() == 0); 9634 } 9635 ios.width(25); 9636 internal(ios); 9637 { 9638 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9639 std::string ex(str, iter.base()); 9640 assert(ex == "*************1234567890.1"); 9641 assert(ios.width() == 0); 9642 } 9643 } 9644 ios.imbue(lg); 9645 { 9646 ios.width(0); 9647 { 9648 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9649 std::string ex(str, iter.base()); 9650 assert(ex == "1_234_567_89_0;1"); 9651 assert(ios.width() == 0); 9652 } 9653 ios.width(25); 9654 left(ios); 9655 { 9656 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9657 std::string ex(str, iter.base()); 9658 assert(ex == "1_234_567_89_0;1*********"); 9659 assert(ios.width() == 0); 9660 } 9661 ios.width(25); 9662 right(ios); 9663 { 9664 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9665 std::string ex(str, iter.base()); 9666 assert(ex == "*********1_234_567_89_0;1"); 9667 assert(ios.width() == 0); 9668 } 9669 ios.width(25); 9670 internal(ios); 9671 { 9672 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9673 std::string ex(str, iter.base()); 9674 assert(ex == "*********1_234_567_89_0;1"); 9675 assert(ios.width() == 0); 9676 } 9677 } 9678 } 9679 } 9680 showpos(ios); 9681 { 9682 noshowpoint(ios); 9683 { 9684 ios.imbue(lc); 9685 { 9686 ios.width(0); 9687 { 9688 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9689 std::string ex(str, iter.base()); 9690 assert(ex == "+1234567890.1"); 9691 assert(ios.width() == 0); 9692 } 9693 ios.width(25); 9694 left(ios); 9695 { 9696 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9697 std::string ex(str, iter.base()); 9698 assert(ex == "+1234567890.1************"); 9699 assert(ios.width() == 0); 9700 } 9701 ios.width(25); 9702 right(ios); 9703 { 9704 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9705 std::string ex(str, iter.base()); 9706 assert(ex == "************+1234567890.1"); 9707 assert(ios.width() == 0); 9708 } 9709 ios.width(25); 9710 internal(ios); 9711 { 9712 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9713 std::string ex(str, iter.base()); 9714 assert(ex == "+************1234567890.1"); 9715 assert(ios.width() == 0); 9716 } 9717 } 9718 ios.imbue(lg); 9719 { 9720 ios.width(0); 9721 { 9722 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9723 std::string ex(str, iter.base()); 9724 assert(ex == "+1_234_567_89_0;1"); 9725 assert(ios.width() == 0); 9726 } 9727 ios.width(25); 9728 left(ios); 9729 { 9730 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9731 std::string ex(str, iter.base()); 9732 assert(ex == "+1_234_567_89_0;1********"); 9733 assert(ios.width() == 0); 9734 } 9735 ios.width(25); 9736 right(ios); 9737 { 9738 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9739 std::string ex(str, iter.base()); 9740 assert(ex == "********+1_234_567_89_0;1"); 9741 assert(ios.width() == 0); 9742 } 9743 ios.width(25); 9744 internal(ios); 9745 { 9746 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9747 std::string ex(str, iter.base()); 9748 assert(ex == "+********1_234_567_89_0;1"); 9749 assert(ios.width() == 0); 9750 } 9751 } 9752 } 9753 showpoint(ios); 9754 { 9755 ios.imbue(lc); 9756 { 9757 ios.width(0); 9758 { 9759 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9760 std::string ex(str, iter.base()); 9761 assert(ex == "+1234567890.1"); 9762 assert(ios.width() == 0); 9763 } 9764 ios.width(25); 9765 left(ios); 9766 { 9767 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9768 std::string ex(str, iter.base()); 9769 assert(ex == "+1234567890.1************"); 9770 assert(ios.width() == 0); 9771 } 9772 ios.width(25); 9773 right(ios); 9774 { 9775 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9776 std::string ex(str, iter.base()); 9777 assert(ex == "************+1234567890.1"); 9778 assert(ios.width() == 0); 9779 } 9780 ios.width(25); 9781 internal(ios); 9782 { 9783 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9784 std::string ex(str, iter.base()); 9785 assert(ex == "+************1234567890.1"); 9786 assert(ios.width() == 0); 9787 } 9788 } 9789 ios.imbue(lg); 9790 { 9791 ios.width(0); 9792 { 9793 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9794 std::string ex(str, iter.base()); 9795 assert(ex == "+1_234_567_89_0;1"); 9796 assert(ios.width() == 0); 9797 } 9798 ios.width(25); 9799 left(ios); 9800 { 9801 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9802 std::string ex(str, iter.base()); 9803 assert(ex == "+1_234_567_89_0;1********"); 9804 assert(ios.width() == 0); 9805 } 9806 ios.width(25); 9807 right(ios); 9808 { 9809 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9810 std::string ex(str, iter.base()); 9811 assert(ex == "********+1_234_567_89_0;1"); 9812 assert(ios.width() == 0); 9813 } 9814 ios.width(25); 9815 internal(ios); 9816 { 9817 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9818 std::string ex(str, iter.base()); 9819 assert(ex == "+********1_234_567_89_0;1"); 9820 assert(ios.width() == 0); 9821 } 9822 } 9823 } 9824 } 9825 } 9826 uppercase(ios); 9827 { 9828 noshowpos(ios); 9829 { 9830 noshowpoint(ios); 9831 { 9832 ios.imbue(lc); 9833 { 9834 ios.width(0); 9835 { 9836 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9837 std::string ex(str, iter.base()); 9838 assert(ex == "1234567890.1"); 9839 assert(ios.width() == 0); 9840 } 9841 ios.width(25); 9842 left(ios); 9843 { 9844 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9845 std::string ex(str, iter.base()); 9846 assert(ex == "1234567890.1*************"); 9847 assert(ios.width() == 0); 9848 } 9849 ios.width(25); 9850 right(ios); 9851 { 9852 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9853 std::string ex(str, iter.base()); 9854 assert(ex == "*************1234567890.1"); 9855 assert(ios.width() == 0); 9856 } 9857 ios.width(25); 9858 internal(ios); 9859 { 9860 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9861 std::string ex(str, iter.base()); 9862 assert(ex == "*************1234567890.1"); 9863 assert(ios.width() == 0); 9864 } 9865 } 9866 ios.imbue(lg); 9867 { 9868 ios.width(0); 9869 { 9870 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9871 std::string ex(str, iter.base()); 9872 assert(ex == "1_234_567_89_0;1"); 9873 assert(ios.width() == 0); 9874 } 9875 ios.width(25); 9876 left(ios); 9877 { 9878 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9879 std::string ex(str, iter.base()); 9880 assert(ex == "1_234_567_89_0;1*********"); 9881 assert(ios.width() == 0); 9882 } 9883 ios.width(25); 9884 right(ios); 9885 { 9886 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9887 std::string ex(str, iter.base()); 9888 assert(ex == "*********1_234_567_89_0;1"); 9889 assert(ios.width() == 0); 9890 } 9891 ios.width(25); 9892 internal(ios); 9893 { 9894 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9895 std::string ex(str, iter.base()); 9896 assert(ex == "*********1_234_567_89_0;1"); 9897 assert(ios.width() == 0); 9898 } 9899 } 9900 } 9901 showpoint(ios); 9902 { 9903 ios.imbue(lc); 9904 { 9905 ios.width(0); 9906 { 9907 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9908 std::string ex(str, iter.base()); 9909 assert(ex == "1234567890.1"); 9910 assert(ios.width() == 0); 9911 } 9912 ios.width(25); 9913 left(ios); 9914 { 9915 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9916 std::string ex(str, iter.base()); 9917 assert(ex == "1234567890.1*************"); 9918 assert(ios.width() == 0); 9919 } 9920 ios.width(25); 9921 right(ios); 9922 { 9923 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9924 std::string ex(str, iter.base()); 9925 assert(ex == "*************1234567890.1"); 9926 assert(ios.width() == 0); 9927 } 9928 ios.width(25); 9929 internal(ios); 9930 { 9931 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9932 std::string ex(str, iter.base()); 9933 assert(ex == "*************1234567890.1"); 9934 assert(ios.width() == 0); 9935 } 9936 } 9937 ios.imbue(lg); 9938 { 9939 ios.width(0); 9940 { 9941 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9942 std::string ex(str, iter.base()); 9943 assert(ex == "1_234_567_89_0;1"); 9944 assert(ios.width() == 0); 9945 } 9946 ios.width(25); 9947 left(ios); 9948 { 9949 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9950 std::string ex(str, iter.base()); 9951 assert(ex == "1_234_567_89_0;1*********"); 9952 assert(ios.width() == 0); 9953 } 9954 ios.width(25); 9955 right(ios); 9956 { 9957 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9958 std::string ex(str, iter.base()); 9959 assert(ex == "*********1_234_567_89_0;1"); 9960 assert(ios.width() == 0); 9961 } 9962 ios.width(25); 9963 internal(ios); 9964 { 9965 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9966 std::string ex(str, iter.base()); 9967 assert(ex == "*********1_234_567_89_0;1"); 9968 assert(ios.width() == 0); 9969 } 9970 } 9971 } 9972 } 9973 showpos(ios); 9974 { 9975 noshowpoint(ios); 9976 { 9977 ios.imbue(lc); 9978 { 9979 ios.width(0); 9980 { 9981 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9982 std::string ex(str, iter.base()); 9983 assert(ex == "+1234567890.1"); 9984 assert(ios.width() == 0); 9985 } 9986 ios.width(25); 9987 left(ios); 9988 { 9989 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9990 std::string ex(str, iter.base()); 9991 assert(ex == "+1234567890.1************"); 9992 assert(ios.width() == 0); 9993 } 9994 ios.width(25); 9995 right(ios); 9996 { 9997 iter = f.put(output_iterator<char*>(str), ios, '*', v); 9998 std::string ex(str, iter.base()); 9999 assert(ex == "************+1234567890.1"); 10000 assert(ios.width() == 0); 10001 } 10002 ios.width(25); 10003 internal(ios); 10004 { 10005 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10006 std::string ex(str, iter.base()); 10007 assert(ex == "+************1234567890.1"); 10008 assert(ios.width() == 0); 10009 } 10010 } 10011 ios.imbue(lg); 10012 { 10013 ios.width(0); 10014 { 10015 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10016 std::string ex(str, iter.base()); 10017 assert(ex == "+1_234_567_89_0;1"); 10018 assert(ios.width() == 0); 10019 } 10020 ios.width(25); 10021 left(ios); 10022 { 10023 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10024 std::string ex(str, iter.base()); 10025 assert(ex == "+1_234_567_89_0;1********"); 10026 assert(ios.width() == 0); 10027 } 10028 ios.width(25); 10029 right(ios); 10030 { 10031 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10032 std::string ex(str, iter.base()); 10033 assert(ex == "********+1_234_567_89_0;1"); 10034 assert(ios.width() == 0); 10035 } 10036 ios.width(25); 10037 internal(ios); 10038 { 10039 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10040 std::string ex(str, iter.base()); 10041 assert(ex == "+********1_234_567_89_0;1"); 10042 assert(ios.width() == 0); 10043 } 10044 } 10045 } 10046 showpoint(ios); 10047 { 10048 ios.imbue(lc); 10049 { 10050 ios.width(0); 10051 { 10052 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10053 std::string ex(str, iter.base()); 10054 assert(ex == "+1234567890.1"); 10055 assert(ios.width() == 0); 10056 } 10057 ios.width(25); 10058 left(ios); 10059 { 10060 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10061 std::string ex(str, iter.base()); 10062 assert(ex == "+1234567890.1************"); 10063 assert(ios.width() == 0); 10064 } 10065 ios.width(25); 10066 right(ios); 10067 { 10068 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10069 std::string ex(str, iter.base()); 10070 assert(ex == "************+1234567890.1"); 10071 assert(ios.width() == 0); 10072 } 10073 ios.width(25); 10074 internal(ios); 10075 { 10076 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10077 std::string ex(str, iter.base()); 10078 assert(ex == "+************1234567890.1"); 10079 assert(ios.width() == 0); 10080 } 10081 } 10082 ios.imbue(lg); 10083 { 10084 ios.width(0); 10085 { 10086 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10087 std::string ex(str, iter.base()); 10088 assert(ex == "+1_234_567_89_0;1"); 10089 assert(ios.width() == 0); 10090 } 10091 ios.width(25); 10092 left(ios); 10093 { 10094 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10095 std::string ex(str, iter.base()); 10096 assert(ex == "+1_234_567_89_0;1********"); 10097 assert(ios.width() == 0); 10098 } 10099 ios.width(25); 10100 right(ios); 10101 { 10102 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10103 std::string ex(str, iter.base()); 10104 assert(ex == "********+1_234_567_89_0;1"); 10105 assert(ios.width() == 0); 10106 } 10107 ios.width(25); 10108 internal(ios); 10109 { 10110 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10111 std::string ex(str, iter.base()); 10112 assert(ex == "+********1_234_567_89_0;1"); 10113 assert(ios.width() == 0); 10114 } 10115 } 10116 } 10117 } 10118 } 10119 } 10120 ios.precision(6); 10121 { 10122 nouppercase(ios); 10123 { 10124 noshowpos(ios); 10125 { 10126 noshowpoint(ios); 10127 { 10128 ios.imbue(lc); 10129 { 10130 ios.width(0); 10131 { 10132 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10133 std::string ex(str, iter.base()); 10134 assert(ex == "1234567890.125000"); 10135 assert(ios.width() == 0); 10136 } 10137 ios.width(25); 10138 left(ios); 10139 { 10140 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10141 std::string ex(str, iter.base()); 10142 assert(ex == "1234567890.125000********"); 10143 assert(ios.width() == 0); 10144 } 10145 ios.width(25); 10146 right(ios); 10147 { 10148 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10149 std::string ex(str, iter.base()); 10150 assert(ex == "********1234567890.125000"); 10151 assert(ios.width() == 0); 10152 } 10153 ios.width(25); 10154 internal(ios); 10155 { 10156 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10157 std::string ex(str, iter.base()); 10158 assert(ex == "********1234567890.125000"); 10159 assert(ios.width() == 0); 10160 } 10161 } 10162 ios.imbue(lg); 10163 { 10164 ios.width(0); 10165 { 10166 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10167 std::string ex(str, iter.base()); 10168 assert(ex == "1_234_567_89_0;125000"); 10169 assert(ios.width() == 0); 10170 } 10171 ios.width(25); 10172 left(ios); 10173 { 10174 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10175 std::string ex(str, iter.base()); 10176 assert(ex == "1_234_567_89_0;125000****"); 10177 assert(ios.width() == 0); 10178 } 10179 ios.width(25); 10180 right(ios); 10181 { 10182 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10183 std::string ex(str, iter.base()); 10184 assert(ex == "****1_234_567_89_0;125000"); 10185 assert(ios.width() == 0); 10186 } 10187 ios.width(25); 10188 internal(ios); 10189 { 10190 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10191 std::string ex(str, iter.base()); 10192 assert(ex == "****1_234_567_89_0;125000"); 10193 assert(ios.width() == 0); 10194 } 10195 } 10196 } 10197 showpoint(ios); 10198 { 10199 ios.imbue(lc); 10200 { 10201 ios.width(0); 10202 { 10203 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10204 std::string ex(str, iter.base()); 10205 assert(ex == "1234567890.125000"); 10206 assert(ios.width() == 0); 10207 } 10208 ios.width(25); 10209 left(ios); 10210 { 10211 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10212 std::string ex(str, iter.base()); 10213 assert(ex == "1234567890.125000********"); 10214 assert(ios.width() == 0); 10215 } 10216 ios.width(25); 10217 right(ios); 10218 { 10219 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10220 std::string ex(str, iter.base()); 10221 assert(ex == "********1234567890.125000"); 10222 assert(ios.width() == 0); 10223 } 10224 ios.width(25); 10225 internal(ios); 10226 { 10227 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10228 std::string ex(str, iter.base()); 10229 assert(ex == "********1234567890.125000"); 10230 assert(ios.width() == 0); 10231 } 10232 } 10233 ios.imbue(lg); 10234 { 10235 ios.width(0); 10236 { 10237 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10238 std::string ex(str, iter.base()); 10239 assert(ex == "1_234_567_89_0;125000"); 10240 assert(ios.width() == 0); 10241 } 10242 ios.width(25); 10243 left(ios); 10244 { 10245 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10246 std::string ex(str, iter.base()); 10247 assert(ex == "1_234_567_89_0;125000****"); 10248 assert(ios.width() == 0); 10249 } 10250 ios.width(25); 10251 right(ios); 10252 { 10253 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10254 std::string ex(str, iter.base()); 10255 assert(ex == "****1_234_567_89_0;125000"); 10256 assert(ios.width() == 0); 10257 } 10258 ios.width(25); 10259 internal(ios); 10260 { 10261 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10262 std::string ex(str, iter.base()); 10263 assert(ex == "****1_234_567_89_0;125000"); 10264 assert(ios.width() == 0); 10265 } 10266 } 10267 } 10268 } 10269 showpos(ios); 10270 { 10271 noshowpoint(ios); 10272 { 10273 ios.imbue(lc); 10274 { 10275 ios.width(0); 10276 { 10277 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10278 std::string ex(str, iter.base()); 10279 assert(ex == "+1234567890.125000"); 10280 assert(ios.width() == 0); 10281 } 10282 ios.width(25); 10283 left(ios); 10284 { 10285 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10286 std::string ex(str, iter.base()); 10287 assert(ex == "+1234567890.125000*******"); 10288 assert(ios.width() == 0); 10289 } 10290 ios.width(25); 10291 right(ios); 10292 { 10293 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10294 std::string ex(str, iter.base()); 10295 assert(ex == "*******+1234567890.125000"); 10296 assert(ios.width() == 0); 10297 } 10298 ios.width(25); 10299 internal(ios); 10300 { 10301 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10302 std::string ex(str, iter.base()); 10303 assert(ex == "+*******1234567890.125000"); 10304 assert(ios.width() == 0); 10305 } 10306 } 10307 ios.imbue(lg); 10308 { 10309 ios.width(0); 10310 { 10311 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10312 std::string ex(str, iter.base()); 10313 assert(ex == "+1_234_567_89_0;125000"); 10314 assert(ios.width() == 0); 10315 } 10316 ios.width(25); 10317 left(ios); 10318 { 10319 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10320 std::string ex(str, iter.base()); 10321 assert(ex == "+1_234_567_89_0;125000***"); 10322 assert(ios.width() == 0); 10323 } 10324 ios.width(25); 10325 right(ios); 10326 { 10327 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10328 std::string ex(str, iter.base()); 10329 assert(ex == "***+1_234_567_89_0;125000"); 10330 assert(ios.width() == 0); 10331 } 10332 ios.width(25); 10333 internal(ios); 10334 { 10335 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10336 std::string ex(str, iter.base()); 10337 assert(ex == "+***1_234_567_89_0;125000"); 10338 assert(ios.width() == 0); 10339 } 10340 } 10341 } 10342 showpoint(ios); 10343 { 10344 ios.imbue(lc); 10345 { 10346 ios.width(0); 10347 { 10348 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10349 std::string ex(str, iter.base()); 10350 assert(ex == "+1234567890.125000"); 10351 assert(ios.width() == 0); 10352 } 10353 ios.width(25); 10354 left(ios); 10355 { 10356 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10357 std::string ex(str, iter.base()); 10358 assert(ex == "+1234567890.125000*******"); 10359 assert(ios.width() == 0); 10360 } 10361 ios.width(25); 10362 right(ios); 10363 { 10364 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10365 std::string ex(str, iter.base()); 10366 assert(ex == "*******+1234567890.125000"); 10367 assert(ios.width() == 0); 10368 } 10369 ios.width(25); 10370 internal(ios); 10371 { 10372 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10373 std::string ex(str, iter.base()); 10374 assert(ex == "+*******1234567890.125000"); 10375 assert(ios.width() == 0); 10376 } 10377 } 10378 ios.imbue(lg); 10379 { 10380 ios.width(0); 10381 { 10382 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10383 std::string ex(str, iter.base()); 10384 assert(ex == "+1_234_567_89_0;125000"); 10385 assert(ios.width() == 0); 10386 } 10387 ios.width(25); 10388 left(ios); 10389 { 10390 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10391 std::string ex(str, iter.base()); 10392 assert(ex == "+1_234_567_89_0;125000***"); 10393 assert(ios.width() == 0); 10394 } 10395 ios.width(25); 10396 right(ios); 10397 { 10398 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10399 std::string ex(str, iter.base()); 10400 assert(ex == "***+1_234_567_89_0;125000"); 10401 assert(ios.width() == 0); 10402 } 10403 ios.width(25); 10404 internal(ios); 10405 { 10406 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10407 std::string ex(str, iter.base()); 10408 assert(ex == "+***1_234_567_89_0;125000"); 10409 assert(ios.width() == 0); 10410 } 10411 } 10412 } 10413 } 10414 } 10415 uppercase(ios); 10416 { 10417 noshowpos(ios); 10418 { 10419 noshowpoint(ios); 10420 { 10421 ios.imbue(lc); 10422 { 10423 ios.width(0); 10424 { 10425 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10426 std::string ex(str, iter.base()); 10427 assert(ex == "1234567890.125000"); 10428 assert(ios.width() == 0); 10429 } 10430 ios.width(25); 10431 left(ios); 10432 { 10433 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10434 std::string ex(str, iter.base()); 10435 assert(ex == "1234567890.125000********"); 10436 assert(ios.width() == 0); 10437 } 10438 ios.width(25); 10439 right(ios); 10440 { 10441 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10442 std::string ex(str, iter.base()); 10443 assert(ex == "********1234567890.125000"); 10444 assert(ios.width() == 0); 10445 } 10446 ios.width(25); 10447 internal(ios); 10448 { 10449 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10450 std::string ex(str, iter.base()); 10451 assert(ex == "********1234567890.125000"); 10452 assert(ios.width() == 0); 10453 } 10454 } 10455 ios.imbue(lg); 10456 { 10457 ios.width(0); 10458 { 10459 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10460 std::string ex(str, iter.base()); 10461 assert(ex == "1_234_567_89_0;125000"); 10462 assert(ios.width() == 0); 10463 } 10464 ios.width(25); 10465 left(ios); 10466 { 10467 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10468 std::string ex(str, iter.base()); 10469 assert(ex == "1_234_567_89_0;125000****"); 10470 assert(ios.width() == 0); 10471 } 10472 ios.width(25); 10473 right(ios); 10474 { 10475 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10476 std::string ex(str, iter.base()); 10477 assert(ex == "****1_234_567_89_0;125000"); 10478 assert(ios.width() == 0); 10479 } 10480 ios.width(25); 10481 internal(ios); 10482 { 10483 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10484 std::string ex(str, iter.base()); 10485 assert(ex == "****1_234_567_89_0;125000"); 10486 assert(ios.width() == 0); 10487 } 10488 } 10489 } 10490 showpoint(ios); 10491 { 10492 ios.imbue(lc); 10493 { 10494 ios.width(0); 10495 { 10496 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10497 std::string ex(str, iter.base()); 10498 assert(ex == "1234567890.125000"); 10499 assert(ios.width() == 0); 10500 } 10501 ios.width(25); 10502 left(ios); 10503 { 10504 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10505 std::string ex(str, iter.base()); 10506 assert(ex == "1234567890.125000********"); 10507 assert(ios.width() == 0); 10508 } 10509 ios.width(25); 10510 right(ios); 10511 { 10512 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10513 std::string ex(str, iter.base()); 10514 assert(ex == "********1234567890.125000"); 10515 assert(ios.width() == 0); 10516 } 10517 ios.width(25); 10518 internal(ios); 10519 { 10520 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10521 std::string ex(str, iter.base()); 10522 assert(ex == "********1234567890.125000"); 10523 assert(ios.width() == 0); 10524 } 10525 } 10526 ios.imbue(lg); 10527 { 10528 ios.width(0); 10529 { 10530 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10531 std::string ex(str, iter.base()); 10532 assert(ex == "1_234_567_89_0;125000"); 10533 assert(ios.width() == 0); 10534 } 10535 ios.width(25); 10536 left(ios); 10537 { 10538 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10539 std::string ex(str, iter.base()); 10540 assert(ex == "1_234_567_89_0;125000****"); 10541 assert(ios.width() == 0); 10542 } 10543 ios.width(25); 10544 right(ios); 10545 { 10546 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10547 std::string ex(str, iter.base()); 10548 assert(ex == "****1_234_567_89_0;125000"); 10549 assert(ios.width() == 0); 10550 } 10551 ios.width(25); 10552 internal(ios); 10553 { 10554 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10555 std::string ex(str, iter.base()); 10556 assert(ex == "****1_234_567_89_0;125000"); 10557 assert(ios.width() == 0); 10558 } 10559 } 10560 } 10561 } 10562 showpos(ios); 10563 { 10564 noshowpoint(ios); 10565 { 10566 ios.imbue(lc); 10567 { 10568 ios.width(0); 10569 { 10570 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10571 std::string ex(str, iter.base()); 10572 assert(ex == "+1234567890.125000"); 10573 assert(ios.width() == 0); 10574 } 10575 ios.width(25); 10576 left(ios); 10577 { 10578 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10579 std::string ex(str, iter.base()); 10580 assert(ex == "+1234567890.125000*******"); 10581 assert(ios.width() == 0); 10582 } 10583 ios.width(25); 10584 right(ios); 10585 { 10586 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10587 std::string ex(str, iter.base()); 10588 assert(ex == "*******+1234567890.125000"); 10589 assert(ios.width() == 0); 10590 } 10591 ios.width(25); 10592 internal(ios); 10593 { 10594 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10595 std::string ex(str, iter.base()); 10596 assert(ex == "+*******1234567890.125000"); 10597 assert(ios.width() == 0); 10598 } 10599 } 10600 ios.imbue(lg); 10601 { 10602 ios.width(0); 10603 { 10604 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10605 std::string ex(str, iter.base()); 10606 assert(ex == "+1_234_567_89_0;125000"); 10607 assert(ios.width() == 0); 10608 } 10609 ios.width(25); 10610 left(ios); 10611 { 10612 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10613 std::string ex(str, iter.base()); 10614 assert(ex == "+1_234_567_89_0;125000***"); 10615 assert(ios.width() == 0); 10616 } 10617 ios.width(25); 10618 right(ios); 10619 { 10620 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10621 std::string ex(str, iter.base()); 10622 assert(ex == "***+1_234_567_89_0;125000"); 10623 assert(ios.width() == 0); 10624 } 10625 ios.width(25); 10626 internal(ios); 10627 { 10628 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10629 std::string ex(str, iter.base()); 10630 assert(ex == "+***1_234_567_89_0;125000"); 10631 assert(ios.width() == 0); 10632 } 10633 } 10634 } 10635 showpoint(ios); 10636 { 10637 ios.imbue(lc); 10638 { 10639 ios.width(0); 10640 { 10641 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10642 std::string ex(str, iter.base()); 10643 assert(ex == "+1234567890.125000"); 10644 assert(ios.width() == 0); 10645 } 10646 ios.width(25); 10647 left(ios); 10648 { 10649 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10650 std::string ex(str, iter.base()); 10651 assert(ex == "+1234567890.125000*******"); 10652 assert(ios.width() == 0); 10653 } 10654 ios.width(25); 10655 right(ios); 10656 { 10657 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10658 std::string ex(str, iter.base()); 10659 assert(ex == "*******+1234567890.125000"); 10660 assert(ios.width() == 0); 10661 } 10662 ios.width(25); 10663 internal(ios); 10664 { 10665 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10666 std::string ex(str, iter.base()); 10667 assert(ex == "+*******1234567890.125000"); 10668 assert(ios.width() == 0); 10669 } 10670 } 10671 ios.imbue(lg); 10672 { 10673 ios.width(0); 10674 { 10675 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10676 std::string ex(str, iter.base()); 10677 assert(ex == "+1_234_567_89_0;125000"); 10678 assert(ios.width() == 0); 10679 } 10680 ios.width(25); 10681 left(ios); 10682 { 10683 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10684 std::string ex(str, iter.base()); 10685 assert(ex == "+1_234_567_89_0;125000***"); 10686 assert(ios.width() == 0); 10687 } 10688 ios.width(25); 10689 right(ios); 10690 { 10691 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10692 std::string ex(str, iter.base()); 10693 assert(ex == "***+1_234_567_89_0;125000"); 10694 assert(ios.width() == 0); 10695 } 10696 ios.width(25); 10697 internal(ios); 10698 { 10699 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10700 std::string ex(str, iter.base()); 10701 assert(ex == "+***1_234_567_89_0;125000"); 10702 assert(ios.width() == 0); 10703 } 10704 } 10705 } 10706 } 10707 } 10708 } 10709 ios.precision(16); 10710 {} 10711 ios.precision(60); 10712 {} 10713 } 10714 } 10715} 10716 10717void test5() 10718{ 10719 char str[200]; 10720 output_iterator<char*> iter; 10721 std::locale lc = std::locale::classic(); 10722 std::locale lg(lc, new my_numpunct); 10723 const my_facet f(1); 10724 { 10725 double v = -0.; 10726 std::ios ios(0); 10727 scientific(ios); 10728 // %e 10729 { 10730 ios.precision(0); 10731 { 10732 nouppercase(ios); 10733 { 10734 noshowpos(ios); 10735 { 10736 noshowpoint(ios); 10737 { 10738 ios.imbue(lc); 10739 { 10740 ios.width(0); 10741 { 10742 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10743 std::string ex(str, iter.base()); 10744 assert(ex == "-0e+00"); 10745 assert(ios.width() == 0); 10746 } 10747 ios.width(25); 10748 left(ios); 10749 { 10750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10751 std::string ex(str, iter.base()); 10752 assert(ex == "-0e+00*******************"); 10753 assert(ios.width() == 0); 10754 } 10755 ios.width(25); 10756 right(ios); 10757 { 10758 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10759 std::string ex(str, iter.base()); 10760 assert(ex == "*******************-0e+00"); 10761 assert(ios.width() == 0); 10762 } 10763 ios.width(25); 10764 internal(ios); 10765 { 10766 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10767 std::string ex(str, iter.base()); 10768 assert(ex == "-*******************0e+00"); 10769 assert(ios.width() == 0); 10770 } 10771 } 10772 ios.imbue(lg); 10773 { 10774 ios.width(0); 10775 { 10776 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10777 std::string ex(str, iter.base()); 10778 assert(ex == "-0e+00"); 10779 assert(ios.width() == 0); 10780 } 10781 ios.width(25); 10782 left(ios); 10783 { 10784 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10785 std::string ex(str, iter.base()); 10786 assert(ex == "-0e+00*******************"); 10787 assert(ios.width() == 0); 10788 } 10789 ios.width(25); 10790 right(ios); 10791 { 10792 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10793 std::string ex(str, iter.base()); 10794 assert(ex == "*******************-0e+00"); 10795 assert(ios.width() == 0); 10796 } 10797 ios.width(25); 10798 internal(ios); 10799 { 10800 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10801 std::string ex(str, iter.base()); 10802 assert(ex == "-*******************0e+00"); 10803 assert(ios.width() == 0); 10804 } 10805 } 10806 } 10807 showpoint(ios); 10808 { 10809 ios.imbue(lc); 10810 { 10811 ios.width(0); 10812 { 10813 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10814 std::string ex(str, iter.base()); 10815 assert(ex == "-0.e+00"); 10816 assert(ios.width() == 0); 10817 } 10818 ios.width(25); 10819 left(ios); 10820 { 10821 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10822 std::string ex(str, iter.base()); 10823 assert(ex == "-0.e+00******************"); 10824 assert(ios.width() == 0); 10825 } 10826 ios.width(25); 10827 right(ios); 10828 { 10829 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10830 std::string ex(str, iter.base()); 10831 assert(ex == "******************-0.e+00"); 10832 assert(ios.width() == 0); 10833 } 10834 ios.width(25); 10835 internal(ios); 10836 { 10837 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10838 std::string ex(str, iter.base()); 10839 assert(ex == "-******************0.e+00"); 10840 assert(ios.width() == 0); 10841 } 10842 } 10843 ios.imbue(lg); 10844 { 10845 ios.width(0); 10846 { 10847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10848 std::string ex(str, iter.base()); 10849 assert(ex == "-0;e+00"); 10850 assert(ios.width() == 0); 10851 } 10852 ios.width(25); 10853 left(ios); 10854 { 10855 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10856 std::string ex(str, iter.base()); 10857 assert(ex == "-0;e+00******************"); 10858 assert(ios.width() == 0); 10859 } 10860 ios.width(25); 10861 right(ios); 10862 { 10863 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10864 std::string ex(str, iter.base()); 10865 assert(ex == "******************-0;e+00"); 10866 assert(ios.width() == 0); 10867 } 10868 ios.width(25); 10869 internal(ios); 10870 { 10871 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10872 std::string ex(str, iter.base()); 10873 assert(ex == "-******************0;e+00"); 10874 assert(ios.width() == 0); 10875 } 10876 } 10877 } 10878 } 10879 showpos(ios); 10880 { 10881 noshowpoint(ios); 10882 { 10883 ios.imbue(lc); 10884 { 10885 ios.width(0); 10886 { 10887 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10888 std::string ex(str, iter.base()); 10889 assert(ex == "-0e+00"); 10890 assert(ios.width() == 0); 10891 } 10892 ios.width(25); 10893 left(ios); 10894 { 10895 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10896 std::string ex(str, iter.base()); 10897 assert(ex == "-0e+00*******************"); 10898 assert(ios.width() == 0); 10899 } 10900 ios.width(25); 10901 right(ios); 10902 { 10903 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10904 std::string ex(str, iter.base()); 10905 assert(ex == "*******************-0e+00"); 10906 assert(ios.width() == 0); 10907 } 10908 ios.width(25); 10909 internal(ios); 10910 { 10911 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10912 std::string ex(str, iter.base()); 10913 assert(ex == "-*******************0e+00"); 10914 assert(ios.width() == 0); 10915 } 10916 } 10917 ios.imbue(lg); 10918 { 10919 ios.width(0); 10920 { 10921 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10922 std::string ex(str, iter.base()); 10923 assert(ex == "-0e+00"); 10924 assert(ios.width() == 0); 10925 } 10926 ios.width(25); 10927 left(ios); 10928 { 10929 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10930 std::string ex(str, iter.base()); 10931 assert(ex == "-0e+00*******************"); 10932 assert(ios.width() == 0); 10933 } 10934 ios.width(25); 10935 right(ios); 10936 { 10937 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10938 std::string ex(str, iter.base()); 10939 assert(ex == "*******************-0e+00"); 10940 assert(ios.width() == 0); 10941 } 10942 ios.width(25); 10943 internal(ios); 10944 { 10945 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10946 std::string ex(str, iter.base()); 10947 assert(ex == "-*******************0e+00"); 10948 assert(ios.width() == 0); 10949 } 10950 } 10951 } 10952 showpoint(ios); 10953 { 10954 ios.imbue(lc); 10955 { 10956 ios.width(0); 10957 { 10958 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10959 std::string ex(str, iter.base()); 10960 assert(ex == "-0.e+00"); 10961 assert(ios.width() == 0); 10962 } 10963 ios.width(25); 10964 left(ios); 10965 { 10966 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10967 std::string ex(str, iter.base()); 10968 assert(ex == "-0.e+00******************"); 10969 assert(ios.width() == 0); 10970 } 10971 ios.width(25); 10972 right(ios); 10973 { 10974 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10975 std::string ex(str, iter.base()); 10976 assert(ex == "******************-0.e+00"); 10977 assert(ios.width() == 0); 10978 } 10979 ios.width(25); 10980 internal(ios); 10981 { 10982 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10983 std::string ex(str, iter.base()); 10984 assert(ex == "-******************0.e+00"); 10985 assert(ios.width() == 0); 10986 } 10987 } 10988 ios.imbue(lg); 10989 { 10990 ios.width(0); 10991 { 10992 iter = f.put(output_iterator<char*>(str), ios, '*', v); 10993 std::string ex(str, iter.base()); 10994 assert(ex == "-0;e+00"); 10995 assert(ios.width() == 0); 10996 } 10997 ios.width(25); 10998 left(ios); 10999 { 11000 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11001 std::string ex(str, iter.base()); 11002 assert(ex == "-0;e+00******************"); 11003 assert(ios.width() == 0); 11004 } 11005 ios.width(25); 11006 right(ios); 11007 { 11008 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11009 std::string ex(str, iter.base()); 11010 assert(ex == "******************-0;e+00"); 11011 assert(ios.width() == 0); 11012 } 11013 ios.width(25); 11014 internal(ios); 11015 { 11016 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11017 std::string ex(str, iter.base()); 11018 assert(ex == "-******************0;e+00"); 11019 assert(ios.width() == 0); 11020 } 11021 } 11022 } 11023 } 11024 } 11025 uppercase(ios); 11026 { 11027 noshowpos(ios); 11028 { 11029 noshowpoint(ios); 11030 { 11031 ios.imbue(lc); 11032 { 11033 ios.width(0); 11034 { 11035 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11036 std::string ex(str, iter.base()); 11037 assert(ex == "-0E+00"); 11038 assert(ios.width() == 0); 11039 } 11040 ios.width(25); 11041 left(ios); 11042 { 11043 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11044 std::string ex(str, iter.base()); 11045 assert(ex == "-0E+00*******************"); 11046 assert(ios.width() == 0); 11047 } 11048 ios.width(25); 11049 right(ios); 11050 { 11051 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11052 std::string ex(str, iter.base()); 11053 assert(ex == "*******************-0E+00"); 11054 assert(ios.width() == 0); 11055 } 11056 ios.width(25); 11057 internal(ios); 11058 { 11059 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11060 std::string ex(str, iter.base()); 11061 assert(ex == "-*******************0E+00"); 11062 assert(ios.width() == 0); 11063 } 11064 } 11065 ios.imbue(lg); 11066 { 11067 ios.width(0); 11068 { 11069 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11070 std::string ex(str, iter.base()); 11071 assert(ex == "-0E+00"); 11072 assert(ios.width() == 0); 11073 } 11074 ios.width(25); 11075 left(ios); 11076 { 11077 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11078 std::string ex(str, iter.base()); 11079 assert(ex == "-0E+00*******************"); 11080 assert(ios.width() == 0); 11081 } 11082 ios.width(25); 11083 right(ios); 11084 { 11085 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11086 std::string ex(str, iter.base()); 11087 assert(ex == "*******************-0E+00"); 11088 assert(ios.width() == 0); 11089 } 11090 ios.width(25); 11091 internal(ios); 11092 { 11093 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11094 std::string ex(str, iter.base()); 11095 assert(ex == "-*******************0E+00"); 11096 assert(ios.width() == 0); 11097 } 11098 } 11099 } 11100 showpoint(ios); 11101 { 11102 ios.imbue(lc); 11103 { 11104 ios.width(0); 11105 { 11106 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11107 std::string ex(str, iter.base()); 11108 assert(ex == "-0.E+00"); 11109 assert(ios.width() == 0); 11110 } 11111 ios.width(25); 11112 left(ios); 11113 { 11114 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11115 std::string ex(str, iter.base()); 11116 assert(ex == "-0.E+00******************"); 11117 assert(ios.width() == 0); 11118 } 11119 ios.width(25); 11120 right(ios); 11121 { 11122 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11123 std::string ex(str, iter.base()); 11124 assert(ex == "******************-0.E+00"); 11125 assert(ios.width() == 0); 11126 } 11127 ios.width(25); 11128 internal(ios); 11129 { 11130 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11131 std::string ex(str, iter.base()); 11132 assert(ex == "-******************0.E+00"); 11133 assert(ios.width() == 0); 11134 } 11135 } 11136 ios.imbue(lg); 11137 { 11138 ios.width(0); 11139 { 11140 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11141 std::string ex(str, iter.base()); 11142 assert(ex == "-0;E+00"); 11143 assert(ios.width() == 0); 11144 } 11145 ios.width(25); 11146 left(ios); 11147 { 11148 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11149 std::string ex(str, iter.base()); 11150 assert(ex == "-0;E+00******************"); 11151 assert(ios.width() == 0); 11152 } 11153 ios.width(25); 11154 right(ios); 11155 { 11156 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11157 std::string ex(str, iter.base()); 11158 assert(ex == "******************-0;E+00"); 11159 assert(ios.width() == 0); 11160 } 11161 ios.width(25); 11162 internal(ios); 11163 { 11164 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11165 std::string ex(str, iter.base()); 11166 assert(ex == "-******************0;E+00"); 11167 assert(ios.width() == 0); 11168 } 11169 } 11170 } 11171 } 11172 showpos(ios); 11173 { 11174 noshowpoint(ios); 11175 { 11176 ios.imbue(lc); 11177 { 11178 ios.width(0); 11179 { 11180 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11181 std::string ex(str, iter.base()); 11182 assert(ex == "-0E+00"); 11183 assert(ios.width() == 0); 11184 } 11185 ios.width(25); 11186 left(ios); 11187 { 11188 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11189 std::string ex(str, iter.base()); 11190 assert(ex == "-0E+00*******************"); 11191 assert(ios.width() == 0); 11192 } 11193 ios.width(25); 11194 right(ios); 11195 { 11196 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11197 std::string ex(str, iter.base()); 11198 assert(ex == "*******************-0E+00"); 11199 assert(ios.width() == 0); 11200 } 11201 ios.width(25); 11202 internal(ios); 11203 { 11204 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11205 std::string ex(str, iter.base()); 11206 assert(ex == "-*******************0E+00"); 11207 assert(ios.width() == 0); 11208 } 11209 } 11210 ios.imbue(lg); 11211 { 11212 ios.width(0); 11213 { 11214 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11215 std::string ex(str, iter.base()); 11216 assert(ex == "-0E+00"); 11217 assert(ios.width() == 0); 11218 } 11219 ios.width(25); 11220 left(ios); 11221 { 11222 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11223 std::string ex(str, iter.base()); 11224 assert(ex == "-0E+00*******************"); 11225 assert(ios.width() == 0); 11226 } 11227 ios.width(25); 11228 right(ios); 11229 { 11230 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11231 std::string ex(str, iter.base()); 11232 assert(ex == "*******************-0E+00"); 11233 assert(ios.width() == 0); 11234 } 11235 ios.width(25); 11236 internal(ios); 11237 { 11238 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11239 std::string ex(str, iter.base()); 11240 assert(ex == "-*******************0E+00"); 11241 assert(ios.width() == 0); 11242 } 11243 } 11244 } 11245 showpoint(ios); 11246 { 11247 ios.imbue(lc); 11248 { 11249 ios.width(0); 11250 { 11251 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11252 std::string ex(str, iter.base()); 11253 assert(ex == "-0.E+00"); 11254 assert(ios.width() == 0); 11255 } 11256 ios.width(25); 11257 left(ios); 11258 { 11259 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11260 std::string ex(str, iter.base()); 11261 assert(ex == "-0.E+00******************"); 11262 assert(ios.width() == 0); 11263 } 11264 ios.width(25); 11265 right(ios); 11266 { 11267 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11268 std::string ex(str, iter.base()); 11269 assert(ex == "******************-0.E+00"); 11270 assert(ios.width() == 0); 11271 } 11272 ios.width(25); 11273 internal(ios); 11274 { 11275 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11276 std::string ex(str, iter.base()); 11277 assert(ex == "-******************0.E+00"); 11278 assert(ios.width() == 0); 11279 } 11280 } 11281 ios.imbue(lg); 11282 { 11283 ios.width(0); 11284 { 11285 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11286 std::string ex(str, iter.base()); 11287 assert(ex == "-0;E+00"); 11288 assert(ios.width() == 0); 11289 } 11290 ios.width(25); 11291 left(ios); 11292 { 11293 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11294 std::string ex(str, iter.base()); 11295 assert(ex == "-0;E+00******************"); 11296 assert(ios.width() == 0); 11297 } 11298 ios.width(25); 11299 right(ios); 11300 { 11301 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11302 std::string ex(str, iter.base()); 11303 assert(ex == "******************-0;E+00"); 11304 assert(ios.width() == 0); 11305 } 11306 ios.width(25); 11307 internal(ios); 11308 { 11309 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11310 std::string ex(str, iter.base()); 11311 assert(ex == "-******************0;E+00"); 11312 assert(ios.width() == 0); 11313 } 11314 } 11315 } 11316 } 11317 } 11318 } 11319 ios.precision(1); 11320 { 11321 nouppercase(ios); 11322 { 11323 noshowpos(ios); 11324 { 11325 noshowpoint(ios); 11326 { 11327 ios.imbue(lc); 11328 { 11329 ios.width(0); 11330 { 11331 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11332 std::string ex(str, iter.base()); 11333 assert(ex == "-0.0e+00"); 11334 assert(ios.width() == 0); 11335 } 11336 ios.width(25); 11337 left(ios); 11338 { 11339 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11340 std::string ex(str, iter.base()); 11341 assert(ex == "-0.0e+00*****************"); 11342 assert(ios.width() == 0); 11343 } 11344 ios.width(25); 11345 right(ios); 11346 { 11347 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11348 std::string ex(str, iter.base()); 11349 assert(ex == "*****************-0.0e+00"); 11350 assert(ios.width() == 0); 11351 } 11352 ios.width(25); 11353 internal(ios); 11354 { 11355 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11356 std::string ex(str, iter.base()); 11357 assert(ex == "-*****************0.0e+00"); 11358 assert(ios.width() == 0); 11359 } 11360 } 11361 ios.imbue(lg); 11362 { 11363 ios.width(0); 11364 { 11365 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11366 std::string ex(str, iter.base()); 11367 assert(ex == "-0;0e+00"); 11368 assert(ios.width() == 0); 11369 } 11370 ios.width(25); 11371 left(ios); 11372 { 11373 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11374 std::string ex(str, iter.base()); 11375 assert(ex == "-0;0e+00*****************"); 11376 assert(ios.width() == 0); 11377 } 11378 ios.width(25); 11379 right(ios); 11380 { 11381 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11382 std::string ex(str, iter.base()); 11383 assert(ex == "*****************-0;0e+00"); 11384 assert(ios.width() == 0); 11385 } 11386 ios.width(25); 11387 internal(ios); 11388 { 11389 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11390 std::string ex(str, iter.base()); 11391 assert(ex == "-*****************0;0e+00"); 11392 assert(ios.width() == 0); 11393 } 11394 } 11395 } 11396 showpoint(ios); 11397 { 11398 ios.imbue(lc); 11399 { 11400 ios.width(0); 11401 { 11402 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11403 std::string ex(str, iter.base()); 11404 assert(ex == "-0.0e+00"); 11405 assert(ios.width() == 0); 11406 } 11407 ios.width(25); 11408 left(ios); 11409 { 11410 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11411 std::string ex(str, iter.base()); 11412 assert(ex == "-0.0e+00*****************"); 11413 assert(ios.width() == 0); 11414 } 11415 ios.width(25); 11416 right(ios); 11417 { 11418 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11419 std::string ex(str, iter.base()); 11420 assert(ex == "*****************-0.0e+00"); 11421 assert(ios.width() == 0); 11422 } 11423 ios.width(25); 11424 internal(ios); 11425 { 11426 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11427 std::string ex(str, iter.base()); 11428 assert(ex == "-*****************0.0e+00"); 11429 assert(ios.width() == 0); 11430 } 11431 } 11432 ios.imbue(lg); 11433 { 11434 ios.width(0); 11435 { 11436 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11437 std::string ex(str, iter.base()); 11438 assert(ex == "-0;0e+00"); 11439 assert(ios.width() == 0); 11440 } 11441 ios.width(25); 11442 left(ios); 11443 { 11444 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11445 std::string ex(str, iter.base()); 11446 assert(ex == "-0;0e+00*****************"); 11447 assert(ios.width() == 0); 11448 } 11449 ios.width(25); 11450 right(ios); 11451 { 11452 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11453 std::string ex(str, iter.base()); 11454 assert(ex == "*****************-0;0e+00"); 11455 assert(ios.width() == 0); 11456 } 11457 ios.width(25); 11458 internal(ios); 11459 { 11460 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11461 std::string ex(str, iter.base()); 11462 assert(ex == "-*****************0;0e+00"); 11463 assert(ios.width() == 0); 11464 } 11465 } 11466 } 11467 } 11468 showpos(ios); 11469 { 11470 noshowpoint(ios); 11471 { 11472 ios.imbue(lc); 11473 { 11474 ios.width(0); 11475 { 11476 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11477 std::string ex(str, iter.base()); 11478 assert(ex == "-0.0e+00"); 11479 assert(ios.width() == 0); 11480 } 11481 ios.width(25); 11482 left(ios); 11483 { 11484 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11485 std::string ex(str, iter.base()); 11486 assert(ex == "-0.0e+00*****************"); 11487 assert(ios.width() == 0); 11488 } 11489 ios.width(25); 11490 right(ios); 11491 { 11492 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11493 std::string ex(str, iter.base()); 11494 assert(ex == "*****************-0.0e+00"); 11495 assert(ios.width() == 0); 11496 } 11497 ios.width(25); 11498 internal(ios); 11499 { 11500 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11501 std::string ex(str, iter.base()); 11502 assert(ex == "-*****************0.0e+00"); 11503 assert(ios.width() == 0); 11504 } 11505 } 11506 ios.imbue(lg); 11507 { 11508 ios.width(0); 11509 { 11510 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11511 std::string ex(str, iter.base()); 11512 assert(ex == "-0;0e+00"); 11513 assert(ios.width() == 0); 11514 } 11515 ios.width(25); 11516 left(ios); 11517 { 11518 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11519 std::string ex(str, iter.base()); 11520 assert(ex == "-0;0e+00*****************"); 11521 assert(ios.width() == 0); 11522 } 11523 ios.width(25); 11524 right(ios); 11525 { 11526 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11527 std::string ex(str, iter.base()); 11528 assert(ex == "*****************-0;0e+00"); 11529 assert(ios.width() == 0); 11530 } 11531 ios.width(25); 11532 internal(ios); 11533 { 11534 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11535 std::string ex(str, iter.base()); 11536 assert(ex == "-*****************0;0e+00"); 11537 assert(ios.width() == 0); 11538 } 11539 } 11540 } 11541 showpoint(ios); 11542 { 11543 ios.imbue(lc); 11544 { 11545 ios.width(0); 11546 { 11547 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11548 std::string ex(str, iter.base()); 11549 assert(ex == "-0.0e+00"); 11550 assert(ios.width() == 0); 11551 } 11552 ios.width(25); 11553 left(ios); 11554 { 11555 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11556 std::string ex(str, iter.base()); 11557 assert(ex == "-0.0e+00*****************"); 11558 assert(ios.width() == 0); 11559 } 11560 ios.width(25); 11561 right(ios); 11562 { 11563 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11564 std::string ex(str, iter.base()); 11565 assert(ex == "*****************-0.0e+00"); 11566 assert(ios.width() == 0); 11567 } 11568 ios.width(25); 11569 internal(ios); 11570 { 11571 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11572 std::string ex(str, iter.base()); 11573 assert(ex == "-*****************0.0e+00"); 11574 assert(ios.width() == 0); 11575 } 11576 } 11577 ios.imbue(lg); 11578 { 11579 ios.width(0); 11580 { 11581 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11582 std::string ex(str, iter.base()); 11583 assert(ex == "-0;0e+00"); 11584 assert(ios.width() == 0); 11585 } 11586 ios.width(25); 11587 left(ios); 11588 { 11589 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11590 std::string ex(str, iter.base()); 11591 assert(ex == "-0;0e+00*****************"); 11592 assert(ios.width() == 0); 11593 } 11594 ios.width(25); 11595 right(ios); 11596 { 11597 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11598 std::string ex(str, iter.base()); 11599 assert(ex == "*****************-0;0e+00"); 11600 assert(ios.width() == 0); 11601 } 11602 ios.width(25); 11603 internal(ios); 11604 { 11605 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11606 std::string ex(str, iter.base()); 11607 assert(ex == "-*****************0;0e+00"); 11608 assert(ios.width() == 0); 11609 } 11610 } 11611 } 11612 } 11613 } 11614 uppercase(ios); 11615 { 11616 noshowpos(ios); 11617 { 11618 noshowpoint(ios); 11619 { 11620 ios.imbue(lc); 11621 { 11622 ios.width(0); 11623 { 11624 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11625 std::string ex(str, iter.base()); 11626 assert(ex == "-0.0E+00"); 11627 assert(ios.width() == 0); 11628 } 11629 ios.width(25); 11630 left(ios); 11631 { 11632 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11633 std::string ex(str, iter.base()); 11634 assert(ex == "-0.0E+00*****************"); 11635 assert(ios.width() == 0); 11636 } 11637 ios.width(25); 11638 right(ios); 11639 { 11640 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11641 std::string ex(str, iter.base()); 11642 assert(ex == "*****************-0.0E+00"); 11643 assert(ios.width() == 0); 11644 } 11645 ios.width(25); 11646 internal(ios); 11647 { 11648 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11649 std::string ex(str, iter.base()); 11650 assert(ex == "-*****************0.0E+00"); 11651 assert(ios.width() == 0); 11652 } 11653 } 11654 ios.imbue(lg); 11655 { 11656 ios.width(0); 11657 { 11658 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11659 std::string ex(str, iter.base()); 11660 assert(ex == "-0;0E+00"); 11661 assert(ios.width() == 0); 11662 } 11663 ios.width(25); 11664 left(ios); 11665 { 11666 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11667 std::string ex(str, iter.base()); 11668 assert(ex == "-0;0E+00*****************"); 11669 assert(ios.width() == 0); 11670 } 11671 ios.width(25); 11672 right(ios); 11673 { 11674 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11675 std::string ex(str, iter.base()); 11676 assert(ex == "*****************-0;0E+00"); 11677 assert(ios.width() == 0); 11678 } 11679 ios.width(25); 11680 internal(ios); 11681 { 11682 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11683 std::string ex(str, iter.base()); 11684 assert(ex == "-*****************0;0E+00"); 11685 assert(ios.width() == 0); 11686 } 11687 } 11688 } 11689 showpoint(ios); 11690 { 11691 ios.imbue(lc); 11692 { 11693 ios.width(0); 11694 { 11695 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11696 std::string ex(str, iter.base()); 11697 assert(ex == "-0.0E+00"); 11698 assert(ios.width() == 0); 11699 } 11700 ios.width(25); 11701 left(ios); 11702 { 11703 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11704 std::string ex(str, iter.base()); 11705 assert(ex == "-0.0E+00*****************"); 11706 assert(ios.width() == 0); 11707 } 11708 ios.width(25); 11709 right(ios); 11710 { 11711 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11712 std::string ex(str, iter.base()); 11713 assert(ex == "*****************-0.0E+00"); 11714 assert(ios.width() == 0); 11715 } 11716 ios.width(25); 11717 internal(ios); 11718 { 11719 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11720 std::string ex(str, iter.base()); 11721 assert(ex == "-*****************0.0E+00"); 11722 assert(ios.width() == 0); 11723 } 11724 } 11725 ios.imbue(lg); 11726 { 11727 ios.width(0); 11728 { 11729 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11730 std::string ex(str, iter.base()); 11731 assert(ex == "-0;0E+00"); 11732 assert(ios.width() == 0); 11733 } 11734 ios.width(25); 11735 left(ios); 11736 { 11737 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11738 std::string ex(str, iter.base()); 11739 assert(ex == "-0;0E+00*****************"); 11740 assert(ios.width() == 0); 11741 } 11742 ios.width(25); 11743 right(ios); 11744 { 11745 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11746 std::string ex(str, iter.base()); 11747 assert(ex == "*****************-0;0E+00"); 11748 assert(ios.width() == 0); 11749 } 11750 ios.width(25); 11751 internal(ios); 11752 { 11753 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11754 std::string ex(str, iter.base()); 11755 assert(ex == "-*****************0;0E+00"); 11756 assert(ios.width() == 0); 11757 } 11758 } 11759 } 11760 } 11761 showpos(ios); 11762 { 11763 noshowpoint(ios); 11764 { 11765 ios.imbue(lc); 11766 { 11767 ios.width(0); 11768 { 11769 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11770 std::string ex(str, iter.base()); 11771 assert(ex == "-0.0E+00"); 11772 assert(ios.width() == 0); 11773 } 11774 ios.width(25); 11775 left(ios); 11776 { 11777 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11778 std::string ex(str, iter.base()); 11779 assert(ex == "-0.0E+00*****************"); 11780 assert(ios.width() == 0); 11781 } 11782 ios.width(25); 11783 right(ios); 11784 { 11785 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11786 std::string ex(str, iter.base()); 11787 assert(ex == "*****************-0.0E+00"); 11788 assert(ios.width() == 0); 11789 } 11790 ios.width(25); 11791 internal(ios); 11792 { 11793 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11794 std::string ex(str, iter.base()); 11795 assert(ex == "-*****************0.0E+00"); 11796 assert(ios.width() == 0); 11797 } 11798 } 11799 ios.imbue(lg); 11800 { 11801 ios.width(0); 11802 { 11803 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11804 std::string ex(str, iter.base()); 11805 assert(ex == "-0;0E+00"); 11806 assert(ios.width() == 0); 11807 } 11808 ios.width(25); 11809 left(ios); 11810 { 11811 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11812 std::string ex(str, iter.base()); 11813 assert(ex == "-0;0E+00*****************"); 11814 assert(ios.width() == 0); 11815 } 11816 ios.width(25); 11817 right(ios); 11818 { 11819 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11820 std::string ex(str, iter.base()); 11821 assert(ex == "*****************-0;0E+00"); 11822 assert(ios.width() == 0); 11823 } 11824 ios.width(25); 11825 internal(ios); 11826 { 11827 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11828 std::string ex(str, iter.base()); 11829 assert(ex == "-*****************0;0E+00"); 11830 assert(ios.width() == 0); 11831 } 11832 } 11833 } 11834 showpoint(ios); 11835 { 11836 ios.imbue(lc); 11837 { 11838 ios.width(0); 11839 { 11840 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11841 std::string ex(str, iter.base()); 11842 assert(ex == "-0.0E+00"); 11843 assert(ios.width() == 0); 11844 } 11845 ios.width(25); 11846 left(ios); 11847 { 11848 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11849 std::string ex(str, iter.base()); 11850 assert(ex == "-0.0E+00*****************"); 11851 assert(ios.width() == 0); 11852 } 11853 ios.width(25); 11854 right(ios); 11855 { 11856 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11857 std::string ex(str, iter.base()); 11858 assert(ex == "*****************-0.0E+00"); 11859 assert(ios.width() == 0); 11860 } 11861 ios.width(25); 11862 internal(ios); 11863 { 11864 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11865 std::string ex(str, iter.base()); 11866 assert(ex == "-*****************0.0E+00"); 11867 assert(ios.width() == 0); 11868 } 11869 } 11870 ios.imbue(lg); 11871 { 11872 ios.width(0); 11873 { 11874 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11875 std::string ex(str, iter.base()); 11876 assert(ex == "-0;0E+00"); 11877 assert(ios.width() == 0); 11878 } 11879 ios.width(25); 11880 left(ios); 11881 { 11882 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11883 std::string ex(str, iter.base()); 11884 assert(ex == "-0;0E+00*****************"); 11885 assert(ios.width() == 0); 11886 } 11887 ios.width(25); 11888 right(ios); 11889 { 11890 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11891 std::string ex(str, iter.base()); 11892 assert(ex == "*****************-0;0E+00"); 11893 assert(ios.width() == 0); 11894 } 11895 ios.width(25); 11896 internal(ios); 11897 { 11898 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11899 std::string ex(str, iter.base()); 11900 assert(ex == "-*****************0;0E+00"); 11901 assert(ios.width() == 0); 11902 } 11903 } 11904 } 11905 } 11906 } 11907 } 11908 ios.precision(6); 11909 { 11910 nouppercase(ios); 11911 { 11912 noshowpos(ios); 11913 { 11914 noshowpoint(ios); 11915 { 11916 ios.imbue(lc); 11917 { 11918 ios.width(0); 11919 { 11920 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11921 std::string ex(str, iter.base()); 11922 assert(ex == "-0.000000e+00"); 11923 assert(ios.width() == 0); 11924 } 11925 ios.width(25); 11926 left(ios); 11927 { 11928 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11929 std::string ex(str, iter.base()); 11930 assert(ex == "-0.000000e+00************"); 11931 assert(ios.width() == 0); 11932 } 11933 ios.width(25); 11934 right(ios); 11935 { 11936 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11937 std::string ex(str, iter.base()); 11938 assert(ex == "************-0.000000e+00"); 11939 assert(ios.width() == 0); 11940 } 11941 ios.width(25); 11942 internal(ios); 11943 { 11944 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11945 std::string ex(str, iter.base()); 11946 assert(ex == "-************0.000000e+00"); 11947 assert(ios.width() == 0); 11948 } 11949 } 11950 ios.imbue(lg); 11951 { 11952 ios.width(0); 11953 { 11954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11955 std::string ex(str, iter.base()); 11956 assert(ex == "-0;000000e+00"); 11957 assert(ios.width() == 0); 11958 } 11959 ios.width(25); 11960 left(ios); 11961 { 11962 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11963 std::string ex(str, iter.base()); 11964 assert(ex == "-0;000000e+00************"); 11965 assert(ios.width() == 0); 11966 } 11967 ios.width(25); 11968 right(ios); 11969 { 11970 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11971 std::string ex(str, iter.base()); 11972 assert(ex == "************-0;000000e+00"); 11973 assert(ios.width() == 0); 11974 } 11975 ios.width(25); 11976 internal(ios); 11977 { 11978 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11979 std::string ex(str, iter.base()); 11980 assert(ex == "-************0;000000e+00"); 11981 assert(ios.width() == 0); 11982 } 11983 } 11984 } 11985 showpoint(ios); 11986 { 11987 ios.imbue(lc); 11988 { 11989 ios.width(0); 11990 { 11991 iter = f.put(output_iterator<char*>(str), ios, '*', v); 11992 std::string ex(str, iter.base()); 11993 assert(ex == "-0.000000e+00"); 11994 assert(ios.width() == 0); 11995 } 11996 ios.width(25); 11997 left(ios); 11998 { 11999 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12000 std::string ex(str, iter.base()); 12001 assert(ex == "-0.000000e+00************"); 12002 assert(ios.width() == 0); 12003 } 12004 ios.width(25); 12005 right(ios); 12006 { 12007 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12008 std::string ex(str, iter.base()); 12009 assert(ex == "************-0.000000e+00"); 12010 assert(ios.width() == 0); 12011 } 12012 ios.width(25); 12013 internal(ios); 12014 { 12015 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12016 std::string ex(str, iter.base()); 12017 assert(ex == "-************0.000000e+00"); 12018 assert(ios.width() == 0); 12019 } 12020 } 12021 ios.imbue(lg); 12022 { 12023 ios.width(0); 12024 { 12025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12026 std::string ex(str, iter.base()); 12027 assert(ex == "-0;000000e+00"); 12028 assert(ios.width() == 0); 12029 } 12030 ios.width(25); 12031 left(ios); 12032 { 12033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12034 std::string ex(str, iter.base()); 12035 assert(ex == "-0;000000e+00************"); 12036 assert(ios.width() == 0); 12037 } 12038 ios.width(25); 12039 right(ios); 12040 { 12041 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12042 std::string ex(str, iter.base()); 12043 assert(ex == "************-0;000000e+00"); 12044 assert(ios.width() == 0); 12045 } 12046 ios.width(25); 12047 internal(ios); 12048 { 12049 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12050 std::string ex(str, iter.base()); 12051 assert(ex == "-************0;000000e+00"); 12052 assert(ios.width() == 0); 12053 } 12054 } 12055 } 12056 } 12057 showpos(ios); 12058 { 12059 noshowpoint(ios); 12060 { 12061 ios.imbue(lc); 12062 { 12063 ios.width(0); 12064 { 12065 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12066 std::string ex(str, iter.base()); 12067 assert(ex == "-0.000000e+00"); 12068 assert(ios.width() == 0); 12069 } 12070 ios.width(25); 12071 left(ios); 12072 { 12073 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12074 std::string ex(str, iter.base()); 12075 assert(ex == "-0.000000e+00************"); 12076 assert(ios.width() == 0); 12077 } 12078 ios.width(25); 12079 right(ios); 12080 { 12081 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12082 std::string ex(str, iter.base()); 12083 assert(ex == "************-0.000000e+00"); 12084 assert(ios.width() == 0); 12085 } 12086 ios.width(25); 12087 internal(ios); 12088 { 12089 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12090 std::string ex(str, iter.base()); 12091 assert(ex == "-************0.000000e+00"); 12092 assert(ios.width() == 0); 12093 } 12094 } 12095 ios.imbue(lg); 12096 { 12097 ios.width(0); 12098 { 12099 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12100 std::string ex(str, iter.base()); 12101 assert(ex == "-0;000000e+00"); 12102 assert(ios.width() == 0); 12103 } 12104 ios.width(25); 12105 left(ios); 12106 { 12107 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12108 std::string ex(str, iter.base()); 12109 assert(ex == "-0;000000e+00************"); 12110 assert(ios.width() == 0); 12111 } 12112 ios.width(25); 12113 right(ios); 12114 { 12115 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12116 std::string ex(str, iter.base()); 12117 assert(ex == "************-0;000000e+00"); 12118 assert(ios.width() == 0); 12119 } 12120 ios.width(25); 12121 internal(ios); 12122 { 12123 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12124 std::string ex(str, iter.base()); 12125 assert(ex == "-************0;000000e+00"); 12126 assert(ios.width() == 0); 12127 } 12128 } 12129 } 12130 showpoint(ios); 12131 { 12132 ios.imbue(lc); 12133 { 12134 ios.width(0); 12135 { 12136 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12137 std::string ex(str, iter.base()); 12138 assert(ex == "-0.000000e+00"); 12139 assert(ios.width() == 0); 12140 } 12141 ios.width(25); 12142 left(ios); 12143 { 12144 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12145 std::string ex(str, iter.base()); 12146 assert(ex == "-0.000000e+00************"); 12147 assert(ios.width() == 0); 12148 } 12149 ios.width(25); 12150 right(ios); 12151 { 12152 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12153 std::string ex(str, iter.base()); 12154 assert(ex == "************-0.000000e+00"); 12155 assert(ios.width() == 0); 12156 } 12157 ios.width(25); 12158 internal(ios); 12159 { 12160 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12161 std::string ex(str, iter.base()); 12162 assert(ex == "-************0.000000e+00"); 12163 assert(ios.width() == 0); 12164 } 12165 } 12166 ios.imbue(lg); 12167 { 12168 ios.width(0); 12169 { 12170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12171 std::string ex(str, iter.base()); 12172 assert(ex == "-0;000000e+00"); 12173 assert(ios.width() == 0); 12174 } 12175 ios.width(25); 12176 left(ios); 12177 { 12178 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12179 std::string ex(str, iter.base()); 12180 assert(ex == "-0;000000e+00************"); 12181 assert(ios.width() == 0); 12182 } 12183 ios.width(25); 12184 right(ios); 12185 { 12186 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12187 std::string ex(str, iter.base()); 12188 assert(ex == "************-0;000000e+00"); 12189 assert(ios.width() == 0); 12190 } 12191 ios.width(25); 12192 internal(ios); 12193 { 12194 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12195 std::string ex(str, iter.base()); 12196 assert(ex == "-************0;000000e+00"); 12197 assert(ios.width() == 0); 12198 } 12199 } 12200 } 12201 } 12202 } 12203 uppercase(ios); 12204 { 12205 noshowpos(ios); 12206 { 12207 noshowpoint(ios); 12208 { 12209 ios.imbue(lc); 12210 { 12211 ios.width(0); 12212 { 12213 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12214 std::string ex(str, iter.base()); 12215 assert(ex == "-0.000000E+00"); 12216 assert(ios.width() == 0); 12217 } 12218 ios.width(25); 12219 left(ios); 12220 { 12221 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12222 std::string ex(str, iter.base()); 12223 assert(ex == "-0.000000E+00************"); 12224 assert(ios.width() == 0); 12225 } 12226 ios.width(25); 12227 right(ios); 12228 { 12229 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12230 std::string ex(str, iter.base()); 12231 assert(ex == "************-0.000000E+00"); 12232 assert(ios.width() == 0); 12233 } 12234 ios.width(25); 12235 internal(ios); 12236 { 12237 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12238 std::string ex(str, iter.base()); 12239 assert(ex == "-************0.000000E+00"); 12240 assert(ios.width() == 0); 12241 } 12242 } 12243 ios.imbue(lg); 12244 { 12245 ios.width(0); 12246 { 12247 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12248 std::string ex(str, iter.base()); 12249 assert(ex == "-0;000000E+00"); 12250 assert(ios.width() == 0); 12251 } 12252 ios.width(25); 12253 left(ios); 12254 { 12255 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12256 std::string ex(str, iter.base()); 12257 assert(ex == "-0;000000E+00************"); 12258 assert(ios.width() == 0); 12259 } 12260 ios.width(25); 12261 right(ios); 12262 { 12263 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12264 std::string ex(str, iter.base()); 12265 assert(ex == "************-0;000000E+00"); 12266 assert(ios.width() == 0); 12267 } 12268 ios.width(25); 12269 internal(ios); 12270 { 12271 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12272 std::string ex(str, iter.base()); 12273 assert(ex == "-************0;000000E+00"); 12274 assert(ios.width() == 0); 12275 } 12276 } 12277 } 12278 showpoint(ios); 12279 { 12280 ios.imbue(lc); 12281 { 12282 ios.width(0); 12283 { 12284 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12285 std::string ex(str, iter.base()); 12286 assert(ex == "-0.000000E+00"); 12287 assert(ios.width() == 0); 12288 } 12289 ios.width(25); 12290 left(ios); 12291 { 12292 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12293 std::string ex(str, iter.base()); 12294 assert(ex == "-0.000000E+00************"); 12295 assert(ios.width() == 0); 12296 } 12297 ios.width(25); 12298 right(ios); 12299 { 12300 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12301 std::string ex(str, iter.base()); 12302 assert(ex == "************-0.000000E+00"); 12303 assert(ios.width() == 0); 12304 } 12305 ios.width(25); 12306 internal(ios); 12307 { 12308 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12309 std::string ex(str, iter.base()); 12310 assert(ex == "-************0.000000E+00"); 12311 assert(ios.width() == 0); 12312 } 12313 } 12314 ios.imbue(lg); 12315 { 12316 ios.width(0); 12317 { 12318 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12319 std::string ex(str, iter.base()); 12320 assert(ex == "-0;000000E+00"); 12321 assert(ios.width() == 0); 12322 } 12323 ios.width(25); 12324 left(ios); 12325 { 12326 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12327 std::string ex(str, iter.base()); 12328 assert(ex == "-0;000000E+00************"); 12329 assert(ios.width() == 0); 12330 } 12331 ios.width(25); 12332 right(ios); 12333 { 12334 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12335 std::string ex(str, iter.base()); 12336 assert(ex == "************-0;000000E+00"); 12337 assert(ios.width() == 0); 12338 } 12339 ios.width(25); 12340 internal(ios); 12341 { 12342 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12343 std::string ex(str, iter.base()); 12344 assert(ex == "-************0;000000E+00"); 12345 assert(ios.width() == 0); 12346 } 12347 } 12348 } 12349 } 12350 showpos(ios); 12351 { 12352 noshowpoint(ios); 12353 { 12354 ios.imbue(lc); 12355 { 12356 ios.width(0); 12357 { 12358 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12359 std::string ex(str, iter.base()); 12360 assert(ex == "-0.000000E+00"); 12361 assert(ios.width() == 0); 12362 } 12363 ios.width(25); 12364 left(ios); 12365 { 12366 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12367 std::string ex(str, iter.base()); 12368 assert(ex == "-0.000000E+00************"); 12369 assert(ios.width() == 0); 12370 } 12371 ios.width(25); 12372 right(ios); 12373 { 12374 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12375 std::string ex(str, iter.base()); 12376 assert(ex == "************-0.000000E+00"); 12377 assert(ios.width() == 0); 12378 } 12379 ios.width(25); 12380 internal(ios); 12381 { 12382 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12383 std::string ex(str, iter.base()); 12384 assert(ex == "-************0.000000E+00"); 12385 assert(ios.width() == 0); 12386 } 12387 } 12388 ios.imbue(lg); 12389 { 12390 ios.width(0); 12391 { 12392 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12393 std::string ex(str, iter.base()); 12394 assert(ex == "-0;000000E+00"); 12395 assert(ios.width() == 0); 12396 } 12397 ios.width(25); 12398 left(ios); 12399 { 12400 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12401 std::string ex(str, iter.base()); 12402 assert(ex == "-0;000000E+00************"); 12403 assert(ios.width() == 0); 12404 } 12405 ios.width(25); 12406 right(ios); 12407 { 12408 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12409 std::string ex(str, iter.base()); 12410 assert(ex == "************-0;000000E+00"); 12411 assert(ios.width() == 0); 12412 } 12413 ios.width(25); 12414 internal(ios); 12415 { 12416 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12417 std::string ex(str, iter.base()); 12418 assert(ex == "-************0;000000E+00"); 12419 assert(ios.width() == 0); 12420 } 12421 } 12422 } 12423 showpoint(ios); 12424 { 12425 ios.imbue(lc); 12426 { 12427 ios.width(0); 12428 { 12429 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12430 std::string ex(str, iter.base()); 12431 assert(ex == "-0.000000E+00"); 12432 assert(ios.width() == 0); 12433 } 12434 ios.width(25); 12435 left(ios); 12436 { 12437 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12438 std::string ex(str, iter.base()); 12439 assert(ex == "-0.000000E+00************"); 12440 assert(ios.width() == 0); 12441 } 12442 ios.width(25); 12443 right(ios); 12444 { 12445 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12446 std::string ex(str, iter.base()); 12447 assert(ex == "************-0.000000E+00"); 12448 assert(ios.width() == 0); 12449 } 12450 ios.width(25); 12451 internal(ios); 12452 { 12453 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12454 std::string ex(str, iter.base()); 12455 assert(ex == "-************0.000000E+00"); 12456 assert(ios.width() == 0); 12457 } 12458 } 12459 ios.imbue(lg); 12460 { 12461 ios.width(0); 12462 { 12463 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12464 std::string ex(str, iter.base()); 12465 assert(ex == "-0;000000E+00"); 12466 assert(ios.width() == 0); 12467 } 12468 ios.width(25); 12469 left(ios); 12470 { 12471 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12472 std::string ex(str, iter.base()); 12473 assert(ex == "-0;000000E+00************"); 12474 assert(ios.width() == 0); 12475 } 12476 ios.width(25); 12477 right(ios); 12478 { 12479 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12480 std::string ex(str, iter.base()); 12481 assert(ex == "************-0;000000E+00"); 12482 assert(ios.width() == 0); 12483 } 12484 ios.width(25); 12485 internal(ios); 12486 { 12487 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12488 std::string ex(str, iter.base()); 12489 assert(ex == "-************0;000000E+00"); 12490 assert(ios.width() == 0); 12491 } 12492 } 12493 } 12494 } 12495 } 12496 } 12497 ios.precision(16); 12498 { 12499 } 12500 ios.precision(60); 12501 { 12502 } 12503 } 12504 } 12505} 12506 12507void test6() 12508{ 12509 char str[200]; 12510 output_iterator<char*> iter; 12511 std::locale lc = std::locale::classic(); 12512 std::locale lg(lc, new my_numpunct); 12513 const my_facet f(1); 12514 { 12515 double v = 1234567890.125; 12516 std::ios ios(0); 12517 scientific(ios); 12518 // %e 12519 { 12520 ios.precision(0); 12521 { 12522 nouppercase(ios); 12523 { 12524 noshowpos(ios); 12525 { 12526 noshowpoint(ios); 12527 { 12528 ios.imbue(lc); 12529 { 12530 ios.width(0); 12531 { 12532 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12533 std::string ex(str, iter.base()); 12534 assert(ex == "1e+09"); 12535 assert(ios.width() == 0); 12536 } 12537 ios.width(25); 12538 left(ios); 12539 { 12540 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12541 std::string ex(str, iter.base()); 12542 assert(ex == "1e+09********************"); 12543 assert(ios.width() == 0); 12544 } 12545 ios.width(25); 12546 right(ios); 12547 { 12548 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12549 std::string ex(str, iter.base()); 12550 assert(ex == "********************1e+09"); 12551 assert(ios.width() == 0); 12552 } 12553 ios.width(25); 12554 internal(ios); 12555 { 12556 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12557 std::string ex(str, iter.base()); 12558 assert(ex == "********************1e+09"); 12559 assert(ios.width() == 0); 12560 } 12561 } 12562 ios.imbue(lg); 12563 { 12564 ios.width(0); 12565 { 12566 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12567 std::string ex(str, iter.base()); 12568 assert(ex == "1e+09"); 12569 assert(ios.width() == 0); 12570 } 12571 ios.width(25); 12572 left(ios); 12573 { 12574 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12575 std::string ex(str, iter.base()); 12576 assert(ex == "1e+09********************"); 12577 assert(ios.width() == 0); 12578 } 12579 ios.width(25); 12580 right(ios); 12581 { 12582 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12583 std::string ex(str, iter.base()); 12584 assert(ex == "********************1e+09"); 12585 assert(ios.width() == 0); 12586 } 12587 ios.width(25); 12588 internal(ios); 12589 { 12590 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12591 std::string ex(str, iter.base()); 12592 assert(ex == "********************1e+09"); 12593 assert(ios.width() == 0); 12594 } 12595 } 12596 } 12597 showpoint(ios); 12598 { 12599 ios.imbue(lc); 12600 { 12601 ios.width(0); 12602 { 12603 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12604 std::string ex(str, iter.base()); 12605 assert(ex == "1.e+09"); 12606 assert(ios.width() == 0); 12607 } 12608 ios.width(25); 12609 left(ios); 12610 { 12611 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12612 std::string ex(str, iter.base()); 12613 assert(ex == "1.e+09*******************"); 12614 assert(ios.width() == 0); 12615 } 12616 ios.width(25); 12617 right(ios); 12618 { 12619 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12620 std::string ex(str, iter.base()); 12621 assert(ex == "*******************1.e+09"); 12622 assert(ios.width() == 0); 12623 } 12624 ios.width(25); 12625 internal(ios); 12626 { 12627 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12628 std::string ex(str, iter.base()); 12629 assert(ex == "*******************1.e+09"); 12630 assert(ios.width() == 0); 12631 } 12632 } 12633 ios.imbue(lg); 12634 { 12635 ios.width(0); 12636 { 12637 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12638 std::string ex(str, iter.base()); 12639 assert(ex == "1;e+09"); 12640 assert(ios.width() == 0); 12641 } 12642 ios.width(25); 12643 left(ios); 12644 { 12645 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12646 std::string ex(str, iter.base()); 12647 assert(ex == "1;e+09*******************"); 12648 assert(ios.width() == 0); 12649 } 12650 ios.width(25); 12651 right(ios); 12652 { 12653 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12654 std::string ex(str, iter.base()); 12655 assert(ex == "*******************1;e+09"); 12656 assert(ios.width() == 0); 12657 } 12658 ios.width(25); 12659 internal(ios); 12660 { 12661 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12662 std::string ex(str, iter.base()); 12663 assert(ex == "*******************1;e+09"); 12664 assert(ios.width() == 0); 12665 } 12666 } 12667 } 12668 } 12669 showpos(ios); 12670 { 12671 noshowpoint(ios); 12672 { 12673 ios.imbue(lc); 12674 { 12675 ios.width(0); 12676 { 12677 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12678 std::string ex(str, iter.base()); 12679 assert(ex == "+1e+09"); 12680 assert(ios.width() == 0); 12681 } 12682 ios.width(25); 12683 left(ios); 12684 { 12685 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12686 std::string ex(str, iter.base()); 12687 assert(ex == "+1e+09*******************"); 12688 assert(ios.width() == 0); 12689 } 12690 ios.width(25); 12691 right(ios); 12692 { 12693 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12694 std::string ex(str, iter.base()); 12695 assert(ex == "*******************+1e+09"); 12696 assert(ios.width() == 0); 12697 } 12698 ios.width(25); 12699 internal(ios); 12700 { 12701 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12702 std::string ex(str, iter.base()); 12703 assert(ex == "+*******************1e+09"); 12704 assert(ios.width() == 0); 12705 } 12706 } 12707 ios.imbue(lg); 12708 { 12709 ios.width(0); 12710 { 12711 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12712 std::string ex(str, iter.base()); 12713 assert(ex == "+1e+09"); 12714 assert(ios.width() == 0); 12715 } 12716 ios.width(25); 12717 left(ios); 12718 { 12719 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12720 std::string ex(str, iter.base()); 12721 assert(ex == "+1e+09*******************"); 12722 assert(ios.width() == 0); 12723 } 12724 ios.width(25); 12725 right(ios); 12726 { 12727 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12728 std::string ex(str, iter.base()); 12729 assert(ex == "*******************+1e+09"); 12730 assert(ios.width() == 0); 12731 } 12732 ios.width(25); 12733 internal(ios); 12734 { 12735 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12736 std::string ex(str, iter.base()); 12737 assert(ex == "+*******************1e+09"); 12738 assert(ios.width() == 0); 12739 } 12740 } 12741 } 12742 showpoint(ios); 12743 { 12744 ios.imbue(lc); 12745 { 12746 ios.width(0); 12747 { 12748 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12749 std::string ex(str, iter.base()); 12750 assert(ex == "+1.e+09"); 12751 assert(ios.width() == 0); 12752 } 12753 ios.width(25); 12754 left(ios); 12755 { 12756 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12757 std::string ex(str, iter.base()); 12758 assert(ex == "+1.e+09******************"); 12759 assert(ios.width() == 0); 12760 } 12761 ios.width(25); 12762 right(ios); 12763 { 12764 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12765 std::string ex(str, iter.base()); 12766 assert(ex == "******************+1.e+09"); 12767 assert(ios.width() == 0); 12768 } 12769 ios.width(25); 12770 internal(ios); 12771 { 12772 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12773 std::string ex(str, iter.base()); 12774 assert(ex == "+******************1.e+09"); 12775 assert(ios.width() == 0); 12776 } 12777 } 12778 ios.imbue(lg); 12779 { 12780 ios.width(0); 12781 { 12782 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12783 std::string ex(str, iter.base()); 12784 assert(ex == "+1;e+09"); 12785 assert(ios.width() == 0); 12786 } 12787 ios.width(25); 12788 left(ios); 12789 { 12790 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12791 std::string ex(str, iter.base()); 12792 assert(ex == "+1;e+09******************"); 12793 assert(ios.width() == 0); 12794 } 12795 ios.width(25); 12796 right(ios); 12797 { 12798 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12799 std::string ex(str, iter.base()); 12800 assert(ex == "******************+1;e+09"); 12801 assert(ios.width() == 0); 12802 } 12803 ios.width(25); 12804 internal(ios); 12805 { 12806 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12807 std::string ex(str, iter.base()); 12808 assert(ex == "+******************1;e+09"); 12809 assert(ios.width() == 0); 12810 } 12811 } 12812 } 12813 } 12814 } 12815 uppercase(ios); 12816 { 12817 noshowpos(ios); 12818 { 12819 noshowpoint(ios); 12820 { 12821 ios.imbue(lc); 12822 { 12823 ios.width(0); 12824 { 12825 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12826 std::string ex(str, iter.base()); 12827 assert(ex == "1E+09"); 12828 assert(ios.width() == 0); 12829 } 12830 ios.width(25); 12831 left(ios); 12832 { 12833 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12834 std::string ex(str, iter.base()); 12835 assert(ex == "1E+09********************"); 12836 assert(ios.width() == 0); 12837 } 12838 ios.width(25); 12839 right(ios); 12840 { 12841 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12842 std::string ex(str, iter.base()); 12843 assert(ex == "********************1E+09"); 12844 assert(ios.width() == 0); 12845 } 12846 ios.width(25); 12847 internal(ios); 12848 { 12849 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12850 std::string ex(str, iter.base()); 12851 assert(ex == "********************1E+09"); 12852 assert(ios.width() == 0); 12853 } 12854 } 12855 ios.imbue(lg); 12856 { 12857 ios.width(0); 12858 { 12859 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12860 std::string ex(str, iter.base()); 12861 assert(ex == "1E+09"); 12862 assert(ios.width() == 0); 12863 } 12864 ios.width(25); 12865 left(ios); 12866 { 12867 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12868 std::string ex(str, iter.base()); 12869 assert(ex == "1E+09********************"); 12870 assert(ios.width() == 0); 12871 } 12872 ios.width(25); 12873 right(ios); 12874 { 12875 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12876 std::string ex(str, iter.base()); 12877 assert(ex == "********************1E+09"); 12878 assert(ios.width() == 0); 12879 } 12880 ios.width(25); 12881 internal(ios); 12882 { 12883 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12884 std::string ex(str, iter.base()); 12885 assert(ex == "********************1E+09"); 12886 assert(ios.width() == 0); 12887 } 12888 } 12889 } 12890 showpoint(ios); 12891 { 12892 ios.imbue(lc); 12893 { 12894 ios.width(0); 12895 { 12896 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12897 std::string ex(str, iter.base()); 12898 assert(ex == "1.E+09"); 12899 assert(ios.width() == 0); 12900 } 12901 ios.width(25); 12902 left(ios); 12903 { 12904 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12905 std::string ex(str, iter.base()); 12906 assert(ex == "1.E+09*******************"); 12907 assert(ios.width() == 0); 12908 } 12909 ios.width(25); 12910 right(ios); 12911 { 12912 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12913 std::string ex(str, iter.base()); 12914 assert(ex == "*******************1.E+09"); 12915 assert(ios.width() == 0); 12916 } 12917 ios.width(25); 12918 internal(ios); 12919 { 12920 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12921 std::string ex(str, iter.base()); 12922 assert(ex == "*******************1.E+09"); 12923 assert(ios.width() == 0); 12924 } 12925 } 12926 ios.imbue(lg); 12927 { 12928 ios.width(0); 12929 { 12930 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12931 std::string ex(str, iter.base()); 12932 assert(ex == "1;E+09"); 12933 assert(ios.width() == 0); 12934 } 12935 ios.width(25); 12936 left(ios); 12937 { 12938 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12939 std::string ex(str, iter.base()); 12940 assert(ex == "1;E+09*******************"); 12941 assert(ios.width() == 0); 12942 } 12943 ios.width(25); 12944 right(ios); 12945 { 12946 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12947 std::string ex(str, iter.base()); 12948 assert(ex == "*******************1;E+09"); 12949 assert(ios.width() == 0); 12950 } 12951 ios.width(25); 12952 internal(ios); 12953 { 12954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12955 std::string ex(str, iter.base()); 12956 assert(ex == "*******************1;E+09"); 12957 assert(ios.width() == 0); 12958 } 12959 } 12960 } 12961 } 12962 showpos(ios); 12963 { 12964 noshowpoint(ios); 12965 { 12966 ios.imbue(lc); 12967 { 12968 ios.width(0); 12969 { 12970 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12971 std::string ex(str, iter.base()); 12972 assert(ex == "+1E+09"); 12973 assert(ios.width() == 0); 12974 } 12975 ios.width(25); 12976 left(ios); 12977 { 12978 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12979 std::string ex(str, iter.base()); 12980 assert(ex == "+1E+09*******************"); 12981 assert(ios.width() == 0); 12982 } 12983 ios.width(25); 12984 right(ios); 12985 { 12986 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12987 std::string ex(str, iter.base()); 12988 assert(ex == "*******************+1E+09"); 12989 assert(ios.width() == 0); 12990 } 12991 ios.width(25); 12992 internal(ios); 12993 { 12994 iter = f.put(output_iterator<char*>(str), ios, '*', v); 12995 std::string ex(str, iter.base()); 12996 assert(ex == "+*******************1E+09"); 12997 assert(ios.width() == 0); 12998 } 12999 } 13000 ios.imbue(lg); 13001 { 13002 ios.width(0); 13003 { 13004 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13005 std::string ex(str, iter.base()); 13006 assert(ex == "+1E+09"); 13007 assert(ios.width() == 0); 13008 } 13009 ios.width(25); 13010 left(ios); 13011 { 13012 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13013 std::string ex(str, iter.base()); 13014 assert(ex == "+1E+09*******************"); 13015 assert(ios.width() == 0); 13016 } 13017 ios.width(25); 13018 right(ios); 13019 { 13020 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13021 std::string ex(str, iter.base()); 13022 assert(ex == "*******************+1E+09"); 13023 assert(ios.width() == 0); 13024 } 13025 ios.width(25); 13026 internal(ios); 13027 { 13028 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13029 std::string ex(str, iter.base()); 13030 assert(ex == "+*******************1E+09"); 13031 assert(ios.width() == 0); 13032 } 13033 } 13034 } 13035 showpoint(ios); 13036 { 13037 ios.imbue(lc); 13038 { 13039 ios.width(0); 13040 { 13041 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13042 std::string ex(str, iter.base()); 13043 assert(ex == "+1.E+09"); 13044 assert(ios.width() == 0); 13045 } 13046 ios.width(25); 13047 left(ios); 13048 { 13049 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13050 std::string ex(str, iter.base()); 13051 assert(ex == "+1.E+09******************"); 13052 assert(ios.width() == 0); 13053 } 13054 ios.width(25); 13055 right(ios); 13056 { 13057 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13058 std::string ex(str, iter.base()); 13059 assert(ex == "******************+1.E+09"); 13060 assert(ios.width() == 0); 13061 } 13062 ios.width(25); 13063 internal(ios); 13064 { 13065 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13066 std::string ex(str, iter.base()); 13067 assert(ex == "+******************1.E+09"); 13068 assert(ios.width() == 0); 13069 } 13070 } 13071 ios.imbue(lg); 13072 { 13073 ios.width(0); 13074 { 13075 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13076 std::string ex(str, iter.base()); 13077 assert(ex == "+1;E+09"); 13078 assert(ios.width() == 0); 13079 } 13080 ios.width(25); 13081 left(ios); 13082 { 13083 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13084 std::string ex(str, iter.base()); 13085 assert(ex == "+1;E+09******************"); 13086 assert(ios.width() == 0); 13087 } 13088 ios.width(25); 13089 right(ios); 13090 { 13091 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13092 std::string ex(str, iter.base()); 13093 assert(ex == "******************+1;E+09"); 13094 assert(ios.width() == 0); 13095 } 13096 ios.width(25); 13097 internal(ios); 13098 { 13099 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13100 std::string ex(str, iter.base()); 13101 assert(ex == "+******************1;E+09"); 13102 assert(ios.width() == 0); 13103 } 13104 } 13105 } 13106 } 13107 } 13108 } 13109 ios.precision(1); 13110 { 13111 nouppercase(ios); 13112 { 13113 noshowpos(ios); 13114 { 13115 noshowpoint(ios); 13116 { 13117 ios.imbue(lc); 13118 { 13119 ios.width(0); 13120 { 13121 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13122 std::string ex(str, iter.base()); 13123 assert(ex == "1.2e+09"); 13124 assert(ios.width() == 0); 13125 } 13126 ios.width(25); 13127 left(ios); 13128 { 13129 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13130 std::string ex(str, iter.base()); 13131 assert(ex == "1.2e+09******************"); 13132 assert(ios.width() == 0); 13133 } 13134 ios.width(25); 13135 right(ios); 13136 { 13137 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13138 std::string ex(str, iter.base()); 13139 assert(ex == "******************1.2e+09"); 13140 assert(ios.width() == 0); 13141 } 13142 ios.width(25); 13143 internal(ios); 13144 { 13145 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13146 std::string ex(str, iter.base()); 13147 assert(ex == "******************1.2e+09"); 13148 assert(ios.width() == 0); 13149 } 13150 } 13151 ios.imbue(lg); 13152 { 13153 ios.width(0); 13154 { 13155 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13156 std::string ex(str, iter.base()); 13157 assert(ex == "1;2e+09"); 13158 assert(ios.width() == 0); 13159 } 13160 ios.width(25); 13161 left(ios); 13162 { 13163 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13164 std::string ex(str, iter.base()); 13165 assert(ex == "1;2e+09******************"); 13166 assert(ios.width() == 0); 13167 } 13168 ios.width(25); 13169 right(ios); 13170 { 13171 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13172 std::string ex(str, iter.base()); 13173 assert(ex == "******************1;2e+09"); 13174 assert(ios.width() == 0); 13175 } 13176 ios.width(25); 13177 internal(ios); 13178 { 13179 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13180 std::string ex(str, iter.base()); 13181 assert(ex == "******************1;2e+09"); 13182 assert(ios.width() == 0); 13183 } 13184 } 13185 } 13186 showpoint(ios); 13187 { 13188 ios.imbue(lc); 13189 { 13190 ios.width(0); 13191 { 13192 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13193 std::string ex(str, iter.base()); 13194 assert(ex == "1.2e+09"); 13195 assert(ios.width() == 0); 13196 } 13197 ios.width(25); 13198 left(ios); 13199 { 13200 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13201 std::string ex(str, iter.base()); 13202 assert(ex == "1.2e+09******************"); 13203 assert(ios.width() == 0); 13204 } 13205 ios.width(25); 13206 right(ios); 13207 { 13208 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13209 std::string ex(str, iter.base()); 13210 assert(ex == "******************1.2e+09"); 13211 assert(ios.width() == 0); 13212 } 13213 ios.width(25); 13214 internal(ios); 13215 { 13216 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13217 std::string ex(str, iter.base()); 13218 assert(ex == "******************1.2e+09"); 13219 assert(ios.width() == 0); 13220 } 13221 } 13222 ios.imbue(lg); 13223 { 13224 ios.width(0); 13225 { 13226 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13227 std::string ex(str, iter.base()); 13228 assert(ex == "1;2e+09"); 13229 assert(ios.width() == 0); 13230 } 13231 ios.width(25); 13232 left(ios); 13233 { 13234 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13235 std::string ex(str, iter.base()); 13236 assert(ex == "1;2e+09******************"); 13237 assert(ios.width() == 0); 13238 } 13239 ios.width(25); 13240 right(ios); 13241 { 13242 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13243 std::string ex(str, iter.base()); 13244 assert(ex == "******************1;2e+09"); 13245 assert(ios.width() == 0); 13246 } 13247 ios.width(25); 13248 internal(ios); 13249 { 13250 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13251 std::string ex(str, iter.base()); 13252 assert(ex == "******************1;2e+09"); 13253 assert(ios.width() == 0); 13254 } 13255 } 13256 } 13257 } 13258 showpos(ios); 13259 { 13260 noshowpoint(ios); 13261 { 13262 ios.imbue(lc); 13263 { 13264 ios.width(0); 13265 { 13266 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13267 std::string ex(str, iter.base()); 13268 assert(ex == "+1.2e+09"); 13269 assert(ios.width() == 0); 13270 } 13271 ios.width(25); 13272 left(ios); 13273 { 13274 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13275 std::string ex(str, iter.base()); 13276 assert(ex == "+1.2e+09*****************"); 13277 assert(ios.width() == 0); 13278 } 13279 ios.width(25); 13280 right(ios); 13281 { 13282 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13283 std::string ex(str, iter.base()); 13284 assert(ex == "*****************+1.2e+09"); 13285 assert(ios.width() == 0); 13286 } 13287 ios.width(25); 13288 internal(ios); 13289 { 13290 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13291 std::string ex(str, iter.base()); 13292 assert(ex == "+*****************1.2e+09"); 13293 assert(ios.width() == 0); 13294 } 13295 } 13296 ios.imbue(lg); 13297 { 13298 ios.width(0); 13299 { 13300 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13301 std::string ex(str, iter.base()); 13302 assert(ex == "+1;2e+09"); 13303 assert(ios.width() == 0); 13304 } 13305 ios.width(25); 13306 left(ios); 13307 { 13308 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13309 std::string ex(str, iter.base()); 13310 assert(ex == "+1;2e+09*****************"); 13311 assert(ios.width() == 0); 13312 } 13313 ios.width(25); 13314 right(ios); 13315 { 13316 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13317 std::string ex(str, iter.base()); 13318 assert(ex == "*****************+1;2e+09"); 13319 assert(ios.width() == 0); 13320 } 13321 ios.width(25); 13322 internal(ios); 13323 { 13324 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13325 std::string ex(str, iter.base()); 13326 assert(ex == "+*****************1;2e+09"); 13327 assert(ios.width() == 0); 13328 } 13329 } 13330 } 13331 showpoint(ios); 13332 { 13333 ios.imbue(lc); 13334 { 13335 ios.width(0); 13336 { 13337 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13338 std::string ex(str, iter.base()); 13339 assert(ex == "+1.2e+09"); 13340 assert(ios.width() == 0); 13341 } 13342 ios.width(25); 13343 left(ios); 13344 { 13345 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13346 std::string ex(str, iter.base()); 13347 assert(ex == "+1.2e+09*****************"); 13348 assert(ios.width() == 0); 13349 } 13350 ios.width(25); 13351 right(ios); 13352 { 13353 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13354 std::string ex(str, iter.base()); 13355 assert(ex == "*****************+1.2e+09"); 13356 assert(ios.width() == 0); 13357 } 13358 ios.width(25); 13359 internal(ios); 13360 { 13361 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13362 std::string ex(str, iter.base()); 13363 assert(ex == "+*****************1.2e+09"); 13364 assert(ios.width() == 0); 13365 } 13366 } 13367 ios.imbue(lg); 13368 { 13369 ios.width(0); 13370 { 13371 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13372 std::string ex(str, iter.base()); 13373 assert(ex == "+1;2e+09"); 13374 assert(ios.width() == 0); 13375 } 13376 ios.width(25); 13377 left(ios); 13378 { 13379 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13380 std::string ex(str, iter.base()); 13381 assert(ex == "+1;2e+09*****************"); 13382 assert(ios.width() == 0); 13383 } 13384 ios.width(25); 13385 right(ios); 13386 { 13387 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13388 std::string ex(str, iter.base()); 13389 assert(ex == "*****************+1;2e+09"); 13390 assert(ios.width() == 0); 13391 } 13392 ios.width(25); 13393 internal(ios); 13394 { 13395 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13396 std::string ex(str, iter.base()); 13397 assert(ex == "+*****************1;2e+09"); 13398 assert(ios.width() == 0); 13399 } 13400 } 13401 } 13402 } 13403 } 13404 uppercase(ios); 13405 { 13406 noshowpos(ios); 13407 { 13408 noshowpoint(ios); 13409 { 13410 ios.imbue(lc); 13411 { 13412 ios.width(0); 13413 { 13414 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13415 std::string ex(str, iter.base()); 13416 assert(ex == "1.2E+09"); 13417 assert(ios.width() == 0); 13418 } 13419 ios.width(25); 13420 left(ios); 13421 { 13422 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13423 std::string ex(str, iter.base()); 13424 assert(ex == "1.2E+09******************"); 13425 assert(ios.width() == 0); 13426 } 13427 ios.width(25); 13428 right(ios); 13429 { 13430 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13431 std::string ex(str, iter.base()); 13432 assert(ex == "******************1.2E+09"); 13433 assert(ios.width() == 0); 13434 } 13435 ios.width(25); 13436 internal(ios); 13437 { 13438 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13439 std::string ex(str, iter.base()); 13440 assert(ex == "******************1.2E+09"); 13441 assert(ios.width() == 0); 13442 } 13443 } 13444 ios.imbue(lg); 13445 { 13446 ios.width(0); 13447 { 13448 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13449 std::string ex(str, iter.base()); 13450 assert(ex == "1;2E+09"); 13451 assert(ios.width() == 0); 13452 } 13453 ios.width(25); 13454 left(ios); 13455 { 13456 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13457 std::string ex(str, iter.base()); 13458 assert(ex == "1;2E+09******************"); 13459 assert(ios.width() == 0); 13460 } 13461 ios.width(25); 13462 right(ios); 13463 { 13464 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13465 std::string ex(str, iter.base()); 13466 assert(ex == "******************1;2E+09"); 13467 assert(ios.width() == 0); 13468 } 13469 ios.width(25); 13470 internal(ios); 13471 { 13472 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13473 std::string ex(str, iter.base()); 13474 assert(ex == "******************1;2E+09"); 13475 assert(ios.width() == 0); 13476 } 13477 } 13478 } 13479 showpoint(ios); 13480 { 13481 ios.imbue(lc); 13482 { 13483 ios.width(0); 13484 { 13485 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13486 std::string ex(str, iter.base()); 13487 assert(ex == "1.2E+09"); 13488 assert(ios.width() == 0); 13489 } 13490 ios.width(25); 13491 left(ios); 13492 { 13493 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13494 std::string ex(str, iter.base()); 13495 assert(ex == "1.2E+09******************"); 13496 assert(ios.width() == 0); 13497 } 13498 ios.width(25); 13499 right(ios); 13500 { 13501 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13502 std::string ex(str, iter.base()); 13503 assert(ex == "******************1.2E+09"); 13504 assert(ios.width() == 0); 13505 } 13506 ios.width(25); 13507 internal(ios); 13508 { 13509 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13510 std::string ex(str, iter.base()); 13511 assert(ex == "******************1.2E+09"); 13512 assert(ios.width() == 0); 13513 } 13514 } 13515 ios.imbue(lg); 13516 { 13517 ios.width(0); 13518 { 13519 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13520 std::string ex(str, iter.base()); 13521 assert(ex == "1;2E+09"); 13522 assert(ios.width() == 0); 13523 } 13524 ios.width(25); 13525 left(ios); 13526 { 13527 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13528 std::string ex(str, iter.base()); 13529 assert(ex == "1;2E+09******************"); 13530 assert(ios.width() == 0); 13531 } 13532 ios.width(25); 13533 right(ios); 13534 { 13535 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13536 std::string ex(str, iter.base()); 13537 assert(ex == "******************1;2E+09"); 13538 assert(ios.width() == 0); 13539 } 13540 ios.width(25); 13541 internal(ios); 13542 { 13543 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13544 std::string ex(str, iter.base()); 13545 assert(ex == "******************1;2E+09"); 13546 assert(ios.width() == 0); 13547 } 13548 } 13549 } 13550 } 13551 showpos(ios); 13552 { 13553 noshowpoint(ios); 13554 { 13555 ios.imbue(lc); 13556 { 13557 ios.width(0); 13558 { 13559 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13560 std::string ex(str, iter.base()); 13561 assert(ex == "+1.2E+09"); 13562 assert(ios.width() == 0); 13563 } 13564 ios.width(25); 13565 left(ios); 13566 { 13567 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13568 std::string ex(str, iter.base()); 13569 assert(ex == "+1.2E+09*****************"); 13570 assert(ios.width() == 0); 13571 } 13572 ios.width(25); 13573 right(ios); 13574 { 13575 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13576 std::string ex(str, iter.base()); 13577 assert(ex == "*****************+1.2E+09"); 13578 assert(ios.width() == 0); 13579 } 13580 ios.width(25); 13581 internal(ios); 13582 { 13583 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13584 std::string ex(str, iter.base()); 13585 assert(ex == "+*****************1.2E+09"); 13586 assert(ios.width() == 0); 13587 } 13588 } 13589 ios.imbue(lg); 13590 { 13591 ios.width(0); 13592 { 13593 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13594 std::string ex(str, iter.base()); 13595 assert(ex == "+1;2E+09"); 13596 assert(ios.width() == 0); 13597 } 13598 ios.width(25); 13599 left(ios); 13600 { 13601 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13602 std::string ex(str, iter.base()); 13603 assert(ex == "+1;2E+09*****************"); 13604 assert(ios.width() == 0); 13605 } 13606 ios.width(25); 13607 right(ios); 13608 { 13609 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13610 std::string ex(str, iter.base()); 13611 assert(ex == "*****************+1;2E+09"); 13612 assert(ios.width() == 0); 13613 } 13614 ios.width(25); 13615 internal(ios); 13616 { 13617 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13618 std::string ex(str, iter.base()); 13619 assert(ex == "+*****************1;2E+09"); 13620 assert(ios.width() == 0); 13621 } 13622 } 13623 } 13624 showpoint(ios); 13625 { 13626 ios.imbue(lc); 13627 { 13628 ios.width(0); 13629 { 13630 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13631 std::string ex(str, iter.base()); 13632 assert(ex == "+1.2E+09"); 13633 assert(ios.width() == 0); 13634 } 13635 ios.width(25); 13636 left(ios); 13637 { 13638 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13639 std::string ex(str, iter.base()); 13640 assert(ex == "+1.2E+09*****************"); 13641 assert(ios.width() == 0); 13642 } 13643 ios.width(25); 13644 right(ios); 13645 { 13646 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13647 std::string ex(str, iter.base()); 13648 assert(ex == "*****************+1.2E+09"); 13649 assert(ios.width() == 0); 13650 } 13651 ios.width(25); 13652 internal(ios); 13653 { 13654 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13655 std::string ex(str, iter.base()); 13656 assert(ex == "+*****************1.2E+09"); 13657 assert(ios.width() == 0); 13658 } 13659 } 13660 ios.imbue(lg); 13661 { 13662 ios.width(0); 13663 { 13664 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13665 std::string ex(str, iter.base()); 13666 assert(ex == "+1;2E+09"); 13667 assert(ios.width() == 0); 13668 } 13669 ios.width(25); 13670 left(ios); 13671 { 13672 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13673 std::string ex(str, iter.base()); 13674 assert(ex == "+1;2E+09*****************"); 13675 assert(ios.width() == 0); 13676 } 13677 ios.width(25); 13678 right(ios); 13679 { 13680 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13681 std::string ex(str, iter.base()); 13682 assert(ex == "*****************+1;2E+09"); 13683 assert(ios.width() == 0); 13684 } 13685 ios.width(25); 13686 internal(ios); 13687 { 13688 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13689 std::string ex(str, iter.base()); 13690 assert(ex == "+*****************1;2E+09"); 13691 assert(ios.width() == 0); 13692 } 13693 } 13694 } 13695 } 13696 } 13697 } 13698 ios.precision(6); 13699 { 13700 } 13701 ios.precision(16); 13702 { 13703 } 13704 ios.precision(60); 13705 { 13706 nouppercase(ios); 13707 { 13708 noshowpos(ios); 13709 { 13710 noshowpoint(ios); 13711 { 13712 ios.imbue(lc); 13713 { 13714 ios.width(0); 13715 { 13716 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13717 std::string ex(str, iter.base()); 13718 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13719 assert(ios.width() == 0); 13720 } 13721 ios.width(25); 13722 left(ios); 13723 { 13724 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13725 std::string ex(str, iter.base()); 13726 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13727 assert(ios.width() == 0); 13728 } 13729 ios.width(25); 13730 right(ios); 13731 { 13732 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13733 std::string ex(str, iter.base()); 13734 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13735 assert(ios.width() == 0); 13736 } 13737 ios.width(25); 13738 internal(ios); 13739 { 13740 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13741 std::string ex(str, iter.base()); 13742 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13743 assert(ios.width() == 0); 13744 } 13745 } 13746 ios.imbue(lg); 13747 { 13748 ios.width(0); 13749 { 13750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13751 std::string ex(str, iter.base()); 13752 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13753 assert(ios.width() == 0); 13754 } 13755 ios.width(25); 13756 left(ios); 13757 { 13758 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13759 std::string ex(str, iter.base()); 13760 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13761 assert(ios.width() == 0); 13762 } 13763 ios.width(25); 13764 right(ios); 13765 { 13766 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13767 std::string ex(str, iter.base()); 13768 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13769 assert(ios.width() == 0); 13770 } 13771 ios.width(25); 13772 internal(ios); 13773 { 13774 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13775 std::string ex(str, iter.base()); 13776 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13777 assert(ios.width() == 0); 13778 } 13779 } 13780 } 13781 showpoint(ios); 13782 { 13783 ios.imbue(lc); 13784 { 13785 ios.width(0); 13786 { 13787 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13788 std::string ex(str, iter.base()); 13789 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13790 assert(ios.width() == 0); 13791 } 13792 ios.width(25); 13793 left(ios); 13794 { 13795 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13796 std::string ex(str, iter.base()); 13797 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13798 assert(ios.width() == 0); 13799 } 13800 ios.width(25); 13801 right(ios); 13802 { 13803 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13804 std::string ex(str, iter.base()); 13805 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13806 assert(ios.width() == 0); 13807 } 13808 ios.width(25); 13809 internal(ios); 13810 { 13811 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13812 std::string ex(str, iter.base()); 13813 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000e+09"); 13814 assert(ios.width() == 0); 13815 } 13816 } 13817 ios.imbue(lg); 13818 { 13819 ios.width(0); 13820 { 13821 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13822 std::string ex(str, iter.base()); 13823 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13824 assert(ios.width() == 0); 13825 } 13826 ios.width(25); 13827 left(ios); 13828 { 13829 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13830 std::string ex(str, iter.base()); 13831 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13832 assert(ios.width() == 0); 13833 } 13834 ios.width(25); 13835 right(ios); 13836 { 13837 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13838 std::string ex(str, iter.base()); 13839 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13840 assert(ios.width() == 0); 13841 } 13842 ios.width(25); 13843 internal(ios); 13844 { 13845 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13846 std::string ex(str, iter.base()); 13847 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000e+09"); 13848 assert(ios.width() == 0); 13849 } 13850 } 13851 } 13852 } 13853 showpos(ios); 13854 { 13855 noshowpoint(ios); 13856 { 13857 ios.imbue(lc); 13858 { 13859 ios.width(0); 13860 { 13861 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13862 std::string ex(str, iter.base()); 13863 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13864 assert(ios.width() == 0); 13865 } 13866 ios.width(25); 13867 left(ios); 13868 { 13869 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13870 std::string ex(str, iter.base()); 13871 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13872 assert(ios.width() == 0); 13873 } 13874 ios.width(25); 13875 right(ios); 13876 { 13877 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13878 std::string ex(str, iter.base()); 13879 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13880 assert(ios.width() == 0); 13881 } 13882 ios.width(25); 13883 internal(ios); 13884 { 13885 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13886 std::string ex(str, iter.base()); 13887 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13888 assert(ios.width() == 0); 13889 } 13890 } 13891 ios.imbue(lg); 13892 { 13893 ios.width(0); 13894 { 13895 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13896 std::string ex(str, iter.base()); 13897 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13898 assert(ios.width() == 0); 13899 } 13900 ios.width(25); 13901 left(ios); 13902 { 13903 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13904 std::string ex(str, iter.base()); 13905 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13906 assert(ios.width() == 0); 13907 } 13908 ios.width(25); 13909 right(ios); 13910 { 13911 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13912 std::string ex(str, iter.base()); 13913 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13914 assert(ios.width() == 0); 13915 } 13916 ios.width(25); 13917 internal(ios); 13918 { 13919 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13920 std::string ex(str, iter.base()); 13921 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13922 assert(ios.width() == 0); 13923 } 13924 } 13925 } 13926 showpoint(ios); 13927 { 13928 ios.imbue(lc); 13929 { 13930 ios.width(0); 13931 { 13932 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13933 std::string ex(str, iter.base()); 13934 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13935 assert(ios.width() == 0); 13936 } 13937 ios.width(25); 13938 left(ios); 13939 { 13940 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13941 std::string ex(str, iter.base()); 13942 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13943 assert(ios.width() == 0); 13944 } 13945 ios.width(25); 13946 right(ios); 13947 { 13948 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13949 std::string ex(str, iter.base()); 13950 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13951 assert(ios.width() == 0); 13952 } 13953 ios.width(25); 13954 internal(ios); 13955 { 13956 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13957 std::string ex(str, iter.base()); 13958 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000e+09"); 13959 assert(ios.width() == 0); 13960 } 13961 } 13962 ios.imbue(lg); 13963 { 13964 ios.width(0); 13965 { 13966 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13967 std::string ex(str, iter.base()); 13968 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13969 assert(ios.width() == 0); 13970 } 13971 ios.width(25); 13972 left(ios); 13973 { 13974 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13975 std::string ex(str, iter.base()); 13976 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13977 assert(ios.width() == 0); 13978 } 13979 ios.width(25); 13980 right(ios); 13981 { 13982 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13983 std::string ex(str, iter.base()); 13984 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13985 assert(ios.width() == 0); 13986 } 13987 ios.width(25); 13988 internal(ios); 13989 { 13990 iter = f.put(output_iterator<char*>(str), ios, '*', v); 13991 std::string ex(str, iter.base()); 13992 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000e+09"); 13993 assert(ios.width() == 0); 13994 } 13995 } 13996 } 13997 } 13998 } 13999 uppercase(ios); 14000 { 14001 noshowpos(ios); 14002 { 14003 noshowpoint(ios); 14004 { 14005 ios.imbue(lc); 14006 { 14007 ios.width(0); 14008 { 14009 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14010 std::string ex(str, iter.base()); 14011 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14012 assert(ios.width() == 0); 14013 } 14014 ios.width(25); 14015 left(ios); 14016 { 14017 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14018 std::string ex(str, iter.base()); 14019 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14020 assert(ios.width() == 0); 14021 } 14022 ios.width(25); 14023 right(ios); 14024 { 14025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14026 std::string ex(str, iter.base()); 14027 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14028 assert(ios.width() == 0); 14029 } 14030 ios.width(25); 14031 internal(ios); 14032 { 14033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14034 std::string ex(str, iter.base()); 14035 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14036 assert(ios.width() == 0); 14037 } 14038 } 14039 ios.imbue(lg); 14040 { 14041 ios.width(0); 14042 { 14043 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14044 std::string ex(str, iter.base()); 14045 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14046 assert(ios.width() == 0); 14047 } 14048 ios.width(25); 14049 left(ios); 14050 { 14051 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14052 std::string ex(str, iter.base()); 14053 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14054 assert(ios.width() == 0); 14055 } 14056 ios.width(25); 14057 right(ios); 14058 { 14059 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14060 std::string ex(str, iter.base()); 14061 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14062 assert(ios.width() == 0); 14063 } 14064 ios.width(25); 14065 internal(ios); 14066 { 14067 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14068 std::string ex(str, iter.base()); 14069 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14070 assert(ios.width() == 0); 14071 } 14072 } 14073 } 14074 showpoint(ios); 14075 { 14076 ios.imbue(lc); 14077 { 14078 ios.width(0); 14079 { 14080 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14081 std::string ex(str, iter.base()); 14082 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14083 assert(ios.width() == 0); 14084 } 14085 ios.width(25); 14086 left(ios); 14087 { 14088 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14089 std::string ex(str, iter.base()); 14090 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14091 assert(ios.width() == 0); 14092 } 14093 ios.width(25); 14094 right(ios); 14095 { 14096 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14097 std::string ex(str, iter.base()); 14098 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14099 assert(ios.width() == 0); 14100 } 14101 ios.width(25); 14102 internal(ios); 14103 { 14104 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14105 std::string ex(str, iter.base()); 14106 assert(ex == "1.234567890125000000000000000000000000000000000000000000000000E+09"); 14107 assert(ios.width() == 0); 14108 } 14109 } 14110 ios.imbue(lg); 14111 { 14112 ios.width(0); 14113 { 14114 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14115 std::string ex(str, iter.base()); 14116 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14117 assert(ios.width() == 0); 14118 } 14119 ios.width(25); 14120 left(ios); 14121 { 14122 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14123 std::string ex(str, iter.base()); 14124 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14125 assert(ios.width() == 0); 14126 } 14127 ios.width(25); 14128 right(ios); 14129 { 14130 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14131 std::string ex(str, iter.base()); 14132 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14133 assert(ios.width() == 0); 14134 } 14135 ios.width(25); 14136 internal(ios); 14137 { 14138 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14139 std::string ex(str, iter.base()); 14140 assert(ex == "1;234567890125000000000000000000000000000000000000000000000000E+09"); 14141 assert(ios.width() == 0); 14142 } 14143 } 14144 } 14145 } 14146 showpos(ios); 14147 { 14148 noshowpoint(ios); 14149 { 14150 ios.imbue(lc); 14151 { 14152 ios.width(0); 14153 { 14154 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14155 std::string ex(str, iter.base()); 14156 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14157 assert(ios.width() == 0); 14158 } 14159 ios.width(25); 14160 left(ios); 14161 { 14162 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14163 std::string ex(str, iter.base()); 14164 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14165 assert(ios.width() == 0); 14166 } 14167 ios.width(25); 14168 right(ios); 14169 { 14170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14171 std::string ex(str, iter.base()); 14172 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14173 assert(ios.width() == 0); 14174 } 14175 ios.width(25); 14176 internal(ios); 14177 { 14178 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14179 std::string ex(str, iter.base()); 14180 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14181 assert(ios.width() == 0); 14182 } 14183 } 14184 ios.imbue(lg); 14185 { 14186 ios.width(0); 14187 { 14188 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14189 std::string ex(str, iter.base()); 14190 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14191 assert(ios.width() == 0); 14192 } 14193 ios.width(25); 14194 left(ios); 14195 { 14196 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14197 std::string ex(str, iter.base()); 14198 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14199 assert(ios.width() == 0); 14200 } 14201 ios.width(25); 14202 right(ios); 14203 { 14204 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14205 std::string ex(str, iter.base()); 14206 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14207 assert(ios.width() == 0); 14208 } 14209 ios.width(25); 14210 internal(ios); 14211 { 14212 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14213 std::string ex(str, iter.base()); 14214 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14215 assert(ios.width() == 0); 14216 } 14217 } 14218 } 14219 showpoint(ios); 14220 { 14221 ios.imbue(lc); 14222 { 14223 ios.width(0); 14224 { 14225 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14226 std::string ex(str, iter.base()); 14227 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14228 assert(ios.width() == 0); 14229 } 14230 ios.width(25); 14231 left(ios); 14232 { 14233 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14234 std::string ex(str, iter.base()); 14235 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14236 assert(ios.width() == 0); 14237 } 14238 ios.width(25); 14239 right(ios); 14240 { 14241 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14242 std::string ex(str, iter.base()); 14243 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14244 assert(ios.width() == 0); 14245 } 14246 ios.width(25); 14247 internal(ios); 14248 { 14249 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14250 std::string ex(str, iter.base()); 14251 assert(ex == "+1.234567890125000000000000000000000000000000000000000000000000E+09"); 14252 assert(ios.width() == 0); 14253 } 14254 } 14255 ios.imbue(lg); 14256 { 14257 ios.width(0); 14258 { 14259 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14260 std::string ex(str, iter.base()); 14261 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14262 assert(ios.width() == 0); 14263 } 14264 ios.width(25); 14265 left(ios); 14266 { 14267 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14268 std::string ex(str, iter.base()); 14269 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14270 assert(ios.width() == 0); 14271 } 14272 ios.width(25); 14273 right(ios); 14274 { 14275 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14276 std::string ex(str, iter.base()); 14277 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14278 assert(ios.width() == 0); 14279 } 14280 ios.width(25); 14281 internal(ios); 14282 { 14283 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14284 std::string ex(str, iter.base()); 14285 assert(ex == "+1;234567890125000000000000000000000000000000000000000000000000E+09"); 14286 assert(ios.width() == 0); 14287 } 14288 } 14289 } 14290 } 14291 } 14292 } 14293 } 14294 } 14295} 14296 14297void test7() 14298{ 14299 char str[200]; 14300 output_iterator<char*> iter; 14301 std::locale lc = std::locale::classic(); 14302 std::locale lg(lc, new my_numpunct); 14303 const my_facet f(1); 14304 { 14305 double v = -0.; 14306 std::ios ios(0); 14307 hexfloat(ios); 14308 // %a 14309 { 14310 ios.precision(0); 14311 { 14312 nouppercase(ios); 14313 { 14314 noshowpos(ios); 14315 { 14316 noshowpoint(ios); 14317 { 14318 ios.imbue(lc); 14319 { 14320 ios.width(0); 14321 { 14322 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14323 std::string ex(str, iter.base()); 14324 assert(ex == "-0x0p+0"); 14325 assert(ios.width() == 0); 14326 } 14327 ios.width(25); 14328 left(ios); 14329 { 14330 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14331 std::string ex(str, iter.base()); 14332 assert(ex == "-0x0p+0******************"); 14333 assert(ios.width() == 0); 14334 } 14335 ios.width(25); 14336 right(ios); 14337 { 14338 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14339 std::string ex(str, iter.base()); 14340 assert(ex == "******************-0x0p+0"); 14341 assert(ios.width() == 0); 14342 } 14343 ios.width(25); 14344 internal(ios); 14345 { 14346 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14347 std::string ex(str, iter.base()); 14348 assert(ex == "-******************0x0p+0"); 14349 assert(ios.width() == 0); 14350 } 14351 } 14352 ios.imbue(lg); 14353 { 14354 ios.width(0); 14355 { 14356 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14357 std::string ex(str, iter.base()); 14358 assert(ex == "-0x0p+0"); 14359 assert(ios.width() == 0); 14360 } 14361 ios.width(25); 14362 left(ios); 14363 { 14364 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14365 std::string ex(str, iter.base()); 14366 assert(ex == "-0x0p+0******************"); 14367 assert(ios.width() == 0); 14368 } 14369 ios.width(25); 14370 right(ios); 14371 { 14372 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14373 std::string ex(str, iter.base()); 14374 assert(ex == "******************-0x0p+0"); 14375 assert(ios.width() == 0); 14376 } 14377 ios.width(25); 14378 internal(ios); 14379 { 14380 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14381 std::string ex(str, iter.base()); 14382 assert(ex == "-******************0x0p+0"); 14383 assert(ios.width() == 0); 14384 } 14385 } 14386 } 14387 showpoint(ios); 14388 { 14389 ios.imbue(lc); 14390 { 14391 ios.width(0); 14392 { 14393 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14394 std::string ex(str, iter.base()); 14395 assert(ex == "-0x0.p+0"); 14396 assert(ios.width() == 0); 14397 } 14398 ios.width(25); 14399 left(ios); 14400 { 14401 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14402 std::string ex(str, iter.base()); 14403 assert(ex == "-0x0.p+0*****************"); 14404 assert(ios.width() == 0); 14405 } 14406 ios.width(25); 14407 right(ios); 14408 { 14409 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14410 std::string ex(str, iter.base()); 14411 assert(ex == "*****************-0x0.p+0"); 14412 assert(ios.width() == 0); 14413 } 14414 ios.width(25); 14415 internal(ios); 14416 { 14417 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14418 std::string ex(str, iter.base()); 14419 assert(ex == "-*****************0x0.p+0"); 14420 assert(ios.width() == 0); 14421 } 14422 } 14423 ios.imbue(lg); 14424 { 14425 ios.width(0); 14426 { 14427 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14428 std::string ex(str, iter.base()); 14429 assert(ex == "-0x0;p+0"); 14430 assert(ios.width() == 0); 14431 } 14432 ios.width(25); 14433 left(ios); 14434 { 14435 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14436 std::string ex(str, iter.base()); 14437 assert(ex == "-0x0;p+0*****************"); 14438 assert(ios.width() == 0); 14439 } 14440 ios.width(25); 14441 right(ios); 14442 { 14443 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14444 std::string ex(str, iter.base()); 14445 assert(ex == "*****************-0x0;p+0"); 14446 assert(ios.width() == 0); 14447 } 14448 ios.width(25); 14449 internal(ios); 14450 { 14451 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14452 std::string ex(str, iter.base()); 14453 assert(ex == "-*****************0x0;p+0"); 14454 assert(ios.width() == 0); 14455 } 14456 } 14457 } 14458 } 14459 showpos(ios); 14460 { 14461 noshowpoint(ios); 14462 { 14463 ios.imbue(lc); 14464 { 14465 ios.width(0); 14466 { 14467 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14468 std::string ex(str, iter.base()); 14469 assert(ex == "-0x0p+0"); 14470 assert(ios.width() == 0); 14471 } 14472 ios.width(25); 14473 left(ios); 14474 { 14475 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14476 std::string ex(str, iter.base()); 14477 assert(ex == "-0x0p+0******************"); 14478 assert(ios.width() == 0); 14479 } 14480 ios.width(25); 14481 right(ios); 14482 { 14483 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14484 std::string ex(str, iter.base()); 14485 assert(ex == "******************-0x0p+0"); 14486 assert(ios.width() == 0); 14487 } 14488 ios.width(25); 14489 internal(ios); 14490 { 14491 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14492 std::string ex(str, iter.base()); 14493 assert(ex == "-******************0x0p+0"); 14494 assert(ios.width() == 0); 14495 } 14496 } 14497 ios.imbue(lg); 14498 { 14499 ios.width(0); 14500 { 14501 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14502 std::string ex(str, iter.base()); 14503 assert(ex == "-0x0p+0"); 14504 assert(ios.width() == 0); 14505 } 14506 ios.width(25); 14507 left(ios); 14508 { 14509 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14510 std::string ex(str, iter.base()); 14511 assert(ex == "-0x0p+0******************"); 14512 assert(ios.width() == 0); 14513 } 14514 ios.width(25); 14515 right(ios); 14516 { 14517 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14518 std::string ex(str, iter.base()); 14519 assert(ex == "******************-0x0p+0"); 14520 assert(ios.width() == 0); 14521 } 14522 ios.width(25); 14523 internal(ios); 14524 { 14525 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14526 std::string ex(str, iter.base()); 14527 assert(ex == "-******************0x0p+0"); 14528 assert(ios.width() == 0); 14529 } 14530 } 14531 } 14532 showpoint(ios); 14533 { 14534 ios.imbue(lc); 14535 { 14536 ios.width(0); 14537 { 14538 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14539 std::string ex(str, iter.base()); 14540 assert(ex == "-0x0.p+0"); 14541 assert(ios.width() == 0); 14542 } 14543 ios.width(25); 14544 left(ios); 14545 { 14546 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14547 std::string ex(str, iter.base()); 14548 assert(ex == "-0x0.p+0*****************"); 14549 assert(ios.width() == 0); 14550 } 14551 ios.width(25); 14552 right(ios); 14553 { 14554 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14555 std::string ex(str, iter.base()); 14556 assert(ex == "*****************-0x0.p+0"); 14557 assert(ios.width() == 0); 14558 } 14559 ios.width(25); 14560 internal(ios); 14561 { 14562 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14563 std::string ex(str, iter.base()); 14564 assert(ex == "-*****************0x0.p+0"); 14565 assert(ios.width() == 0); 14566 } 14567 } 14568 ios.imbue(lg); 14569 { 14570 ios.width(0); 14571 { 14572 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14573 std::string ex(str, iter.base()); 14574 assert(ex == "-0x0;p+0"); 14575 assert(ios.width() == 0); 14576 } 14577 ios.width(25); 14578 left(ios); 14579 { 14580 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14581 std::string ex(str, iter.base()); 14582 assert(ex == "-0x0;p+0*****************"); 14583 assert(ios.width() == 0); 14584 } 14585 ios.width(25); 14586 right(ios); 14587 { 14588 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14589 std::string ex(str, iter.base()); 14590 assert(ex == "*****************-0x0;p+0"); 14591 assert(ios.width() == 0); 14592 } 14593 ios.width(25); 14594 internal(ios); 14595 { 14596 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14597 std::string ex(str, iter.base()); 14598 assert(ex == "-*****************0x0;p+0"); 14599 assert(ios.width() == 0); 14600 } 14601 } 14602 } 14603 } 14604 } 14605 uppercase(ios); 14606 { 14607 noshowpos(ios); 14608 { 14609 noshowpoint(ios); 14610 { 14611 ios.imbue(lc); 14612 { 14613 ios.width(0); 14614 { 14615 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14616 std::string ex(str, iter.base()); 14617 assert(ex == "-0X0P+0"); 14618 assert(ios.width() == 0); 14619 } 14620 ios.width(25); 14621 left(ios); 14622 { 14623 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14624 std::string ex(str, iter.base()); 14625 assert(ex == "-0X0P+0******************"); 14626 assert(ios.width() == 0); 14627 } 14628 ios.width(25); 14629 right(ios); 14630 { 14631 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14632 std::string ex(str, iter.base()); 14633 assert(ex == "******************-0X0P+0"); 14634 assert(ios.width() == 0); 14635 } 14636 ios.width(25); 14637 internal(ios); 14638 { 14639 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14640 std::string ex(str, iter.base()); 14641 assert(ex == "-******************0X0P+0"); 14642 assert(ios.width() == 0); 14643 } 14644 } 14645 ios.imbue(lg); 14646 { 14647 ios.width(0); 14648 { 14649 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14650 std::string ex(str, iter.base()); 14651 assert(ex == "-0X0P+0"); 14652 assert(ios.width() == 0); 14653 } 14654 ios.width(25); 14655 left(ios); 14656 { 14657 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14658 std::string ex(str, iter.base()); 14659 assert(ex == "-0X0P+0******************"); 14660 assert(ios.width() == 0); 14661 } 14662 ios.width(25); 14663 right(ios); 14664 { 14665 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14666 std::string ex(str, iter.base()); 14667 assert(ex == "******************-0X0P+0"); 14668 assert(ios.width() == 0); 14669 } 14670 ios.width(25); 14671 internal(ios); 14672 { 14673 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14674 std::string ex(str, iter.base()); 14675 assert(ex == "-******************0X0P+0"); 14676 assert(ios.width() == 0); 14677 } 14678 } 14679 } 14680 showpoint(ios); 14681 { 14682 ios.imbue(lc); 14683 { 14684 ios.width(0); 14685 { 14686 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14687 std::string ex(str, iter.base()); 14688 assert(ex == "-0X0.P+0"); 14689 assert(ios.width() == 0); 14690 } 14691 ios.width(25); 14692 left(ios); 14693 { 14694 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14695 std::string ex(str, iter.base()); 14696 assert(ex == "-0X0.P+0*****************"); 14697 assert(ios.width() == 0); 14698 } 14699 ios.width(25); 14700 right(ios); 14701 { 14702 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14703 std::string ex(str, iter.base()); 14704 assert(ex == "*****************-0X0.P+0"); 14705 assert(ios.width() == 0); 14706 } 14707 ios.width(25); 14708 internal(ios); 14709 { 14710 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14711 std::string ex(str, iter.base()); 14712 assert(ex == "-*****************0X0.P+0"); 14713 assert(ios.width() == 0); 14714 } 14715 } 14716 ios.imbue(lg); 14717 { 14718 ios.width(0); 14719 { 14720 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14721 std::string ex(str, iter.base()); 14722 assert(ex == "-0X0;P+0"); 14723 assert(ios.width() == 0); 14724 } 14725 ios.width(25); 14726 left(ios); 14727 { 14728 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14729 std::string ex(str, iter.base()); 14730 assert(ex == "-0X0;P+0*****************"); 14731 assert(ios.width() == 0); 14732 } 14733 ios.width(25); 14734 right(ios); 14735 { 14736 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14737 std::string ex(str, iter.base()); 14738 assert(ex == "*****************-0X0;P+0"); 14739 assert(ios.width() == 0); 14740 } 14741 ios.width(25); 14742 internal(ios); 14743 { 14744 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14745 std::string ex(str, iter.base()); 14746 assert(ex == "-*****************0X0;P+0"); 14747 assert(ios.width() == 0); 14748 } 14749 } 14750 } 14751 } 14752 showpos(ios); 14753 { 14754 noshowpoint(ios); 14755 { 14756 ios.imbue(lc); 14757 { 14758 ios.width(0); 14759 { 14760 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14761 std::string ex(str, iter.base()); 14762 assert(ex == "-0X0P+0"); 14763 assert(ios.width() == 0); 14764 } 14765 ios.width(25); 14766 left(ios); 14767 { 14768 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14769 std::string ex(str, iter.base()); 14770 assert(ex == "-0X0P+0******************"); 14771 assert(ios.width() == 0); 14772 } 14773 ios.width(25); 14774 right(ios); 14775 { 14776 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14777 std::string ex(str, iter.base()); 14778 assert(ex == "******************-0X0P+0"); 14779 assert(ios.width() == 0); 14780 } 14781 ios.width(25); 14782 internal(ios); 14783 { 14784 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14785 std::string ex(str, iter.base()); 14786 assert(ex == "-******************0X0P+0"); 14787 assert(ios.width() == 0); 14788 } 14789 } 14790 ios.imbue(lg); 14791 { 14792 ios.width(0); 14793 { 14794 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14795 std::string ex(str, iter.base()); 14796 assert(ex == "-0X0P+0"); 14797 assert(ios.width() == 0); 14798 } 14799 ios.width(25); 14800 left(ios); 14801 { 14802 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14803 std::string ex(str, iter.base()); 14804 assert(ex == "-0X0P+0******************"); 14805 assert(ios.width() == 0); 14806 } 14807 ios.width(25); 14808 right(ios); 14809 { 14810 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14811 std::string ex(str, iter.base()); 14812 assert(ex == "******************-0X0P+0"); 14813 assert(ios.width() == 0); 14814 } 14815 ios.width(25); 14816 internal(ios); 14817 { 14818 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14819 std::string ex(str, iter.base()); 14820 assert(ex == "-******************0X0P+0"); 14821 assert(ios.width() == 0); 14822 } 14823 } 14824 } 14825 showpoint(ios); 14826 { 14827 ios.imbue(lc); 14828 { 14829 ios.width(0); 14830 { 14831 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14832 std::string ex(str, iter.base()); 14833 assert(ex == "-0X0.P+0"); 14834 assert(ios.width() == 0); 14835 } 14836 ios.width(25); 14837 left(ios); 14838 { 14839 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14840 std::string ex(str, iter.base()); 14841 assert(ex == "-0X0.P+0*****************"); 14842 assert(ios.width() == 0); 14843 } 14844 ios.width(25); 14845 right(ios); 14846 { 14847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14848 std::string ex(str, iter.base()); 14849 assert(ex == "*****************-0X0.P+0"); 14850 assert(ios.width() == 0); 14851 } 14852 ios.width(25); 14853 internal(ios); 14854 { 14855 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14856 std::string ex(str, iter.base()); 14857 assert(ex == "-*****************0X0.P+0"); 14858 assert(ios.width() == 0); 14859 } 14860 } 14861 ios.imbue(lg); 14862 { 14863 ios.width(0); 14864 { 14865 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14866 std::string ex(str, iter.base()); 14867 assert(ex == "-0X0;P+0"); 14868 assert(ios.width() == 0); 14869 } 14870 ios.width(25); 14871 left(ios); 14872 { 14873 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14874 std::string ex(str, iter.base()); 14875 assert(ex == "-0X0;P+0*****************"); 14876 assert(ios.width() == 0); 14877 } 14878 ios.width(25); 14879 right(ios); 14880 { 14881 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14882 std::string ex(str, iter.base()); 14883 assert(ex == "*****************-0X0;P+0"); 14884 assert(ios.width() == 0); 14885 } 14886 ios.width(25); 14887 internal(ios); 14888 { 14889 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14890 std::string ex(str, iter.base()); 14891 assert(ex == "-*****************0X0;P+0"); 14892 assert(ios.width() == 0); 14893 } 14894 } 14895 } 14896 } 14897 } 14898 } 14899 ios.precision(1); 14900 { 14901 nouppercase(ios); 14902 { 14903 noshowpos(ios); 14904 { 14905 noshowpoint(ios); 14906 { 14907 ios.imbue(lc); 14908 { 14909 ios.width(0); 14910 { 14911 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14912 std::string ex(str, iter.base()); 14913 assert(ex == "-0x0p+0"); 14914 assert(ios.width() == 0); 14915 } 14916 ios.width(25); 14917 left(ios); 14918 { 14919 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14920 std::string ex(str, iter.base()); 14921 assert(ex == "-0x0p+0******************"); 14922 assert(ios.width() == 0); 14923 } 14924 ios.width(25); 14925 right(ios); 14926 { 14927 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14928 std::string ex(str, iter.base()); 14929 assert(ex == "******************-0x0p+0"); 14930 assert(ios.width() == 0); 14931 } 14932 ios.width(25); 14933 internal(ios); 14934 { 14935 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14936 std::string ex(str, iter.base()); 14937 assert(ex == "-******************0x0p+0"); 14938 assert(ios.width() == 0); 14939 } 14940 } 14941 ios.imbue(lg); 14942 { 14943 ios.width(0); 14944 { 14945 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14946 std::string ex(str, iter.base()); 14947 assert(ex == "-0x0p+0"); 14948 assert(ios.width() == 0); 14949 } 14950 ios.width(25); 14951 left(ios); 14952 { 14953 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14954 std::string ex(str, iter.base()); 14955 assert(ex == "-0x0p+0******************"); 14956 assert(ios.width() == 0); 14957 } 14958 ios.width(25); 14959 right(ios); 14960 { 14961 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14962 std::string ex(str, iter.base()); 14963 assert(ex == "******************-0x0p+0"); 14964 assert(ios.width() == 0); 14965 } 14966 ios.width(25); 14967 internal(ios); 14968 { 14969 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14970 std::string ex(str, iter.base()); 14971 assert(ex == "-******************0x0p+0"); 14972 assert(ios.width() == 0); 14973 } 14974 } 14975 } 14976 showpoint(ios); 14977 { 14978 ios.imbue(lc); 14979 { 14980 ios.width(0); 14981 { 14982 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14983 std::string ex(str, iter.base()); 14984 assert(ex == "-0x0.p+0"); 14985 assert(ios.width() == 0); 14986 } 14987 ios.width(25); 14988 left(ios); 14989 { 14990 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14991 std::string ex(str, iter.base()); 14992 assert(ex == "-0x0.p+0*****************"); 14993 assert(ios.width() == 0); 14994 } 14995 ios.width(25); 14996 right(ios); 14997 { 14998 iter = f.put(output_iterator<char*>(str), ios, '*', v); 14999 std::string ex(str, iter.base()); 15000 assert(ex == "*****************-0x0.p+0"); 15001 assert(ios.width() == 0); 15002 } 15003 ios.width(25); 15004 internal(ios); 15005 { 15006 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15007 std::string ex(str, iter.base()); 15008 assert(ex == "-*****************0x0.p+0"); 15009 assert(ios.width() == 0); 15010 } 15011 } 15012 ios.imbue(lg); 15013 { 15014 ios.width(0); 15015 { 15016 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15017 std::string ex(str, iter.base()); 15018 assert(ex == "-0x0;p+0"); 15019 assert(ios.width() == 0); 15020 } 15021 ios.width(25); 15022 left(ios); 15023 { 15024 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15025 std::string ex(str, iter.base()); 15026 assert(ex == "-0x0;p+0*****************"); 15027 assert(ios.width() == 0); 15028 } 15029 ios.width(25); 15030 right(ios); 15031 { 15032 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15033 std::string ex(str, iter.base()); 15034 assert(ex == "*****************-0x0;p+0"); 15035 assert(ios.width() == 0); 15036 } 15037 ios.width(25); 15038 internal(ios); 15039 { 15040 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15041 std::string ex(str, iter.base()); 15042 assert(ex == "-*****************0x0;p+0"); 15043 assert(ios.width() == 0); 15044 } 15045 } 15046 } 15047 } 15048 showpos(ios); 15049 { 15050 noshowpoint(ios); 15051 { 15052 ios.imbue(lc); 15053 { 15054 ios.width(0); 15055 { 15056 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15057 std::string ex(str, iter.base()); 15058 assert(ex == "-0x0p+0"); 15059 assert(ios.width() == 0); 15060 } 15061 ios.width(25); 15062 left(ios); 15063 { 15064 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15065 std::string ex(str, iter.base()); 15066 assert(ex == "-0x0p+0******************"); 15067 assert(ios.width() == 0); 15068 } 15069 ios.width(25); 15070 right(ios); 15071 { 15072 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15073 std::string ex(str, iter.base()); 15074 assert(ex == "******************-0x0p+0"); 15075 assert(ios.width() == 0); 15076 } 15077 ios.width(25); 15078 internal(ios); 15079 { 15080 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15081 std::string ex(str, iter.base()); 15082 assert(ex == "-******************0x0p+0"); 15083 assert(ios.width() == 0); 15084 } 15085 } 15086 ios.imbue(lg); 15087 { 15088 ios.width(0); 15089 { 15090 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15091 std::string ex(str, iter.base()); 15092 assert(ex == "-0x0p+0"); 15093 assert(ios.width() == 0); 15094 } 15095 ios.width(25); 15096 left(ios); 15097 { 15098 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15099 std::string ex(str, iter.base()); 15100 assert(ex == "-0x0p+0******************"); 15101 assert(ios.width() == 0); 15102 } 15103 ios.width(25); 15104 right(ios); 15105 { 15106 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15107 std::string ex(str, iter.base()); 15108 assert(ex == "******************-0x0p+0"); 15109 assert(ios.width() == 0); 15110 } 15111 ios.width(25); 15112 internal(ios); 15113 { 15114 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15115 std::string ex(str, iter.base()); 15116 assert(ex == "-******************0x0p+0"); 15117 assert(ios.width() == 0); 15118 } 15119 } 15120 } 15121 showpoint(ios); 15122 { 15123 ios.imbue(lc); 15124 { 15125 ios.width(0); 15126 { 15127 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15128 std::string ex(str, iter.base()); 15129 assert(ex == "-0x0.p+0"); 15130 assert(ios.width() == 0); 15131 } 15132 ios.width(25); 15133 left(ios); 15134 { 15135 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15136 std::string ex(str, iter.base()); 15137 assert(ex == "-0x0.p+0*****************"); 15138 assert(ios.width() == 0); 15139 } 15140 ios.width(25); 15141 right(ios); 15142 { 15143 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15144 std::string ex(str, iter.base()); 15145 assert(ex == "*****************-0x0.p+0"); 15146 assert(ios.width() == 0); 15147 } 15148 ios.width(25); 15149 internal(ios); 15150 { 15151 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15152 std::string ex(str, iter.base()); 15153 assert(ex == "-*****************0x0.p+0"); 15154 assert(ios.width() == 0); 15155 } 15156 } 15157 ios.imbue(lg); 15158 { 15159 ios.width(0); 15160 { 15161 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15162 std::string ex(str, iter.base()); 15163 assert(ex == "-0x0;p+0"); 15164 assert(ios.width() == 0); 15165 } 15166 ios.width(25); 15167 left(ios); 15168 { 15169 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15170 std::string ex(str, iter.base()); 15171 assert(ex == "-0x0;p+0*****************"); 15172 assert(ios.width() == 0); 15173 } 15174 ios.width(25); 15175 right(ios); 15176 { 15177 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15178 std::string ex(str, iter.base()); 15179 assert(ex == "*****************-0x0;p+0"); 15180 assert(ios.width() == 0); 15181 } 15182 ios.width(25); 15183 internal(ios); 15184 { 15185 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15186 std::string ex(str, iter.base()); 15187 assert(ex == "-*****************0x0;p+0"); 15188 assert(ios.width() == 0); 15189 } 15190 } 15191 } 15192 } 15193 } 15194 uppercase(ios); 15195 { 15196 noshowpos(ios); 15197 { 15198 noshowpoint(ios); 15199 { 15200 ios.imbue(lc); 15201 { 15202 ios.width(0); 15203 { 15204 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15205 std::string ex(str, iter.base()); 15206 assert(ex == "-0X0P+0"); 15207 assert(ios.width() == 0); 15208 } 15209 ios.width(25); 15210 left(ios); 15211 { 15212 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15213 std::string ex(str, iter.base()); 15214 assert(ex == "-0X0P+0******************"); 15215 assert(ios.width() == 0); 15216 } 15217 ios.width(25); 15218 right(ios); 15219 { 15220 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15221 std::string ex(str, iter.base()); 15222 assert(ex == "******************-0X0P+0"); 15223 assert(ios.width() == 0); 15224 } 15225 ios.width(25); 15226 internal(ios); 15227 { 15228 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15229 std::string ex(str, iter.base()); 15230 assert(ex == "-******************0X0P+0"); 15231 assert(ios.width() == 0); 15232 } 15233 } 15234 ios.imbue(lg); 15235 { 15236 ios.width(0); 15237 { 15238 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15239 std::string ex(str, iter.base()); 15240 assert(ex == "-0X0P+0"); 15241 assert(ios.width() == 0); 15242 } 15243 ios.width(25); 15244 left(ios); 15245 { 15246 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15247 std::string ex(str, iter.base()); 15248 assert(ex == "-0X0P+0******************"); 15249 assert(ios.width() == 0); 15250 } 15251 ios.width(25); 15252 right(ios); 15253 { 15254 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15255 std::string ex(str, iter.base()); 15256 assert(ex == "******************-0X0P+0"); 15257 assert(ios.width() == 0); 15258 } 15259 ios.width(25); 15260 internal(ios); 15261 { 15262 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15263 std::string ex(str, iter.base()); 15264 assert(ex == "-******************0X0P+0"); 15265 assert(ios.width() == 0); 15266 } 15267 } 15268 } 15269 showpoint(ios); 15270 { 15271 ios.imbue(lc); 15272 { 15273 ios.width(0); 15274 { 15275 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15276 std::string ex(str, iter.base()); 15277 assert(ex == "-0X0.P+0"); 15278 assert(ios.width() == 0); 15279 } 15280 ios.width(25); 15281 left(ios); 15282 { 15283 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15284 std::string ex(str, iter.base()); 15285 assert(ex == "-0X0.P+0*****************"); 15286 assert(ios.width() == 0); 15287 } 15288 ios.width(25); 15289 right(ios); 15290 { 15291 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15292 std::string ex(str, iter.base()); 15293 assert(ex == "*****************-0X0.P+0"); 15294 assert(ios.width() == 0); 15295 } 15296 ios.width(25); 15297 internal(ios); 15298 { 15299 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15300 std::string ex(str, iter.base()); 15301 assert(ex == "-*****************0X0.P+0"); 15302 assert(ios.width() == 0); 15303 } 15304 } 15305 ios.imbue(lg); 15306 { 15307 ios.width(0); 15308 { 15309 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15310 std::string ex(str, iter.base()); 15311 assert(ex == "-0X0;P+0"); 15312 assert(ios.width() == 0); 15313 } 15314 ios.width(25); 15315 left(ios); 15316 { 15317 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15318 std::string ex(str, iter.base()); 15319 assert(ex == "-0X0;P+0*****************"); 15320 assert(ios.width() == 0); 15321 } 15322 ios.width(25); 15323 right(ios); 15324 { 15325 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15326 std::string ex(str, iter.base()); 15327 assert(ex == "*****************-0X0;P+0"); 15328 assert(ios.width() == 0); 15329 } 15330 ios.width(25); 15331 internal(ios); 15332 { 15333 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15334 std::string ex(str, iter.base()); 15335 assert(ex == "-*****************0X0;P+0"); 15336 assert(ios.width() == 0); 15337 } 15338 } 15339 } 15340 } 15341 showpos(ios); 15342 { 15343 noshowpoint(ios); 15344 { 15345 ios.imbue(lc); 15346 { 15347 ios.width(0); 15348 { 15349 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15350 std::string ex(str, iter.base()); 15351 assert(ex == "-0X0P+0"); 15352 assert(ios.width() == 0); 15353 } 15354 ios.width(25); 15355 left(ios); 15356 { 15357 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15358 std::string ex(str, iter.base()); 15359 assert(ex == "-0X0P+0******************"); 15360 assert(ios.width() == 0); 15361 } 15362 ios.width(25); 15363 right(ios); 15364 { 15365 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15366 std::string ex(str, iter.base()); 15367 assert(ex == "******************-0X0P+0"); 15368 assert(ios.width() == 0); 15369 } 15370 ios.width(25); 15371 internal(ios); 15372 { 15373 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15374 std::string ex(str, iter.base()); 15375 assert(ex == "-******************0X0P+0"); 15376 assert(ios.width() == 0); 15377 } 15378 } 15379 ios.imbue(lg); 15380 { 15381 ios.width(0); 15382 { 15383 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15384 std::string ex(str, iter.base()); 15385 assert(ex == "-0X0P+0"); 15386 assert(ios.width() == 0); 15387 } 15388 ios.width(25); 15389 left(ios); 15390 { 15391 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15392 std::string ex(str, iter.base()); 15393 assert(ex == "-0X0P+0******************"); 15394 assert(ios.width() == 0); 15395 } 15396 ios.width(25); 15397 right(ios); 15398 { 15399 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15400 std::string ex(str, iter.base()); 15401 assert(ex == "******************-0X0P+0"); 15402 assert(ios.width() == 0); 15403 } 15404 ios.width(25); 15405 internal(ios); 15406 { 15407 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15408 std::string ex(str, iter.base()); 15409 assert(ex == "-******************0X0P+0"); 15410 assert(ios.width() == 0); 15411 } 15412 } 15413 } 15414 showpoint(ios); 15415 { 15416 ios.imbue(lc); 15417 { 15418 ios.width(0); 15419 { 15420 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15421 std::string ex(str, iter.base()); 15422 assert(ex == "-0X0.P+0"); 15423 assert(ios.width() == 0); 15424 } 15425 ios.width(25); 15426 left(ios); 15427 { 15428 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15429 std::string ex(str, iter.base()); 15430 assert(ex == "-0X0.P+0*****************"); 15431 assert(ios.width() == 0); 15432 } 15433 ios.width(25); 15434 right(ios); 15435 { 15436 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15437 std::string ex(str, iter.base()); 15438 assert(ex == "*****************-0X0.P+0"); 15439 assert(ios.width() == 0); 15440 } 15441 ios.width(25); 15442 internal(ios); 15443 { 15444 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15445 std::string ex(str, iter.base()); 15446 assert(ex == "-*****************0X0.P+0"); 15447 assert(ios.width() == 0); 15448 } 15449 } 15450 ios.imbue(lg); 15451 { 15452 ios.width(0); 15453 { 15454 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15455 std::string ex(str, iter.base()); 15456 assert(ex == "-0X0;P+0"); 15457 assert(ios.width() == 0); 15458 } 15459 ios.width(25); 15460 left(ios); 15461 { 15462 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15463 std::string ex(str, iter.base()); 15464 assert(ex == "-0X0;P+0*****************"); 15465 assert(ios.width() == 0); 15466 } 15467 ios.width(25); 15468 right(ios); 15469 { 15470 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15471 std::string ex(str, iter.base()); 15472 assert(ex == "*****************-0X0;P+0"); 15473 assert(ios.width() == 0); 15474 } 15475 ios.width(25); 15476 internal(ios); 15477 { 15478 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15479 std::string ex(str, iter.base()); 15480 assert(ex == "-*****************0X0;P+0"); 15481 assert(ios.width() == 0); 15482 } 15483 } 15484 } 15485 } 15486 } 15487 } 15488 ios.precision(6); 15489 { 15490 nouppercase(ios); 15491 { 15492 noshowpos(ios); 15493 { 15494 noshowpoint(ios); 15495 { 15496 ios.imbue(lc); 15497 { 15498 ios.width(0); 15499 { 15500 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15501 std::string ex(str, iter.base()); 15502 assert(ex == "-0x0p+0"); 15503 assert(ios.width() == 0); 15504 } 15505 ios.width(25); 15506 left(ios); 15507 { 15508 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15509 std::string ex(str, iter.base()); 15510 assert(ex == "-0x0p+0******************"); 15511 assert(ios.width() == 0); 15512 } 15513 ios.width(25); 15514 right(ios); 15515 { 15516 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15517 std::string ex(str, iter.base()); 15518 assert(ex == "******************-0x0p+0"); 15519 assert(ios.width() == 0); 15520 } 15521 ios.width(25); 15522 internal(ios); 15523 { 15524 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15525 std::string ex(str, iter.base()); 15526 assert(ex == "-******************0x0p+0"); 15527 assert(ios.width() == 0); 15528 } 15529 } 15530 ios.imbue(lg); 15531 { 15532 ios.width(0); 15533 { 15534 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15535 std::string ex(str, iter.base()); 15536 assert(ex == "-0x0p+0"); 15537 assert(ios.width() == 0); 15538 } 15539 ios.width(25); 15540 left(ios); 15541 { 15542 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15543 std::string ex(str, iter.base()); 15544 assert(ex == "-0x0p+0******************"); 15545 assert(ios.width() == 0); 15546 } 15547 ios.width(25); 15548 right(ios); 15549 { 15550 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15551 std::string ex(str, iter.base()); 15552 assert(ex == "******************-0x0p+0"); 15553 assert(ios.width() == 0); 15554 } 15555 ios.width(25); 15556 internal(ios); 15557 { 15558 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15559 std::string ex(str, iter.base()); 15560 assert(ex == "-******************0x0p+0"); 15561 assert(ios.width() == 0); 15562 } 15563 } 15564 } 15565 showpoint(ios); 15566 { 15567 ios.imbue(lc); 15568 { 15569 ios.width(0); 15570 { 15571 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15572 std::string ex(str, iter.base()); 15573 assert(ex == "-0x0.p+0"); 15574 assert(ios.width() == 0); 15575 } 15576 ios.width(25); 15577 left(ios); 15578 { 15579 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15580 std::string ex(str, iter.base()); 15581 assert(ex == "-0x0.p+0*****************"); 15582 assert(ios.width() == 0); 15583 } 15584 ios.width(25); 15585 right(ios); 15586 { 15587 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15588 std::string ex(str, iter.base()); 15589 assert(ex == "*****************-0x0.p+0"); 15590 assert(ios.width() == 0); 15591 } 15592 ios.width(25); 15593 internal(ios); 15594 { 15595 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15596 std::string ex(str, iter.base()); 15597 assert(ex == "-*****************0x0.p+0"); 15598 assert(ios.width() == 0); 15599 } 15600 } 15601 ios.imbue(lg); 15602 { 15603 ios.width(0); 15604 { 15605 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15606 std::string ex(str, iter.base()); 15607 assert(ex == "-0x0;p+0"); 15608 assert(ios.width() == 0); 15609 } 15610 ios.width(25); 15611 left(ios); 15612 { 15613 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15614 std::string ex(str, iter.base()); 15615 assert(ex == "-0x0;p+0*****************"); 15616 assert(ios.width() == 0); 15617 } 15618 ios.width(25); 15619 right(ios); 15620 { 15621 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15622 std::string ex(str, iter.base()); 15623 assert(ex == "*****************-0x0;p+0"); 15624 assert(ios.width() == 0); 15625 } 15626 ios.width(25); 15627 internal(ios); 15628 { 15629 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15630 std::string ex(str, iter.base()); 15631 assert(ex == "-*****************0x0;p+0"); 15632 assert(ios.width() == 0); 15633 } 15634 } 15635 } 15636 } 15637 showpos(ios); 15638 { 15639 noshowpoint(ios); 15640 { 15641 ios.imbue(lc); 15642 { 15643 ios.width(0); 15644 { 15645 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15646 std::string ex(str, iter.base()); 15647 assert(ex == "-0x0p+0"); 15648 assert(ios.width() == 0); 15649 } 15650 ios.width(25); 15651 left(ios); 15652 { 15653 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15654 std::string ex(str, iter.base()); 15655 assert(ex == "-0x0p+0******************"); 15656 assert(ios.width() == 0); 15657 } 15658 ios.width(25); 15659 right(ios); 15660 { 15661 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15662 std::string ex(str, iter.base()); 15663 assert(ex == "******************-0x0p+0"); 15664 assert(ios.width() == 0); 15665 } 15666 ios.width(25); 15667 internal(ios); 15668 { 15669 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15670 std::string ex(str, iter.base()); 15671 assert(ex == "-******************0x0p+0"); 15672 assert(ios.width() == 0); 15673 } 15674 } 15675 ios.imbue(lg); 15676 { 15677 ios.width(0); 15678 { 15679 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15680 std::string ex(str, iter.base()); 15681 assert(ex == "-0x0p+0"); 15682 assert(ios.width() == 0); 15683 } 15684 ios.width(25); 15685 left(ios); 15686 { 15687 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15688 std::string ex(str, iter.base()); 15689 assert(ex == "-0x0p+0******************"); 15690 assert(ios.width() == 0); 15691 } 15692 ios.width(25); 15693 right(ios); 15694 { 15695 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15696 std::string ex(str, iter.base()); 15697 assert(ex == "******************-0x0p+0"); 15698 assert(ios.width() == 0); 15699 } 15700 ios.width(25); 15701 internal(ios); 15702 { 15703 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15704 std::string ex(str, iter.base()); 15705 assert(ex == "-******************0x0p+0"); 15706 assert(ios.width() == 0); 15707 } 15708 } 15709 } 15710 showpoint(ios); 15711 { 15712 ios.imbue(lc); 15713 { 15714 ios.width(0); 15715 { 15716 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15717 std::string ex(str, iter.base()); 15718 assert(ex == "-0x0.p+0"); 15719 assert(ios.width() == 0); 15720 } 15721 ios.width(25); 15722 left(ios); 15723 { 15724 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15725 std::string ex(str, iter.base()); 15726 assert(ex == "-0x0.p+0*****************"); 15727 assert(ios.width() == 0); 15728 } 15729 ios.width(25); 15730 right(ios); 15731 { 15732 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15733 std::string ex(str, iter.base()); 15734 assert(ex == "*****************-0x0.p+0"); 15735 assert(ios.width() == 0); 15736 } 15737 ios.width(25); 15738 internal(ios); 15739 { 15740 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15741 std::string ex(str, iter.base()); 15742 assert(ex == "-*****************0x0.p+0"); 15743 assert(ios.width() == 0); 15744 } 15745 } 15746 ios.imbue(lg); 15747 { 15748 ios.width(0); 15749 { 15750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15751 std::string ex(str, iter.base()); 15752 assert(ex == "-0x0;p+0"); 15753 assert(ios.width() == 0); 15754 } 15755 ios.width(25); 15756 left(ios); 15757 { 15758 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15759 std::string ex(str, iter.base()); 15760 assert(ex == "-0x0;p+0*****************"); 15761 assert(ios.width() == 0); 15762 } 15763 ios.width(25); 15764 right(ios); 15765 { 15766 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15767 std::string ex(str, iter.base()); 15768 assert(ex == "*****************-0x0;p+0"); 15769 assert(ios.width() == 0); 15770 } 15771 ios.width(25); 15772 internal(ios); 15773 { 15774 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15775 std::string ex(str, iter.base()); 15776 assert(ex == "-*****************0x0;p+0"); 15777 assert(ios.width() == 0); 15778 } 15779 } 15780 } 15781 } 15782 } 15783 uppercase(ios); 15784 { 15785 noshowpos(ios); 15786 { 15787 noshowpoint(ios); 15788 { 15789 ios.imbue(lc); 15790 { 15791 ios.width(0); 15792 { 15793 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15794 std::string ex(str, iter.base()); 15795 assert(ex == "-0X0P+0"); 15796 assert(ios.width() == 0); 15797 } 15798 ios.width(25); 15799 left(ios); 15800 { 15801 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15802 std::string ex(str, iter.base()); 15803 assert(ex == "-0X0P+0******************"); 15804 assert(ios.width() == 0); 15805 } 15806 ios.width(25); 15807 right(ios); 15808 { 15809 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15810 std::string ex(str, iter.base()); 15811 assert(ex == "******************-0X0P+0"); 15812 assert(ios.width() == 0); 15813 } 15814 ios.width(25); 15815 internal(ios); 15816 { 15817 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15818 std::string ex(str, iter.base()); 15819 assert(ex == "-******************0X0P+0"); 15820 assert(ios.width() == 0); 15821 } 15822 } 15823 ios.imbue(lg); 15824 { 15825 ios.width(0); 15826 { 15827 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15828 std::string ex(str, iter.base()); 15829 assert(ex == "-0X0P+0"); 15830 assert(ios.width() == 0); 15831 } 15832 ios.width(25); 15833 left(ios); 15834 { 15835 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15836 std::string ex(str, iter.base()); 15837 assert(ex == "-0X0P+0******************"); 15838 assert(ios.width() == 0); 15839 } 15840 ios.width(25); 15841 right(ios); 15842 { 15843 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15844 std::string ex(str, iter.base()); 15845 assert(ex == "******************-0X0P+0"); 15846 assert(ios.width() == 0); 15847 } 15848 ios.width(25); 15849 internal(ios); 15850 { 15851 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15852 std::string ex(str, iter.base()); 15853 assert(ex == "-******************0X0P+0"); 15854 assert(ios.width() == 0); 15855 } 15856 } 15857 } 15858 showpoint(ios); 15859 { 15860 ios.imbue(lc); 15861 { 15862 ios.width(0); 15863 { 15864 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15865 std::string ex(str, iter.base()); 15866 assert(ex == "-0X0.P+0"); 15867 assert(ios.width() == 0); 15868 } 15869 ios.width(25); 15870 left(ios); 15871 { 15872 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15873 std::string ex(str, iter.base()); 15874 assert(ex == "-0X0.P+0*****************"); 15875 assert(ios.width() == 0); 15876 } 15877 ios.width(25); 15878 right(ios); 15879 { 15880 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15881 std::string ex(str, iter.base()); 15882 assert(ex == "*****************-0X0.P+0"); 15883 assert(ios.width() == 0); 15884 } 15885 ios.width(25); 15886 internal(ios); 15887 { 15888 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15889 std::string ex(str, iter.base()); 15890 assert(ex == "-*****************0X0.P+0"); 15891 assert(ios.width() == 0); 15892 } 15893 } 15894 ios.imbue(lg); 15895 { 15896 ios.width(0); 15897 { 15898 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15899 std::string ex(str, iter.base()); 15900 assert(ex == "-0X0;P+0"); 15901 assert(ios.width() == 0); 15902 } 15903 ios.width(25); 15904 left(ios); 15905 { 15906 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15907 std::string ex(str, iter.base()); 15908 assert(ex == "-0X0;P+0*****************"); 15909 assert(ios.width() == 0); 15910 } 15911 ios.width(25); 15912 right(ios); 15913 { 15914 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15915 std::string ex(str, iter.base()); 15916 assert(ex == "*****************-0X0;P+0"); 15917 assert(ios.width() == 0); 15918 } 15919 ios.width(25); 15920 internal(ios); 15921 { 15922 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15923 std::string ex(str, iter.base()); 15924 assert(ex == "-*****************0X0;P+0"); 15925 assert(ios.width() == 0); 15926 } 15927 } 15928 } 15929 } 15930 showpos(ios); 15931 { 15932 noshowpoint(ios); 15933 { 15934 ios.imbue(lc); 15935 { 15936 ios.width(0); 15937 { 15938 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15939 std::string ex(str, iter.base()); 15940 assert(ex == "-0X0P+0"); 15941 assert(ios.width() == 0); 15942 } 15943 ios.width(25); 15944 left(ios); 15945 { 15946 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15947 std::string ex(str, iter.base()); 15948 assert(ex == "-0X0P+0******************"); 15949 assert(ios.width() == 0); 15950 } 15951 ios.width(25); 15952 right(ios); 15953 { 15954 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15955 std::string ex(str, iter.base()); 15956 assert(ex == "******************-0X0P+0"); 15957 assert(ios.width() == 0); 15958 } 15959 ios.width(25); 15960 internal(ios); 15961 { 15962 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15963 std::string ex(str, iter.base()); 15964 assert(ex == "-******************0X0P+0"); 15965 assert(ios.width() == 0); 15966 } 15967 } 15968 ios.imbue(lg); 15969 { 15970 ios.width(0); 15971 { 15972 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15973 std::string ex(str, iter.base()); 15974 assert(ex == "-0X0P+0"); 15975 assert(ios.width() == 0); 15976 } 15977 ios.width(25); 15978 left(ios); 15979 { 15980 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15981 std::string ex(str, iter.base()); 15982 assert(ex == "-0X0P+0******************"); 15983 assert(ios.width() == 0); 15984 } 15985 ios.width(25); 15986 right(ios); 15987 { 15988 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15989 std::string ex(str, iter.base()); 15990 assert(ex == "******************-0X0P+0"); 15991 assert(ios.width() == 0); 15992 } 15993 ios.width(25); 15994 internal(ios); 15995 { 15996 iter = f.put(output_iterator<char*>(str), ios, '*', v); 15997 std::string ex(str, iter.base()); 15998 assert(ex == "-******************0X0P+0"); 15999 assert(ios.width() == 0); 16000 } 16001 } 16002 } 16003 showpoint(ios); 16004 { 16005 ios.imbue(lc); 16006 { 16007 ios.width(0); 16008 { 16009 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16010 std::string ex(str, iter.base()); 16011 assert(ex == "-0X0.P+0"); 16012 assert(ios.width() == 0); 16013 } 16014 ios.width(25); 16015 left(ios); 16016 { 16017 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16018 std::string ex(str, iter.base()); 16019 assert(ex == "-0X0.P+0*****************"); 16020 assert(ios.width() == 0); 16021 } 16022 ios.width(25); 16023 right(ios); 16024 { 16025 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16026 std::string ex(str, iter.base()); 16027 assert(ex == "*****************-0X0.P+0"); 16028 assert(ios.width() == 0); 16029 } 16030 ios.width(25); 16031 internal(ios); 16032 { 16033 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16034 std::string ex(str, iter.base()); 16035 assert(ex == "-*****************0X0.P+0"); 16036 assert(ios.width() == 0); 16037 } 16038 } 16039 ios.imbue(lg); 16040 { 16041 ios.width(0); 16042 { 16043 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16044 std::string ex(str, iter.base()); 16045 assert(ex == "-0X0;P+0"); 16046 assert(ios.width() == 0); 16047 } 16048 ios.width(25); 16049 left(ios); 16050 { 16051 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16052 std::string ex(str, iter.base()); 16053 assert(ex == "-0X0;P+0*****************"); 16054 assert(ios.width() == 0); 16055 } 16056 ios.width(25); 16057 right(ios); 16058 { 16059 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16060 std::string ex(str, iter.base()); 16061 assert(ex == "*****************-0X0;P+0"); 16062 assert(ios.width() == 0); 16063 } 16064 ios.width(25); 16065 internal(ios); 16066 { 16067 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16068 std::string ex(str, iter.base()); 16069 assert(ex == "-*****************0X0;P+0"); 16070 assert(ios.width() == 0); 16071 } 16072 } 16073 } 16074 } 16075 } 16076 } 16077 ios.precision(16); 16078 { 16079 } 16080 ios.precision(60); 16081 { 16082 } 16083 } 16084 } 16085} 16086 16087void test8() 16088{ 16089 char str[200]; 16090 output_iterator<char*> iter; 16091 std::locale lc = std::locale::classic(); 16092 std::locale lg(lc, new my_numpunct); 16093 const my_facet f(1); 16094 { 16095 double v = 1234567890.125; 16096 std::ios ios(0); 16097 hexfloat(ios); 16098 // %a 16099 { 16100 ios.precision(0); 16101 { 16102 nouppercase(ios); 16103 { 16104 noshowpos(ios); 16105 { 16106 noshowpoint(ios); 16107 { 16108 ios.imbue(lc); 16109 { 16110 ios.width(0); 16111 { 16112 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16113 std::string ex(str, iter.base()); 16114 assert(ex == "0x1.26580b488p+30"); 16115 assert(ios.width() == 0); 16116 } 16117 ios.width(25); 16118 left(ios); 16119 { 16120 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16121 std::string ex(str, iter.base()); 16122 assert(ex == "0x1.26580b488p+30********"); 16123 assert(ios.width() == 0); 16124 } 16125 ios.width(25); 16126 right(ios); 16127 { 16128 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16129 std::string ex(str, iter.base()); 16130 assert(ex == "********0x1.26580b488p+30"); 16131 assert(ios.width() == 0); 16132 } 16133 ios.width(25); 16134 internal(ios); 16135 { 16136 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16137 std::string ex(str, iter.base()); 16138 assert(ex == "0x********1.26580b488p+30"); 16139 assert(ios.width() == 0); 16140 } 16141 } 16142 ios.imbue(lg); 16143 { 16144 ios.width(0); 16145 { 16146 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16147 std::string ex(str, iter.base()); 16148 assert(ex == "0x1;26580b488p+30"); 16149 assert(ios.width() == 0); 16150 } 16151 ios.width(25); 16152 left(ios); 16153 { 16154 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16155 std::string ex(str, iter.base()); 16156 assert(ex == "0x1;26580b488p+30********"); 16157 assert(ios.width() == 0); 16158 } 16159 ios.width(25); 16160 right(ios); 16161 { 16162 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16163 std::string ex(str, iter.base()); 16164 assert(ex == "********0x1;26580b488p+30"); 16165 assert(ios.width() == 0); 16166 } 16167 ios.width(25); 16168 internal(ios); 16169 { 16170 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16171 std::string ex(str, iter.base()); 16172 assert(ex == "0x********1;26580b488p+30"); 16173 assert(ios.width() == 0); 16174 } 16175 } 16176 } 16177 showpoint(ios); 16178 { 16179 ios.imbue(lc); 16180 { 16181 ios.width(0); 16182 { 16183 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16184 std::string ex(str, iter.base()); 16185 assert(ex == "0x1.26580b488p+30"); 16186 assert(ios.width() == 0); 16187 } 16188 ios.width(25); 16189 left(ios); 16190 { 16191 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16192 std::string ex(str, iter.base()); 16193 assert(ex == "0x1.26580b488p+30********"); 16194 assert(ios.width() == 0); 16195 } 16196 ios.width(25); 16197 right(ios); 16198 { 16199 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16200 std::string ex(str, iter.base()); 16201 assert(ex == "********0x1.26580b488p+30"); 16202 assert(ios.width() == 0); 16203 } 16204 ios.width(25); 16205 internal(ios); 16206 { 16207 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16208 std::string ex(str, iter.base()); 16209 assert(ex == "0x********1.26580b488p+30"); 16210 assert(ios.width() == 0); 16211 } 16212 } 16213 ios.imbue(lg); 16214 { 16215 ios.width(0); 16216 { 16217 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16218 std::string ex(str, iter.base()); 16219 assert(ex == "0x1;26580b488p+30"); 16220 assert(ios.width() == 0); 16221 } 16222 ios.width(25); 16223 left(ios); 16224 { 16225 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16226 std::string ex(str, iter.base()); 16227 assert(ex == "0x1;26580b488p+30********"); 16228 assert(ios.width() == 0); 16229 } 16230 ios.width(25); 16231 right(ios); 16232 { 16233 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16234 std::string ex(str, iter.base()); 16235 assert(ex == "********0x1;26580b488p+30"); 16236 assert(ios.width() == 0); 16237 } 16238 ios.width(25); 16239 internal(ios); 16240 { 16241 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16242 std::string ex(str, iter.base()); 16243 assert(ex == "0x********1;26580b488p+30"); 16244 assert(ios.width() == 0); 16245 } 16246 } 16247 } 16248 } 16249 showpos(ios); 16250 { 16251 noshowpoint(ios); 16252 { 16253 ios.imbue(lc); 16254 { 16255 ios.width(0); 16256 { 16257 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16258 std::string ex(str, iter.base()); 16259 assert(ex == "+0x1.26580b488p+30"); 16260 assert(ios.width() == 0); 16261 } 16262 ios.width(25); 16263 left(ios); 16264 { 16265 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16266 std::string ex(str, iter.base()); 16267 assert(ex == "+0x1.26580b488p+30*******"); 16268 assert(ios.width() == 0); 16269 } 16270 ios.width(25); 16271 right(ios); 16272 { 16273 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16274 std::string ex(str, iter.base()); 16275 assert(ex == "*******+0x1.26580b488p+30"); 16276 assert(ios.width() == 0); 16277 } 16278 ios.width(25); 16279 internal(ios); 16280 { 16281 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16282 std::string ex(str, iter.base()); 16283 assert(ex == "+*******0x1.26580b488p+30"); 16284 assert(ios.width() == 0); 16285 } 16286 } 16287 ios.imbue(lg); 16288 { 16289 ios.width(0); 16290 { 16291 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16292 std::string ex(str, iter.base()); 16293 assert(ex == "+0x1;26580b488p+30"); 16294 assert(ios.width() == 0); 16295 } 16296 ios.width(25); 16297 left(ios); 16298 { 16299 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16300 std::string ex(str, iter.base()); 16301 assert(ex == "+0x1;26580b488p+30*******"); 16302 assert(ios.width() == 0); 16303 } 16304 ios.width(25); 16305 right(ios); 16306 { 16307 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16308 std::string ex(str, iter.base()); 16309 assert(ex == "*******+0x1;26580b488p+30"); 16310 assert(ios.width() == 0); 16311 } 16312 ios.width(25); 16313 internal(ios); 16314 { 16315 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16316 std::string ex(str, iter.base()); 16317 assert(ex == "+*******0x1;26580b488p+30"); 16318 assert(ios.width() == 0); 16319 } 16320 } 16321 } 16322 showpoint(ios); 16323 { 16324 ios.imbue(lc); 16325 { 16326 ios.width(0); 16327 { 16328 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16329 std::string ex(str, iter.base()); 16330 assert(ex == "+0x1.26580b488p+30"); 16331 assert(ios.width() == 0); 16332 } 16333 ios.width(25); 16334 left(ios); 16335 { 16336 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16337 std::string ex(str, iter.base()); 16338 assert(ex == "+0x1.26580b488p+30*******"); 16339 assert(ios.width() == 0); 16340 } 16341 ios.width(25); 16342 right(ios); 16343 { 16344 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16345 std::string ex(str, iter.base()); 16346 assert(ex == "*******+0x1.26580b488p+30"); 16347 assert(ios.width() == 0); 16348 } 16349 ios.width(25); 16350 internal(ios); 16351 { 16352 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16353 std::string ex(str, iter.base()); 16354 assert(ex == "+*******0x1.26580b488p+30"); 16355 assert(ios.width() == 0); 16356 } 16357 } 16358 ios.imbue(lg); 16359 { 16360 ios.width(0); 16361 { 16362 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16363 std::string ex(str, iter.base()); 16364 assert(ex == "+0x1;26580b488p+30"); 16365 assert(ios.width() == 0); 16366 } 16367 ios.width(25); 16368 left(ios); 16369 { 16370 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16371 std::string ex(str, iter.base()); 16372 assert(ex == "+0x1;26580b488p+30*******"); 16373 assert(ios.width() == 0); 16374 } 16375 ios.width(25); 16376 right(ios); 16377 { 16378 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16379 std::string ex(str, iter.base()); 16380 assert(ex == "*******+0x1;26580b488p+30"); 16381 assert(ios.width() == 0); 16382 } 16383 ios.width(25); 16384 internal(ios); 16385 { 16386 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16387 std::string ex(str, iter.base()); 16388 assert(ex == "+*******0x1;26580b488p+30"); 16389 assert(ios.width() == 0); 16390 } 16391 } 16392 } 16393 } 16394 } 16395 uppercase(ios); 16396 { 16397 noshowpos(ios); 16398 { 16399 noshowpoint(ios); 16400 { 16401 ios.imbue(lc); 16402 { 16403 ios.width(0); 16404 { 16405 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16406 std::string ex(str, iter.base()); 16407 assert(ex == "0X1.26580B488P+30"); 16408 assert(ios.width() == 0); 16409 } 16410 ios.width(25); 16411 left(ios); 16412 { 16413 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16414 std::string ex(str, iter.base()); 16415 assert(ex == "0X1.26580B488P+30********"); 16416 assert(ios.width() == 0); 16417 } 16418 ios.width(25); 16419 right(ios); 16420 { 16421 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16422 std::string ex(str, iter.base()); 16423 assert(ex == "********0X1.26580B488P+30"); 16424 assert(ios.width() == 0); 16425 } 16426 ios.width(25); 16427 internal(ios); 16428 { 16429 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16430 std::string ex(str, iter.base()); 16431 assert(ex == "0X********1.26580B488P+30"); 16432 assert(ios.width() == 0); 16433 } 16434 } 16435 ios.imbue(lg); 16436 { 16437 ios.width(0); 16438 { 16439 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16440 std::string ex(str, iter.base()); 16441 assert(ex == "0X1;26580B488P+30"); 16442 assert(ios.width() == 0); 16443 } 16444 ios.width(25); 16445 left(ios); 16446 { 16447 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16448 std::string ex(str, iter.base()); 16449 assert(ex == "0X1;26580B488P+30********"); 16450 assert(ios.width() == 0); 16451 } 16452 ios.width(25); 16453 right(ios); 16454 { 16455 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16456 std::string ex(str, iter.base()); 16457 assert(ex == "********0X1;26580B488P+30"); 16458 assert(ios.width() == 0); 16459 } 16460 ios.width(25); 16461 internal(ios); 16462 { 16463 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16464 std::string ex(str, iter.base()); 16465 assert(ex == "0X********1;26580B488P+30"); 16466 assert(ios.width() == 0); 16467 } 16468 } 16469 } 16470 showpoint(ios); 16471 { 16472 ios.imbue(lc); 16473 { 16474 ios.width(0); 16475 { 16476 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16477 std::string ex(str, iter.base()); 16478 assert(ex == "0X1.26580B488P+30"); 16479 assert(ios.width() == 0); 16480 } 16481 ios.width(25); 16482 left(ios); 16483 { 16484 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16485 std::string ex(str, iter.base()); 16486 assert(ex == "0X1.26580B488P+30********"); 16487 assert(ios.width() == 0); 16488 } 16489 ios.width(25); 16490 right(ios); 16491 { 16492 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16493 std::string ex(str, iter.base()); 16494 assert(ex == "********0X1.26580B488P+30"); 16495 assert(ios.width() == 0); 16496 } 16497 ios.width(25); 16498 internal(ios); 16499 { 16500 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16501 std::string ex(str, iter.base()); 16502 assert(ex == "0X********1.26580B488P+30"); 16503 assert(ios.width() == 0); 16504 } 16505 } 16506 ios.imbue(lg); 16507 { 16508 ios.width(0); 16509 { 16510 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16511 std::string ex(str, iter.base()); 16512 assert(ex == "0X1;26580B488P+30"); 16513 assert(ios.width() == 0); 16514 } 16515 ios.width(25); 16516 left(ios); 16517 { 16518 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16519 std::string ex(str, iter.base()); 16520 assert(ex == "0X1;26580B488P+30********"); 16521 assert(ios.width() == 0); 16522 } 16523 ios.width(25); 16524 right(ios); 16525 { 16526 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16527 std::string ex(str, iter.base()); 16528 assert(ex == "********0X1;26580B488P+30"); 16529 assert(ios.width() == 0); 16530 } 16531 ios.width(25); 16532 internal(ios); 16533 { 16534 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16535 std::string ex(str, iter.base()); 16536 assert(ex == "0X********1;26580B488P+30"); 16537 assert(ios.width() == 0); 16538 } 16539 } 16540 } 16541 } 16542 showpos(ios); 16543 { 16544 noshowpoint(ios); 16545 { 16546 ios.imbue(lc); 16547 { 16548 ios.width(0); 16549 { 16550 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16551 std::string ex(str, iter.base()); 16552 assert(ex == "+0X1.26580B488P+30"); 16553 assert(ios.width() == 0); 16554 } 16555 ios.width(25); 16556 left(ios); 16557 { 16558 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16559 std::string ex(str, iter.base()); 16560 assert(ex == "+0X1.26580B488P+30*******"); 16561 assert(ios.width() == 0); 16562 } 16563 ios.width(25); 16564 right(ios); 16565 { 16566 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16567 std::string ex(str, iter.base()); 16568 assert(ex == "*******+0X1.26580B488P+30"); 16569 assert(ios.width() == 0); 16570 } 16571 ios.width(25); 16572 internal(ios); 16573 { 16574 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16575 std::string ex(str, iter.base()); 16576 assert(ex == "+*******0X1.26580B488P+30"); 16577 assert(ios.width() == 0); 16578 } 16579 } 16580 ios.imbue(lg); 16581 { 16582 ios.width(0); 16583 { 16584 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16585 std::string ex(str, iter.base()); 16586 assert(ex == "+0X1;26580B488P+30"); 16587 assert(ios.width() == 0); 16588 } 16589 ios.width(25); 16590 left(ios); 16591 { 16592 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16593 std::string ex(str, iter.base()); 16594 assert(ex == "+0X1;26580B488P+30*******"); 16595 assert(ios.width() == 0); 16596 } 16597 ios.width(25); 16598 right(ios); 16599 { 16600 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16601 std::string ex(str, iter.base()); 16602 assert(ex == "*******+0X1;26580B488P+30"); 16603 assert(ios.width() == 0); 16604 } 16605 ios.width(25); 16606 internal(ios); 16607 { 16608 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16609 std::string ex(str, iter.base()); 16610 assert(ex == "+*******0X1;26580B488P+30"); 16611 assert(ios.width() == 0); 16612 } 16613 } 16614 } 16615 showpoint(ios); 16616 { 16617 ios.imbue(lc); 16618 { 16619 ios.width(0); 16620 { 16621 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16622 std::string ex(str, iter.base()); 16623 assert(ex == "+0X1.26580B488P+30"); 16624 assert(ios.width() == 0); 16625 } 16626 ios.width(25); 16627 left(ios); 16628 { 16629 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16630 std::string ex(str, iter.base()); 16631 assert(ex == "+0X1.26580B488P+30*******"); 16632 assert(ios.width() == 0); 16633 } 16634 ios.width(25); 16635 right(ios); 16636 { 16637 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16638 std::string ex(str, iter.base()); 16639 assert(ex == "*******+0X1.26580B488P+30"); 16640 assert(ios.width() == 0); 16641 } 16642 ios.width(25); 16643 internal(ios); 16644 { 16645 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16646 std::string ex(str, iter.base()); 16647 assert(ex == "+*******0X1.26580B488P+30"); 16648 assert(ios.width() == 0); 16649 } 16650 } 16651 ios.imbue(lg); 16652 { 16653 ios.width(0); 16654 { 16655 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16656 std::string ex(str, iter.base()); 16657 assert(ex == "+0X1;26580B488P+30"); 16658 assert(ios.width() == 0); 16659 } 16660 ios.width(25); 16661 left(ios); 16662 { 16663 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16664 std::string ex(str, iter.base()); 16665 assert(ex == "+0X1;26580B488P+30*******"); 16666 assert(ios.width() == 0); 16667 } 16668 ios.width(25); 16669 right(ios); 16670 { 16671 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16672 std::string ex(str, iter.base()); 16673 assert(ex == "*******+0X1;26580B488P+30"); 16674 assert(ios.width() == 0); 16675 } 16676 ios.width(25); 16677 internal(ios); 16678 { 16679 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16680 std::string ex(str, iter.base()); 16681 assert(ex == "+*******0X1;26580B488P+30"); 16682 assert(ios.width() == 0); 16683 } 16684 } 16685 } 16686 } 16687 } 16688 } 16689 ios.precision(1); 16690 { 16691 nouppercase(ios); 16692 { 16693 noshowpos(ios); 16694 { 16695 noshowpoint(ios); 16696 { 16697 ios.imbue(lc); 16698 { 16699 ios.width(0); 16700 { 16701 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16702 std::string ex(str, iter.base()); 16703 assert(ex == "0x1.26580b488p+30"); 16704 assert(ios.width() == 0); 16705 } 16706 ios.width(25); 16707 left(ios); 16708 { 16709 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16710 std::string ex(str, iter.base()); 16711 assert(ex == "0x1.26580b488p+30********"); 16712 assert(ios.width() == 0); 16713 } 16714 ios.width(25); 16715 right(ios); 16716 { 16717 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16718 std::string ex(str, iter.base()); 16719 assert(ex == "********0x1.26580b488p+30"); 16720 assert(ios.width() == 0); 16721 } 16722 ios.width(25); 16723 internal(ios); 16724 { 16725 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16726 std::string ex(str, iter.base()); 16727 assert(ex == "0x********1.26580b488p+30"); 16728 assert(ios.width() == 0); 16729 } 16730 } 16731 ios.imbue(lg); 16732 { 16733 ios.width(0); 16734 { 16735 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16736 std::string ex(str, iter.base()); 16737 assert(ex == "0x1;26580b488p+30"); 16738 assert(ios.width() == 0); 16739 } 16740 ios.width(25); 16741 left(ios); 16742 { 16743 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16744 std::string ex(str, iter.base()); 16745 assert(ex == "0x1;26580b488p+30********"); 16746 assert(ios.width() == 0); 16747 } 16748 ios.width(25); 16749 right(ios); 16750 { 16751 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16752 std::string ex(str, iter.base()); 16753 assert(ex == "********0x1;26580b488p+30"); 16754 assert(ios.width() == 0); 16755 } 16756 ios.width(25); 16757 internal(ios); 16758 { 16759 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16760 std::string ex(str, iter.base()); 16761 assert(ex == "0x********1;26580b488p+30"); 16762 assert(ios.width() == 0); 16763 } 16764 } 16765 } 16766 showpoint(ios); 16767 { 16768 ios.imbue(lc); 16769 { 16770 ios.width(0); 16771 { 16772 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16773 std::string ex(str, iter.base()); 16774 assert(ex == "0x1.26580b488p+30"); 16775 assert(ios.width() == 0); 16776 } 16777 ios.width(25); 16778 left(ios); 16779 { 16780 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16781 std::string ex(str, iter.base()); 16782 assert(ex == "0x1.26580b488p+30********"); 16783 assert(ios.width() == 0); 16784 } 16785 ios.width(25); 16786 right(ios); 16787 { 16788 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16789 std::string ex(str, iter.base()); 16790 assert(ex == "********0x1.26580b488p+30"); 16791 assert(ios.width() == 0); 16792 } 16793 ios.width(25); 16794 internal(ios); 16795 { 16796 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16797 std::string ex(str, iter.base()); 16798 assert(ex == "0x********1.26580b488p+30"); 16799 assert(ios.width() == 0); 16800 } 16801 } 16802 ios.imbue(lg); 16803 { 16804 ios.width(0); 16805 { 16806 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16807 std::string ex(str, iter.base()); 16808 assert(ex == "0x1;26580b488p+30"); 16809 assert(ios.width() == 0); 16810 } 16811 ios.width(25); 16812 left(ios); 16813 { 16814 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16815 std::string ex(str, iter.base()); 16816 assert(ex == "0x1;26580b488p+30********"); 16817 assert(ios.width() == 0); 16818 } 16819 ios.width(25); 16820 right(ios); 16821 { 16822 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16823 std::string ex(str, iter.base()); 16824 assert(ex == "********0x1;26580b488p+30"); 16825 assert(ios.width() == 0); 16826 } 16827 ios.width(25); 16828 internal(ios); 16829 { 16830 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16831 std::string ex(str, iter.base()); 16832 assert(ex == "0x********1;26580b488p+30"); 16833 assert(ios.width() == 0); 16834 } 16835 } 16836 } 16837 } 16838 showpos(ios); 16839 { 16840 noshowpoint(ios); 16841 { 16842 ios.imbue(lc); 16843 { 16844 ios.width(0); 16845 { 16846 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16847 std::string ex(str, iter.base()); 16848 assert(ex == "+0x1.26580b488p+30"); 16849 assert(ios.width() == 0); 16850 } 16851 ios.width(25); 16852 left(ios); 16853 { 16854 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16855 std::string ex(str, iter.base()); 16856 assert(ex == "+0x1.26580b488p+30*******"); 16857 assert(ios.width() == 0); 16858 } 16859 ios.width(25); 16860 right(ios); 16861 { 16862 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16863 std::string ex(str, iter.base()); 16864 assert(ex == "*******+0x1.26580b488p+30"); 16865 assert(ios.width() == 0); 16866 } 16867 ios.width(25); 16868 internal(ios); 16869 { 16870 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16871 std::string ex(str, iter.base()); 16872 assert(ex == "+*******0x1.26580b488p+30"); 16873 assert(ios.width() == 0); 16874 } 16875 } 16876 ios.imbue(lg); 16877 { 16878 ios.width(0); 16879 { 16880 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16881 std::string ex(str, iter.base()); 16882 assert(ex == "+0x1;26580b488p+30"); 16883 assert(ios.width() == 0); 16884 } 16885 ios.width(25); 16886 left(ios); 16887 { 16888 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16889 std::string ex(str, iter.base()); 16890 assert(ex == "+0x1;26580b488p+30*******"); 16891 assert(ios.width() == 0); 16892 } 16893 ios.width(25); 16894 right(ios); 16895 { 16896 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16897 std::string ex(str, iter.base()); 16898 assert(ex == "*******+0x1;26580b488p+30"); 16899 assert(ios.width() == 0); 16900 } 16901 ios.width(25); 16902 internal(ios); 16903 { 16904 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16905 std::string ex(str, iter.base()); 16906 assert(ex == "+*******0x1;26580b488p+30"); 16907 assert(ios.width() == 0); 16908 } 16909 } 16910 } 16911 showpoint(ios); 16912 { 16913 ios.imbue(lc); 16914 { 16915 ios.width(0); 16916 { 16917 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16918 std::string ex(str, iter.base()); 16919 assert(ex == "+0x1.26580b488p+30"); 16920 assert(ios.width() == 0); 16921 } 16922 ios.width(25); 16923 left(ios); 16924 { 16925 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16926 std::string ex(str, iter.base()); 16927 assert(ex == "+0x1.26580b488p+30*******"); 16928 assert(ios.width() == 0); 16929 } 16930 ios.width(25); 16931 right(ios); 16932 { 16933 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16934 std::string ex(str, iter.base()); 16935 assert(ex == "*******+0x1.26580b488p+30"); 16936 assert(ios.width() == 0); 16937 } 16938 ios.width(25); 16939 internal(ios); 16940 { 16941 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16942 std::string ex(str, iter.base()); 16943 assert(ex == "+*******0x1.26580b488p+30"); 16944 assert(ios.width() == 0); 16945 } 16946 } 16947 ios.imbue(lg); 16948 { 16949 ios.width(0); 16950 { 16951 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16952 std::string ex(str, iter.base()); 16953 assert(ex == "+0x1;26580b488p+30"); 16954 assert(ios.width() == 0); 16955 } 16956 ios.width(25); 16957 left(ios); 16958 { 16959 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16960 std::string ex(str, iter.base()); 16961 assert(ex == "+0x1;26580b488p+30*******"); 16962 assert(ios.width() == 0); 16963 } 16964 ios.width(25); 16965 right(ios); 16966 { 16967 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16968 std::string ex(str, iter.base()); 16969 assert(ex == "*******+0x1;26580b488p+30"); 16970 assert(ios.width() == 0); 16971 } 16972 ios.width(25); 16973 internal(ios); 16974 { 16975 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16976 std::string ex(str, iter.base()); 16977 assert(ex == "+*******0x1;26580b488p+30"); 16978 assert(ios.width() == 0); 16979 } 16980 } 16981 } 16982 } 16983 } 16984 uppercase(ios); 16985 { 16986 noshowpos(ios); 16987 { 16988 noshowpoint(ios); 16989 { 16990 ios.imbue(lc); 16991 { 16992 ios.width(0); 16993 { 16994 iter = f.put(output_iterator<char*>(str), ios, '*', v); 16995 std::string ex(str, iter.base()); 16996 assert(ex == "0X1.26580B488P+30"); 16997 assert(ios.width() == 0); 16998 } 16999 ios.width(25); 17000 left(ios); 17001 { 17002 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17003 std::string ex(str, iter.base()); 17004 assert(ex == "0X1.26580B488P+30********"); 17005 assert(ios.width() == 0); 17006 } 17007 ios.width(25); 17008 right(ios); 17009 { 17010 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17011 std::string ex(str, iter.base()); 17012 assert(ex == "********0X1.26580B488P+30"); 17013 assert(ios.width() == 0); 17014 } 17015 ios.width(25); 17016 internal(ios); 17017 { 17018 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17019 std::string ex(str, iter.base()); 17020 assert(ex == "0X********1.26580B488P+30"); 17021 assert(ios.width() == 0); 17022 } 17023 } 17024 ios.imbue(lg); 17025 { 17026 ios.width(0); 17027 { 17028 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17029 std::string ex(str, iter.base()); 17030 assert(ex == "0X1;26580B488P+30"); 17031 assert(ios.width() == 0); 17032 } 17033 ios.width(25); 17034 left(ios); 17035 { 17036 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17037 std::string ex(str, iter.base()); 17038 assert(ex == "0X1;26580B488P+30********"); 17039 assert(ios.width() == 0); 17040 } 17041 ios.width(25); 17042 right(ios); 17043 { 17044 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17045 std::string ex(str, iter.base()); 17046 assert(ex == "********0X1;26580B488P+30"); 17047 assert(ios.width() == 0); 17048 } 17049 ios.width(25); 17050 internal(ios); 17051 { 17052 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17053 std::string ex(str, iter.base()); 17054 assert(ex == "0X********1;26580B488P+30"); 17055 assert(ios.width() == 0); 17056 } 17057 } 17058 } 17059 showpoint(ios); 17060 { 17061 ios.imbue(lc); 17062 { 17063 ios.width(0); 17064 { 17065 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17066 std::string ex(str, iter.base()); 17067 assert(ex == "0X1.26580B488P+30"); 17068 assert(ios.width() == 0); 17069 } 17070 ios.width(25); 17071 left(ios); 17072 { 17073 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17074 std::string ex(str, iter.base()); 17075 assert(ex == "0X1.26580B488P+30********"); 17076 assert(ios.width() == 0); 17077 } 17078 ios.width(25); 17079 right(ios); 17080 { 17081 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17082 std::string ex(str, iter.base()); 17083 assert(ex == "********0X1.26580B488P+30"); 17084 assert(ios.width() == 0); 17085 } 17086 ios.width(25); 17087 internal(ios); 17088 { 17089 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17090 std::string ex(str, iter.base()); 17091 assert(ex == "0X********1.26580B488P+30"); 17092 assert(ios.width() == 0); 17093 } 17094 } 17095 ios.imbue(lg); 17096 { 17097 ios.width(0); 17098 { 17099 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17100 std::string ex(str, iter.base()); 17101 assert(ex == "0X1;26580B488P+30"); 17102 assert(ios.width() == 0); 17103 } 17104 ios.width(25); 17105 left(ios); 17106 { 17107 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17108 std::string ex(str, iter.base()); 17109 assert(ex == "0X1;26580B488P+30********"); 17110 assert(ios.width() == 0); 17111 } 17112 ios.width(25); 17113 right(ios); 17114 { 17115 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17116 std::string ex(str, iter.base()); 17117 assert(ex == "********0X1;26580B488P+30"); 17118 assert(ios.width() == 0); 17119 } 17120 ios.width(25); 17121 internal(ios); 17122 { 17123 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17124 std::string ex(str, iter.base()); 17125 assert(ex == "0X********1;26580B488P+30"); 17126 assert(ios.width() == 0); 17127 } 17128 } 17129 } 17130 } 17131 showpos(ios); 17132 { 17133 noshowpoint(ios); 17134 { 17135 ios.imbue(lc); 17136 { 17137 ios.width(0); 17138 { 17139 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17140 std::string ex(str, iter.base()); 17141 assert(ex == "+0X1.26580B488P+30"); 17142 assert(ios.width() == 0); 17143 } 17144 ios.width(25); 17145 left(ios); 17146 { 17147 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17148 std::string ex(str, iter.base()); 17149 assert(ex == "+0X1.26580B488P+30*******"); 17150 assert(ios.width() == 0); 17151 } 17152 ios.width(25); 17153 right(ios); 17154 { 17155 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17156 std::string ex(str, iter.base()); 17157 assert(ex == "*******+0X1.26580B488P+30"); 17158 assert(ios.width() == 0); 17159 } 17160 ios.width(25); 17161 internal(ios); 17162 { 17163 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17164 std::string ex(str, iter.base()); 17165 assert(ex == "+*******0X1.26580B488P+30"); 17166 assert(ios.width() == 0); 17167 } 17168 } 17169 ios.imbue(lg); 17170 { 17171 ios.width(0); 17172 { 17173 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17174 std::string ex(str, iter.base()); 17175 assert(ex == "+0X1;26580B488P+30"); 17176 assert(ios.width() == 0); 17177 } 17178 ios.width(25); 17179 left(ios); 17180 { 17181 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17182 std::string ex(str, iter.base()); 17183 assert(ex == "+0X1;26580B488P+30*******"); 17184 assert(ios.width() == 0); 17185 } 17186 ios.width(25); 17187 right(ios); 17188 { 17189 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17190 std::string ex(str, iter.base()); 17191 assert(ex == "*******+0X1;26580B488P+30"); 17192 assert(ios.width() == 0); 17193 } 17194 ios.width(25); 17195 internal(ios); 17196 { 17197 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17198 std::string ex(str, iter.base()); 17199 assert(ex == "+*******0X1;26580B488P+30"); 17200 assert(ios.width() == 0); 17201 } 17202 } 17203 } 17204 showpoint(ios); 17205 { 17206 ios.imbue(lc); 17207 { 17208 ios.width(0); 17209 { 17210 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17211 std::string ex(str, iter.base()); 17212 assert(ex == "+0X1.26580B488P+30"); 17213 assert(ios.width() == 0); 17214 } 17215 ios.width(25); 17216 left(ios); 17217 { 17218 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17219 std::string ex(str, iter.base()); 17220 assert(ex == "+0X1.26580B488P+30*******"); 17221 assert(ios.width() == 0); 17222 } 17223 ios.width(25); 17224 right(ios); 17225 { 17226 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17227 std::string ex(str, iter.base()); 17228 assert(ex == "*******+0X1.26580B488P+30"); 17229 assert(ios.width() == 0); 17230 } 17231 ios.width(25); 17232 internal(ios); 17233 { 17234 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17235 std::string ex(str, iter.base()); 17236 assert(ex == "+*******0X1.26580B488P+30"); 17237 assert(ios.width() == 0); 17238 } 17239 } 17240 ios.imbue(lg); 17241 { 17242 ios.width(0); 17243 { 17244 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17245 std::string ex(str, iter.base()); 17246 assert(ex == "+0X1;26580B488P+30"); 17247 assert(ios.width() == 0); 17248 } 17249 ios.width(25); 17250 left(ios); 17251 { 17252 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17253 std::string ex(str, iter.base()); 17254 assert(ex == "+0X1;26580B488P+30*******"); 17255 assert(ios.width() == 0); 17256 } 17257 ios.width(25); 17258 right(ios); 17259 { 17260 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17261 std::string ex(str, iter.base()); 17262 assert(ex == "*******+0X1;26580B488P+30"); 17263 assert(ios.width() == 0); 17264 } 17265 ios.width(25); 17266 internal(ios); 17267 { 17268 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17269 std::string ex(str, iter.base()); 17270 assert(ex == "+*******0X1;26580B488P+30"); 17271 assert(ios.width() == 0); 17272 } 17273 } 17274 } 17275 } 17276 } 17277 } 17278 ios.precision(6); 17279 { 17280 } 17281 ios.precision(16); 17282 { 17283 } 17284 ios.precision(60); 17285 { 17286 nouppercase(ios); 17287 { 17288 noshowpos(ios); 17289 { 17290 noshowpoint(ios); 17291 { 17292 ios.imbue(lc); 17293 { 17294 ios.width(0); 17295 { 17296 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17297 std::string ex(str, iter.base()); 17298 assert(ex == "0x1.26580b488p+30"); 17299 assert(ios.width() == 0); 17300 } 17301 ios.width(25); 17302 left(ios); 17303 { 17304 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17305 std::string ex(str, iter.base()); 17306 assert(ex == "0x1.26580b488p+30********"); 17307 assert(ios.width() == 0); 17308 } 17309 ios.width(25); 17310 right(ios); 17311 { 17312 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17313 std::string ex(str, iter.base()); 17314 assert(ex == "********0x1.26580b488p+30"); 17315 assert(ios.width() == 0); 17316 } 17317 ios.width(25); 17318 internal(ios); 17319 { 17320 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17321 std::string ex(str, iter.base()); 17322 assert(ex == "0x********1.26580b488p+30"); 17323 assert(ios.width() == 0); 17324 } 17325 } 17326 ios.imbue(lg); 17327 { 17328 ios.width(0); 17329 { 17330 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17331 std::string ex(str, iter.base()); 17332 assert(ex == "0x1;26580b488p+30"); 17333 assert(ios.width() == 0); 17334 } 17335 ios.width(25); 17336 left(ios); 17337 { 17338 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17339 std::string ex(str, iter.base()); 17340 assert(ex == "0x1;26580b488p+30********"); 17341 assert(ios.width() == 0); 17342 } 17343 ios.width(25); 17344 right(ios); 17345 { 17346 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17347 std::string ex(str, iter.base()); 17348 assert(ex == "********0x1;26580b488p+30"); 17349 assert(ios.width() == 0); 17350 } 17351 ios.width(25); 17352 internal(ios); 17353 { 17354 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17355 std::string ex(str, iter.base()); 17356 assert(ex == "0x********1;26580b488p+30"); 17357 assert(ios.width() == 0); 17358 } 17359 } 17360 } 17361 showpoint(ios); 17362 { 17363 ios.imbue(lc); 17364 { 17365 ios.width(0); 17366 { 17367 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17368 std::string ex(str, iter.base()); 17369 assert(ex == "0x1.26580b488p+30"); 17370 assert(ios.width() == 0); 17371 } 17372 ios.width(25); 17373 left(ios); 17374 { 17375 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17376 std::string ex(str, iter.base()); 17377 assert(ex == "0x1.26580b488p+30********"); 17378 assert(ios.width() == 0); 17379 } 17380 ios.width(25); 17381 right(ios); 17382 { 17383 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17384 std::string ex(str, iter.base()); 17385 assert(ex == "********0x1.26580b488p+30"); 17386 assert(ios.width() == 0); 17387 } 17388 ios.width(25); 17389 internal(ios); 17390 { 17391 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17392 std::string ex(str, iter.base()); 17393 assert(ex == "0x********1.26580b488p+30"); 17394 assert(ios.width() == 0); 17395 } 17396 } 17397 ios.imbue(lg); 17398 { 17399 ios.width(0); 17400 { 17401 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17402 std::string ex(str, iter.base()); 17403 assert(ex == "0x1;26580b488p+30"); 17404 assert(ios.width() == 0); 17405 } 17406 ios.width(25); 17407 left(ios); 17408 { 17409 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17410 std::string ex(str, iter.base()); 17411 assert(ex == "0x1;26580b488p+30********"); 17412 assert(ios.width() == 0); 17413 } 17414 ios.width(25); 17415 right(ios); 17416 { 17417 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17418 std::string ex(str, iter.base()); 17419 assert(ex == "********0x1;26580b488p+30"); 17420 assert(ios.width() == 0); 17421 } 17422 ios.width(25); 17423 internal(ios); 17424 { 17425 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17426 std::string ex(str, iter.base()); 17427 assert(ex == "0x********1;26580b488p+30"); 17428 assert(ios.width() == 0); 17429 } 17430 } 17431 } 17432 } 17433 showpos(ios); 17434 { 17435 noshowpoint(ios); 17436 { 17437 ios.imbue(lc); 17438 { 17439 ios.width(0); 17440 { 17441 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17442 std::string ex(str, iter.base()); 17443 assert(ex == "+0x1.26580b488p+30"); 17444 assert(ios.width() == 0); 17445 } 17446 ios.width(25); 17447 left(ios); 17448 { 17449 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17450 std::string ex(str, iter.base()); 17451 assert(ex == "+0x1.26580b488p+30*******"); 17452 assert(ios.width() == 0); 17453 } 17454 ios.width(25); 17455 right(ios); 17456 { 17457 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17458 std::string ex(str, iter.base()); 17459 assert(ex == "*******+0x1.26580b488p+30"); 17460 assert(ios.width() == 0); 17461 } 17462 ios.width(25); 17463 internal(ios); 17464 { 17465 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17466 std::string ex(str, iter.base()); 17467 assert(ex == "+*******0x1.26580b488p+30"); 17468 assert(ios.width() == 0); 17469 } 17470 } 17471 ios.imbue(lg); 17472 { 17473 ios.width(0); 17474 { 17475 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17476 std::string ex(str, iter.base()); 17477 assert(ex == "+0x1;26580b488p+30"); 17478 assert(ios.width() == 0); 17479 } 17480 ios.width(25); 17481 left(ios); 17482 { 17483 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17484 std::string ex(str, iter.base()); 17485 assert(ex == "+0x1;26580b488p+30*******"); 17486 assert(ios.width() == 0); 17487 } 17488 ios.width(25); 17489 right(ios); 17490 { 17491 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17492 std::string ex(str, iter.base()); 17493 assert(ex == "*******+0x1;26580b488p+30"); 17494 assert(ios.width() == 0); 17495 } 17496 ios.width(25); 17497 internal(ios); 17498 { 17499 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17500 std::string ex(str, iter.base()); 17501 assert(ex == "+*******0x1;26580b488p+30"); 17502 assert(ios.width() == 0); 17503 } 17504 } 17505 } 17506 showpoint(ios); 17507 { 17508 ios.imbue(lc); 17509 { 17510 ios.width(0); 17511 { 17512 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17513 std::string ex(str, iter.base()); 17514 assert(ex == "+0x1.26580b488p+30"); 17515 assert(ios.width() == 0); 17516 } 17517 ios.width(25); 17518 left(ios); 17519 { 17520 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17521 std::string ex(str, iter.base()); 17522 assert(ex == "+0x1.26580b488p+30*******"); 17523 assert(ios.width() == 0); 17524 } 17525 ios.width(25); 17526 right(ios); 17527 { 17528 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17529 std::string ex(str, iter.base()); 17530 assert(ex == "*******+0x1.26580b488p+30"); 17531 assert(ios.width() == 0); 17532 } 17533 ios.width(25); 17534 internal(ios); 17535 { 17536 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17537 std::string ex(str, iter.base()); 17538 assert(ex == "+*******0x1.26580b488p+30"); 17539 assert(ios.width() == 0); 17540 } 17541 } 17542 ios.imbue(lg); 17543 { 17544 ios.width(0); 17545 { 17546 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17547 std::string ex(str, iter.base()); 17548 assert(ex == "+0x1;26580b488p+30"); 17549 assert(ios.width() == 0); 17550 } 17551 ios.width(25); 17552 left(ios); 17553 { 17554 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17555 std::string ex(str, iter.base()); 17556 assert(ex == "+0x1;26580b488p+30*******"); 17557 assert(ios.width() == 0); 17558 } 17559 ios.width(25); 17560 right(ios); 17561 { 17562 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17563 std::string ex(str, iter.base()); 17564 assert(ex == "*******+0x1;26580b488p+30"); 17565 assert(ios.width() == 0); 17566 } 17567 ios.width(25); 17568 internal(ios); 17569 { 17570 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17571 std::string ex(str, iter.base()); 17572 assert(ex == "+*******0x1;26580b488p+30"); 17573 assert(ios.width() == 0); 17574 } 17575 } 17576 } 17577 } 17578 } 17579 uppercase(ios); 17580 { 17581 noshowpos(ios); 17582 { 17583 noshowpoint(ios); 17584 { 17585 ios.imbue(lc); 17586 { 17587 ios.width(0); 17588 { 17589 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17590 std::string ex(str, iter.base()); 17591 assert(ex == "0X1.26580B488P+30"); 17592 assert(ios.width() == 0); 17593 } 17594 ios.width(25); 17595 left(ios); 17596 { 17597 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17598 std::string ex(str, iter.base()); 17599 assert(ex == "0X1.26580B488P+30********"); 17600 assert(ios.width() == 0); 17601 } 17602 ios.width(25); 17603 right(ios); 17604 { 17605 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17606 std::string ex(str, iter.base()); 17607 assert(ex == "********0X1.26580B488P+30"); 17608 assert(ios.width() == 0); 17609 } 17610 ios.width(25); 17611 internal(ios); 17612 { 17613 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17614 std::string ex(str, iter.base()); 17615 assert(ex == "0X********1.26580B488P+30"); 17616 assert(ios.width() == 0); 17617 } 17618 } 17619 ios.imbue(lg); 17620 { 17621 ios.width(0); 17622 { 17623 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17624 std::string ex(str, iter.base()); 17625 assert(ex == "0X1;26580B488P+30"); 17626 assert(ios.width() == 0); 17627 } 17628 ios.width(25); 17629 left(ios); 17630 { 17631 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17632 std::string ex(str, iter.base()); 17633 assert(ex == "0X1;26580B488P+30********"); 17634 assert(ios.width() == 0); 17635 } 17636 ios.width(25); 17637 right(ios); 17638 { 17639 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17640 std::string ex(str, iter.base()); 17641 assert(ex == "********0X1;26580B488P+30"); 17642 assert(ios.width() == 0); 17643 } 17644 ios.width(25); 17645 internal(ios); 17646 { 17647 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17648 std::string ex(str, iter.base()); 17649 assert(ex == "0X********1;26580B488P+30"); 17650 assert(ios.width() == 0); 17651 } 17652 } 17653 } 17654 showpoint(ios); 17655 { 17656 ios.imbue(lc); 17657 { 17658 ios.width(0); 17659 { 17660 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17661 std::string ex(str, iter.base()); 17662 assert(ex == "0X1.26580B488P+30"); 17663 assert(ios.width() == 0); 17664 } 17665 ios.width(25); 17666 left(ios); 17667 { 17668 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17669 std::string ex(str, iter.base()); 17670 assert(ex == "0X1.26580B488P+30********"); 17671 assert(ios.width() == 0); 17672 } 17673 ios.width(25); 17674 right(ios); 17675 { 17676 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17677 std::string ex(str, iter.base()); 17678 assert(ex == "********0X1.26580B488P+30"); 17679 assert(ios.width() == 0); 17680 } 17681 ios.width(25); 17682 internal(ios); 17683 { 17684 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17685 std::string ex(str, iter.base()); 17686 assert(ex == "0X********1.26580B488P+30"); 17687 assert(ios.width() == 0); 17688 } 17689 } 17690 ios.imbue(lg); 17691 { 17692 ios.width(0); 17693 { 17694 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17695 std::string ex(str, iter.base()); 17696 assert(ex == "0X1;26580B488P+30"); 17697 assert(ios.width() == 0); 17698 } 17699 ios.width(25); 17700 left(ios); 17701 { 17702 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17703 std::string ex(str, iter.base()); 17704 assert(ex == "0X1;26580B488P+30********"); 17705 assert(ios.width() == 0); 17706 } 17707 ios.width(25); 17708 right(ios); 17709 { 17710 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17711 std::string ex(str, iter.base()); 17712 assert(ex == "********0X1;26580B488P+30"); 17713 assert(ios.width() == 0); 17714 } 17715 ios.width(25); 17716 internal(ios); 17717 { 17718 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17719 std::string ex(str, iter.base()); 17720 assert(ex == "0X********1;26580B488P+30"); 17721 assert(ios.width() == 0); 17722 } 17723 } 17724 } 17725 } 17726 showpos(ios); 17727 { 17728 noshowpoint(ios); 17729 { 17730 ios.imbue(lc); 17731 { 17732 ios.width(0); 17733 { 17734 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17735 std::string ex(str, iter.base()); 17736 assert(ex == "+0X1.26580B488P+30"); 17737 assert(ios.width() == 0); 17738 } 17739 ios.width(25); 17740 left(ios); 17741 { 17742 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17743 std::string ex(str, iter.base()); 17744 assert(ex == "+0X1.26580B488P+30*******"); 17745 assert(ios.width() == 0); 17746 } 17747 ios.width(25); 17748 right(ios); 17749 { 17750 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17751 std::string ex(str, iter.base()); 17752 assert(ex == "*******+0X1.26580B488P+30"); 17753 assert(ios.width() == 0); 17754 } 17755 ios.width(25); 17756 internal(ios); 17757 { 17758 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17759 std::string ex(str, iter.base()); 17760 assert(ex == "+*******0X1.26580B488P+30"); 17761 assert(ios.width() == 0); 17762 } 17763 } 17764 ios.imbue(lg); 17765 { 17766 ios.width(0); 17767 { 17768 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17769 std::string ex(str, iter.base()); 17770 assert(ex == "+0X1;26580B488P+30"); 17771 assert(ios.width() == 0); 17772 } 17773 ios.width(25); 17774 left(ios); 17775 { 17776 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17777 std::string ex(str, iter.base()); 17778 assert(ex == "+0X1;26580B488P+30*******"); 17779 assert(ios.width() == 0); 17780 } 17781 ios.width(25); 17782 right(ios); 17783 { 17784 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17785 std::string ex(str, iter.base()); 17786 assert(ex == "*******+0X1;26580B488P+30"); 17787 assert(ios.width() == 0); 17788 } 17789 ios.width(25); 17790 internal(ios); 17791 { 17792 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17793 std::string ex(str, iter.base()); 17794 assert(ex == "+*******0X1;26580B488P+30"); 17795 assert(ios.width() == 0); 17796 } 17797 } 17798 } 17799 showpoint(ios); 17800 { 17801 ios.imbue(lc); 17802 { 17803 ios.width(0); 17804 { 17805 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17806 std::string ex(str, iter.base()); 17807 assert(ex == "+0X1.26580B488P+30"); 17808 assert(ios.width() == 0); 17809 } 17810 ios.width(25); 17811 left(ios); 17812 { 17813 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17814 std::string ex(str, iter.base()); 17815 assert(ex == "+0X1.26580B488P+30*******"); 17816 assert(ios.width() == 0); 17817 } 17818 ios.width(25); 17819 right(ios); 17820 { 17821 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17822 std::string ex(str, iter.base()); 17823 assert(ex == "*******+0X1.26580B488P+30"); 17824 assert(ios.width() == 0); 17825 } 17826 ios.width(25); 17827 internal(ios); 17828 { 17829 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17830 std::string ex(str, iter.base()); 17831 assert(ex == "+*******0X1.26580B488P+30"); 17832 assert(ios.width() == 0); 17833 } 17834 } 17835 ios.imbue(lg); 17836 { 17837 ios.width(0); 17838 { 17839 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17840 std::string ex(str, iter.base()); 17841 assert(ex == "+0X1;26580B488P+30"); 17842 assert(ios.width() == 0); 17843 } 17844 ios.width(25); 17845 left(ios); 17846 { 17847 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17848 std::string ex(str, iter.base()); 17849 assert(ex == "+0X1;26580B488P+30*******"); 17850 assert(ios.width() == 0); 17851 } 17852 ios.width(25); 17853 right(ios); 17854 { 17855 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17856 std::string ex(str, iter.base()); 17857 assert(ex == "*******+0X1;26580B488P+30"); 17858 assert(ios.width() == 0); 17859 } 17860 ios.width(25); 17861 internal(ios); 17862 { 17863 iter = f.put(output_iterator<char*>(str), ios, '*', v); 17864 std::string ex(str, iter.base()); 17865 assert(ex == "+*******0X1;26580B488P+30"); 17866 assert(ios.width() == 0); 17867 } 17868 } 17869 } 17870 } 17871 } 17872 } 17873 } 17874 } 17875} 17876 17877int main() 17878{ 17879 test1(); 17880 test2(); 17881 test3(); 17882 test4(); 17883 test5(); 17884 test6(); 17885 test7(); 17886 test8(); 17887} 17888