Merge -r 127928:132243 from trunk
[official-gcc.git] / libstdc++-v3 / doc / html / 17_intro / c++1998_status.html
blob7865e6499822cc5ac2a485b462b775fea26522a7
1 <pre>
3 Completion Checklist for the Standard C++ Library
4 Updated: 2003-04-25
6 Status Code Legend:
7 M - Missing
8 S - Present as stub.
9 X - Partially implemented, or buggy.
10 T - Implemented, pending test/inspection.
11 V - Verified to pass all available test suites.
12 Q - Qualified by inspection for non-testable correctness.
13 P - Portability verified.
14 C - Certified.
16 Lexical notes:
17 Only status codes appear in column 0. Notes relating to conformance
18 issues appear [in brackets].
20 Note that this checklist does not (yet) include all emendations
21 recommended by the ISO Library Working Group:
22 http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/lwg-toc.html
24 Detailed explanation of status codes:
26 M - Missing: The name is not visible to programs that include
27 the specified header, either at compile or link stage.
29 S - Present as stub: A program can use the name, but no implementation
30 is provided. Programs that use the name link correctly, but
31 cannot usefully be run.
33 X - Partially implemented, or buggy: Some implementation has been
34 provided, but it is known or believed not to conform fully.
35 It may have an incorrect base class, wrong namespace, wrong
36 storage class, or simply not fully implement requirements.
37 However, it may be sufficiently usable to help test other
38 components.
40 T - Implemented, pending test/inspection: Implementation believed
41 to be complete, and informal testing suggests it is ready for
42 formal verification.
44 V - Verified, passes all test suites: Verified to satisfy all
45 generically testable conformance requirements.
47 Q - Qualified by inspection for non-testable correctness:
48 Inspected, "implementation-defined" documentation accepted,
49 local usability criteria satisfied, formally inspected for
50 other untestable conformance. (Untestable requirements
51 include exception-safety, thread-safety, worst-case
52 complexity, memory cleanliness, usefulness.)
54 P - Portability verified: Qualified on all primary target platforms.
56 C - Certified: Formally certified to have passed all tests,
57 inspections, qualifications; approved under "signing authority"
58 to be used to satisfy contractual guarantees.
60 ----------------------------------------------------------------------
61 <algorithm> <iomanip> <list> <ostream> <streambuf>
62 <bitset> <ios> <locale> <queue> <string>
63 <complex> <iosfwd> <map> <set> <typeinfo>
64 X <deque> <iostream> <memory> <sstream> <utility>
65 <exception> <istream> <new> <stack> <valarray>
66 <fstream> <iterator> <numeric> <stdexcept> <vector>
67 <functional> <limits>
69 [C header names must be in std:: to qualify. Related to shadow/ dir.]
70 <cassert> <ciso646> <csetjmp> <cstdio> <ctime>
71 <cctype> <climits> <csignal> <cstdlib> <cwchar>
72 X <cerrno> <clocale> <cstdarg> <cstring> <cwctype>
73 <cfloat> <cmath> <cstddef>
75 Macro:
76 X errno, declared or defined in <cerrno>.
78 Macro fn:
79 X setjmp(jmp_buf), declared or defined in <csetjmp>
80 X va_end(va_list), declared or defined in <cstdarg>
82 Types:
83 X clock_t, div_t, FILE, fpos_t, lconv, ldiv_t, mbstate_t,
84 X ptrdiff_t, sig_atomic_t, size_t, time_t, tm, va_list,
85 X wctrans_t, wctype_t, and wint_t.
87 1 Which of the functions in the C++ Standard Library are not reentrant
88 subroutines is implementation-defined.
90 18.1 Types [lib.support.types]
91 X <cstddef>
92 X NULL
93 X offsetof
94 X ptrdiff_t
95 X size_t
97 18.2 Implementation properties [lib.support.limits]
99 <limits>, <climits>, and <cfloat>
101 18.2.1 Numeric limits [lib.limits]
103 X template<class T> class numeric_limits;
105 T enum float_round_style;
106 T enum float_denorm_style;
108 T template<> class numeric_limits<bool>;
110 T template<> class numeric_limits<char>;
111 T template<> class numeric_limits<signed char>;
112 T template<> class numeric_limits<unsigned char>;
113 T template<> class numeric_limits<wchar_t>;
115 T template<> class numeric_limits<short>;
116 T template<> class numeric_limits<int>;
117 T template<> class numeric_limits<long>;
118 T template<> class numeric_limits<unsigned short>;
119 T template<> class numeric_limits<unsigned int>;
120 T template<> class numeric_limits<unsigned long>;
122 X template<> class numeric_limits<float>;
123 X template<> class numeric_limits<double>;
124 X template<> class numeric_limits<long double>;
126 18.2.1.1 Template class numeric_limits [lib.numeric.limits]
127 T template<class T> class numeric_limits {
128 public:
129 T static const bool is_specialized = false;
130 T static T min() throw();
131 T static T max() throw();
132 T static const int digits = 0;
133 T static const int digits10 = 0;
134 T static const bool is_signed = false;
135 T static const bool is_integer = false;
136 T static const bool is_exact = false;
137 T static const int radix = 0;
138 T static T epsilon() throw();
139 T static T round_error() throw();
141 T static const int min_exponent = 0;
142 T static const int min_exponent10 = 0;
143 T static const int max_exponent = 0;
144 T static const int max_exponent10 = 0;
146 T static const bool has_infinity = false;
147 T static const bool has_quiet_NaN = false;
148 T static const bool has_signaling_NaN = false;
149 T static const float_denorm_style has_denorm = denorm_absent;
150 T static const bool has_denorm_loss = false;
151 T static T infinity() throw();
152 T static T quiet_NaN() throw();
153 T static T signaling_NaN() throw();
154 T static T denorm_min() throw();
156 T static const bool is_iec559 = false;
157 T static const bool is_bounded = false;
158 T static const bool is_modulo = false;
160 T static const bool traps = false;
161 T static const bool tinyness_before = false;
162 T static const float_round_style round_style = round_toward_zero;
165 18.2.1.3 Type float_round_style [lib.round.style]
167 T enum float_round_style {
168 T round_indeterminate = -1,
169 T round_toward_zero = 0,
170 T round_to_nearest = 1,
171 T round_toward_infinity = 2,
172 T round_toward_neg_infinity = 3
175 18.2.1.4 Type float_denorm_style [lib.denorm.style]
177 T enum float_denorm_style {
178 T denorm_indeterminate = -1;
179 T denorm_absent = 0;
180 T denorm present = 1;
183 18.2.1.5 numeric_limits specializations [lib.numeric.special]
185 [Note: see Note at 18.2.1. ]
187 18.2.2 C Library [lib.c.limits]
189 1 Header <climits> (Table 3):
190 CHAR_BIT INT_MAX LONG_MIN SCHAR_MIN UCHAR_MAX USHRT_MAX
191 X CHAR_MAX INT_MIN MB_LEN_MAX SHRT_MAX UINT_MAX
192 CHAR_MIN LONG_MAX SCHAR_MAX SHRT_MIN ULONG_MAX
194 3 Header <cfloat> (Table 4):
196 DBL_DIG DBL_MIN_EXP FLT_MIN_10_EXP LDBL_MAX_10_EXP
197 DBL_EPSILON FLT_DIG FLT_MIN_EXP LDBL_MAX_EXP
198 DBL_MANT_DIG FLT_EPSILON FLT_RADIX LDBL_MIN
199 X DBL_MAX FLT_MANT_DIG FLT_ROUNDS LDBL_MIN_10_EXP
200 DBL_MAX_10_EXP FLT_MAX LDBL_DIG LDBL_MIN_EXP
201 DBL_MAX_EXP FLT_MAX_10_EXP LDBL_EPSILON
202 DBL_MIN FLT_MAX_EXP LDBL_MANT_DIG
203 DBL_MIN_10_EXP FLT_MIN LDBL_MAX
206 1 Header <cstdlib> (partial), Table 5:
207 X EXIT_FAILURE EXIT_SUCCESS
208 abort atexit exit
210 S abort(void)
211 S extern "C" int atexit(void (*f)(void))
212 S extern "C++" int atexit(void (*f)(void))
213 S exit(int status)
215 18.4 Dynamic memory management [lib.support.dynamic]
217 Header <new> synopsis
219 T class bad_alloc;
220 T struct nothrow_t {};
221 T extern const nothrow_t nothrow;
222 T typedef void (*new_handler)();
223 T new_handler set_new_handler(new_handler new_p) throw();
225 T void* operator new(std::size_t size) throw(std::bad_alloc);
226 T void* operator new(std::size_t size, const std::nothrow_t&) throw();
227 T void operator delete(void* ptr) throw();
228 T void operator delete(void* ptr, const std::nothrow_t&) throw();
229 T void* operator new[](std::size_t size) throw(std::bad_alloc);
230 T void* operator new[](std::size_t size, const std::nothrow_t&) throw();
231 T void operator delete[](void* ptr) throw();
232 T void operator delete[](void* ptr, const std::nothrow_t&) throw();
233 T void* operator new (std::size_t size, void* ptr) throw();
234 T void* operator new[](std::size_t size, void* ptr) throw();
235 T void operator delete (void* ptr, void*) throw();
236 T void operator delete[](void* ptr, void*) throw();
238 18.4.2.1 Class bad_alloc [lib.bad.alloc]
240 T class bad_alloc : public exception {
241 public:
242 T bad_alloc() throw();
243 T bad_alloc(const bad_alloc&) throw();
244 T bad_alloc& operator=(const bad_alloc&) throw();
245 T virtual ~bad_alloc() throw();
246 T virtual const char* what() const throw();
250 T new_handler set_new_handler(new_handler new_p) throw();
253 Header <typeinfo> synopsis
255 T class type_info;
256 T class bad_cast;
257 T class bad_typeid;
259 18.5.1 - Class type_info [lib.type.info]
261 T class type_info {
262 public:
263 T virtual ~type_info();
264 T bool operator==(const type_info& rhs) const;
265 T bool operator!=(const type_info& rhs) const;
266 T bool before(const type_info& rhs) const;
267 T const char* name() const;
268 private:
269 T type_info(const type_info& rhs);
270 T type_info& operator=(const type_info& rhs);
273 18.5.2 - Class bad_cast [lib.bad.cast]
275 T bad_cast() throw();
276 T virtual const char* bad_cast::what() const throw();
278 18.5.3 Class bad_typeid [lib.bad.typeid]
280 T class bad_typeid : public exception {
281 public:
282 T bad_typeid() throw();
283 T bad_typeid(const bad_typeid&) throw();
284 T bad_typeid& operator=(const bad_typeid&) throw();
285 T virtual ~bad_typeid() throw();
286 T virtual const char* what() const throw();
289 18.6 Exception handling [lib.support.exception]
291 T Header <exception> synopsis
293 T class exception;
294 T class bad_exception;
296 T typedef void (*unexpected_handler)();
297 T unexpected_handler set_unexpected(unexpected_handler f) throw();
298 T void unexpected();
299 T typedef void (*terminate_handler)();
300 T terminate_handler set_terminate(terminate_handler f) throw();
301 T void terminate();
302 T bool uncaught_exception();
304 18.6.1 Class exception [lib.exception]
306 T class exception {
307 public:
308 T exception() throw();
309 T exception(const exception&) throw();
310 T exception& operator=(const exception&) throw();
311 T virtual ~exception() throw();
312 T virtual const char* what() const throw();
315 18.6.2.1 Class bad_exception [lib.bad.exception]
316 T class bad_exception : public exception {
317 public:
318 T bad_exception() throw();
319 T bad_exception(const bad_exception&) throw();
320 T bad_exception& operator=(const bad_exception&) throw();
321 T virtual ~bad_exception() throw();
322 T virtual const char* what() const throw();
325 18.7 Other runtime support [lib.support.runtime]
327 1 Headers <cstdarg> (variable arguments), <csetjmp> (nonlocal jumps),
328 <ctime> (system clock clock(), time()), <csignal> (signal handling),
329 and <cstdlib> (runtime environment getenv(), system()).
331 Table 6--Header <cstdarg> synopsis
332 Macros: va_arg va_end va_start
333 X Type: va_list
335 Table 7--Header <csetjmp> synopsis
337 Macro: setjmp |
338 X Type: jmp_buf
339 Function: longjmp
341 Table 8--Header <ctime> synopsis
343 Macros: CLOCKS_PER_SEC
344 X Types: clock_t
345 Functions: clock
347 Table 9--Header <csignal> synopsis
349 X Macros: SIGABRT SIGILL SIGSEGV SIG_DFL
350 SIG_IGN SIGFPE SIGINT SIGTERM SIG_ERR
351 Type: sig_atomic_t
352 Functions: raise signal
354 Table 10--Header <cstdlib> synopsis
356 X Functions: getenv system
358 19.1 Exception classes [lib.std.exceptions]
360 Header <stdexcept> synopsis
362 T class logic_error;
363 T class domain_error;
364 T class invalid_argument;
365 T class length_error;
366 T class out_of_range;
367 T class runtime_error;
368 T class range_error;
369 T class overflow_error;
370 T class underflow_error;
372 19.1.1 Class logic_error [lib.logic.error]
373 T class logic_error : public exception {
374 public:
375 T explicit logic_error(const string& what_arg);
378 19.1.2 Class domain_error [lib.domain.error]
380 T class domain_error : public logic_error {
381 public:
382 T explicit domain_error(const string& what_arg);
385 19.1.3 Class invalid_argument [lib.invalid.argument]
387 T class invalid_argument : public logic_error {
388 public:
389 T explicit invalid_argument(const string& what_arg);
392 19.1.4 Class length_error [lib.length.error]
394 T class length_error : public logic_error {
395 public:
396 T explicit length_error(const string& what_arg);
399 19.1.5 Class out_of_range [lib.out.of.range]
401 T class out_of_range : public logic_error {
402 public:
403 T explicit out_of_range(const string& what_arg);
407 19.1.6 Class runtime_error [lib.runtime.error]
409 T class runtime_error : public exception {
410 public:
411 T explicit runtime_error(const string& what_arg);
415 19.1.7 Class range_error [lib.range.error]
417 T class range_error : public runtime_error {
418 public:
419 T explicit range_error(const string& what_arg);
422 19.1.8 Class overflow_error [lib.overflow.error]
424 T class overflow_error : public runtime_error {
425 public:
426 T explicit overflow_error(const string& what_arg);
430 19.1.9 Class underflow_error [lib.underflow.error]
432 T class underflow_error : public runtime_error {
433 public:
434 T explicit underflow_error(const string& what_arg);
438 19.2 Assertions [lib.assertions]
440 Table 2--Header <cassert> synopsis
442 X Macro: assert
444 19.3 Error numbers [lib.errno]
446 Table 3--Header <cerrno> synopsis
448 X |Macros: EDOM ERANGE errno |
451 20.2 Utility components [lib.utility]
453 Header <utility> synopsis
455 // _lib.operators_, operators:
456 T namespace rel_ops {
457 T template<class T> bool operator!=(const T&, const T&);
458 T template<class T> bool operator> (const T&, const T&);
459 T template<class T> bool operator<=(const T&, const T&);
460 T template<class T> bool operator>=(const T&, const T&);
462 // _lib.pairs_, pairs:
463 T template <class T1, class T2> struct pair;
464 T template <class T1, class T2>
465 bool operator==(const pair<T1,T2>&, const pair<T1,T2>&);
466 T template <class T1, class T2>
467 bool operator< (const pair<T1,T2>&, const pair<T1,T2>&);
468 T template <class T1, class T2>
469 bool operator!=(const pair<T1,T2>&, const pair<T1,T2>&);
470 T template <class T1, class T2>
471 bool operator> (const pair<T1,T2>&, const pair<T1,T2>&);
472 T template <class T1, class T2>
473 bool operator>=(const pair<T1,T2>&, const pair<T1,T2>&);
474 T template <class T1, class T2>
475 bool operator<=(const pair<T1,T2>&, const pair<T1,T2>&);
476 T template <class T1, class T2> pair<T1,T2> make_pair(const T1&, const T2&);
479 20.2.2 Pairs [lib.pairs]
481 T template <class T1, class T2>
482 struct pair {
483 T typedef T1 first_type;
484 T typedef T2 second_type;
486 T T1 first;
487 T T2 second;
488 T pair();
489 T pair(const T1& x, const T2& y);
490 T template<class U, class V> pair(const pair<U, V> &p);
493 20.3 Function objects [lib.function.objects]
495 Header <functional> synopsis
497 // _lib.base_, base:
498 V template <class Arg, class Result> struct unary_function;
499 V template <class Arg1, class Arg2, class Result> struct binary_function;
501 // _lib.arithmetic.operations_, arithmetic operations:
502 V template <class T> struct plus;
503 V template <class T> struct minus;
504 V template <class T> struct multiplies;
505 V template <class T> struct divides;
506 V template <class T> struct modulus;
507 V template <class T> struct negate;
508 // _lib.comparisons_, comparisons:
509 V template <class T> struct equal_to;
510 V template <class T> struct not_equal_to;
511 V template <class T> struct greater;
512 V template <class T> struct less;
513 V template <class T> struct greater_equal;
514 V template <class T> struct less_equal;
515 // _lib.logical.operations_, logical operations:
516 V template <class T> struct logical_and;
517 V template <class T> struct logical_or;
518 V template <class T> struct logical_not;
519 // _lib.negators_, negators:
520 template <class Predicate> struct unary_negate;
521 V template <class Predicate>
522 unary_negate<Predicate> not1(const Predicate&);
523 V template <class Predicate> struct binary_negate;
524 V template <class Predicate>
525 binary_negate<Predicate> not2(const Predicate&);
526 // _lib.binders_, binders:
527 V template <class Operation> class binder1st;
528 V template <class Operation, class T>
529 binder1st<Operation> bind1st(const Operation&, const T&);
530 V template <class Operation> class binder2nd;
531 V template <class Operation, class T>
532 binder2nd<Operation> bind2nd(const Operation&, const T&);
533 // _lib.function.pointer.adaptors_, adaptors:
534 V template <class Arg, class Result> class pointer_to_unary_function;
535 V template <class Arg, class Result>
536 pointer_to_unary_function<Arg,Result> ptr_fun(Result (*)(Arg));
537 V template <class Arg1, class Arg2, class Result>
538 class pointer_to_binary_function;
539 V template <class Arg1, class Arg2, class Result>
540 pointer_to_binary_function<Arg1,Arg2,Result>
541 ptr_fun(Result (*)(Arg1,Arg2));
543 // _lib.member.pointer.adaptors_, adaptors:
544 V template<class S, class T> class mem_fun_t;
545 V template<class S, class T, class A> class mem_fun1_t;
546 V template<class S, class T>
547 mem_fun_t<S,T> mem_fun(S (T::*f)());
548 V template<class S, class T, class A>
549 mem_fun1_t<S,T,A> mem_fun(S (T::*f)(A));
550 V template<class S, class T> class mem_fun_ref_t;
551 V template<class S, class T, class A> class mem_fun1_ref_t;
552 V template<class S, class T>
553 mem_fun_ref_t<S,T> mem_fun_ref(S (T::*f)());
554 V template<class S, class T, class A>
555 mem_fun1_ref_t<S,T,A> mem_fun_ref(S (T::*f)(A));
557 V template <class S, class T> class const_mem_fun_t;
558 V template <class S, class T, class A> class const_mem_fun1_t;
559 V template <class S, class T>
560 const_mem_fun_t<S,T> mem_fun(S (T::*f)() const);
561 V template <class S, class T, class A>
562 const_mem_fun1_t<S,T,A> mem_fun(S (T::*f)(A) const);
563 V template <class S, class T> class const_mem_fun_ref_t;
564 V template <class S, class T, class A> class const_mem_fun1_ref_t;
565 V template <class S, class T>
566 const_mem_fun_ref_t<S,T> mem_fun_ref(S (T::*f)() const);
567 V template <class S, class T, class A>
568 const_mem_fun1_ref_t<S,T,A> mem_fun_ref(S (T::*f)(A) const);
571 20.3.1 Base [lib.base]
573 V template <class Arg, class Result>
574 struct unary_function {
575 V typedef Arg argument_type;
576 V typedef Result result_type;
578 V template <class Arg1, class Arg2, class Result>
579 struct binary_function {
580 V typedef Arg1 first_argument_type;
581 V typedef Arg2 second_argument_type;
582 V typedef Result result_type;
585 20.3.2 Arithmetic operations [lib.arithmetic.operations]
587 T template <class T> struct plus : binary_function<T,T,T> {
588 V T operator()(const T& x, const T& y) const;
591 T template <class T> struct minus : binary_function<T,T,T> {
592 V T operator()(const T& x, const T& y) const;
595 T template <class T> struct multiplies : binary_function<T,T,T> {
596 V T operator()(const T& x, const T& y) const;
599 T template <class T> struct divides : binary_function<T,T,T> {
600 V T operator()(const T& x, const T& y) const;
603 T template <class T> struct modulus : binary_function<T,T,T> {
604 V T operator()(const T& x, const T& y) const;
607 T template <class T> struct negate : unary_function<T,T> {
608 V T operator()(const T& x) const;
611 20.3.3 Comparisons [lib.comparisons]
613 T template <class T> struct equal_to : binary_function<T,T,bool> {
614 V bool operator()(const T& x, const T& y) const;
617 T template <class T> struct not_equal_to : binary_function<T,T,bool> {
618 V bool operator()(const T& x, const T& y) const;
621 T template <class T> struct greater : binary_function<T,T,bool> {
622 V bool operator()(const T& x, const T& y) const;
625 T template <class T> struct less : binary_function<T,T,bool> {
626 V bool operator()(const T& x, const T& y) const;
629 T template <class T> struct greater_equal : binary_function<T,T,bool> {
630 V bool operator()(const T& x, const T& y) const;
633 T template <class T> struct less_equal : binary_function<T,T,bool> {
634 V bool operator()(const T& x, const T& y) const;
637 20.3.4 Logical operations [lib.logical.operations]
639 T template <class T> struct logical_and : binary_function<T,T,bool> {
640 V bool operator()(const T& x, const T& y) const;
643 T template <class T> struct logical_or : binary_function<T,T,bool> {
644 V bool operator()(const T& x, const T& y) const;
647 T template <class T> struct logical_not : unary_function<T,bool> {
648 V bool operator()(const T& x) const;
651 20.3.5 Negators [lib.negators]
653 T template <class Predicate>
654 class unary_negate
655 : public unary_function<typename Predicate::argument_type,bool> {
656 public:
657 T explicit unary_negate(const Predicate& pred);
658 V bool operator()(const typename Predicate::argument_type& x) const;
661 T template <class Predicate>
662 class binary_negate
663 : public binary_function<typename Predicate::first_argument_type,
664 typename Predicate::second_argument_type, bool> {
665 public:
666 T explicit binary_negate(const Predicate& pred);
667 V bool operator()(const typename Predicate::first_argument_type& x,
668 const typename Predicate::second_argument_type& y) const;
672 20.3.6 Binders [lib.binders]
674 20.3.6.1 Template class binder1st [lib.binder.1st]
675 T template <class Operation>
676 class binder1st
677 : public unary_function<typename Operation::second_argument_type,
678 typename Operation::result_type> {
679 protected:
680 T Operation op;
681 T typename Operation::first_argument_type value;
682 public:
683 V binder1st(const Operation& x,
684 const typename Operation::first_argument_type& y);
685 V typename Operation::result_type
686 operator()(const typename Operation::second_argument_type& x) const;
689 20.3.6.2 bind1st [lib.bind.1st]
691 V template <class Operation, class T>
692 binder1st<Operation> bind1st(const Operation& op, const T& x);
694 20.3.6.3 Template class binder2nd [lib.binder.2nd]
695 T template <class Operation>
696 class binder2nd
697 : public unary_function<typename Operation::first_argument_type,
698 typename Operation::result_type> {
699 protected:
700 T Operation op;
701 T typename Operation::second_argument_type value;
702 public:
703 V binder2nd(const Operation& x,
704 const typename Operation::second_argument_type& y);
705 V typename Operation::result_type
706 operator()(const typename Operation::first_argument_type& x) const;
709 20.3.6.4 bind2nd [lib.bind.2nd]
711 T template <class Operation, class T>
712 binder2nd<Operation> bind2nd(const Operation& op, const T& x);
715 20.3.7 Adaptors for pointers to [lib.function.pointer.adaptors]
716 functions
718 1 To allow pointers to (unary and binary) functions to work with func-
719 tion adaptors the library provides:
721 T template <class Arg, class Result>
722 class pointer_to_unary_function : public unary_function<Arg, Result> {
723 public:
724 T explicit pointer_to_unary_function(Result (*f)(Arg));
725 V Result operator()(Arg x) const;
728 T template <class Arg, class Result>
729 pointer_to_unary_function<Arg, Result> ptr_fun(Result (*f)(Arg));
731 T template <class Arg1, class Arg2, class Result>
732 class pointer_to_binary_function :
733 public binary_function<Arg1,Arg2,Result> {
734 public:
735 T explicit pointer_to_binary_function(Result (*f)(Arg1, Arg2));
736 V Result operator()(Arg1 x, Arg2 y) const;
740 20.3.8 Adaptors for pointers to [lib.member.pointer.adaptors]
741 members
743 T template <class S, class T> class mem_fun_t
744 : public unary_function<T*, S> {
745 public:
746 T explicit mem_fun_t(S (T::*p)());
747 V S operator()(T* p) const;
750 T template <class S, class T, class A> class mem_fun1_t
751 : public binary_function<T*, A, S> {
752 public:
753 T explicit mem_fun1_t(S (T::*p)(A));
754 V S operator()(T* p, A x) const;
757 V template<class S, class T> mem_fun_t<S,T>
758 mem_fun(S (T::*f)());
759 V template<class S, class T, class A> mem_fun1_t<S,T,A>
760 mem_fun(S (T::*f)(A));
762 T template <class S, class T> class mem_fun_ref_t
763 : public unary_function<T, S> {
764 public:
765 T explicit mem_fun_ref_t(S (T::*p)());
766 V S operator()(T& p) const;
769 T template <class S, class T, class A> class mem_fun1_ref_t
770 : public binary_function<T, A, S> {
771 public:
772 T explicit mem_fun1_ref_t(S (T::*p)(A));
773 V S operator()(T& p, A x) const;
776 T template<class S, class T> mem_fun_ref_t<S,T>
777 mem_fun_ref(S (T::*f)());
779 T template<class S, class T, class A> mem_fun1_ref_t<S,T,A>
780 mem_fun_ref(S (T::*f)(A));
782 T template <class S, class T> class const_mem_fun_t
783 : public unary_function<T*, S> {
784 public:
785 T explicit const_mem_fun_t(S (T::*p)() const);
786 V S operator()(const T* p) const;
789 T template <class S, class T, class A> class const_mem_fun1_t
790 : public binary_function<T*, A, S> {
791 public:
792 T explicit const mem_fun1_t(S (T::*p)(A) const);
793 V S operator()(const T* p, A x) const;
796 V template<class S, class T> const_mem_fun_t<S,T>
797 mem_fun(S (T::*f)() const);
798 V template<class S, class T, class A> const_mem_fun1_t<S,T,A>
799 mem_fun(S (T::*f)(A) const);
801 T template <class S, class T> class const_mem_fun_ref_t
802 : public unary_function<T, S> {
803 public:
804 T explicit const_mem_fun_ref_t(S (T::*p)() const);
805 V S operator()(const T& p) const;
808 T template <class S, class T, class A> class const_mem_fun1_ref_t
809 : public binary_function<T, A, S> {
810 public:
811 T explicit const_mem_fun1_ref_t(S (T::*p)(A) const);
812 V S operator()(const T& p, A x) const;
815 T template<class S, class T> const_mem_fun_ref_t<S,T>
816 mem_fun_ref(S (T::*f)() const);
818 T template<class S, class T, class A> const_mem_fun1_ref_t<S,T,A>
819 mem_fun_ref(S (T::*f)(A) const);
821 20.4 Memory [lib.memory]
823 Header <memory> synopsis
825 // _lib.default.allocator_, the default allocator:
826 T template <class T> class allocator;
827 T template <> class allocator<void>;
828 T template <class T, class U>
829 bool operator==(const allocator<T>&, const allocator<U>&) throw();
830 T template <class T, class U>
831 bool operator!=(const allocator<T>&, const allocator<U>&) throw();
832 // _lib.storage.iterator_, raw storage iterator:
833 T template <class OutputIterator, class T> class raw_storage_iterator;
834 // _lib.temporary.buffer_, temporary buffers:
835 T template <class T>
836 pair<T*,ptrdiff_t> get_temporary_buffer(ptrdiff_t n);
837 T template <class T>
838 void return_temporary_buffer(T* p);
839 // _lib.specialized.algorithms_, specialized algorithms:
840 T template <class InputIterator, class ForwardIterator>
841 ForwardIterator
842 uninitialized_copy(InputIterator first, InputIterator last,
843 ForwardIterator result);
844 T template <class ForwardIterator, class T>
845 void uninitialized_fill(ForwardIterator first, ForwardIterator last,
846 const T& x);
847 T template <class ForwardIterator, class Size, class T>
848 void uninitialized_fill_n(ForwardIterator first, Size n, const T& x);
849 // _lib.auto.ptr_, pointers:
850 X template<class X> class auto_ptr;
853 20.4.1 The default allocator [lib.default.allocator]
855 T template <class T> class allocator;
856 // specialize for void:
857 T template <> class allocator<void> {
858 public:
859 T typedef void* pointer;
860 T typedef const void* const_pointer;
861 // reference-to-void members are impossible.
862 T typedef void value_type;
863 T template <class U> struct rebind { typedef allocator<U> other; };
866 T template <class T> class allocator {
867 public:
868 T typedef size_t size_type;
869 T typedef ptrdiff_t difference_type;
870 T typedef T* pointer;
871 T typedef const T* const_pointer;
872 T typedef T& reference;
873 T typedef const T& const_reference;
874 T typedef T value_type;
875 T template <class U> struct rebind { typedef allocator<U> other; };
876 T allocator() throw();
877 T allocator(const allocator&) throw();
878 T template <class U> allocator(const allocator<U>&) throw();
879 T ~allocator() throw();
880 T pointer address(reference x) const;
881 T const_pointer address(const_reference x) const;
882 T pointer allocate(
883 size_type, allocator<void>::const_pointer hint = 0);
884 T void deallocate(pointer p, size_type n);
885 T size_type max_size() const throw();
886 T void construct(pointer p, const T& val);
887 T void destroy(pointer p);
890 20.4.1.2 allocator globals [lib.allocator.globals]
892 T template <class T1, class T2>
893 bool operator==(const allocator<T1>&, const allocator<T2>&) throw();
894 T template <class T1, class T2>
895 bool operator!=(const allocator<T1>&, const allocator<T2>&) throw();
897 20.4.2 Raw storage iterator [lib.storage.iterator]
899 T template <class OutputIterator, class T>
900 class raw_storage_iterator
901 : public iterator<output_iterator_tag,void,void,void,void> {
902 public:
903 T explicit raw_storage_iterator(OutputIterator x);
904 T raw_storage_iterator<OutputIterator,T>& operator*();
905 T raw_storage_iterator<OutputIterator,T>& operator=(const T& element);
906 T raw_storage_iterator<OutputIterator,T>& operator++();
907 T raw_storage_iterator<OutputIterator,T> operator++(int);
910 20.4.3 Temporary buffers [lib.temporary.buffer]
912 T template <class T>
913 pair<T*, ptrdiff_t> get_temporary_buffer(ptrdiff_t n);
915 T template <class T> void return_temporary_buffer(T* p);
917 20.4.4 Specialized algorithms [lib.specialized.algorithms]
919 20.4.4.1 uninitialized_copy [lib.uninitialized.copy]
921 V template <class InputIterator, class ForwardIterator>
922 ForwardIterator
923 uninitialized_copy(InputIterator first, InputIterator last,
924 ForwardIterator result);
926 20.4.4.2 uninitialized_fill [lib.uninitialized.fill]
928 V template <class ForwardIterator, class T>
929 void uninitialized_fill(ForwardIterator first, ForwardIterator last,
930 const T& x);
932 20.4.4.3 uninitialized_fill_n [lib.uninitialized.fill.n]
934 V template <class ForwardIterator, class Size, class T>
935 void uninitialized_fill_n(ForwardIterator first, Size n, const T& x);
937 20.4.5 Template class auto_ptr [lib.auto.ptr]
939 X template<class X> class auto_ptr {
940 template <class Y> struct auto_ptr_ref {};
941 public:
942 T typedef X element_type;
943 // _lib.auto.ptr.cons_ construct/copy/destroy:
944 T explicit auto_ptr(X* p =0) throw();
945 T auto_ptr(auto_ptr&) throw();
946 T template<class Y> auto_ptr(auto_ptr<Y>&) throw();
947 T auto_ptr& operator=(auto_ptr&) throw();
948 T template<class Y> auto_ptr& operator=(auto_ptr<Y>&) throw();
949 T ~auto_ptr() throw();
950 // _lib.auto.ptr.members_ members:
951 T X& operator*() const throw();
952 T X* operator->() const throw();
953 T X* get() const throw();
954 T X* release() throw();
955 T void reset(X* p =0) throw();
957 // _lib.auto.ptr.conv_ conversions:
958 X auto_ptr(auto_ptr_ref<X>) throw();
959 X template<class Y> operator auto_ptr_ref<Y>() throw();
960 X template<class Y> operator auto_ptr<Y>() throw();
963 20.4.6 C Library [lib.c.malloc]
965 Table 7--Header <cstdlib> synopsis
967 X Functions: calloc malloc
968 free realloc
971 Table 8--Header <cstring> synopsis
973 X Macro: NULL
974 X Type: size_t
975 X Functions: memchr memcmp
976 X memcpy memmove memset
978 Table 9--Header <ctime> synopsis
980 X Macros: NULL
981 X Types: size_t clock_t time_t
982 X Struct: tm
983 Functions:
984 X asctime clock difftime localtime strftime
985 X ctime gmtime mktime time
987 21.1.1 Character traits requirements [lib.char.traits.require]
989 2 The struct template
990 T template<class charT> struct char_traits;
991 shall be provided in the header <string> as a basis for explicit spe-
992 cializations.
995 21.1.3.1 struct [lib.char.traits.specializations.char]
996 char_traits<char>
998 T template<>
999 struct char_traits<char> {
1000 T typedef char char_type;
1001 T typedef int int_type;
1002 T typedef streamoff off_type;
1003 T typedef streampos pos_type;
1004 T typedef mbstate_t state_type;
1006 T static void assign(char_type& c1, const char_type& c2);
1007 T static bool eq(const char_type& c1, const char_type& c2);
1008 T static bool lt(const char_type& c1, const char_type& c2);
1010 T static int compare(const char_type* s1, const char_type* s2, size_t n);
1011 T static size_t length(const char_type* s);
1012 T static const char_type* find(const char_type* s, size_t n,
1013 const char_type& a);
1014 T static char_type* move(char_type* s1, const char_type* s2, size_t n);
1015 T static char_type* copy(char_type* s1, const char_type* s2, size_t n);
1016 T static char_type* assign(char_type* s, size_t n, char_type a);
1018 T static int_type not_eof(const int_type& c);
1019 T static char_type to_char_type(const int_type& c);
1020 T static int_type to_int_type(const char_type& c);
1021 T static bool eq_int_type(const int_type& c1, const int_type& c2);
1022 T static int_type eof();
1025 21.1.3.2 struct [lib.char.traits.specializations.wchar.t]
1026 char_traits<wchar_t>
1028 V template<>
1029 struct char_traits<wchar_t> {
1030 V typedef wchar_t char_type;
1031 V typedef wint_t int_type;
1032 V typedef streamoff off_type;
1033 V typedef wstreampos pos_type;
1034 V typedef mbstate_t state_type;
1036 V static void assign(char_type& c1, const char_type& c2);
1037 V static bool eq(const char_type& c1, const char_type& c2);
1038 V static bool lt(const char_type& c1, const char_type& c2);
1040 V static int compare(const char_type* s1, const char_type* s2, size_t n);
1041 V static size_t length(const char_type* s);
1042 V static const char_type* find(const char_type* s, size_t n,
1043 const char_type& a);
1044 V static char_type* move(char_type* s1, const char_type* s2, size_t n);
1045 V static char_type* copy(char_type* s1, const char_type* s2, size_t n);
1046 V static char_type* assign(char_type* s, size_t n, char_type a);
1048 V static int_type not_eof(const int_type& c);
1049 V static char_type to_char_type(const int_type& c);
1050 V static int_type to_int_type(const char_type& c);
1051 V static bool eq_int_type(const int_type& c1, const int_type& c2);
1052 V static int_type eof();
1055 21.2 String classes [lib.string.classes]
1057 // _lib.char.traits_, character traits:
1058 V template<class charT>
1059 struct char_traits;
1060 V template <> struct char_traits<char>;
1061 V template <> struct char_traits<wchar_t>;
1063 // _lib.basic.string_, basic_string:
1064 V template<class charT, class traits = char_traits<charT>,
1065 class Allocator = allocator<charT> >
1066 class basic_string;
1067 V template<class charT, class traits, class Allocator>
1068 basic_string<charT,traits,Allocator>
1069 operator+(const basic_string<charT,traits,Allocator>& lhs,
1070 const basic_string<charT,traits,Allocator>& rhs);
1071 V template<class charT, class traits, class Allocator>
1072 basic_string<charT,traits,Allocator>
1073 operator+(const charT* lhs,
1074 const basic_string<charT,traits,Allocator>& rhs);
1075 V template<class charT, class traits, class Allocator>
1076 basic_string<charT,traits,Allocator>
1077 operator+(charT lhs, const basic_string<charT,traits,Allocator>& rhs);
1078 V template<class charT, class traits, class Allocator>
1079 basic_string<charT,traits,Allocator>
1080 operator+(const basic_string<charT,traits,Allocator>& lhs,
1081 const charT* rhs);
1082 V template<class charT, class traits, class Allocator>
1083 basic_string<charT,traits,Allocator>
1084 operator+(const basic_string<charT,traits,Allocator>& lhs, charT rhs);
1086 V template<class charT, class traits, class Allocator>
1087 bool operator==(const basic_string<charT,traits,Allocator>& lhs,
1088 const basic_string<charT,traits,Allocator>& rhs);
1089 V template<class charT, class traits, class Allocator>
1090 bool operator==(const charT* lhs,
1091 const basic_string<charT,traits,Allocator>& rhs);
1092 V template<class charT, class traits, class Allocator>
1093 bool operator==(const basic_string<charT,traits,Allocator>& lhs,
1094 const charT* rhs);
1095 V template<class charT, class traits, class Allocator>
1096 bool operator!=(const basic_string<charT,traits,Allocator>& lhs,
1097 const basic_string<charT,traits,Allocator>& rhs);
1098 V template<class charT, class traits, class Allocator>
1099 bool operator!=(const charT* lhs,
1100 const basic_string<charT,traits,Allocator>& rhs);
1101 V template<class charT, class traits, class Allocator>
1102 bool operator!=(const basic_string<charT,traits,Allocator>& lhs,
1103 const charT* rhs);
1104 V template<class charT, class traits, class Allocator>
1105 bool operator< (const basic_string<charT,traits,Allocator>& lhs,
1106 const basic_string<charT,traits,Allocator>& rhs);
1107 V template<class charT, class traits, class Allocator>
1108 bool operator< (const basic_string<charT,traits,Allocator>& lhs,
1109 const charT* rhs);
1110 V template<class charT, class traits, class Allocator>
1111 bool operator< (const charT* lhs,
1112 const basic_string<charT,traits,Allocator>& rhs);
1113 V template<class charT, class traits, class Allocator>
1114 bool operator> (const basic_string<charT,traits,Allocator>& lhs,
1115 const basic_string<charT,traits,Allocator>& rhs);
1116 V template<class charT, class traits, class Allocator>
1117 bool operator> (const basic_string<charT,traits,Allocator>& lhs,
1118 const charT* rhs);
1119 V template<class charT, class traits, class Allocator>
1120 bool operator> (const charT* lhs,
1121 const basic_string<charT,traits,Allocator>& rhs);
1122 V template<class charT, class traits, class Allocator>
1123 bool operator<=(const basic_string<charT,traits,Allocator>& lhs,
1124 const basic_string<charT,traits,Allocator>& rhs);
1125 V template<class charT, class traits, class Allocator>
1126 bool operator<=(const basic_string<charT,traits,Allocator>& lhs,
1127 const charT* rhs);
1128 V template<class charT, class traits, class Allocator>
1129 bool operator<=(const charT* lhs,
1130 const basic_string<charT,traits,Allocator>& rhs);
1131 V template<class charT, class traits, class Allocator>
1132 bool operator>=(const basic_string<charT,traits,Allocator>& lhs,
1133 const basic_string<charT,traits,Allocator>& rhs);
1134 V template<class charT, class traits, class Allocator>
1135 bool operator>=(const basic_string<charT,traits,Allocator>& lhs,
1136 const charT* rhs);
1137 V template<class charT, class traits, class Allocator>
1138 bool operator>=(const charT* lhs,
1139 const basic_string<charT,traits,Allocator>& rhs);
1141 // _lib.string.special_:
1142 V template<class charT, class traits, class Allocator>
1143 void swap(basic_string<charT,traits,Allocator>& lhs,
1144 basic_string<charT,traits,Allocator>& rhs);
1145 V template<class charT, class traits, class Allocator>
1146 basic_istream<charT,traits>&
1147 operator>>(basic_istream<charT,traits>& is,
1148 basic_string<charT,traits,Allocator>& str);
1149 T template<class charT, class traits, class Allocator>
1150 basic_ostream<charT, traits>&
1151 operator<<(basic_ostream<charT, traits>& os,
1152 const basic_string<charT,traits,Allocator>& str);
1153 V template<class charT, class traits, class Allocator>
1154 basic_istream<charT,traits>&
1155 getline(basic_istream<charT,traits>& is,
1156 basic_string<charT,traits,Allocator>& str,
1157 charT delim);
1158 V template<class charT, class traits, class Allocator>
1159 basic_istream<charT,traits>&
1160 getline(basic_istream<charT,traits>& is,
1161 basic_string<charT,traits,Allocator>& str);
1162 V typedef basic_string<char> string;
1163 T typedef basic_string<wchar_t> wstring;
1166 21.3 Template class basic_string [lib.basic.string]
1168 V namespace std {
1169 template<class charT, class traits = char_traits<charT>,
1170 class Allocator = allocator<charT> >
1171 class basic_string {
1172 public:
1173 // types:
1174 typedef traits traits_type;
1175 typedef typename traits::char_type value_type;
1176 typedef Allocator allocator_type;
1177 typedef typename Allocator::size_type size_type;
1178 typedef typename Allocator::difference_type difference_type;
1179 typedef typename Allocator::reference reference;
1180 typedef typename Allocator::const_reference const_reference;
1181 typedef typename Allocator::pointer pointer;
1182 typedef typename Allocator::const_pointer const_pointer;
1183 typedef implementation defined iterator;
1184 typedef implementation defined const_iterator;
1185 typedef std::reverse_iterator<iterator> reverse_iterator;
1186 typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
1187 static const size_type npos = -1;
1189 // _lib.string.cons_ construct/copy/destroy:
1190 V explicit basic_string(const Allocator& a = Allocator());
1191 V basic_string(const basic_string& str, size_type pos = 0,
1192 size_type n = npos, const Allocator& a = Allocator());
1193 V basic_string(const charT* s,
1194 size_type n, const Allocator& a = Allocator());
1195 V basic_string(const charT* s, const Allocator& a = Allocator());
1196 V basic_string(size_type n, charT c, const Allocator& a = Allocator());
1197 V template<class InputIterator>
1198 basic_string(InputIterator begin, InputIterator end,
1199 const Allocator& a = Allocator());
1200 V ~basic_string();
1201 V basic_string& operator=(const basic_string& str);
1202 V basic_string& operator=(const charT* s);
1203 V basic_string& operator=(charT c);
1204 // _lib.string.iterators_ iterators:
1205 V iterator begin();
1206 V const_iterator begin() const;
1207 V iterator end();
1208 V const_iterator end() const;
1210 V reverse_iterator rbegin();
1211 V const_reverse_iterator rbegin() const;
1212 V reverse_iterator rend();
1213 V const_reverse_iterator rend() const;
1214 // _lib.string.capacity_ capacity:
1215 V size_type size() const;
1216 V size_type length() const;
1217 V size_type max_size() const;
1218 V void resize(size_type n, charT c);
1219 V void resize(size_type n);
1220 V size_type capacity() const;
1221 V void reserve(size_type res_arg = 0);
1222 V void clear();
1223 V bool empty() const;
1224 // _lib.string.access_ element access:
1225 V const_reference operator[](size_type pos) const;
1226 V reference operator[](size_type pos);
1227 V const_reference at(size_type n) const;
1228 V reference at(size_type n);
1229 // _lib.string.modifiers_ modifiers:
1230 V basic_string& operator+=(const basic_string& str);
1231 V basic_string& operator+=(const charT* s);
1232 V basic_string& operator+=(charT c);
1233 V basic_string& append(const basic_string& str);
1234 V basic_string& append(const basic_string& str, size_type pos,
1235 size_type n);
1236 V basic_string& append(const charT* s, size_type n);
1237 V basic_string& append(const charT* s);
1238 V basic_string& append(size_type n, charT c);
1239 V template<class InputIterator>
1240 basic_string& append(InputIterator first, InputIterator last);
1241 V void push_back(const charT);
1243 V basic_string& assign(const basic_string&);
1244 V basic_string& assign(const basic_string& str, size_type pos,
1245 size_type n);
1246 V basic_string& assign(const charT* s, size_type n);
1247 V basic_string& assign(const charT* s);
1248 V basic_string& assign(size_type n, charT c);
1249 V template<class InputIterator>
1250 basic_string& assign(InputIterator first, InputIterator last);
1251 V basic_string& insert(size_type pos1, const basic_string& str);
1252 V basic_string& insert(size_type pos1, const basic_string& str,
1253 size_type pos2, size_type n);
1254 V basic_string& insert(size_type pos, const charT* s, size_type n);
1255 V basic_string& insert(size_type pos, const charT* s);
1256 V basic_string& insert(size_type pos, size_type n, charT c);
1257 V iterator insert(iterator p, charT c);
1258 V void insert(iterator p, size_type n, charT c);
1259 V template<class InputIterator>
1260 void insert(iterator p, InputIterator first, InputIterator last);
1261 V basic_string& erase(size_type pos = 0, size_type n = npos);
1262 V iterator erase(iterator position);
1263 V iterator erase(iterator first, iterator last);
1264 V basic_string& replace(size_type pos1, size_type n1,
1265 const basic_string& str);
1266 V basic_string& replace(size_type pos1, size_type n1,
1267 const basic_string& str,
1268 size_type pos2, size_type n2);
1269 V basic_string& replace(size_type pos, size_type n1, const charT* s,
1270 size_type n2);
1271 V basic_string& replace(size_type pos, size_type n1, const charT* s);
1272 V basic_string& replace(size_type pos, size_type n1, size_type n2,
1273 charT c);
1274 V basic_string& replace(iterator i1, iterator i2, const basic_string& str);
1275 V basic_string& replace(iterator i1, iterator i2, const charT* s,
1276 size_type n);
1277 V basic_string& replace(iterator i1, iterator i2, const charT* s);
1278 V basic_string& replace(iterator i1, iterator i2,
1279 size_type n, charT c);
1280 V template<class InputIterator>
1281 basic_string& replace(iterator i1, iterator i2,
1282 InputIterator j1, InputIterator j2);
1283 V size_type copy(charT* s, size_type n, size_type pos = 0) const;
1284 V void swap(basic_string<charT,traits,Allocator>&);
1285 // _lib.string.ops_ string operations:
1286 V const charT* c_str() const; // explicit
1287 V const charT* data() const;
1288 V allocator_type get_allocator() const;
1289 V size_type find (const basic_string& str, size_type pos = 0) const;
1290 V size_type find (const charT* s, size_type pos, size_type n) const;
1291 V size_type find (const charT* s, size_type pos = 0) const;
1292 V size_type find (charT c, size_type pos = 0) const;
1293 V size_type rfind(const basic_string& str, size_type pos = npos) const;
1294 V size_type rfind(const charT* s, size_type pos, size_type n) const;
1295 V size_type rfind(const charT* s, size_type pos = npos) const;
1296 V size_type rfind(charT c, size_type pos = npos) const;
1298 V size_type find_first_of(const basic_string& str,
1299 size_type pos = 0) const;
1300 V size_type find_first_of(const charT* s,
1301 size_type pos, size_type n) const;
1302 V size_type find_first_of(const charT* s, size_type pos = 0) const;
1303 V size_type find_first_of(charT c, size_type pos = 0) const;
1304 V size_type find_last_of (const basic_string& str,
1305 size_type pos = npos) const;
1306 V size_type find_last_of (const charT* s,
1307 size_type pos, size_type n) const;
1308 V size_type find_last_of (const charT* s, size_type pos = npos) const;
1309 V size_type find_last_of (charT c, size_type pos = npos) const;
1310 V size_type find_first_not_of(const basic_string& str,
1311 size_type pos = 0) const;
1312 V size_type find_first_not_of(const charT* s, size_type pos,
1313 size_type n) const;
1314 V size_type find_first_not_of(const charT* s, size_type pos = 0) const;
1315 V size_type find_first_not_of(charT c, size_type pos = 0) const;
1316 V size_type find_last_not_of (const basic_string& str,
1317 size_type pos = npos) const;
1318 V size_type find_last_not_of (const charT* s, size_type pos,
1319 size_type n) const;
1320 V size_type find_last_not_of (const charT* s,
1321 size_type pos = npos) const;
1322 V size_type find_last_not_of (charT c, size_type pos = npos) const;
1323 V basic_string substr(size_type pos = 0, size_type n = npos) const;
1324 V int compare(const basic_string& str) const;
1325 V int compare(size_type pos1, size_type n1,
1326 const basic_string& str) const;
1327 V int compare(size_type pos1, size_type n1,
1328 const basic_string& str,
1329 size_type pos2, size_type n2) const;
1330 V int compare(const charT* s) const;
1331 V int compare(size_type pos1, size_type n1,
1332 const charT* s, size_type n2 = npos) const;
1336 21.4 Null-terminated sequence utilities [lib.c.strings]
1338 Table 10--Header <cctype> synopsis
1340 isalnum isdigit isprint isupper tolower
1341 X isalpha isgraph ispunct isxdigit toupper
1342 iscntrl islower isspace
1344 Table 11--Header <cwctype> synopsis
1346 X Macro: WEOF <cwctype>
1347 X Types: wctrans_t wctype_t wint_t <cwctype>
1348 Functions:
1349 X iswalnum iswctype iswlower iswspace towctrans wctrans
1350 X iswalpha iswdigit iswprint iswupper towlower wctype
1351 X iswcntrl iswgraph iswpunct iswxdigit towupper
1353 Table 12--Header <cstring> synopsis
1355 X Macro: NULL <cstring>
1356 X Type: size_t <cstring>
1357 Functions:
1358 X memchr strcat strcspn strncpy strtok
1359 X memcmp strchr strerror strpbrk strxfrm
1360 X memcpy strcmp strlen strrchr
1361 X memmove strcoll strncat strspn
1362 X memset strcpy strncmp strstr
1364 Table 13--Header <cwchar> synopsis
1365 Macros: NULL <cwchar> WCHAR_MAX WCHAR_MIN WEOF <cwchar>
1366 Types: mbstate_t wint_t <cwchar> size_t
1367 Functions:
1368 X btowc getwchar ungetwc wcscpy wcsrtombs wmemchr
1369 X fgetwc mbrlen vfwprintf wcscspn wcsspn wmemcmp
1370 X fgetws mbrtowc vswprintf wcsftime wcsstr wmemcpy
1371 X fputwc mbsinit vwprintf wcslen wcstod wmemmove
1372 X fputws mbsrtowcs wcrtomb wcsncat wcstok wmemset
1373 X fwide putwc wcscat wcsncmp wcstol wprintf
1374 X fwprintf putwchar wcschr wcsncpy wcstoul wscanf
1375 X fwscanf swprintf wcscmp wcspbrk wcsxfrm
1376 X getwc swscanf wcscoll wcsrchr wctob
1378 Table 14--Header <cstdlib> synopsis
1380 Macros: MB_CUR_MAX
1381 Functions:
1382 X atol mblen strtod wctomb
1383 X atof mbstowcs strtol wcstombs
1384 X atoi mbtowc strtoul
1386 X const char* strchr(const char* s, int c);
1387 X char* strchr( char* s, int c);
1389 X const char* strpbrk(const char* s1, const char* s2);
1390 X char* strpbrk( char* s1, const char* s2);
1392 X const char* strrchr(const char* s, int c);
1393 X char* strrchr( char* s, int c);
1395 X const char* strstr(const char* s1, const char* s2);
1396 X char* strstr( char* s1, const char* s2);
1398 X const void* memchr(const void* s, int c, size_t n);
1399 X void* memchr( void* s, int c, size_t n);
1401 X const wchar_t* wcschr(const wchar_t* s, wchar_t c);
1402 X wchar_t* wcschr( wchar_t* s, wchar_t c);
1404 X const wchar_t* wcspbrk(const wchar_t* s1, const wchar_t* s2);
1405 X wchar_t* wcspbrk( wchar_t* s1, const wchar_t* s2);
1407 X const wchar_t* wcsrchr(const wchar_t* s, wchar_t c);
1408 X wchar_t* wcsrchr( wchar_t* s, wchar_t c);
1410 X const wchar_t* wcsstr(const wchar_t* s1, const wchar_t* s2);
1411 X wchar_t* wcsstr( wchar_t* s1, const wchar_t* s2);
1413 X const wchar_t* wmemchr(const wchar_t* s, wchar_t c, size_t n);
1414 X wchar_t* wmemchr( wchar_t* s, wchar_t c, size_t n);
1416 [for initial efforts on the above, see shadow/string.h]
1418 22.1 Locales [lib.locales]
1420 Header <locale> synopsis
1422 // _lib.locale_, locale:
1423 T class locale;
1424 T template <class Facet> const Facet& use_facet(const locale&);
1425 T template <class Facet> bool has_facet(const locale&) throw();
1427 // _lib.locale.convenience_, convenience interfaces:
1428 T template <class charT> bool isspace (charT c, const locale& loc);
1429 T template <class charT> bool isprint (charT c, const locale& loc);
1430 T template <class charT> bool iscntrl (charT c, const locale& loc);
1431 T template <class charT> bool isupper (charT c, const locale& loc);
1432 T template <class charT> bool islower (charT c, const locale& loc);
1433 T template <class charT> bool isalpha (charT c, const locale& loc);
1434 T template <class charT> bool isdigit (charT c, const locale& loc);
1435 T template <class charT> bool ispunct (charT c, const locale& loc);
1436 T template <class charT> bool isxdigit(charT c, const locale& loc);
1437 T template <class charT> bool isalnum (charT c, const locale& loc);
1438 T template <class charT> bool isgraph (charT c, const locale& loc);
1439 T template <class charT> charT toupper(charT c, const locale& loc);
1440 T template <class charT> charT tolower(charT c, const locale& loc);
1441 // _lib.category.ctype_ and _lib.facet.ctype.special_, ctype:
1442 class ctype_base;
1443 T template <class charT> class ctype;
1444 T template <> class ctype<char>; // specialization
1445 S template <class charT> class ctype_byname;
1446 S template <> class ctype_byname<char>; // specialization
1447 T class codecvt_base;
1448 X template <class internT, class externT, class stateT> class codecvt;
1449 S template <class internT, class externT, class stateT> class codecvt_byname;
1450 // _lib.category.numeric_ and _lib.facet.numpunct_, numeric:
1451 X template <class charT, class InputIterator> class num_get;
1452 X template <class charT, class OutputIterator> class num_put;
1453 T template <class charT> class numpunct;
1454 S template <class charT> class numpunct_byname;
1455 // _lib.category.collate_, collation:
1456 T template <class charT> class collate;
1457 S template <class charT> class collate_byname;
1458 // _lib.category.time_, date and time:
1459 T class time_base;
1460 S template <class charT, class InputIterator> class time_get;
1461 S template <class charT, class InputIterator> class time_get_byname;
1462 S template <class charT, class OutputIterator> class time_put;
1463 S template <class charT, class OutputIterator> class time_put_byname;
1464 // _lib.category.monetary_, money:
1465 T class money_base;
1466 S template <class charT, class InputIterator> class money_get;
1467 S template <class charT, class OutputIterator> class money_put;
1468 S template <class charT, bool Intl> class moneypunct;
1469 S template <class charT, bool Intl> class moneypunct_byname;
1470 // _lib.category.messages_, message retrieval:
1471 T class messages_base;
1472 S template <class charT> class messages;
1473 S template <class charT> class messages_byname;
1476 22.1.1 Class locale [lib.locale]
1478 X class locale {
1479 public:
1480 // types:
1481 T class facet;
1482 T class id;
1483 T typedef int category;
1484 T static const category // values assigned here are for exposition only
1485 T none = 0,
1486 T collate = 0x010, ctype = 0x020,
1487 T monetary = 0x040, numeric = 0x080,
1488 T time = 0x100, messages = 0x200,
1489 T all = collate | ctype | monetary | numeric | time | messages;
1490 // construct/copy/destroy:
1491 T locale() throw()
1492 T locale(const locale& other) throw()
1493 X explicit locale(const char* std_name);
1494 X locale(const locale& other, const char* std_name, category);
1495 T template <class Facet> locale(const locale& other, Facet* f);
1496 T locale(const locale& other, const locale& one, category);
1497 T ~locale() throw(); // non-virtual
1498 T const locale& operator=(const locale& other) throw();
1499 T template <class Facet> locale combine(const locale& other) const;
1500 // locale operations:
1501 X basic_string<char> name() const;
1502 T bool operator==(const locale& other) const;
1503 T bool operator!=(const locale& other) const;
1504 T template <class charT, class Traits, class Allocator>
1505 bool operator()(const basic_string<charT,Traits,Allocator>& s1,
1506 const basic_string<charT,Traits,Allocator>& s2) const;
1507 // global locale objects:
1508 T static locale global(const locale&);
1509 T static const locale& classic();
1512 22.1.1.1 locale types [lib.locale.types]
1514 22.1.1.1.1 Type locale::category [lib.locale.category]
1516 T typedef int category;
1518 T none, collate, ctype, monetary, numeric, time, and messages
1520 [required locale members]
1521 T collate<char>, collate<wchar_t>
1522 T ctype<char>, ctype<wchar_t>
1523 T codecvt<char,char,mbstate_t>,
1524 S codecvt<wchar_t,char,mbstate_t>
1525 T moneypunct<char>, moneypunct<wchar_t>
1526 T moneypunct<char,true>, moneypunct<wchar_t,true>,
1527 S money_get<char>, money_get<wchar_t
1528 S money_put<char>, money_put<wchar_t>
1529 T numpunct<char>, numpunct<wchar_t>,
1530 X num_get<char>, num_get<wchar_t>
1531 X num_put<char>, num_put<wchar_t>
1532 S time_get<char>, time_get<wchar_t>,
1533 S time_put<char>, time_put<wchar_t>
1534 S messages<char>, messages<wchar_t>
1536 [required instantiations]
1537 S collate_byname<char>, collate_byname<wchar_t>
1538 S ctype_byname<char>, ctype_byname<wchar_t>
1539 S codecvt_byname<char,char,mbstate_t>,
1540 S codecvt_byname<wchar_t,char,mbstate_t>
1541 S moneypunct_byname<char,International>,
1542 S moneypunct_byname<wchar_t,International>,
1543 S money_get<C,InputIterator>,
1544 S money_put<C,OutputIterator>
1545 S numpunct_byname<char>, numpunct_byname<wchar_t>
1546 X num_get<C,InputIterator>, num_put<C,OutputIterator>
1547 S time_get<char,InputIterator>,
1548 S time_get_byname<char,InputIterator>,
1549 S time_get<wchar_t,OutputIterator>,
1550 S time_get_byname<wchar_t,OutputIterator>,
1551 S time_put<char,OutputIterator>,
1552 S time_put_byname<char,OutputIterator>,
1553 S time_put<wchar_t,OutputIterator>
1554 S time_put_byname<wchar_t,OutputIterator>
1555 S messages_byname<char>, messages_byname<wchar_t>
1558 22.1.1.1.2 Class locale::facet [lib.locale.facet]
1560 T class locale::facet {
1561 protected:
1562 T explicit facet(size_t refs = 0);
1563 T virtual ~facet();
1564 private:
1565 T facet(const facet&); // not defined
1566 T void operator=(const facet&); // not defined
1571 22.1.1.1.3 Class locale::id [lib.locale.id]
1573 T class locale::id {
1574 public:
1575 T id();
1576 private:
1577 T void operator=(const id&); // not defined
1578 T id(const id&); // not defined
1583 22.2.1 The ctype category [lib.category.ctype]
1585 T class ctype_base {
1586 public:
1587 T enum mask { // numeric values are for exposition only.
1588 T space=, print=, cntrl=, upper=, lower=,
1589 T alpha=, digit=, punct=, xdigit=,
1590 T alnum=, graph=
1595 22.2.1.1 Template class ctype [lib.locale.ctype]
1597 T template <class charT>
1598 class ctype : public locale::facet, public ctype_base {
1599 public:
1600 T typedef charT char_type;
1601 T explicit ctype(size_t refs = 0);
1602 T bool is(mask m, charT c) const;
1603 T const charT* is(const charT* low, const charT* high, mask* vec) const;
1604 T const charT* scan_is(mask m,
1605 const charT* low, const charT* high) const;
1606 T const charT* scan_not(mask m,
1607 const charT* low, const charT* high) const;
1608 T charT toupper(charT c) const;
1609 T const charT* toupper(charT* low, const charT* high) const;
1610 T charT tolower(charT c) const;
1611 T const charT* tolower(charT* low, const charT* high) const;
1612 T charT widen(char c) const;
1613 T const char* widen(const char* low, const char* high, charT* to) const;
1614 T char narrow(charT c, char dfault) const;
1615 T const charT* narrow(const charT* low, const charT*, char dfault,
1616 char* to) const;
1617 T static locale::id id;
1619 protected:
1620 T ~ctype(); // virtual
1621 T virtual bool do_is(mask m, charT c) const;
1622 T virtual const charT* do_is(const charT* low, const charT* high,
1623 mask* vec) const;
1624 T virtual const charT* do_scan_is(mask m,
1625 const charT* low, const charT* high) const;
1626 T virtual const charT* do_scan_not(mask m,
1627 const charT* low, const charT* high) const;
1628 T virtual charT do_toupper(charT) const;
1629 T virtual const charT* do_toupper(charT* low, const charT* high) const;
1630 T virtual charT do_tolower(charT) const;
1631 T virtual const charT* do_tolower(charT* low, const charT* high) const;
1632 T virtual charT do_widen(char) const;
1633 T virtual const char* do_widen(const char* low, const char* high,
1634 charT* dest) const;
1635 T virtual char do_narrow(charT, char dfault) const;
1636 T virtual const charT* do_narrow(const charT* low, const charT* high,
1637 char dfault, char* dest) const;
1641 22.2.1.2 Template class ctype_byname [lib.locale.ctype.byname]
1643 X template <class charT>
1644 class ctype_byname : public ctype<charT> {
1645 public:
1646 T typedef ctype<charT>::mask mask;
1647 S explicit ctype_byname(const char*, size_t refs = 0);
1648 protected:
1649 S ~ctype_byname(); // virtual
1650 S virtual bool do_is(mask m, charT c) const;
1651 S virtual const charT* do_is(const charT* low, const charT* high,
1652 mask* vec) const;
1653 S virtual const char* do_scan_is(mask m,
1654 const charT* low, const charT* high) const;
1655 S virtual const char* do_scan_not(mask m,
1656 const charT* low, const charT* high) const;
1657 S virtual charT do_toupper(charT) const;
1658 S virtual const charT* do_toupper(charT* low, const charT* high) const;
1659 S virtual charT do_tolower(charT) const;
1660 S virtual const charT* do_tolower(charT* low, const charT* high) const;
1661 S virtual charT do_widen(char) const;
1662 S virtual const char* do_widen(const char* low, const char* high,
1663 charT* dest) const;
1664 S virtual char do_narrow(charT, char dfault) const;
1665 S virtual const charT* do_narrow(const charT* low, const charT* high,
1666 char dfault, char* dest) const;
1669 22.2.1.3 ctype specializations [lib.facet.ctype.special]
1671 T template <> class ctype<char>
1672 : public locale::facet, public ctype_base {
1673 public:
1674 T typedef char char_type;
1675 T explicit ctype(const mask* tab = 0, bool del = false,
1676 size_t refs = 0);
1677 T bool is(mask m, char c) const;
1678 T const char* is(const char* low, const char* high, mask* vec) const;
1679 T const char* scan_is (mask m,
1680 const char* low, const char* high) const;
1681 T const char* scan_not(mask m,
1682 const char* low, const char* high) const;
1683 T char toupper(char c) const;
1684 T const char* toupper(char* low, const char* high) const;
1685 T char tolower(char c) const;
1686 T const char* tolower(char* low, const char* high) const;
1687 T char widen(char c) const;
1688 T const char* widen(const char* low, const char* high, char* to) const;
1689 T char narrow(char c, char dfault) const;
1690 T const char* narrow(const char* low, const char* high, char dfault,
1691 char* to) const;
1692 T static locale::id id;
1693 T static const size_t table_size = IMPLEMENTATION_DEFINED;
1695 protected:
1696 T const mask* table() const throw();
1697 T static const mask* classic_table() throw();
1698 T ~ctype(); // virtual
1699 T virtual char do_toupper(char c) const;
1700 T virtual const char* do_toupper(char* low, const char* high) const;
1701 T virtual char do_tolower(char c) const;
1702 T virtual const char* do_tolower(char* low, const char* high) const;
1704 T virtual char do_widen(char c) const;
1705 T virtual const char* do_widen(const char* low,
1706 const char* high,
1707 char* to) const;
1708 T virtual char do_narrow(char c, char dfault) const;
1709 T virtual const char* do_narrow(const char* low,
1710 const char* high,
1711 char dfault, char* to) const;
1715 22.2.1.4 Class [lib.locale.ctype.byname.special]
1716 ctype_byname<char>
1718 X template <> class ctype_byname<char> : public ctype<char> {
1719 public:
1720 S explicit ctype_byname(const char*, size_t refs = 0);
1721 protected:
1722 S ~ctype_byname(); // virtual
1723 S virtual char do_toupper(char c) const;
1724 S virtual const char* do_toupper(char* low, const char* high) const;
1725 S virtual char do_tolower(char c) const;
1726 S virtual const char* do_tolower(char* low, const char* high) const;
1728 S virtual char do_widen(char c) const;
1729 S virtual const char* do_widen(char* low,
1730 const char* high,
1731 char* to) const;
1732 S virtual char do_widen(char c) const;
1733 S virtual const char* do_widen(char* low, const char* high) const;
1739 22.2.1.5 Template class codecvt [lib.locale.codecvt]
1741 T class codecvt_base {
1742 public:
1743 T enum result { ok, partial, error, noconv };
1746 T template <class internT, class externT, class stateT>
1747 class codecvt : public locale::facet, public codecvt_base {
1748 public:
1749 T typedef internT intern_type;
1750 T typedef externT extern_type;
1751 T typedef stateT state_type;
1752 T explicit codecvt(size_t refs = 0)
1753 T result out(stateT& state,
1754 const internT* from, const internT* from_end, const internT*& from_next,
1755 externT* to, externT* to_limit, externT*& to_next) const;
1756 T result unshift(stateT& state,
1757 externT* to, externT* to_limit, externT*& to_next) const;
1758 T result in(stateT& state,
1759 const externT* from, const externT* from_end, const externT*& from_next,
1760 internT* to, internT* to_limit, internT*& to_next) const;
1761 T int encoding() const throw();
1762 T bool always_noconv() const throw();
1763 T int length(const stateT&, const externT* from, const externT* end,
1764 size_t max) const;
1765 T int max_length() const throw();
1766 T static locale::id id;
1768 protected:
1769 T ~codecvt(); // virtual
1770 T virtual result do_out(stateT& state,
1771 const internT* from, const internT* from_end, const internT*& from_next,
1772 externT* to, externT* to_limit, externT*& to_next) const;
1773 T virtual result do_in(stateT& state,
1774 T const externT* from, const externT* from_end, const externT*& from_next,
1775 internT* to, internT* to_limit, internT*& to_next) const;
1776 T virtual result do_unshift(stateT& state,
1777 externT* to, externT* to_limit, externT*& to_next) const;
1778 T virtual int do_encoding() const throw();
1779 T virtual bool do_always_noconv() const throw();
1780 T virtual int do_length(const stateT&, const externT* from,
1781 const externT* end, size_t max) const;
1782 T virtual int do_max_length() const throw();
1787 22.2.1.6 Template class [lib.locale.codecvt.byname]
1788 codecvt_byname
1790 X template <class internT, class externT, class stateT>
1791 class codecvt_byname : public codecvt<internT, externT, stateT> {
1792 public:
1793 S explicit codecvt_byname(const char*, size_t refs = 0);
1794 protected:
1795 S ~codecvt_byname(); // virtual
1796 S virtual result do_out(stateT& state,
1797 const internT* from, const internT* from_end, const internT*& from_next,
1798 externT* to, externT* to_limit, externT*& to_next) const;
1799 S virtual result do_in(stateT& state,
1800 const externT* from, const externT* from_end, const externT*& from_next,
1801 internT* to, internT* to_limit, internT*& to_next) const;
1802 S virtual result do_unshift(stateT& state,
1803 externT* to, externT* to_limit, externT*& to_next) const;
1804 S virtual int do_encoding() const throw();
1805 S virtual bool do_always_noconv() const throw();
1806 S virtual int do_length(const stateT&, const externT* from,
1807 const externT* end, size_t max) const;
1808 S virtual result do_unshift(stateT& state,
1809 externT* to, externT* to_limit, externT*& to_next) const;
1810 S virtual int do_max_length() const throw();
1814 22.2.2.1 Template class num_get [lib.locale.num.get]
1816 X template <class charT, class InputIterator = istreambuf_iterator<charT> >
1817 class num_get : public locale::facet {
1818 public:
1819 T typedef charT char_type;
1820 T typedef InputIterator iter_type;
1821 T explicit num_get(size_t refs = 0);
1822 T iter_type get(iter_type in, iter_type end, ios_base&,
1823 ios_base::iostate& err, bool& v) const;
1824 T iter_type get(iter_type in, iter_type end, ios_base& ,
1825 ios_base::iostate& err, long& v) const;
1826 T iter_type get(iter_type in, iter_type end, ios_base&,
1827 ios_base::iostate& err, unsigned short& v) const;
1828 T iter_type get(iter_type in, iter_type end, ios_base&,
1829 ios_base::iostate& err, unsigned int& v) const;
1830 T iter_type get(iter_type in, iter_type end, ios_base&,
1831 ios_base::iostate& err, unsigned long& v) const;
1832 T iter_type get(iter_type in, iter_type end, ios_base&,
1833 ios_base::iostate& err, float& v) const;
1834 T iter_type get(iter_type in, iter_type end, ios_base&,
1835 ios_base::iostate& err, double& v) const;
1836 T iter_type get(iter_type in, iter_type end, ios_base&,
1837 ios_base::iostate& err, long double& v) const;
1838 T iter_type get(iter_type in, iter_type end, ios_base&,
1839 ios_base::iostate& err, void*& v) const;
1840 T static locale::id id;
1842 protected:
1843 T ~num_get(); // virtual
1844 T virtual iter_type do_get(iter_type, iter_type, ios_base&,
1845 ios_base::iostate& err, bool& v) const;
1846 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1847 ios_base::iostate& err, long& v) const;
1848 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1849 ios_base::iostate& err, unsigned short& v) const;
1850 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1851 ios_base::iostate& err, unsigned int& v) const;
1852 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1853 ios_base::iostate& err, unsigned long& v) const;
1854 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1855 ios_base::iostate& err, float& v) const;
1856 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1857 ios_base::iostate& err, double& v) const;
1858 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1859 ios_base::iostate& err, long double& v) const;
1860 S virtual iter_type do_get(iter_type, iter_type, ios_base&,
1861 ios_base::iostate& err, void*& v) const;
1866 22.2.2.2 Template class num_put [lib.locale.nm.put]
1868 X template <class charT, class OutputIterator = ostreambuf_iterator<charT> >
1869 class num_put : public locale::facet {
1870 public:
1871 T typedef charT char_type;
1872 T typedef OutputIterator iter_type;
1873 T explicit num_put(size_t refs = 0);
1874 T iter_type put(iter_type s, ios_base& f, char_type fill, bool v) const;
1875 T iter_type put(iter_type s, ios_base& f, char_type fill, long v) const;
1876 T iter_type put(iter_type s, ios_base& f, char_type fill,
1877 unsigned long v) const;
1878 T iter_type put(iter_type s, ios_base& f, char_type fill,
1879 double v) const;
1880 T iter_type put(iter_type s, ios_base& f, char_type fill,
1881 long double v) const;
1882 T iter_type put(iter_type s, ios_base& f, char_type fill,
1883 const void* v) const;
1884 T static locale::id id;
1885 protected:
1886 T ~num_put(); // virtual
1887 T virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1888 bool v) const;
1889 T virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1890 long v) const;
1891 T virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1892 unsigned long) const;
1893 S virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1894 double v) const;
1895 S virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1896 long double v) const;
1897 T virtual iter_type do_put(iter_type, ios_base&, char_type fill,
1898 const void* v) const;
1902 22.2.3.1 Template class numpunct [lib.locale.numpunct]
1904 T template <class charT>
1905 class numpunct : public locale::facet {
1906 public:
1907 T typedef charT char_type;
1908 T typedef basic_string<charT> string_type;
1909 T explicit numpunct(size_t refs = 0);
1910 T char_type decimal_point() const;
1911 T char_type thousands_sep() const;
1912 T string grouping() const;
1913 T string_type truename() const;
1914 T string_type falsename() const;
1915 T static locale::id id;
1916 protected:
1917 T ~numpunct(); // virtual
1918 T virtual char_type do_decimal_point() const;
1919 T virtual char_type do_thousands_sep() const;
1920 T virtual string do_grouping() const;
1921 T virtual string_type do_truename() const; // for bool
1922 T virtual string_type do_falsename() const; // for bool
1928 22.2.3.2 Template class [lib.locale.numpunct.byname]
1929 numpunct_byname
1931 X template <class charT>
1932 class numpunct_byname : public numpunct<charT> {
1933 // this class is specialized for char and wchar_t.
1934 public:
1935 T typedef charT char_type;
1936 T typedef basic_string<charT> string_type;
1937 S explicit numpunct_byname(const char*, size_t refs = 0);
1938 protected:
1939 S ~numpunct_byname(); // virtual
1940 S virtual char_type do_decimal_point() const;
1941 S virtual char_type do_thousands_sep() const;
1942 S virtual string do_grouping() const;
1943 S virtual string_type do_truename() const; // for bool
1944 S virtual string_type do_falsename() const; // for bool
1948 22.2.4.1 Template class collate [lib.locale.collate]
1950 T template <class charT>
1951 class collate : public locale::facet {
1952 public:
1953 T typedef charT char_type;
1954 T typedef basic_string<charT> string_type;
1955 T explicit collate(size_t refs = 0);
1956 T int compare(const charT* low1, const charT* high1,
1957 const charT* low2, const charT* high2) const;
1958 T string_type transform(const charT* low, const charT* high) const;
1959 T long hash(const charT* low, const charT* high) const;
1960 T static locale::id id;
1961 protected:
1962 T ~collate(); // virtual
1963 T virtual int do_compare(const charT* low1, const charT* high1,
1964 const charT* low2, const charT* high2) const;
1965 T virtual string_type do_transform
1966 (const charT* low, const charT* high) const;
1967 T virtual long do_hash (const charT* low, const charT* high) const;
1971 22.2.4.2 Template class [lib.locale.collate.byname]
1972 collate_byname
1974 X template <class charT>
1975 class collate_byname : public collate<charT> {
1976 public:
1977 T typedef basic_string<charT> string_type;
1978 T explicit collate_byname(const char*, size_t refs = 0);
1979 protected:
1980 S ~collate_byname(); // virtual
1981 S virtual int do_compare(const charT* low1, const charT* high1,
1982 const charT* low2, const charT* high2) const;
1983 S virtual string_type do_transform
1984 (const charT* low, const charT* high) const;
1985 S virtual long do_hash (const charT* low, const charT* high) const;
1989 22.2.5.1 Template class time_get [lib.locale.time.get]
1991 T class time_base {
1992 public:
1993 T enum dateorder { no_order, dmy, mdy, ymd, ydm };
1996 [Note: semantics of time_get members are implementation-defined.
1997 To complete implementation requires documenting behavior.]
1999 X template <class charT, class InputIterator = istreambuf_iterator<charT> >
2000 class time_get : public locale::facet, public time_base {
2001 public:
2002 T typedef charT char_type;
2003 T typedef InputIterator iter_type;
2004 T explicit time_get(size_t refs = 0);
2006 T dateorder date_order() const { return do_date_order(); }
2007 T iter_type get_time(iter_type s, iter_type end, ios_base& f,
2008 ios_base::iostate& err, tm* t) const;
2009 T iter_type get_date(iter_type s, iter_type end, ios_base& f,
2010 ios_base::iostate& err, tm* t) const;
2011 T iter_type get_weekday(iter_type s, iter_type end, ios_base& f,
2012 ios_base::iostate& err, tm* t) const;
2013 T iter_type get_monthname(iter_type s, iter_type end, ios_base& f,
2014 ios_base::iostate& err, tm* t) const;
2015 T iter_type get_year(iter_type s, iter_type end, ios_base& f,
2016 ios_base::iostate& err, tm* t) const;
2017 T static locale::id id;
2018 protected:
2019 ~time_get(); // virtual
2020 X virtual dateorder do_date_order() const;
2021 S virtual iter_type do_get_time(iter_type s, iter_type end, ios_base&,
2022 ios_base::iostate& err, tm* t) const;
2023 S virtual iter_type do_get_date(iter_type s, iter_type end, ios_base&,
2024 ios_base::iostate& err, tm* t) const;
2025 S virtual iter_type do_get_weekday(iter_type s, iter_type end, ios_base&,
2026 ios_base::iostate& err, tm* t) const;
2027 S virtual iter_type do_get_monthname(iter_type s, ios_base&,
2028 ios_base::iostate& err, tm* t) const;
2029 S virtual iter_type do_get_year(iter_type s, iter_type end, ios_base&,
2030 ios_base::iostate& err, tm* t) const;
2035 22.2.5.2 Template class [lib.locale.time.get.byname]
2036 time_get_byname
2038 X template <class charT, class InputIterator = istreambuf_iterator<charT> >
2039 class time_get_byname : public time_get<charT, InputIterator> {
2040 public:
2041 T typedef time_base::dateorder dateorder;
2042 T typedef InputIterator iter_type
2044 S explicit time_get_byname(const char*, size_t refs = 0);
2045 protected:
2046 S ~time_get_byname(); // virtual
2047 S virtual dateorder do_date_order() const;
2048 S virtual iter_type do_get_time(iter_type s, iter_type end, ios_base&,
2049 ios_base::iostate& err, tm* t) const;
2050 S virtual iter_type do_get_date(iter_type s, iter_type end, ios_base&,
2051 ios_base::iostate& err, tm* t) const;
2052 T virtual iter_type do_get_weekday(iter_type s, iter_type end, ios_base&,
2053 ios_base::iostate& err, tm* t) const;
2054 T virtual iter_type do_get_monthname(iter_type s, iter_type end, ios_base&,
2055 ios_base::iostate& err, tm* t) const;
2056 S virtual iter_type do_get_year(iter_type s, iter_type end, ios_base&,
2057 ios_base::iostate& err, tm* t) const;
2061 22.2.5.3 Template class time_put [lib.locale.time.put]
2063 X template <class charT, class OutputIterator = ostreambuf_iterator<charT> >
2064 class time_put : public locale::facet {
2065 public:
2066 T typedef charT char_type;
2067 T typedef OutputIterator iter_type;
2068 T explicit time_put(size_t refs = 0);
2069 // the following is implemented in terms of other member functions.
2070 S iter_type put(iter_type s, ios_base& f, char_type fill, const tm* tmb,
2071 const charT* pattern, const charT* pat_end) const;
2072 T iter_type put(iter_type s, ios_base& f, char_type fill,
2073 const tm* tmb, char format, char modifier = 0) const;
2074 T static locale::id id;
2075 protected:
2076 T ~time_put(); // virtual
2077 S virtual iter_type do_put(iter_type s, ios_base&, char_type, const tm* t,
2078 char format, char modifier) const;
2083 22.2.5.4 Template class [lib.locale.time.put.byname]
2084 time_put_byname
2086 T template <class charT, class OutputIterator = ostreambuf_iterator<charT> >
2087 class time_put_byname : public time_put<charT, OutputIterator>
2089 public:
2090 T typedef charT char_type;
2091 T typedef OutputIterator iter_type;
2093 T explicit time_put_byname(const char*, size_t refs = 0);
2094 protected:
2095 T ~time_put_byname(); // virtual
2096 S virtual iter_type do_put(iter_type s, ios_base&, char_type, const tm* t,
2097 char format, char modifier) const;
2101 22.2.6.1 Template class money_get [lib.locale.money.get]
2103 X template <class charT,
2104 class InputIterator = istreambuf_iterator<charT> >
2105 class money_get : public locale::facet {
2106 public:
2107 T typedef charT char_type;
2108 T typedef InputIterator iter_type;
2109 T typedef basic_string<charT> string_type;
2110 T explicit money_get(size_t refs = 0);
2111 T iter_type get(iter_type s, iter_type end, bool intl,
2112 ios_base& f, ios_base::iostate& err,
2113 long double& units) const;
2114 T iter_type get(iter_type s, iter_type end, bool intl,
2115 ios_base& f, ios_base::iostate& err,
2116 string_type& digits) const;
2117 T static locale::id id;
2118 protected:
2119 T ~money_get(); // virtual
2120 S virtual iter_type do_get(iter_type, iter_type, bool, ios_base&,
2121 ios_base::iostate& err, long double& units) const;
2122 S virtual iter_type do_get(iter_type, iter_type, bool, ios_base&,
2123 ios_base::iostate& err, string_type& digits) const;
2126 22.2.6.2 Template class money_put [lib.locale.money.put]
2128 X template <class charT,
2129 class OutputIterator = ostreambuf_iterator<charT> >
2130 class money_put : public locale::facet {
2131 public:
2132 T typedef charT char_type;
2133 T typedef OutputIterator iter_type;
2134 T typedef basic_string<charT> string_type;
2135 T explicit money_put(size_t refs = 0);
2136 T iter_type put(iter_type s, bool intl, ios_base& f,
2137 char_type fill, long double units) const;
2138 T iter_type put(iter_type s, bool intl, ios_base& f,
2139 char_type fill, const string_type& digits) const;
2140 T static locale::id id;
2142 protected:
2143 T ~money_put(); // virtual
2144 S virtual iter_type
2145 do_put(iter_type, bool, ios_base&, char_type fill,
2146 long double units) const;
2147 S virtual iter_type
2148 do_put(iter_type, bool, ios_base&, char_type fill,
2149 const string_type& digits) const;
2153 22.2.6.3 Template class moneypunct [lib.locale.moneypunct]
2155 T class money_base {
2156 public:
2157 T enum part { none, space, symbol, sign, value };
2158 T struct pattern { char field[4]; };
2161 X template <class charT, bool International = false>
2162 class moneypunct : public locale::facet, public money_base {
2163 public:
2164 T typedef charT char_type;
2165 T typedef basic_string<charT> string_type;
2166 T explicit moneypunct(size_t refs = 0);
2167 T charT decimal_point() const;
2168 T charT thousands_sep() const;
2169 T string grouping() const;
2170 T string_type curr_symbol() const;
2171 T string_type positive_sign() const;
2172 T string_type negative_sign() const;
2173 T int frac_digits() const;
2174 T pattern pos_format() const;
2175 T pattern neg_format() const;
2176 T static locale::id id;
2177 T static const bool intl = International;
2178 protected:
2179 T ~moneypunct(); // virtual
2180 S virtual charT do_decimal_point() const;
2181 S virtual charT do_thousands_sep() const;
2182 S virtual string do_grouping() const;
2183 S virtual string_type do_curr_symbol() const;
2184 S virtual string_type do_positive_sign() const;
2185 S virtual string_type do_negative_sign() const;
2186 S virtual int do_frac_digits() const;
2187 T virtual pattern do_pos_format() const;
2188 T virtual pattern do_neg_format() const;
2192 22.2.6.4 Template class [lib.locale.moneypunct.byname]
2193 moneypunct_byname
2195 X template <class charT, bool Intl = false>
2196 class moneypunct_byname : public moneypunct<charT, Intl> {
2197 public:
2198 T typedef money_base::pattern pattern;
2199 T typedef basic_string<charT> string_type;
2201 T explicit moneypunct_byname(const char*, size_t refs = 0);
2202 protected:
2203 T ~moneypunct_byname(); // virtual
2204 S virtual charT do_decimal_point() const;
2205 S virtual charT do_thousands_sep() const;
2206 S virtual string do_grouping() const;
2207 S virtual string_type do_curr_symbol() const;
2208 S virtual string_type do_positive_sign() const;
2209 S virtual string_type do_negative_sign() const;
2210 S virtual int do_frac_digits() const;
2211 S virtual pattern do_pos_format() const;
2212 S virtual pattern do_neg_format() const;
2215 22.2.7.1 Template class messages [lib.locale.messages]
2217 T class messages_base {
2218 public:
2219 T typedef int catalog;
2222 X template <class charT>
2223 class messages : public locale::facet, public messages_base {
2224 public:
2225 T typedef charT char_type;
2226 T typedef basic_string<charT> string_type;
2227 T explicit messages(size_t refs = 0);
2228 T catalog open(const basic_string<char>& fn, const locale&) const;
2229 T string_type get(catalog c, int set, int msgid,
2230 const string_type& dfault) const;
2231 T void close(catalog c) const;
2232 T static locale::id id;
2233 protected:
2234 T ~messages(); // virtual
2235 S virtual catalog do_open(const basic_string<char>&, const locale&) const;
2236 S virtual string_type do_get(catalog, int set, int msgid,
2237 const string_type& dfault) const;
2238 S virtual void do_close(catalog) const;
2241 22.2.7.2 Template class [lib.locale.messages.byname]
2242 messages_byname
2245 X template <class charT>
2246 class messages_byname : public messages<charT> {
2247 public:
2248 T typedef messages_base::catalog catalog;
2249 T typedef basic_string<charT> string_type;
2251 T explicit messages_byname(const char*, size_t refs = 0);
2252 protected:
2253 T ~messages_byname(); // virtual
2254 S virtual catalog do_open(const basic_string<char>&, const locale&) const;
2255 S virtual string_type do_get(catalog, int set, int msgid,
2256 const string_type& dfault) const;
2257 S virtual void do_close(catalog) const;
2261 22.3 C Library Locales [lib.c.locales]
2264 Table 13--Header <clocale> synopsis
2265 Macros:
2266 X LC_ALL LC_COLLATE LC_CTYPE
2267 X LC_MONETARY LC_NUMERIC LC_TIME
2268 X NULL
2269 X Struct: lconv
2270 X Functions: localeconv setlocale
2273 23.2 Sequences [lib.sequences]
2275 <deque>, <list>, <queue>, <stack>, and <vector>.
2277 Header <deque> synopsis
2279 T template <class T, class Allocator = allocator<T> > class deque;
2280 T template <class T, class Allocator>
2281 bool operator==(const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2282 T template <class T, class Allocator>
2283 bool operator< (const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2284 T template <class T, class Allocator>
2285 bool operator!=(const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2286 T template <class T, class Allocator>
2287 bool operator> (const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2288 T template <class T, class Allocator>
2289 bool operator>=(const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2290 T template <class T, class Allocator>
2291 bool operator<=(const deque<T,Allocator>& x, const deque<T,Allocator>& y);
2292 T template <class T, class Allocator>
2293 void swap(deque<T,Allocator>& x, deque<T,Allocator>& y);
2296 Header <list> synopsis
2298 T template <class T, class Allocator = allocator<T> > class list;
2299 T template <class T, class Allocator>
2300 bool operator==(const list<T,Allocator>& x, const list<T,Allocator>& y);
2301 T template <class T, class Allocator>
2302 bool operator< (const list<T,Allocator>& x, const list<T,Allocator>& y);
2303 T template <class T, class Allocator>
2304 bool operator!=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2305 T template <class T, class Allocator>
2306 bool operator> (const list<T,Allocator>& x, const list<T,Allocator>& y);
2307 T template <class T, class Allocator>
2308 bool operator>=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2309 T template <class T, class Allocator>
2310 bool operator<=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2311 T template <class T, class Allocator>
2312 void swap(list<T,Allocator>& x, list<T,Allocator>& y);
2315 Header <queue> synopsis
2317 namespace std {
2318 T template <class T, class Container = deque<T> > class queue;
2319 T template <class T, class Container>
2320 bool operator==(const queue<T, Container>& x,
2321 const queue<T, Container>& y);
2322 T template <class T, class Container>
2323 bool operator< (const queue<T, Container>& x,
2324 const queue<T, Container>& y);
2325 T template <class T, class Container>
2326 bool operator!=(const queue<T, Container>& x,
2327 const queue<T, Container>& y);
2328 T template <class T, class Container>
2329 bool operator> (const queue<T, Container>& x,
2330 const queue<T, Container>& y);
2331 T template <class T, class Container>
2332 bool operator>=(const queue<T, Container>& x,
2333 const queue<T, Container>& y);
2334 T template <class T, class Container>
2335 bool operator<=(const queue<T, Container>& x,
2336 const queue<T, Container>& y);
2337 T template <class T, class Container = vector<T>,
2338 class Compare = less<typename Container::value_type> >
2339 T class priority_queue;
2342 Header <stack> synopsis
2344 namespace std {
2345 T template <class T, class Container = deque<T> > class stack;
2346 T template <class T, class Container>
2347 bool operator==(const stack<T, Container>& x,
2348 const stack<T, Container>& y);
2349 T template <class T, class Container>
2350 bool operator< (const stack<T, Container>& x,
2351 const stack<T, Container>& y);
2352 T template <class T, class Container>
2353 bool operator!=(const stack<T, Container>& x,
2354 const stack<T, Container>& y);
2355 T template <class T, class Container>
2356 bool operator> (const stack<T, Container>& x,
2357 const stack<T, Container>& y);
2358 T template <class T, class Container>
2359 bool operator>=(const stack<T, Container>& x,
2360 const stack<T, Container>& y);
2361 T template <class T, class Container>
2362 bool operator<=(const stack<T, Container>& x,
2363 const stack<T, Container>& y);
2366 Header <vector> synopsis
2368 T template <class T, class Allocator = allocator<T> > class vector;
2370 T template <class T, class Allocator>
2371 bool operator==(const vector<T,Allocator>& x,
2372 const vector<T,Allocator>& y);
2373 T template <class T, class Allocator>
2374 bool operator< (const vector<T,Allocator>& x,
2375 const vector<T,Allocator>& y);
2376 T template <class T, class Allocator>
2377 bool operator!=(const vector<T,Allocator>& x,
2378 const vector<T,Allocator>& y);
2379 T template <class T, class Allocator>
2380 bool operator> (const vector<T,Allocator>& x,
2381 const vector<T,Allocator>& y);
2382 T template <class T, class Allocator>
2383 bool operator>=(const vector<T,Allocator>& x,
2384 const vector<T,Allocator>& y);
2385 T template <class T, class Allocator>
2386 bool operator<=(const vector<T,Allocator>& x,
2387 const vector<T,Allocator>& y);
2388 T template <class T, class Allocator>
2389 void swap(vector<T,Allocator>& x, vector<T,Allocator>& y);
2391 T template <class Allocator> class vector<bool,Allocator>;
2392 T template <class Allocator>
2393 bool operator==(const vector<bool,Allocator>& x,
2394 const vector<bool,Allocator>& y);
2395 T template <class Allocator>
2396 bool operator< (const vector<bool,Allocator>& x,
2397 const vector<bool,Allocator>& y);
2398 T template <class Allocator>
2399 bool operator!=(const vector<bool,Allocator>& x,
2400 const vector<bool,Allocator>& y);
2401 T template <class Allocator>
2402 bool operator> (const vector<bool,Allocator>& x,
2403 const vector<bool,Allocator>& y);
2404 T template <class Allocator>
2405 bool operator>=(const vector<bool,Allocator>& x,
2406 const vector<bool,Allocator>& y);
2407 T template <class Allocator>
2408 bool operator<=(const vector<bool,Allocator>& x,
2409 const vector<bool,Allocator>& y);
2410 T template <class Allocator>
2411 void swap(vector<bool,Allocator>& x, vector<bool,Allocator>& y);
2414 23.2.1 Template class deque [lib.deque]
2416 template <class T, class Allocator = allocator<T> >
2417 T class deque {
2418 public:
2419 // types:
2420 T typedef typename Allocator::reference reference;
2421 T typedef typename Allocator::const_reference const_reference;
2422 T typedef implementation defined iterator;
2423 T typedef implementation defined const_iterator;
2424 T typedef implementation defined size_type;
2425 T typedef implementation defined difference_type;
2426 T typedef T value_type;
2427 T typedef Allocator allocator_type;
2428 T typedef typename Allocator::pointer pointer;
2429 T typedef typename Allocator::const_pointer const_pointer;
2430 T typedef std::reverse_iterator<iterator> reverse_iterator;
2431 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
2432 // _lib.deque.cons_ construct/copy/destroy:
2433 T explicit deque(const Allocator& = Allocator());
2434 T explicit deque(size_type n, const T& value = T(),
2435 const Allocator& = Allocator());
2436 T template <class InputIterator>
2437 deque(InputIterator first, InputIterator last,
2438 const Allocator& = Allocator());
2439 T deque(const deque<T,Allocator>& x);
2440 T ~deque();
2441 T deque<T,Allocator>& operator=(const deque<T,Allocator>& x);
2442 T template <class InputIterator>
2443 void assign(InputIterator first, InputIterator last);
2444 T void assign(size_type n, const T& t);
2445 T allocator_type get_allocator() const;
2446 // iterators:
2447 T iterator begin();
2448 T const_iterator begin() const;
2449 T iterator end();
2450 T const_iterator end() const;
2451 T reverse_iterator rbegin();
2452 T const_reverse_iterator rbegin() const;
2453 T reverse_iterator rend();
2454 T const_reverse_iterator rend() const;
2455 // _lib.deque.capacity_ capacity:
2456 T size_type size() const;
2457 T size_type max_size() const;
2458 T void resize(size_type sz, T c = T());
2459 T bool empty() const;
2461 // element access:
2462 T reference operator[](size_type n);
2463 T const_reference operator[](size_type n) const;
2464 T reference at(size_type n);
2465 T const_reference at(size_type n) const;
2466 T reference front();
2467 T const_reference front() const;
2468 T reference back();
2469 T const_reference back() const;
2470 // _lib.deque.modifiers_ modifiers:
2471 T void push_front(const T& x);
2472 T void push_back(const T& x);
2473 T iterator insert(iterator position, const T& x);
2474 T void insert(iterator position, size_type n, const T& x);
2475 T template <class InputIterator>
2476 void insert (iterator position,
2477 InputIterator first, InputIterator last);
2478 T void pop_front();
2479 T void pop_back();
2480 T iterator erase(iterator position);
2481 T iterator erase(iterator first, iterator last);
2482 T void swap(deque<T,Allocator>&);
2483 T void clear();
2485 T template <class T, class Allocator>
2486 bool operator==(const deque<T,Allocator>& x,
2487 const deque<T,Allocator>& y);
2488 T template <class T, class Allocator>
2489 bool operator< (const deque<T,Allocator>& x,
2490 const deque<T,Allocator>& y);
2491 T template <class T, class Allocator>
2492 bool operator!=(const deque<T,Allocator>& x,
2493 const deque<T,Allocator>& y);
2494 T template <class T, class Allocator>
2495 bool operator> (const deque<T,Allocator>& x,
2496 const deque<T,Allocator>& y);
2497 T template <class T, class Allocator>
2498 bool operator>=(const deque<T,Allocator>& x,
2499 const deque<T,Allocator>& y);
2500 T template <class T, class Allocator>
2501 bool operator<=(const deque<T,Allocator>& x,
2502 const deque<T,Allocator>& y);
2503 // specialized algorithms:
2504 T template <class T, class Allocator>
2505 void swap(deque<T,Allocator>& x, deque<T,Allocator>& y);
2508 23.2.2 Template class list [lib.list]
2510 T template <class T, class Allocator = allocator<T> >
2511 class list {
2512 public:
2513 // types:
2514 T typedef typename Allocator::reference reference;
2515 T typedef typename Allocator::const_reference const_reference;
2516 T typedef implementation defined iterator;
2517 T typedef implementation defined const_iterator;
2518 T typedef implementation defined size_type;
2519 T typedef implementation defined difference_type;
2520 T typedef T value_type;
2521 T typedef Allocator allocator_type;
2522 T typedef typename Allocator::pointer pointer;
2523 T typedef typename Allocator::const_pointer const_pointer;
2524 T typedef std::reverse_iterator<iterator> reverse_iterator;
2525 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
2527 // _lib.list.cons_ construct/copy/destroy:
2528 T explicit list(const Allocator& = Allocator());
2529 T explicit list(size_type n, const T& value = T(),
2530 const Allocator& = Allocator());
2531 T template <class InputIterator>
2532 list(InputIterator first, InputIterator last,
2533 const Allocator& = Allocator());
2534 T list(const list<T,Allocator>& x);
2535 T ~list();
2536 T list<T,Allocator>& operator=(const list<T,Allocator>& x);
2537 T template <class InputIterator>
2538 void assign(InputIterator first, InputIterator last);
2539 T void assign(size_type n, const T& t);
2540 T allocator_type get_allocator() const;
2541 // iterators:
2542 T iterator begin();
2543 T const_iterator begin() const;
2544 T iterator end();
2545 T const_iterator end() const;
2546 T reverse_iterator rbegin();
2547 T const_reverse_iterator rbegin() const;
2548 T reverse_iterator rend();
2549 T const_reverse_iterator rend() const;
2550 // _lib.list.capacity_ capacity:
2551 T bool empty() const;
2552 T size_type size() const;
2553 T size_type max_size() const;
2554 T void resize(size_type sz, T c = T());
2555 // element access:
2556 T reference front();
2557 T const_reference front() const;
2558 T reference back();
2559 T const_reference back() const;
2560 // _lib.list.modifiers_ modifiers:
2561 T void push_front(const T& x);
2562 T void pop_front();
2563 T void push_back(const T& x);
2564 T void pop_back();
2565 T iterator insert(iterator position, const T& x);
2566 T void insert(iterator position, size_type n, const T& x);
2567 T template <class InputIterator>
2568 void insert(iterator position, InputIterator first,
2569 InputIterator last);
2570 T iterator erase(iterator position);
2571 T iterator erase(iterator position, iterator last);
2572 T void swap(list<T,Allocator>&);
2573 T void clear();
2574 // _lib.list.ops_ list operations:
2575 T void splice(iterator position, list<T,Allocator>& x);
2576 T void splice(iterator position, list<T,Allocator>& x, iterator i);
2577 T void splice(iterator position, list<T,Allocator>& x, iterator first,
2578 iterator last);
2579 T void remove(const T& value);
2580 T template <class Predicate> void remove_if(Predicate pred);
2582 T void unique();
2583 T template <class BinaryPredicate>
2584 void unique(BinaryPredicate binary_pred);
2585 T void merge(list<T,Allocator>& x);
2586 T template <class Compare> void merge(list<T,Allocator>& x, Compare comp);
2587 void sort();
2588 T template <class Compare> void sort(Compare comp);
2589 void reverse();
2591 T template <class T, class Allocator>
2592 bool operator==(const list<T,Allocator>& x, const list<T,Allocator>& y);
2593 T template <class T, class Allocator>
2594 bool operator< (const list<T,Allocator>& x, const list<T,Allocator>& y);
2595 T template <class T, class Allocator>
2596 bool operator!=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2597 T template <class T, class Allocator>
2598 bool operator> (const list<T,Allocator>& x, const list<T,Allocator>& y);
2599 T template <class T, class Allocator>
2600 bool operator>=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2601 T template <class T, class Allocator>
2602 bool operator<=(const list<T,Allocator>& x, const list<T,Allocator>& y);
2603 // specialized algorithms:
2604 T template <class T, class Allocator>
2605 void swap(list<T,Allocator>& x, list<T,Allocator>& y);
2608 23.2.3.1 Template class queue [lib.queue]
2610 T template <class T, class Container = deque<T> >
2611 class queue {
2612 public:
2613 T typedef typename Container::value_type value_type;
2614 T typedef typename Container::size_type size_type;
2615 T typedef Container container_type;
2616 protected:
2617 T Container c;
2618 public:
2619 T explicit queue(const Container& = Container());
2621 T bool empty() const { return c.empty(); }
2622 T size_type size() const { return c.size(); }
2623 T value_type& front() { return c.front(); }
2624 T const value_type& front() const { return c.front(); }
2625 T value_type& back() { return c.back(); }
2626 T const value_type& back() const { return c.back(); }
2627 T void push(const value_type& x) { c.push_back(x); }
2628 T void pop() { c.pop_front(); }
2631 T template <class T, class Container>
2632 bool operator==(const queue<T, Container>& x,
2633 const queue<T, Container>& y);
2634 T template <class T, class Container>
2635 bool operator< (const queue<T, Container>& x,
2636 const queue<T, Container>& y);
2637 T template <class T, class Container>
2638 bool operator!=(const queue<T, Container>& x,
2639 const queue<T, Container>& y);
2640 T template <class T, class Container>
2641 bool operator> (const queue<T, Container>& x,
2642 const queue<T, Container>& y);
2643 T template <class T, class Container>
2644 bool operator>=(const queue<T, Container>& x,
2645 const queue<T, Container>& y);
2646 T template <class T, class Container>
2647 bool operator<=(const queue<T, Container>& x,
2648 const queue<T, Container>& y);
2650 23.2.3.2 Template class priority_queue [lib.priority.queue]
2652 T template <class T, class Container = vector<T>,
2653 class Compare = less<typename Container::value_type> >
2654 class priority_queue {
2655 public:
2656 T typedef typename Container::value_type value_type;
2657 T typedef typename Container::size_type size_type;
2658 T typedef Container container_type;
2659 protected:
2660 T Container c;
2661 T Compare comp;
2662 public:
2663 T explicit priority_queue(const Compare& x = Compare(),
2664 const Container& = Container());
2665 T template <class InputIterator>
2666 priority_queue(InputIterator first, InputIterator last,
2667 const Compare& x = Compare(),
2668 const Container& = Container());
2670 T bool empty() const { return c.empty(); }
2671 T size_type size() const { return c.size(); }
2672 T const value_type& top() const { return c.front(); }
2673 T void push(const value_type& x);
2674 T void pop();
2677 23.2.3.3 Template class stack [lib.stack]
2679 T template <class T, class Container = deque<T> >
2680 class stack {
2681 public:
2682 T typedef typename Container::value_type value_type;
2683 T typedef typename Container::size_type size_type;
2684 T typedef Container container_type;
2685 protected:
2686 T Container c;
2687 public:
2688 T explicit stack(const Container& = Container());
2690 T bool empty() const { return c.empty(); }
2691 T size_type size() const { return c.size(); }
2692 T value_type& top() { return c.back(); }
2693 T const value_type& top() const { return c.back(); }
2694 T void push(const value_type& x) { c.push_back(x); }
2695 T void pop() { c.pop_back(); }
2697 T template <class T, class Container>
2698 bool operator==(const stack<T, Container>& x,
2699 const stack<T, Container>& y);
2700 T template <class T, class Container>
2701 bool operator< (const stack<T, Container>& x,
2702 const stack<T, Container>& y);
2703 T template <class T, class Container>
2704 bool operator!=(const stack<T, Container>& x,
2705 const stack<T, Container>& y);
2706 T template <class T, class Container>
2707 bool operator> (const stack<T, Container>& x,
2708 const stack<T, Container>& y);
2709 T template <class T, class Container>
2710 bool operator>=(const stack<T, Container>& x,
2711 const stack<T, Container>& y);
2712 T template <class T, class Container>
2713 bool operator<=(const stack<T, Container>& x,
2714 const stack<T, Container>& y);
2716 23.2.4 Template class vector [lib.vector]
2718 template <class T, class Allocator = allocator<T> >
2719 T class vector {
2720 public:
2721 // types:
2722 T typedef typename Allocator::reference reference;
2723 T typedef typename Allocator::const_reference const_reference;
2724 T typedef implementation defined iterator;
2725 T typedef implementation defined const_iterator;
2726 T typedef implementation defined size_type;
2727 T typedef implementation defined difference_type;
2728 T typedef T value_type;
2729 T typedef Allocator allocator_type;
2730 T typedef typename Allocator::pointer pointer;
2731 T typedef typename Allocator::const_pointer const_pointer
2732 T typedef std::reverse_iterator<iterator> reverse_iterator;
2733 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
2734 // _lib.vector.cons_ construct/copy/destroy:
2735 T explicit vector(const Allocator& = Allocator());
2736 T explicit vector(size_type n, const T& value = T(),
2737 const Allocator& = Allocator());
2738 T template <class InputIterator>
2739 vector(InputIterator first, InputIterator last,
2740 const Allocator& = Allocator());
2741 T vector(const vector<T,Allocator>& x);
2742 T ~vector();
2743 T vector<T,Allocator>& operator=(const vector<T,Allocator>& x);
2744 T template <class InputIterator>
2745 void assign(InputIterator first, InputIterator last);
2746 T void assign(size_type n, const T& u);
2747 T allocator_type get_allocator() const;
2748 // iterators:
2749 T iterator begin();
2750 T const_iterator begin() const;
2751 T iterator end();
2752 T const_iterator end() const;
2753 T reverse_iterator rbegin();
2754 T const_reverse_iterator rbegin() const;
2755 T reverse_iterator rend();
2756 T const_reverse_iterator rend() const;
2757 // _lib.vector.capacity_ capacity:
2758 T size_type size() const;
2759 T size_type max_size() const;
2760 T void resize(size_type sz, T c = T());
2761 T size_type capacity() const;
2762 T bool empty() const;
2763 T void reserve(size_type n);
2765 // element access:
2766 T reference operator[](size_type n);
2767 T const_reference operator[](size_type n) const;
2768 T const_reference at(size_type n) const;
2769 T reference at(size_type n);
2770 T reference front();
2771 T const_reference front() const;
2772 T reference back();
2773 T const_reference back() const;
2774 // _lib.vector.modifiers_ modifiers:
2775 T void push_back(const T& x);
2776 T void pop_back();
2777 T iterator insert(iterator position, const T& x);
2778 T void insert(iterator position, size_type n, const T& x);
2779 T template <class InputIterator>
2780 void insert(iterator position,
2781 InputIterator first, InputIterator last);
2782 T iterator erase(iterator position);
2783 T iterator erase(iterator first, iterator last);
2784 T void swap(vector<T,Allocator>&);
2785 T void clear();
2788 T template <class T, class Allocator>
2789 bool operator==(const vector<T,Allocator>& x,
2790 const vector<T,Allocator>& y);
2791 T template <class T, class Allocator>
2792 bool operator< (const vector<T,Allocator>& x,
2793 const vector<T,Allocator>& y);
2794 T template <class T, class Allocator>
2795 bool operator!=(const vector<T,Allocator>& x,
2796 const vector<T,Allocator>& y);
2797 T template <class T, class Allocator>
2798 bool operator> (const vector<T,Allocator>& x,
2799 const vector<T,Allocator>& y);
2800 T template <class T, class Allocator>
2801 bool operator>=(const vector<T,Allocator>& x,
2802 const vector<T,Allocator>& y);
2803 T template <class T, class Allocator>
2804 bool operator<=(const vector<T,Allocator>& x,
2805 const vector<T,Allocator>& y);
2806 // specialized algorithms:
2807 T template <class T, class Allocator>
2808 void swap(vector<T,Allocator>& x, vector<T,Allocator>& y);
2811 23.2.5 Class vector<bool> [lib.vector.bool]
2813 T template <class Allocator> class vector<bool, Allocator> {
2814 public:
2815 // types:
2816 T typedef bool const_reference;
2817 T typedef implementation defined iterator;
2818 T typedef implementation defined const_iterator;
2819 T typedef implementation defined size_type;
2820 T typedef implementation defined difference_type;
2821 T typedef bool value_type;
2822 T typedef Allocator allocator_type;
2823 T typedef implementation defined pointer;
2824 T typedef implementation defined const_pointer
2825 T typedef std::reverse_iterator<iterator> reverse_iterator;
2826 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
2827 // bit reference:
2828 T class reference {
2829 friend class vector;
2830 T reference();
2831 public:
2832 T ~reference();
2833 T operator bool() const;
2834 T reference& operator=(const bool x);
2835 T reference& operator=(const reference& x);
2836 T void flip(); // flips the bit
2839 // construct/copy/destroy:
2840 T explicit vector(const Allocator& = Allocator());
2841 T explicit vector(size_type n, const bool& value = bool(),
2842 const Allocator& = Allocator());
2843 T template <class InputIterator>
2844 vector(InputIterator first, InputIterator last,
2845 const Allocator& = Allocator());
2846 T vector(const vector<bool,Allocator>& x);
2847 T ~vector();
2848 T vector<bool,Allocator>& operator=(const vector<bool,Allocator>& x);
2849 T template <class InputIterator>
2850 void assign(InputIterator first, InputIterator last);
2851 T void assign(size_type n, const T& t);
2852 T allocator_type get_allocator() const;
2853 // iterators:
2854 T iterator begin();
2855 T const_iterator begin() const;
2856 T iterator end();
2857 T const_iterator end() const;
2858 T reverse_iterator rbegin();
2859 T const_reverse_iterator rbegin() const;
2860 T reverse_iterator rend();
2861 T const_reverse_iterator rend() const;
2862 // capacity:
2863 T size_type size() const;
2864 T size_type max_size() const;
2865 T void resize(size_type sz, bool c = false);
2866 T size_type capacity() const;
2867 T bool empty() const;
2868 T void reserve(size_type n);
2869 // element access:
2870 T reference operator[](size_type n);
2871 T const_reference operator[](size_type n) const;
2872 T const_reference at(size_type n) const;
2873 T reference at(size_type n);
2874 T reference front();
2875 T const_reference front() const;
2876 T reference back();
2877 T const_reference back() const;
2878 // modifiers:
2879 T void push_back(const bool& x);
2880 T void pop_back();
2881 T iterator insert(iterator position, const bool& x);
2882 T void insert (iterator position, size_type n, const bool& x);
2883 T template <class InputIterator>
2884 void insert(iterator position,
2885 InputIterator first, InputIterator last);
2886 T iterator erase(iterator position);
2887 T iterator erase(iterator first, iterator last);
2888 T void swap(vector<bool,Allocator>&);
2889 T static void swap(reference x, reference y);
2890 T void flip(); // flips all bits
2891 T void clear();
2894 T template <class Allocator>
2895 bool operator==(const vector<bool,Allocator>& x,
2896 const vector<bool,Allocator>& y);
2897 T template <class Allocator>
2898 bool operator< (const vector<bool,Allocator>& x,
2899 const vector<bool,Allocator>& y);
2900 T template <class Allocator>
2901 bool operator!=(const vector<bool,Allocator>& x,
2902 const vector<bool,Allocator>& y);
2903 T template <class Allocator>
2904 bool operator> (const vector<bool,Allocator>& x,
2905 const vector<bool,Allocator>& y);
2906 T template <class Allocator>
2907 bool operator>=(const vector<bool,Allocator>& x,
2908 const vector<bool,Allocator>& y);
2909 T template <class Allocator>
2910 bool operator<=(const vector<bool,Allocator>& x,
2911 const vector<bool,Allocator>& y);
2912 // specialized algorithms:
2913 T template <class Allocator>
2914 void swap(vector<bool,Allocator>& x, vector<bool,Allocator>& y);
2916 23.3 Associative containers [lib.associative]
2918 <map> and <set>:
2920 Header <map> synopsis
2922 template <class Key, class T, class Compare = less<Key>,
2923 class Allocator = allocator<pair<const Key, T> > >
2924 T class map;
2926 T template <class Key, class T, class Compare, class Allocator>
2927 bool operator==(const map<Key,T,Compare,Allocator>& x,
2928 const map<Key,T,Compare,Allocator>& y);
2929 T template <class Key, class T, class Compare, class Allocator>
2930 bool operator< (const map<Key,T,Compare,Allocator>& x,
2931 const map<Key,T,Compare,Allocator>& y);
2932 T template <class Key, class T, class Compare, class Allocator>
2933 bool operator!=(const map<Key,T,Compare,Allocator>& x,
2934 const map<Key,T,Compare,Allocator>& y);
2935 T template <class Key, class T, class Compare, class Allocator>
2936 bool operator> (const map<Key,T,Compare,Allocator>& x,
2937 const map<Key,T,Compare,Allocator>& y);
2938 T template <class Key, class T, class Compare, class Allocator>
2939 bool operator>=(const map<Key,T,Compare,Allocator>& x,
2940 const map<Key,T,Compare,Allocator>& y);
2941 T template <class Key, class T, class Compare, class Allocator>
2942 bool operator<=(const map<Key,T,Compare,Allocator>& x,
2943 const map<Key,T,Compare,Allocator>& y);
2944 T template <class Key, class T, class Compare, class Allocator>
2945 void swap(map<Key,T,Compare,Allocator>& x,
2946 map<Key,T,Compare,Allocator>& y);
2947 T template <class Key, class T, class Compare = less<Key>,
2948 class Allocator = allocator<pair<const Key, T> > >
2949 class multimap;
2950 T template <class Key, class T, class Compare, class Allocator>
2951 bool operator==(const multimap<Key,T,Compare,Allocator>& x,
2952 const multimap<Key,T,Compare,Allocator>& y);
2953 T template <class Key, class T, class Compare, class Allocator>
2954 bool operator< (const multimap<Key,T,Compare,Allocator>& x,
2955 const multimap<Key,T,Compare,Allocator>& y);
2956 T template <class Key, class T, class Compare, class Allocator>
2957 bool operator!=(const multimap<Key,T,Compare,Allocator>& x,
2958 const multimap<Key,T,Compare,Allocator>& y);
2959 T template <class Key, class T, class Compare, class Allocator>
2960 bool operator> (const multimap<Key,T,Compare,Allocator>& x,
2961 const multimap<Key,T,Compare,Allocator>& y);
2962 T template <class Key, class T, class Compare, class Allocator>
2963 bool operator>=(const multimap<Key,T,Compare,Allocator>& x,
2964 const multimap<Key,T,Compare,Allocator>& y);
2965 T template <class Key, class T, class Compare, class Allocator>
2966 bool operator<=(const multimap<Key,T,Compare,Allocator>& x,
2967 const multimap<Key,T,Compare,Allocator>& y);
2968 T template <class Key, class T, class Compare, class Allocator>
2969 void swap(multimap<Key,T,Compare,Allocator>& x,
2970 multimap<Key,T,Compare,Allocator>& y);
2973 Header <set> synopsis
2975 template <class Key, class Compare = less<Key>,
2976 class Allocator = allocator<Key> >
2977 T class set;
2979 T template <class Key, class Compare, class Allocator>
2980 bool operator==(const set<Key,Compare,Allocator>& x,
2981 const set<Key,Compare,Allocator>& y);
2982 T template <class Key, class Compare, class Allocator>
2983 bool operator< (const set<Key,Compare,Allocator>& x,
2984 const set<Key,Compare,Allocator>& y);
2985 T template <class Key, class Compare, class Allocator>
2986 bool operator!=(const set<Key,Compare,Allocator>& x,
2987 const set<Key,Compare,Allocator>& y);
2988 T template <class Key, class Compare, class Allocator>
2989 bool operator> (const set<Key,Compare,Allocator>& x,
2990 const set<Key,Compare,Allocator>& y);
2991 T template <class Key, class Compare, class Allocator>
2992 bool operator>=(const set<Key,Compare,Allocator>& x,
2993 const set<Key,Compare,Allocator>& y);
2994 T template <class Key, class Compare, class Allocator>
2995 bool operator<=(const set<Key,Compare,Allocator>& x,
2996 const set<Key,Compare,Allocator>& y);
2997 T template <class Key, class Compare, class Allocator>
2998 void swap(set<Key,Compare,Allocator>& x,
2999 set<Key,Compare,Allocator>& y);
3000 T template <class Key, class Compare = less<Key>,
3001 class Allocator = allocator<Key> >
3002 class multiset;
3003 T template <class Key, class Compare, class Allocator>
3004 bool operator==(const multiset<Key,Compare,Allocator>& x,
3005 const multiset<Key,Compare,Allocator>& y);
3006 T template <class Key, class Compare, class Allocator>
3007 bool operator< (const multiset<Key,Compare,Allocator>& x,
3008 const multiset<Key,Compare,Allocator>& y);
3009 T template <class Key, class Compare, class Allocator>
3010 bool operator!=(const multiset<Key,Compare,Allocator>& x,
3011 const multiset<Key,Compare,Allocator>& y);
3012 T template <class Key, class Compare, class Allocator>
3013 bool operator> (const multiset<Key,Compare,Allocator>& x,
3014 const multiset<Key,Compare,Allocator>& y);
3015 T template <class Key, class Compare, class Allocator>
3016 bool operator>=(const multiset<Key,Compare,Allocator>& x,
3017 const multiset<Key,Compare,Allocator>& y);
3018 T template <class Key, class Compare, class Allocator>
3019 bool operator<=(const multiset<Key,Compare,Allocator>& x,
3020 const multiset<Key,Compare,Allocator>& y);
3021 T template <class Key, class Compare, class Allocator>
3022 void swap(multiset<Key,Compare,Allocator>& x,
3023 multiset<Key,Compare,Allocator>& y);
3026 23.3.1 Template class map [lib.map]
3028 template <class Key, class T, class Compare = less<Key>,
3029 class Allocator = allocator<pair<const Key, T> > >
3030 T class map {
3031 public:
3032 // types:
3033 T typedef Key key_type;
3034 T typedef T mapped_type;
3035 T typedef pair<const Key, T> value_type;
3036 T typedef Compare key_compare;
3037 T typedef Allocator allocator_type;
3038 T typedef typename Allocator::reference reference;
3039 T typedef typename Allocator::const_reference const_reference;
3040 T typedef implementation defined iterator;
3041 T typedef implementation defined const_iterator;
3042 T typedef implementation defined size_type;
3043 T typedef implementation defined difference_type;
3044 T typedef typename Allocator::pointer pointer;
3045 T typedef typename Allocator::const_pointer const_pointer;
3046 T typedef std::reverse_iterator<iterator> reverse_iterator;
3047 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
3048 T class value_compare
3049 : public binary_function<value_type,value_type,bool> {
3050 friend class map;
3051 protected:
3052 T Compare comp;
3053 T value_compare(Compare c) : comp(c) {}
3054 public:
3055 T bool operator()(const value_type& x, const value_type& y) const {
3056 return comp(x.first, y.first);
3060 // _lib.map.cons_ construct/copy/destroy:
3061 T explicit map(const Compare& comp = Compare(),
3062 const Allocator& = Allocator());
3063 T template <class InputIterator>
3064 map(InputIterator first, InputIterator last,
3065 const Compare& comp = Compare(), const Allocator& = Allocator());
3066 T map(const map<Key,T,Compare,Allocator>& x);
3067 T ~map();
3068 T map<Key,T,Compare,Allocator>&
3069 operator=(const map<Key,T,Compare,Allocator>& x);
3070 // iterators:
3071 T iterator begin();
3072 T const_iterator begin() const;
3073 T iterator end();
3074 T const_iterator end() const;
3075 T reverse_iterator rbegin();
3076 T const_reverse_iterator rbegin() const;
3077 T reverse_iterator rend();
3078 T const_reverse_iterator rend() const;
3079 // capacity:
3080 T bool empty() const;
3081 T size_type size() const;
3082 T size_type max_size() const;
3083 // _lib.map.access_ element access:
3084 T T& operator[](const key_type& x);
3085 // modifiers:
3086 T pair<iterator, bool> insert(const value_type& x);
3087 T iterator insert(iterator position, const value_type& x);
3088 T template <class InputIterator>
3089 void insert(InputIterator first, InputIterator last);
3090 T void erase(iterator position);
3091 T size_type erase(const key_type& x);
3092 T void erase(iterator first, iterator last);
3093 T void swap(map<Key,T,Compare,Allocator>&);
3094 T void clear();
3095 // observers:
3096 T key_compare key_comp() const;
3097 T value_compare value_comp() const;
3098 // _lib.map.ops_ map operations:
3099 T iterator find(const key_type& x);
3100 T const_iterator find(const key_type& x) const;
3101 T size_type count(const key_type& x) const;
3102 T iterator lower_bound(const key_type& x);
3103 T const_iterator lower_bound(const key_type& x) const;
3104 T iterator upper_bound(const key_type& x);
3105 T const_iterator upper_bound(const key_type& x) const;
3106 T pair<iterator,iterator>
3107 equal_range(const key_type& x);
3108 T pair<const_iterator,const_iterator>
3109 equal_range(const key_type& x) const;
3112 T template <class Key, class T, class Compare, class Allocator>
3113 bool operator==(const map<Key,T,Compare,Allocator>& x,
3114 const map<Key,T,Compare,Allocator>& y);
3115 T template <class Key, class T, class Compare, class Allocator>
3116 bool operator< (const map<Key,T,Compare,Allocator>& x,
3117 const map<Key,T,Compare,Allocator>& y);
3118 T template <class Key, class T, class Compare, class Allocator>
3119 bool operator!=(const map<Key,T,Compare,Allocator>& x,
3120 const map<Key,T,Compare,Allocator>& y);
3121 T template <class Key, class T, class Compare, class Allocator>
3122 bool operator> (const map<Key,T,Compare,Allocator>& x,
3123 const map<Key,T,Compare,Allocator>& y);
3124 T template <class Key, class T, class Compare, class Allocator>
3125 bool operator>=(const map<Key,T,Compare,Allocator>& x,
3126 const map<Key,T,Compare,Allocator>& y);
3127 T template <class Key, class T, class Compare, class Allocator>
3128 bool operator<=(const map<Key,T,Compare,Allocator>& x,
3129 const map<Key,T,Compare,Allocator>& y);
3130 // specialized algorithms:
3131 T template <class Key, class T, class Compare, class Allocator>
3132 void swap(map<Key,T,Compare,Allocator>& x,
3133 map<Key,T,Compare,Allocator>& y);
3135 23.3.2 Template class multimap [lib.multimap]
3137 template <class Key, class T, class Compare = less<Key>,
3138 class Allocator = allocator<pair<const Key, T> > >
3139 T class multimap {
3140 public:
3141 // types:
3142 T typedef Key key_type;
3143 T typedef T mapped_type;
3144 T typedef pair<const Key,T> value_type;
3145 T typedef Compare key_compare;
3146 T typedef Allocator allocator_type;
3147 T typedef typename Allocator::reference reference;
3148 T typedef typename Allocator::const_reference const_reference;
3149 T typedef implementation defined iterator;
3150 T typedef implementation defined const_iterator;
3151 T typedef implementation defined size_type;
3152 T typedef implementation defined difference_type
3153 T typedef typename Allocator::pointer pointer;
3154 T typedef typename Allocator::const_pointer const_pointer;
3155 T typedef std::reverse_iterator<iterator> reverse_iterator;
3156 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
3157 T class value_compare
3158 : public binary_function<value_type,value_type,bool> {
3159 friend class multimap;
3160 protected:
3161 T Compare comp;
3162 T value_compare(Compare c) : comp(c) {}
3163 public:
3164 T bool operator()(const value_type& x, const value_type& y) const {
3165 return comp(x.first, y.first);
3168 // construct/copy/destroy:
3169 T explicit multimap(const Compare& comp = Compare(),
3170 const Allocator& = Allocator());
3171 T template <class InputIterator>
3172 multimap(InputIterator first, InputIterator last,
3173 const Compare& comp = Compare(),
3174 const Allocator& = Allocator());
3175 T multimap(const multimap<Key,T,Compare,Allocator>& x);
3176 T ~multimap();
3177 T multimap<Key,T,Compare,Allocator>&
3178 operator=(const multimap<Key,T,Compare,Allocator>& x);
3179 T allocator_type get_allocator() const;
3181 // iterators:
3182 T iterator begin();
3183 T const_iterator begin() const;
3184 T iterator end();
3185 T const_iterator end() const;
3186 T reverse_iterator rbegin();
3187 T const_reverse_iterator rbegin() const;
3188 T reverse_iterator rend();
3189 T const_reverse_iterator rend() const;
3190 // capacity:
3191 T bool empty() const;
3192 T size_type size() const;
3193 T size_type max_size() const;
3194 // modifiers:
3195 T iterator insert(const value_type& x);
3196 T iterator insert(iterator position, const value_type& x);
3197 T template <class InputIterator>
3198 void insert(InputIterator first, InputIterator last);
3199 T void erase(iterator position);
3200 T size_type erase(const key_type& x);
3201 T void erase(iterator first, iterator last);
3202 T void swap(multimap<Key,T,Compare,Allocator>&);
3203 T void clear();
3204 // observers:
3205 T key_compare key_comp() const;
3206 T value_compare value_comp() const;
3207 // map operations:
3208 T iterator find(const key_type& x);
3209 T const_iterator find(const key_type& x) const;
3210 T size_type count(const key_type& x) const;
3211 T iterator lower_bound(const key_type& x);
3212 T const_iterator lower_bound(const key_type& x) const;
3213 T iterator upper_bound(const key_type& x);
3214 T const_iterator upper_bound(const key_type& x) const;
3215 T pair<iterator,iterator> equal_range(const key_type& x);
3216 T pair<const_iterator,const_iterator> equal_range(const key_type& x) const;
3219 T template <class Key, class T, class Compare, class Allocator>
3220 bool operator==(const multimap<Key,T,Compare,Allocator>& x,
3221 const multimap<Key,T,Compare,Allocator>& y);
3222 T template <class Key, class T, class Compare, class Allocator>
3223 bool operator< (const multimap<Key,T,Compare,Allocator>& x,
3224 const multimap<Key,T,Compare,Allocator>& y);
3225 T template <class Key, class T, class Compare, class Allocator>
3226 bool operator!=(const multimap<Key,T,Compare,Allocator>& x,
3227 const multimap<Key,T,Compare,Allocator>& y);
3228 T template <class Key, class T, class Compare, class Allocator>
3229 bool operator> (const multimap<Key,T,Compare,Allocator>& x,
3230 const multimap<Key,T,Compare,Allocator>& y);
3231 T template <class Key, class T, class Compare, class Allocator>
3232 bool operator>=(const multimap<Key,T,Compare,Allocator>& x,
3233 const multimap<Key,T,Compare,Allocator>& y);
3234 T template <class Key, class T, class Compare, class Allocator>
3235 bool operator<=(const multimap<Key,T,Compare,Allocator>& x,
3236 const multimap<Key,T,Compare,Allocator>& y);
3237 // specialized algorithms:
3238 T template <class Key, class T, class Compare, class Allocator>
3239 void swap(multimap<Key,T,Compare,Allocator>& x,
3240 multimap<Key,T,Compare,Allocator>& y);
3243 23.3.3 Template class set [lib.set]
3245 template <class Key, class Compare = less<Key>,
3246 class Allocator = allocator<Key> >
3247 T class set {
3248 public:
3249 // types:
3250 T typedef Key key_type;
3251 T typedef Key value_type;
3252 T typedef Compare key_compare;
3253 T typedef Compare value_compare;
3254 T typedef Allocator allocator_type;
3255 T typedef typename Allocator::reference reference;
3256 T typedef typename Allocator::const_reference const_reference;
3257 T typedef implementation defined iterator;
3258 T typedef implementation defined const_iterator;
3259 T typedef implementation defined size_type;
3260 T typedef implementation defined difference_type;
3261 T typedef typename Allocator::pointer pointer;
3262 T typedef typename Allocator::const_pointer const_pointer;
3263 T typedef std::reverse_iterator<iterator> reverse_iterator;
3264 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
3265 // _lib.set.cons_ construct/copy/destroy:
3266 T explicit set(const Compare& comp = Compare(),
3267 const Allocator& = Allocator());
3268 T template <class InputIterator>
3269 set(InputIterator first, InputIterator last,
3270 const Compare& comp = Compare(), const Allocator& = Allocator());
3271 T set(const set<Key,Compare,Allocator>& x);
3272 T ~set();
3273 T set<Key,Compare,Allocator>&
3274 operator=(const set<Key,Compare,Allocator>& x);
3275 T allocator_type get_allocator() const;
3276 // iterators:
3277 T iterator begin();
3278 T const_iterator begin() const;
3279 T iterator end();
3280 T const_iterator end() const;
3281 T reverse_iterator rbegin();
3282 T const_reverse_iterator rbegin() const;
3283 T reverse_iterator rend();
3284 T const_reverse_iterator rend() const;
3285 // capacity:
3286 T bool empty() const;
3287 T size_type size() const;
3288 T size_type max_size() const;
3289 // modifiers:
3290 T pair<iterator,bool> insert(const value_type& x);
3291 T iterator insert(iterator position, const value_type& x);
3292 T template <class InputIterator>
3293 T void insert(InputIterator first, InputIterator last);
3294 T void erase(iterator position);
3295 T size_type erase(const key_type& x);
3296 T void erase(iterator first, iterator last);
3297 T void swap(set<Key,Compare,Allocator>&);
3298 T void clear();
3300 // observers:
3301 T key_compare key_comp() const;
3302 T value_compare value_comp() const;
3303 // set operations:
3304 T iterator find(const key_type& x) const;
3305 T size_type count(const key_type& x) const;
3306 T iterator lower_bound(const key_type& x) const;
3307 T iterator upper_bound(const key_type& x) const;
3308 T pair<iterator,iterator> equal_range(const key_type& x) const;
3310 T template <class Key, class Compare, class Allocator>
3311 bool operator==(const set<Key,Compare,Allocator>& x,
3312 const set<Key,Compare,Allocator>& y);
3313 T template <class Key, class Compare, class Allocator>
3314 bool operator< (const set<Key,Compare,Allocator>& x,
3315 const set<Key,Compare,Allocator>& y);
3316 T template <class Key, class Compare, class Allocator>
3317 bool operator!=(const set<Key,Compare,Allocator>& x,
3318 const set<Key,Compare,Allocator>& y);
3319 T template <class Key, class Compare, class Allocator>
3320 bool operator> (const set<Key,Compare,Allocator>& x,
3321 const set<Key,Compare,Allocator>& y);
3322 T template <class Key, class Compare, class Allocator>
3323 bool operator>=(const set<Key,Compare,Allocator>& x,
3324 const set<Key,Compare,Allocator>& y);
3325 T template <class Key, class Compare, class Allocator>
3326 bool operator<=(const set<Key,Compare,Allocator>& x,
3327 const set<Key,Compare,Allocator>& y);
3328 // specialized algorithms:
3329 T template <class Key, class Compare, class Allocator>
3330 void swap(set<Key,Compare,Allocator>& x,
3331 set<Key,Compare,Allocator>& y);
3333 23.3.4 Template class multiset [lib.multiset]
3335 template <class Key, class Compare = less<Key>,
3336 class Allocator = allocator<Key> >
3337 T class multiset {
3338 public:
3339 // types:
3340 T typedef Key key_type;
3341 T typedef Key value_type;
3342 T typedef Compare key_compare;
3343 T typedef Compare value_compare;
3344 T typedef Allocator allocator_type;
3345 T typedef typename Allocator::reference reference;
3346 T typedef typename Allocator::const_reference const_reference;
3347 T typedef implementation defined iterator;
3348 T typedef implementation defined const_iterator;
3349 T typedef implementation defined size_type;
3350 T typedef implementation defined difference_type
3351 T typedef typename Allocator::pointer pointer;
3352 T typedef typename Allocator::const_pointer const_pointer;
3353 T typedef std::reverse_iterator<iterator> reverse_iterator;
3354 T typedef std::reverse_iterator<const_iterator> const_reverse_iterator;
3356 // construct/copy/destroy:
3357 T explicit multiset(const Compare& comp = Compare(),
3358 const Allocator& = Allocator());
3359 T template <class InputIterator>
3360 multiset(InputIterator first, InputIterator last,
3361 const Compare& comp = Compare(),
3362 const Allocator& = Allocator());
3363 T multiset(const multiset<Key,Compare,Allocator>& x);
3364 T ~multiset();
3365 T multiset<Key,Compare,Allocator>&
3366 operator=(const multiset<Key,Compare,Allocator>& x);
3367 T allocator_type get_allocator() const;
3368 // iterators:
3369 T iterator begin();
3370 T const_iterator begin() const;
3371 T iterator end();
3372 T const_iterator end() const;
3373 T reverse_iterator rbegin();
3374 T const_reverse_iterator rbegin() const;
3375 T reverse_iterator rend();
3376 T const_reverse_iterator rend() const;
3377 // capacity:
3378 T bool empty() const;
3379 T size_type size() const;
3380 T size_type max_size() const;
3381 // modifiers:
3382 T iterator insert(const value_type& x);
3383 T iterator insert(iterator position, const value_type& x);
3384 T template <class InputIterator>
3385 void insert(InputIterator first, InputIterator last);
3386 T void erase(iterator position);
3387 T size_type erase(const key_type& x);
3388 T void erase(iterator first, iterator last);
3389 T void swap(multiset<Key,Compare,Allocator>&);
3390 T void clear();
3391 // observers:
3392 T key_compare key_comp() const;
3393 T value_compare value_comp() const;
3394 // set operations:
3395 T iterator find(const key_type& x) const;
3396 T size_type count(const key_type& x) const;
3397 T iterator lower_bound(const key_type& x) const;
3398 T iterator upper_bound(const key_type& x) const;
3399 T pair<iterator,iterator> equal_range(const key_type& x) const;
3402 T template <class Key, class Compare, class Allocator>
3403 bool operator==(const multiset<Key,Compare,Allocator>& x,
3404 const multiset<Key,Compare,Allocator>& y);
3405 T template <class Key, class Compare, class Allocator>
3406 bool operator< (const multiset<Key,Compare,Allocator>& x,
3407 const multiset<Key,Compare,Allocator>& y);
3408 T template <class Key, class Compare, class Allocator>
3409 bool operator!=(const multiset<Key,Compare,Allocator>& x,
3410 const multiset<Key,Compare,Allocator>& y);
3411 T template <class Key, class Compare, class Allocator>
3412 bool operator> (const multiset<Key,Compare,Allocator>& x,
3413 const multiset<Key,Compare,Allocator>& y);
3414 T template <class Key, class Compare, class Allocator>
3415 bool operator>=(const multiset<Key,Compare,Allocator>& x,
3416 const multiset<Key,Compare,Allocator>& y);
3417 T template <class Key, class Compare, class Allocator>
3418 bool operator<=(const multiset<Key,Compare,Allocator>& x,
3419 const multiset<Key,Compare,Allocator>& y);
3420 // specialized algorithms:
3421 T template <class Key, class Compare, class Allocator>
3422 void swap(multiset<Key,Compare,Allocator>& x,
3423 multiset<Key,Compare,Allocator>& y);
3425 23.3.5 Template class bitset [lib.template.bitset]
3427 Header <bitset> synopsis
3429 T template <size_t N> class bitset;
3430 // _lib.bitset.operators_ bitset operations:
3431 T template <size_t N>
3432 bitset<N> operator&(const bitset<N>&, const bitset<N>&);
3433 T template <size_t N>
3434 bitset<N> operator|(const bitset<N>&, const bitset<N>&);
3435 T template <size_t N>
3436 bitset<N> operator^(const bitset<N>&, const bitset<N>&);
3437 T template <class charT, class traits, size_t N>
3438 basic_istream<charT, traits>&
3439 operator>>(basic_istream<charT, traits>& is, bitset<N>& x);
3440 T template <class charT, class traits, size_t N>
3441 basic_ostream<charT, traits>&
3442 operator<<(basic_ostream<charT, traits>& os, const bitset<N>& x);
3444 T template<size_t N> class bitset {
3445 public:
3446 // bit reference:
3447 T class reference {
3448 friend class bitset;
3449 T reference();
3450 public:
3451 T ~reference();
3452 T reference& operator=(bool x); // for b[i] = x;
3453 T reference& operator=(const reference&); // for b[i] = b[j];
3454 T bool operator~() const; // flips the bit
3455 T operator bool() const; // for x = b[i];
3456 T reference& flip(); // for b[i].flip();
3459 // _lib.bitset.cons_ constructors:
3460 T bitset();
3461 T bitset(unsigned long val);
3462 T template<class charT, class traits, class Allocator>
3463 explicit bitset(
3464 const basic_string<charT,traits,Allocator>& str,
3465 typename basic_string<charT,traits,Allocator>::size_type pos = 0,
3466 typename basic_string<charT,traits,Allocator>::size_type n =
3467 basic_string<charT,traits,Allocator>::npos);
3468 // _lib.bitset.members_ bitset operations:
3469 T bitset<N>& operator&=(const bitset<N>& rhs);
3470 T bitset<N>& operator|=(const bitset<N>& rhs);
3471 T bitset<N>& operator^=(const bitset<N>& rhs);
3472 T bitset<N>& operator<<=(size_t pos);
3473 T bitset<N>& operator>>=(size_t pos);
3474 T bitset<N>& set();
3475 T bitset<N>& set(size_t pos, int val = true);
3476 T bitset<N>& reset();
3477 T bitset<N>& reset(size_t pos);
3478 T bitset<N> operator~() const;
3479 T bitset<N>& flip();
3480 T bitset<N>& flip(size_t pos);
3481 // element access:
3482 T reference operator[](size_t pos); // for b[i];
3483 T unsigned long to_ulong() const;
3484 T template <class charT, class traits, class Allocator>
3485 basic_string<charT, traits, Allocator> to_string() const;
3486 T size_t count() const;
3487 T size_t size() const;
3488 T bool operator==(const bitset<N>& rhs) const;
3489 T bool operator!=(const bitset<N>& rhs) const;
3490 T bool test(size_t pos) const;
3491 T bool any() const;
3492 T bool none() const;
3493 T bitset<N> operator<<(size_t pos) const;
3494 T bitset<N> operator>>(size_t pos) const;
3500 24.2 Header <iterator> synopsis [lib.iterator.synopsis]
3502 // _lib.iterator.primitives_, primitives:
3503 T template<class Iterator> struct iterator_traits;
3504 T template<class T> struct iterator_traits<T*>;
3506 X template<class Category, class T, class Distance = ptrdiff_t,
3507 class Pointer = T*, class Reference = T&> struct iterator;
3508 T struct input_iterator_tag {};
3509 T struct output_iterator_tag {};
3510 T struct forward_iterator_tag: public input_iterator_tag {};
3511 T struct bidirectional_iterator_tag: public forward_iterator_tag {};
3512 T struct random_access_iterator_tag: public bidirectional_iterator_tag {};
3513 // _lib.iterator.operations_, iterator operations:
3514 T template <class InputIterator, class Distance>
3515 void advance(InputIterator& i, Distance n);
3516 T template <class InputIterator>
3517 typename iterator_traits<InputIterator>::difference_type
3518 distance(InputIterator first, InputIterator last);
3519 // _lib.predef.iterators_, predefined iterators:
3520 X template <class Iterator> class reverse_iterator;
3521 T template <class Iterator>
3522 bool operator==(
3523 const reverse_iterator<Iterator>& x,
3524 const reverse_iterator<Iterator>& y);
3525 T template <class Iterator>
3526 bool operator<(
3527 const reverse_iterator<Iterator>& x,
3528 const reverse_iterator<Iterator>& y);
3529 T template <class Iterator>
3530 bool operator!=(
3531 const reverse_iterator<Iterator>& x,
3532 const reverse_iterator<Iterator>& y);
3533 T template <class Iterator>
3534 bool operator>(
3535 const reverse_iterator<Iterator>& x,
3536 const reverse_iterator<Iterator>& y);
3537 T template <class Iterator>
3538 bool operator>=(
3539 const reverse_iterator<Iterator>& x,
3540 const reverse_iterator<Iterator>& y);
3541 T template <class Iterator>
3542 bool operator<=(
3543 const reverse_iterator<Iterator>& x,
3544 const reverse_iterator<Iterator>& y);
3545 T template <class Iterator>
3546 typename reverse_iterator<Iterator>::difference_type operator-(
3547 const reverse_iterator<Iterator>& x,
3548 const reverse_iterator<Iterator>& y);
3549 T template <class Iterator>
3550 reverse_iterator<Iterator>
3551 operator+(
3552 typename reverse_iterator<Iterator>::difference_type n,
3553 const reverse_iterator<Iterator>& x);
3555 X template <class Container> class back_insert_iterator;
3556 T template <class Container>
3557 back_insert_iterator<Container> back_inserter(Container& x);
3558 X template <class Container> class front_insert_iterator;
3559 T template <class Container>
3560 front_insert_iterator<Container> front_inserter(Container& x);
3561 X template <class Container> class insert_iterator;
3562 T template <class Container, class Iterator>
3563 insert_iterator<Container> inserter(Container& x, Iterator i);
3564 // _lib.stream.iterators_, stream iterators:
3565 X template <class T, class charT = char, class traits = char_traits<charT>,
3566 class Distance = ptrdiff_t>
3567 class istream_iterator;
3568 template <class T, class charT, class traits, class Distance>
3569 X bool operator==(const istream_iterator<T,charT,traits,Distance>& x,
3570 const istream_iterator<T,charT,traits,Distance>& y);
3571 template <class T, class charT, class traits, class Distance>
3572 X bool operator!=(const istream_iterator<T,charT,traits,Distance>& x,
3573 const istream_iterator<T,charT,traits,Distance>& y);
3574 X template <class T, class charT = char, class traits = char_traits<charT> >
3575 class ostream_iterator;
3576 X template<class charT, class traits = char_traits<charT> >
3577 class istreambuf_iterator;
3578 X template <class charT, class traits>
3579 bool operator==(const istreambuf_iterator<charT,traits>& a,
3580 const istreambuf_iterator<charT,traits>& b);
3581 X template <class charT, class traits>
3582 bool operator!=(const istreambuf_iterator<charT,traits>& a,
3583 const istreambuf_iterator<charT,traits>& b);
3584 T template <class charT, class traits = char_traits<charT> >
3585 class ostreambuf_iterator;
3587 24.3 Iterator primitives [lib.iterator.primitives]
3589 T template<class Iterator> struct iterator_traits {
3590 T typedef typename Iterator::difference_type difference_type;
3591 T typedef typename Iterator::value_type value_type;
3592 T typedef typename Iterator::pointer pointer;
3593 T typedef typename Iterator::reference reference;
3594 T typedef typename Iterator::iterator_category iterator_category;
3597 T template<class T> struct iterator_traits<T*> {
3598 T typedef ptrdiff_t difference_type;
3599 T typedef T value_type;
3600 T typedef T* pointer;
3601 T typedef T& reference;
3602 T typedef random_access_iterator_tag iterator_category;
3605 T template<class T> struct iterator_traits<const T*> {
3606 T typedef ptrdiff_t difference_type;
3607 T typedef T value_type;
3608 T typedef const T* pointer;
3609 T typedef const T& reference;
3610 T typedef random_access_iterator_tag iterator_category;
3613 24.3.2 Basic iterator [lib.iterator.basic]
3615 template<class Category, class T, class Distance = ptrdiff_t,
3616 class Pointer = T*, class Reference = T&>
3617 X struct iterator {
3618 T typedef T value_type;
3619 T typedef Distance difference_type;
3620 T typedef Pointer pointer;
3621 T typedef Reference reference;
3622 T typedef Category iterator_category;
3625 24.3.3 Standard iterator tags [lib.std.iterator.tags]
3627 T struct input_iterator_tag {};
3628 T struct output_iterator_tag {};
3629 T struct forward_iterator_tag: public input_iterator_tag {};
3630 T struct bidirectional_iterator_tag: public forward_iterator_tag {};
3631 T struct random_access_iterator_tag: public bidirectional_iterator_tag {};
3634 24.4.1 Reverse iterators [lib.reverse.iterators]
3636 template <class Iterator>
3637 X class reverse_iterator : public
3638 iterator<typename iterator_traits<Iterator>::iterator_category,
3639 typename iterator_traits<Iterator>::value_type,
3640 typename iterator_traits<Iterator>::difference_type,
3641 typename iterator_traits<Iterator>::pointer,
3642 typename iterator_traits<Iterator>::reference> {
3643 protected:
3644 T Iterator current;
3645 public:
3646 T typedef Iterator
3647 iterator_type;
3648 T typedef typename iterator_traits<Iterator>::difference_type
3649 difference_type;
3650 T typedef typename iterator_traits<Iterator>::reference
3651 reference;
3652 T typedef typename iterator_traits<Iterator>::pointer
3653 pointer;
3655 T reverse_iterator();
3656 T explicit reverse_iterator(Iterator x);
3657 T template <class U> reverse_iterator(const reverse_iterator<U>& u);
3658 T Iterator base() const; // explicit
3659 T reference operator*() const;
3660 T pointer operator->() const;
3661 T reverse_iterator& operator++();
3662 T reverse_iterator operator++(int);
3663 T reverse_iterator& operator--();
3664 T reverse_iterator operator--(int);
3666 T reverse_iterator operator+ (difference_type n) const;
3667 T reverse_iterator& operator+=(difference_type n);
3668 T reverse_iterator operator- (difference_type n) const;
3669 T reverse_iterator& operator-=(difference_type n);
3670 T reference operator[](difference_type n) const;
3672 T template <class Iterator>
3673 bool operator==(
3674 const reverse_iterator<Iterator>& x,
3675 const reverse_iterator<Iterator>& y);
3676 T template <class Iterator>
3677 bool operator<(
3678 const reverse_iterator<Iterator>& x,
3679 const reverse_iterator<Iterator>& y);
3680 T template <class Iterator>
3681 bool operator!=(
3682 const reverse_iterator<Iterator>& x,
3683 const reverse_iterator<Iterator>& y);
3684 T template <class Iterator>
3685 bool operator>(
3686 const reverse_iterator<Iterator>& x,
3687 const reverse_iterator<Iterator>& y);
3688 T template <class Iterator>
3689 bool operator>=(
3690 const reverse_iterator<Iterator>& x,
3691 const reverse_iterator<Iterator>& y);
3692 T template <class Iterator>
3693 bool operator<=(
3694 const reverse_iterator<Iterator>& x,
3695 const reverse_iterator<Iterator>& y);
3696 T template <class Iterator>
3697 typename reverse_iterator<Iterator>::difference_type operator-(
3698 const reverse_iterator<Iterator>& x,
3699 const reverse_iterator<Iterator>& y);
3700 T template <class Iterator>
3701 reverse_iterator<Iterator> operator+(
3702 typename reverse_iterator<Iterator>::difference_type n,
3703 const reverse_iterator<Iterator>& x);
3706 24.4.2.1 Template class [lib.back.insert.iterator]
3707 back_insert_iterator
3709 template <class Container>
3710 X class back_insert_iterator :
3711 public iterator<output_iterator_tag,void,void,void,void> {
3712 protected:
3713 T Container* container;
3714 public:
3715 T typedef Container container_type;
3716 T explicit back_insert_iterator(Container& x);
3717 T back_insert_iterator<Container>&
3718 operator=(typename Container::const_reference value);
3720 T back_insert_iterator<Container>& operator*();
3721 T back_insert_iterator<Container>& operator++();
3722 T back_insert_iterator<Container> operator++(int);
3724 T template <class Container>
3725 back_insert_iterator<Container> back_inserter(Container& x);
3729 24.4.2.3 Template class [lib.front.insert.iterator]
3730 front_insert_iterator
3732 template <class Container>
3733 X class front_insert_iterator :
3734 public iterator<output_iterator_tag,void,void,void,void> {
3735 protected:
3736 T Container* container;
3737 public:
3738 T typedef Container container_type;
3739 T explicit front_insert_iterator(Container& x);
3740 T front_insert_iterator<Container>&
3741 operator=(typename Container::const_reference value);
3742 T front_insert_iterator<Container>& operator*();
3743 T front_insert_iterator<Container>& operator++();
3744 T front_insert_iterator<Container> operator++(int);
3746 T template <class Container>
3747 front_insert_iterator<Container> front_inserter(Container& x);
3750 24.4.2.5 Template class insert_iterator [lib.insert.iterator]
3752 template <class Container>
3753 X class insert_iterator :
3754 public iterator<output_iterator_tag,void,void,void,void> {
3755 protected:
3756 T Container* container;
3757 T typename Container::iterator iter;
3758 public:
3759 T typedef Container container_type;
3760 T insert_iterator(Container& x, typename Container::iterator i);
3761 T insert_iterator<Container>&
3762 operator=(typename Container::const_reference value);
3763 T insert_iterator<Container>& operator*();
3764 T insert_iterator<Container>& operator++();
3765 T insert_iterator<Container>& operator++(int);
3767 T template <class Container, class Iterator>
3768 insert_iterator<Container> inserter(Container& x, Iterator i);
3770 24.5.1 Template class istream_iterator [lib.istream.iterator]
3772 template <class T, class charT = char, class traits = char_traits<charT>,
3773 class Distance = ptrdiff_t>
3774 X class istream_iterator:
3775 public iterator<input_iterator_tag, T, Distance, const T*, const T&> {
3776 public:
3777 T typedef charT char_type
3778 T typedef traits traits_type;
3779 T typedef basic_istream<charT,traits> istream_type;
3780 T istream_iterator();
3781 T istream_iterator(istream_type& s);
3782 T istream_iterator(const istream_iterator<T,charT,traits,Distance>& x);
3783 T ~istream_iterator();
3785 T const T& operator*() const;
3786 T const T* operator->() const;
3787 T istream_iterator<T,charT,traits,Distance>& operator++();
3788 T istream_iterator<T,charT,traits,Distance> operator++(int);
3791 T template <class T, class charT, class traits, class Distance>
3792 bool operator==(const istream_iterator<T,charT,traits,Distance>& x,
3793 const istream_iterator<T,charT,traits,Distance>& y);
3794 T template <class T, class charT, class traits, class Distance>
3795 bool operator!=(const istream_iterator<T,charT,traits,Distance>& x,
3796 const istream_iterator<T,charT,traits,Distance>& y);
3799 24.5.2 Template class ostream_iterator [lib.ostream.iterator]
3801 template <class T, class charT = char, class traits = char_traits<charT> >
3802 X class ostream_iterator:
3803 public iterator<output_iterator_tag, void, void, void, void> {
3804 public:
3805 T typedef charT char_type;
3806 T typedef traits traits_type;
3807 T typedef basic_ostream<charT,traits> ostream_type;
3808 T ostream_iterator(ostream_type& s);
3809 T ostream_iterator(ostream_type& s, const charT* delimiter);
3810 T ostream_iterator(const ostream_iterator<T,charT,traits>& x);
3811 T ~ostream_iterator();
3812 T ostream_iterator<T,charT,traits>& operator=(const T& value);
3814 T ostream_iterator<T,charT,traits>& operator*();
3815 T ostream_iterator<T,charT,traits>& operator++();
3816 T ostream_iterator<T,charT,traits>& operator++(int);
3820 24.5.3 Template class [lib.istreambuf.iterator]
3821 istreambuf_iterator
3823 template<class charT, class traits = char_traits<charT> >
3824 X class istreambuf_iterator
3825 : public iterator<input_iterator_tag, charT,
3826 typename traits::off_type, charT*, charT&> {
3827 public:
3828 T typedef charT char_type;
3829 T typedef traits traits_type;
3830 T typedef typename traits::int_type int_type;
3831 T typedef basic_streambuf<charT,traits> streambuf_type;
3832 T typedef basic_istream<charT,traits> istream_type;
3833 T class proxy; // exposition only
3834 T istreambuf_iterator() throw();
3835 T istreambuf_iterator(istream_type& s) throw();
3836 T istreambuf_iterator(streambuf_type* s) throw();
3837 T istreambuf_iterator(const proxy& p) throw();
3838 T charT operator*() const;
3839 T istreambuf_iterator<charT,traits>& operator++();
3840 T proxy operator++(int);
3841 X bool equal(istreambuf_iterator& b);
3844 T template <class charT, class traits>
3845 bool operator==(const istreambuf_iterator<charT,traits>& a,
3846 const istreambuf_iterator<charT,traits>& b);
3848 T template <class charT, class traits>
3849 bool operator!=(const istreambuf_iterator<charT,traits>& a,
3850 const istreambuf_iterator<charT,traits>& b);
3852 24.5.3.1 Template class [lib.istreambuf.iterator::proxy]
3853 istreambuf_iterator::proxy
3855 template <class charT, class traits = char_traits<charT> >
3856 T class istreambuf_iterator<charT, traits>::proxy
3858 T charT keep_;
3859 T basic_streambuf<charT,traits>* sbuf_;
3860 T proxy(charT c,
3861 basic_streambuf<charT,traits>* sbuf);
3862 : keep_(c), sbuf_(sbuf) {}
3863 public:
3864 T charT operator*() { return keep_; }
3869 24.5.4 Template class [lib.ostreambuf.iterator]
3870 ostreambuf_iterator
3872 template <class charT, class traits = char_traits<charT> >
3873 T class ostreambuf_iterator:
3874 public iterator<output_iterator_tag, void, void, void, void> {
3875 public:
3876 T typedef charT char_type;
3877 T typedef traits traits_type;
3878 T typedef basic_streambuf<charT,traits> streambuf_type;
3879 T typedef basic_ostream<charT,traits> ostream_type;
3880 public:
3881 T ostreambuf_iterator(ostream_type& s) throw();
3882 T ostreambuf_iterator(streambuf_type* s) throw();
3883 T ostreambuf_iterator& operator=(charT c);
3884 T ostreambuf_iterator& operator*();
3885 T ostreambuf_iterator& operator++();
3886 T ostreambuf_iterator& operator++(int);
3887 T bool failed() const throw();
3891 Header <algorithm> synopsis
3894 // _lib.alg.nonmodifying_, non-modifying sequence operations:
3895 T template<class InputIterator, class Function>
3896 Function for_each(InputIterator first, InputIterator last, Function f);
3897 T template<class InputIterator, class T>
3898 InputIterator find(InputIterator first, InputIterator last,
3899 const T& value);
3900 T template<class InputIterator, class Predicate>
3901 InputIterator find_if(InputIterator first, InputIterator last,
3902 Predicate pred);
3903 T template<class ForwardIterator1, class ForwardIterator2>
3904 ForwardIterator1
3905 find_end(ForwardIterator1 first1, ForwardIterator1 last1,
3906 ForwardIterator2 first2, ForwardIterator2 last2);
3907 T template<class ForwardIterator1, class ForwardIterator2,
3908 class BinaryPredicate>
3909 ForwardIterator1
3910 find_end(ForwardIterator1 first1, ForwardIterator1 last1,
3911 ForwardIterator2 first2, ForwardIterator2 last2,
3912 BinaryPredicate pred);
3913 T template<class ForwardIterator1, class ForwardIterator2>
3914 ForwardIterator1
3915 find_first_of(ForwardIterator1 first1, ForwardIterator1 last1,
3916 ForwardIterator2 first2, ForwardIterator2 last2);
3917 T template<class ForwardIterator1, class ForwardIterator2,
3918 class BinaryPredicate>
3919 ForwardIterator1
3920 find_first_of(ForwardIterator1 first1, ForwardIterator1 last1,
3921 ForwardIterator2 first2, ForwardIterator2 last2,
3922 BinaryPredicate pred);
3923 T template<class ForwardIterator>
3924 ForwardIterator adjacent_find(ForwardIterator first,
3925 ForwardIterator last);
3926 T template<class ForwardIterator, class BinaryPredicate>
3927 ForwardIterator adjacent_find(ForwardIterator first,
3928 ForwardIterator last, BinaryPredicate pred);
3929 T template<class InputIterator, class T>
3930 typename iterator_traits<InputIterator>::difference_type
3931 count(InputIterator first, InputIterator last, const T& value);
3932 T template<class InputIterator, class Predicate>
3933 typename iterator_traits<InputIterator>::difference_type
3934 count_if(InputIterator first, InputIterator last, Predicate pred);
3935 T template<class InputIterator1, class InputIterator2>
3936 pair<InputIterator1, InputIterator2>
3937 mismatch(InputIterator1 first1, InputIterator1 last1,
3938 InputIterator2 first2);
3939 T template<class InputIterator1, class InputIterator2, class BinaryPredicate>
3940 pair<InputIterator1, InputIterator2>
3941 mismatch(InputIterator1 first1, InputIterator1 last1,
3942 InputIterator2 first2, BinaryPredicate pred);
3944 T template<class InputIterator1, class InputIterator2>
3945 bool equal(InputIterator1 first1, InputIterator1 last1,
3946 InputIterator2 first2);
3947 T template<class InputIterator1, class InputIterator2, class BinaryPredicate>
3948 bool equal(InputIterator1 first1, InputIterator1 last1,
3949 InputIterator2 first2, BinaryPredicate pred);
3950 T template<class ForwardIterator1, class ForwardIterator2>
3951 ForwardIterator1 search(ForwardIterator1 first1, ForwardIterator1 last1,
3952 ForwardIterator2 first2, ForwardIterator2 last2);
3953 T template<class ForwardIterator1, class ForwardIterator2,
3954 class BinaryPredicate>
3955 ForwardIterator1 search(ForwardIterator1 first1, ForwardIterator1 last1,
3956 ForwardIterator2 first2, ForwardIterator2 last2,
3957 BinaryPredicate pred);
3958 T template<class ForwardIterator, class Size, class T>
3959 ForwardIterator search_n(ForwardIterator first, ForwardIterator last,
3960 Size count, const T& value);
3961 T template<class ForwardIterator, class Size, class T, class BinaryPredicate>
3962 ForwardIterator1 search_n(ForwardIterator first, ForwardIterator last,
3963 Size count, const T& value,
3964 BinaryPredicate pred);
3965 // _lib.alg.modifying.operations_, modifying sequence operations:
3966 // _lib.alg.copy_, copy:
3967 T template<class InputIterator, class OutputIterator>
3968 OutputIterator copy(InputIterator first, InputIterator last,
3969 OutputIterator result);
3970 T template<class BidirectionalIterator1, class BidirectionalIterator2>
3971 BidirectionalIterator2
3972 copy_backward(BidirectionalIterator1 first, BidirectionalIterator1 last,
3973 BidirectionalIterator2 result);
3974 // _lib.alg.swap_, swap:
3975 T template<class T> void swap(T& a, T& b);
3976 T template<class ForwardIterator1, class ForwardIterator2>
3977 ForwardIterator2 swap_ranges(ForwardIterator1 first1,
3978 ForwardIterator1 last1, ForwardIterator2 first2);
3979 T template<class ForwardIterator1, class ForwardIterator2>
3980 void iter_swap(ForwardIterator1 a, ForwardIterator2 b);
3981 T template<class InputIterator, class OutputIterator, class UnaryOperation>
3982 OutputIterator transform(InputIterator first, InputIterator last,
3983 OutputIterator result, UnaryOperation op);
3984 T template<class InputIterator1, class InputIterator2, class OutputIterator,
3985 class BinaryOperation>
3986 OutputIterator transform(InputIterator1 first1, InputIterator1 last1,
3987 InputIterator2 first2, OutputIterator result,
3988 BinaryOperation binary_op);
3990 T template<class ForwardIterator, class T>
3991 void replace(ForwardIterator first, ForwardIterator last,
3992 const T& old_value, const T& new_value);
3993 T template<class ForwardIterator, class Predicate, class T>
3994 void replace_if(ForwardIterator first, ForwardIterator last,
3995 Predicate pred, const T& new_value);
3996 T template<class InputIterator, class OutputIterator, class T>
3997 OutputIterator replace_copy(InputIterator first, InputIterator last,
3998 OutputIterator result,
3999 const T& old_value, const T& new_value);
4000 T template<class Iterator, class OutputIterator, class Predicate, class T>
4001 OutputIterator replace_copy_if(Iterator first, Iterator last,
4002 OutputIterator result,
4003 Predicate pred, const T& new_value);
4004 T template<class ForwardIterator, class T>
4005 void fill(ForwardIterator first, ForwardIterator last, const T& value);
4006 T template<class OutputIterator, class Size, class T>
4007 void fill_n(OutputIterator first, Size n, const T& value);
4008 T template<class ForwardIterator, class Generator>
4009 void generate(ForwardIterator first, ForwardIterator last, Generator gen);
4010 T template<class OutputIterator, class Size, class Generator>
4011 void generate_n(OutputIterator first, Size n, Generator gen);
4012 T template<class ForwardIterator, class T>
4013 ForwardIterator remove(ForwardIterator first, ForwardIterator last,
4014 const T& value);
4015 T template<class ForwardIterator, class Predicate>
4016 ForwardIterator remove_if(ForwardIterator first, ForwardIterator last,
4017 Predicate pred);
4018 T template<class InputIterator, class OutputIterator, class T>
4019 OutputIterator remove_copy(InputIterator first, InputIterator last,
4020 OutputIterator result, const T& value);
4021 T template<class InputIterator, class OutputIterator, class Predicate>
4022 OutputIterator remove_copy_if(InputIterator first, InputIterator last,
4023 OutputIterator result, Predicate pred);
4024 T template<class ForwardIterator>
4025 ForwardIterator unique(ForwardIterator first, ForwardIterator last);
4026 T template<class ForwardIterator, class BinaryPredicate>
4027 ForwardIterator unique(ForwardIterator first, ForwardIterator last,
4028 BinaryPredicate pred);
4029 T template<class InputIterator, class OutputIterator>
4030 OutputIterator unique_copy(InputIterator first, InputIterator last,
4031 OutputIterator result);
4032 T template<class InputIterator, class OutputIterator, class BinaryPredicate>
4033 OutputIterator unique_copy(InputIterator first, InputIterator last,
4034 OutputIterator result, BinaryPredicate pred);
4035 T template<class BidirectionalIterator>
4036 void reverse(BidirectionalIterator first, BidirectionalIterator last);
4037 T template<class BidirectionalIterator, class OutputIterator>
4038 OutputIterator reverse_copy(BidirectionalIterator first,
4039 BidirectionalIterator last,
4040 OutputIterator result);
4042 T template<class ForwardIterator>
4043 void rotate(ForwardIterator first, ForwardIterator middle,
4044 ForwardIterator last);
4045 T template<class ForwardIterator, class OutputIterator>
4046 OutputIterator rotate_copy(ForwardIterator first, ForwardIterator middle,
4047 ForwardIterator last, OutputIterator result);
4048 T template<class RandomAccessIterator>
4049 void random_shuffle(RandomAccessIterator first,
4050 RandomAccessIterator last);
4051 T template<class RandomAccessIterator, class RandomNumberGenerator>
4052 void random_shuffle(RandomAccessIterator first,
4053 RandomAccessIterator last,
4054 RandomNumberGenerator& rand);
4055 // _lib.alg.partitions_, partitions:
4056 T template<class BidirectionalIterator, class Predicate>
4057 BidirectionalIterator partition(BidirectionalIterator first,
4058 BidirectionalIterator last,
4059 Predicate pred);
4060 T template<class BidirectionalIterator, class Predicate>
4061 BidirectionalIterator stable_partition(BidirectionalIterator first,
4062 BidirectionalIterator last,
4063 Predicate pred);
4064 // _lib.alg.sorting_, sorting and related operations:
4065 // _lib.alg.sort_, sorting:
4066 T template<class RandomAccessIterator>
4067 void sort(RandomAccessIterator first, RandomAccessIterator last);
4068 T template<class RandomAccessIterator, class Compare>
4069 void sort(RandomAccessIterator first, RandomAccessIterator last,
4070 Compare comp);
4071 T template<class RandomAccessIterator>
4072 void stable_sort(RandomAccessIterator first, RandomAccessIterator last);
4073 T template<class RandomAccessIterator, class Compare>
4074 void stable_sort(RandomAccessIterator first, RandomAccessIterator last,
4075 Compare comp);
4076 T template<class RandomAccessIterator>
4077 void partial_sort(RandomAccessIterator first,
4078 RandomAccessIterator middle,
4079 RandomAccessIterator last);
4080 T template<class RandomAccessIterator, class Compare>
4081 void partial_sort(RandomAccessIterator first,
4082 RandomAccessIterator middle,
4083 RandomAccessIterator last, Compare comp);
4084 T template<class InputIterator, class RandomAccessIterator>
4085 RandomAccessIterator
4086 partial_sort_copy(InputIterator first, InputIterator last,
4087 RandomAccessIterator result_first,
4088 RandomAccessIterator result_last);
4089 T template<class InputIterator, class RandomAccessIterator, class Compare>
4090 RandomAccessIterator
4091 partial_sort_copy(InputIterator first, InputIterator last,
4092 RandomAccessIterator result_first,
4093 RandomAccessIterator result_last,
4094 Compare comp);
4096 T template<class RandomAccessIterator>
4097 void nth_element(RandomAccessIterator first, RandomAccessIterator nth,
4098 RandomAccessIterator last);
4099 T template<class RandomAccessIterator, class Compare>
4100 void nth_element(RandomAccessIterator first, RandomAccessIterator nth,
4101 RandomAccessIterator last, Compare comp);
4102 // _lib.alg.binary.search_, binary search:
4103 T template<class ForwardIterator, class T>
4104 ForwardIterator lower_bound(ForwardIterator first, ForwardIterator last,
4105 const T& value);
4106 T template<class ForwardIterator, class T, class Compare>
4107 ForwardIterator lower_bound(ForwardIterator first, ForwardIterator last,
4108 const T& value, Compare comp);
4109 T template<class ForwardIterator, class T>
4110 ForwardIterator upper_bound(ForwardIterator first, ForwardIterator last,
4111 const T& value);
4112 T template<class ForwardIterator, class T, class Compare>
4113 ForwardIterator upper_bound(ForwardIterator first, ForwardIterator last,
4114 const T& value, Compare comp);
4115 T template<class ForwardIterator, class T>
4116 pair<ForwardIterator, ForwardIterator>
4117 equal_range(ForwardIterator first, ForwardIterator last,
4118 const T& value);
4119 T template<class ForwardIterator, class T, class Compare>
4120 pair<ForwardIterator, ForwardIterator>
4121 equal_range(ForwardIterator first, ForwardIterator last,
4122 const T& value, Compare comp);
4123 T template<class ForwardIterator, class T>
4124 bool binary_search(ForwardIterator first, ForwardIterator last,
4125 const T& value);
4126 T template<class ForwardIterator, class T, class Compare>
4127 bool binary_search(ForwardIterator first, ForwardIterator last,
4128 const T& value, Compare comp);
4129 // _lib.alg.merge_, merge:
4130 T template<class InputIterator1, class InputIterator2, class OutputIterator>
4131 OutputIterator merge(InputIterator1 first1, InputIterator1 last1,
4132 InputIterator2 first2, InputIterator2 last2,
4133 OutputIterator result);
4134 T template<class InputIterator1, class InputIterator2, class OutputIterator,
4135 class Compare>
4136 OutputIterator merge(InputIterator1 first1, InputIterator1 last1,
4137 InputIterator2 first2, InputIterator2 last2,
4138 OutputIterator result, Compare comp);
4139 T template<class BidirectionalIterator>
4140 void inplace_merge(BidirectionalIterator first,
4141 BidirectionalIterator middle,
4142 BidirectionalIterator last);
4143 T template<class BidirectionalIterator, class Compare>
4144 void inplace_merge(BidirectionalIterator first,
4145 BidirectionalIterator middle,
4146 BidirectionalIterator last, Compare comp);
4148 // _lib.alg.set.operations_, set operations:
4149 T template<class InputIterator1, class InputIterator2>
4150 bool includes(InputIterator1 first1, InputIterator1 last1,
4151 InputIterator2 first2, InputIterator2 last2);
4152 T template<class InputIterator1, class InputIterator2, class Compare>
4153 bool includes(InputIterator1 first1, InputIterator1 last1,
4154 InputIterator2 first2, InputIterator2 last2, Compare comp);
4155 T template<class InputIterator1, class InputIterator2, class OutputIterator>
4156 OutputIterator set_union(InputIterator1 first1, InputIterator1 last1,
4157 InputIterator2 first2, InputIterator2 last2,
4158 OutputIterator result);
4159 T template<class InputIterator1, class InputIterator2, class OutputIterator,
4160 class Compare>
4161 OutputIterator set_union(InputIterator1 first1, InputIterator1 last1,
4162 InputIterator2 first2, InputIterator2 last2,
4163 OutputIterator result, Compare comp);
4164 T template<class InputIterator1, class InputIterator2, class OutputIterator>
4165 OutputIterator set_intersection
4166 (InputIterator1 first1, InputIterator1 last1,
4167 InputIterator2 first2, InputIterator2 last2,
4168 OutputIterator result);
4169 T template<class InputIterator1, class InputIterator2, class OutputIterator,
4170 class Compare>
4171 OutputIterator set_intersection
4172 (InputIterator1 first1, InputIterator1 last1,
4173 InputIterator2 first2, InputIterator2 last2,
4174 OutputIterator result, Compare comp);
4175 T template<class InputIterator1, class InputIterator2, class OutputIterator>
4176 OutputIterator set_difference
4177 (InputIterator1 first1, InputIterator1 last1,
4178 InputIterator2 first2, InputIterator2 last2,
4179 OutputIterator result);
4180 T template<class InputIterator1, class InputIterator2, class OutputIterator,
4181 class Compare>
4182 OutputIterator set_difference(InputIterator1 first1, InputIterator1 last1,
4183 InputIterator2 first2, InputIterator2 last2,
4184 OutputIterator result, Compare comp);
4185 T template<class InputIterator1, class InputIterator2, class OutputIterator>
4186 OutputIterator
4187 set_symmetric_difference(InputIterator1 first1, InputIterator1 last1,
4188 InputIterator2 first2, InputIterator2 last2,
4189 OutputIterator result);
4190 T template<class InputIterator1, class InputIterator2, class OutputIterator,
4191 class Compare>
4192 OutputIterator
4193 set_symmetric_difference(InputIterator1 first1, InputIterator1 last1,
4194 InputIterator2 first2, InputIterator2 last2,
4195 OutputIterator result, Compare comp);
4196 // _lib.alg.heap.operations_, heap operations:
4197 T template<class RandomAccessIterator>
4198 void push_heap(RandomAccessIterator first, RandomAccessIterator last);
4199 T template<class RandomAccessIterator, class Compare>
4200 void push_heap(RandomAccessIterator first, RandomAccessIterator last,
4201 Compare comp);
4203 T template<class RandomAccessIterator>
4204 void pop_heap(RandomAccessIterator first, RandomAccessIterator last);
4205 T template<class RandomAccessIterator, class Compare>
4206 void pop_heap(RandomAccessIterator first, RandomAccessIterator last,
4207 Compare comp);
4208 T template<class RandomAccessIterator>
4209 void make_heap(RandomAccessIterator first, RandomAccessIterator last);
4210 T template<class RandomAccessIterator, class Compare>
4211 void make_heap(RandomAccessIterator first, RandomAccessIterator last,
4212 Compare comp);
4213 T template<class RandomAccessIterator>
4214 void sort_heap(RandomAccessIterator first, RandomAccessIterator last);
4215 T template<class RandomAccessIterator, class Compare>
4216 void sort_heap(RandomAccessIterator first, RandomAccessIterator last,
4217 Compare comp);
4218 // _lib.alg.min.max_, minimum and maximum:
4219 T template<class T> const T& min(const T& a, const T& b);
4220 T template<class T, class Compare>
4221 const T& min(const T& a, const T& b, Compare comp);
4222 T template<class T> const T& max(const T& a, const T& b);
4223 T template<class T, class Compare>
4224 const T& max(const T& a, const T& b, Compare comp);
4225 T template<class ForwardIterator>
4226 ForwardIterator min_element(ForwardIterator first, ForwardIterator last);
4227 T template<class ForwardIterator, class Compare>
4228 ForwardIterator min_element(ForwardIterator first, ForwardIterator last,
4229 Compare comp);
4230 T template<class ForwardIterator>
4231 ForwardIterator max_element(ForwardIterator first, ForwardIterator last);
4232 T template<class ForwardIterator, class Compare>
4233 ForwardIterator max_element(ForwardIterator first, ForwardIterator last,
4234 Compare comp);
4235 T template<class InputIterator1, class InputIterator2>
4236 bool lexicographical_compare
4237 (InputIterator1 first1, InputIterator1 last1,
4238 InputIterator2 first2, InputIterator2 last2);
4239 T template<class InputIterator1, class InputIterator2, class Compare>
4240 bool lexicographical_compare
4241 (InputIterator1 first1, InputIterator1 last1,
4242 InputIterator2 first2, InputIterator2 last2,
4243 Compare comp);
4245 // _lib.alg.permutation.generators_, permutations
4246 T template<class BidirectionalIterator>
4247 bool next_permutation(BidirectionalIterator first,
4248 BidirectionalIterator last);
4249 T template<class BidirectionalIterator, class Compare>
4250 bool next_permutation(BidirectionalIterator first,
4251 BidirectionalIterator last, Compare comp);
4252 T template<class BidirectionalIterator>
4253 bool prev_permutation(BidirectionalIterator first,
4254 BidirectionalIterator last);
4255 T template<class BidirectionalIterator, class Compare>
4256 bool prev_permutation(BidirectionalIterator first,
4257 BidirectionalIterator last, Compare comp);
4260 25.4 C library algorithms [lib.alg.c.library]
4262 1 Header <cstdlib> (partial, Table 2):
4264 Table 2--Header <cstdlib> synopsis
4266 Functions: bsearch qsort
4269 X extern "C" void *bsearch(const void *key, const void *base,
4270 size_t nmemb, size_t size,
4271 int (*compar)(const void *, const void *));
4272 X extern "C++" void *bsearch(const void *key, const void *base,
4273 size_t nmemb, size_t size,
4274 int (*compar)(const void *, const void *));
4276 X extern "C" void qsort(void* base, size_t nmemb, size_t size,
4277 int (*compar)(const void*, const void*));
4278 X extern "C++" void qsort(void* base, size_t nmemb, size_t size,
4279 int (*compar)(const void*, const void*));
4283 26.2 Complex numbers [lib.complex.numbers]
4286 26.2.1 Header <complex> synopsis [lib.complex.synopsis]
4288 T template<class T> class complex;
4289 T template<> class complex<float>;
4290 T template<> class complex<double>;
4291 T template<> class complex<long double>;
4292 // _lib.complex.ops_ operators:
4293 T template<class T>
4294 complex<T> operator+(const complex<T>&, const complex<T>&);
4295 T template<class T> complex<T> operator+(const complex<T>&, const T&);
4296 T template<class T> complex<T> operator+(const T&, const complex<T>&);
4297 T template<class T> complex<T> operator-
4298 (const complex<T>&, const complex<T>&);
4299 T template<class T> complex<T> operator-(const complex<T>&, const T&);
4300 T template<class T> complex<T> operator-(const T&, const complex<T>&);
4301 T template<class T> complex<T> operator*
4302 (const complex<T>&, const complex<T>&);
4303 T template<class T> complex<T> operator*(const complex<T>&, const T&);
4304 T template<class T> complex<T> operator*(const T&, const complex<T>&);
4305 T template<class T> complex<T> operator/
4306 (const complex<T>&, const complex<T>&);
4307 T template<class T> complex<T> operator/(const complex<T>&, const T&);
4308 T template<class T> complex<T> operator/(const T&, const complex<T>&);
4309 T template<class T> complex<T> operator+(const complex<T>&);
4310 T template<class T> complex<T> operator-(const complex<T>&);
4311 T template<class T> bool operator==
4312 (const complex<T>&, const complex<T>&);
4313 T template<class T> bool operator==(const complex<T>&, const T&);
4314 T template<class T> bool operator==(const T&, const complex<T>&);
4315 T template<class T> bool operator!=(const complex<T>&, const complex<T>&);
4316 T template<class T> bool operator!=(const complex<T>&, const T&);
4317 T template<class T> bool operator!=(const T&, const complex<T>&);
4318 T template<class T, class charT, class traits>
4319 basic_istream<charT, traits>&
4320 operator>>(basic_istream<charT, traits>&, complex<T>&);
4322 T template<class T, class charT, class traits>
4323 basic_ostream<charT, traits>&
4324 operator<<(basic_ostream<charT, traits>&, const complex<T>&);
4325 // _lib.complex.value.ops_ values:
4326 T template<class T> T real(const complex<T>&);
4327 T template<class T> T imag(const complex<T>&);
4329 T template<class T> T abs(const complex<T>&);
4330 T template<class T> T arg(const complex<T>&);
4331 T template<class T> T norm(const complex<T>&);
4332 T template<class T> complex<T> conj(const complex<T>&);
4333 T template<class T> complex<T> polar(const T&, const T&);
4334 // _lib.complex.transcendentals_ transcendentals:
4335 T template<class T> complex<T> cos (const complex<T>&);
4336 T template<class T> complex<T> cosh (const complex<T>&);
4337 T template<class T> complex<T> exp (const complex<T>&);
4338 T template<class T> complex<T> log (const complex<T>&);
4339 T template<class T> complex<T> log10(const complex<T>&);
4340 T template<class T> complex<T> pow(const complex<T>&, int);
4341 T template<class T> complex<T> pow(const complex<T>&, const T&);
4342 T template<class T> complex<T> pow(const complex<T>&, const complex<T>&);
4343 T template<class T> complex<T> pow(const T&, const complex<T>&);
4344 T template<class T> complex<T> sin (const complex<T>&);
4345 T template<class T> complex<T> sinh (const complex<T>&);
4346 T template<class T> complex<T> sqrt (const complex<T>&);
4347 T template<class T> complex<T> tan (const complex<T>&);
4348 T template<class T> complex<T> tanh (const complex<T>&);
4351 26.2.2 Template class complex [lib.complex]
4353 template<class T>
4354 T class complex {
4355 public:
4356 T typedef T value_type;
4358 T complex(const T& re = T(), const T& im = T());
4359 T complex(const complex&);
4360 T template<class X> complex(const complex<X>&);
4362 T T real() const;
4363 T T imag() const;
4365 T complex<T>& operator= (const T&);
4366 T complex<T>& operator+=(const T&);
4367 T complex<T>& operator-=(const T&);
4368 T complex<T>& operator*=(const T&);
4369 T complex<T>& operator/=(const T&);
4371 T complex& operator=(const complex&);
4372 T template<class X> complex<T>& operator= (const complex<X>&);
4373 T template<class X> complex<T>& operator+=(const complex<X>&);
4374 T template<class X> complex<T>& operator-=(const complex<X>&);
4375 T template<class X> complex<T>& operator*=(const complex<X>&);
4376 T template<class X> complex<T>& operator/=(const complex<X>&);
4379 T template<class T> complex<T> operator+
4380 (const complex<T>&, const complex<T>&);
4381 T template<class T> complex<T> operator+(const complex<T>&, const T&);
4382 T template<class T> complex<T> operator+(const T&, const complex<T>&);
4384 T template<class T> complex<T> operator-
4385 (const complex<T>&, const complex<T>&);
4386 T template<class T> complex<T> operator-(const complex<T>&, const T&);
4387 T template<class T> complex<T> operator-(const T&, const complex<T>&);
4389 T template<class T> complex<T> operator*
4390 (const complex<T>&, const complex<T>&);
4391 T template<class T> complex<T> operator*(const complex<T>&, const T&);
4392 T template<class T> complex<T> operator*(const T&, const complex<T>&);
4394 T template<class T> complex<T> operator/
4395 (const complex<T>&, const complex<T>&);
4396 T template<class T> complex<T> operator/(const complex<T>&, const T&);
4397 T template<class T> complex<T> operator/(const T&, const complex<T>&);
4399 T template<class T> complex<T> operator+(const complex<T>&);
4400 T template<class T> complex<T> operator-(const complex<T>&);
4402 T template<class T> bool operator==(const complex<T>&, const complex<T>&);
4403 T template<class T> bool operator==(const complex<T>&, const T&);
4404 T template<class T> bool operator==(const T&, const complex<T>&);
4406 T template<class T> bool operator!=(const complex<T>&, const complex<T>&);
4407 T template<class T> bool operator!=(const complex<T>&, const T&);
4408 T template<class T> bool operator!=(const T&, const complex<T>&);
4410 T template<class T, class charT, class traits>
4411 basic_istream<charT, traits>&
4412 operator>>(basic_istream<charT, traits>&, complex<T>&);
4414 T template<class T, class charT, class traits>
4415 basic_ostream<charT, traits>&
4416 operator<<(basic_ostream<charT, traits>&, const complex<T>&);
4419 26.2.3 complex specializations [lib.complex.special]
4421 T template<> class complex<float> {
4422 public:
4423 T typedef float value_type;
4425 T complex(float re = 0.0f, float im = 0.0f);
4426 T explicit complex(const complex<double>&);
4427 T explicit complex(const complex<long double>&);
4428 T float real() const;
4429 T float imag() const;
4431 T complex<float>& operator= (float);
4432 T complex<float>& operator+=(float);
4433 T complex<float>& operator-=(float);
4434 T complex<float>& operator*=(float);
4435 T complex<float>& operator/=(float);
4437 T complex<float>& operator=(const complex<float>&);
4438 T template<class X> complex<float>& operator= (const complex<X>&);
4439 T template<class X> complex<float>& operator+=(const complex<X>&);
4440 T template<class X> complex<float>& operator-=(const complex<X>&);
4441 T template<class X> complex<float>& operator*=(const complex<X>&);
4442 T template<class X> complex<float>& operator/=(const complex<X>&);
4444 T template<> class complex<double> {
4445 public:
4446 T typedef double value_type;
4448 T complex(double re = 0.0, double im = 0.0);
4449 T complex(const complex<float>&);
4450 T explicit complex(const complex<long double>&);
4451 T double real() const;
4452 T double imag() const;
4454 T complex<double>& operator= (double);
4455 T complex<double>& operator+=(double);
4456 T complex<double>& operator-=(double);
4457 T complex<double>& operator*=(double);
4458 T complex<double>& operator/=(double);
4460 T complex<double>& operator=(const complex<double>&);
4461 T template<class X> complex<double>& operator= (const complex<X>&);
4462 T template<class X> complex<double>& operator+=(const complex<X>&);
4463 T template<class X> complex<double>& operator-=(const complex<X>&);
4464 T template<class X> complex<double>& operator*=(const complex<X>&);
4465 T template<class X> complex<double>& operator/=(const complex<X>&);
4468 T template<> class complex<long double> {
4469 public:
4470 T typedef long double value_type;
4472 T complex(long double re = 0.0L, long double im = 0.0L);
4473 T complex(const complex<float>&);
4474 T complex(const complex<double>&);
4475 T long double real() const;
4476 T long double imag() const;
4478 T complex<long double>& operator=(const complex<long double>&);
4479 T complex<long double>& operator= (long double);
4480 T complex<long double>& operator+=(long double);
4481 T complex<long double>& operator-=(long double);
4482 T complex<long double>& operator*=(long double);
4483 T complex<long double>& operator/=(long double);
4485 T template<class X> complex<long double>& operator= (const complex<X>&);
4486 T template<class X> complex<long double>& operator+=(const complex<X>&);
4487 T template<class X> complex<long double>& operator-=(const complex<X>&);
4488 T template<class X> complex<long double>& operator*=(const complex<X>&);
4489 T template<class X> complex<long double>& operator/=(const complex<X>&);
4492 26.3 Numeric arrays [lib.numarray]
4494 26.3.1 Header <valarray> synopsis [lib.valarray.synopsis]
4496 T template<class T> class valarray; // An array of type T
4497 T class slice;
4498 T template<class T> class slice_array;
4499 T class gslice;
4500 T template<class T> class gslice_array;
4501 T template<class T> class mask_array; // a masked array
4502 T template<class T> class indirect_array; // an indirected array
4504 T template<class T> valarray<T> operator*
4505 (const valarray<T>&, const valarray<T>&);
4506 T template<class T> valarray<T> operator* (const valarray<T>&, const T&);
4507 T template<class T> valarray<T> operator* (const T&, const valarray<T>&);
4508 T template<class T> valarray<T> operator/
4509 (const valarray<T>&, const valarray<T>&);
4510 T template<class T> valarray<T> operator/ (const valarray<T>&, const T&);
4511 T template<class T> valarray<T> operator/ (const T&, const valarray<T>&);
4512 T template<class T> valarray<T> operator%
4513 (const valarray<T>&, const valarray<T>&);
4514 T template<class T> valarray<T> operator% (const valarray<T>&, const T&);
4515 T template<class T> valarray<T> operator% (const T&, const valarray<T>&);
4516 T template<class T> valarray<T> operator+
4517 (const valarray<T>&, const valarray<T>&);
4518 T template<class T> valarray<T> operator+ (const valarray<T>&, const T&);
4519 T template<class T> valarray<T> operator+ (const T&, const valarray<T>&);
4520 T template<class T> valarray<T> operator-
4521 (const valarray<T>&, const valarray<T>&);
4522 T template<class T> valarray<T> operator- (const valarray<T>&, const T&);
4523 T template<class T> valarray<T> operator- (const T&, const valarray<T>&);
4524 T template<class T> valarray<T> operator^
4525 (const valarray<T>&, const valarray<T>&);
4526 T template<class T> valarray<T> operator^ (const valarray<T>&, const T&);
4527 T template<class T> valarray<T> operator^ (const T&, const valarray<T>&);
4528 T template<class T> valarray<T> operator&
4529 (const valarray<T>&, const valarray<T>&);
4530 T template<class T> valarray<T> operator& (const valarray<T>&, const T&);
4531 T template<class T> valarray<T> operator& (const T&, const valarray<T>&);
4532 T template<class T> valarray<T> operator|
4533 (const valarray<T>&, const valarray<T>&);
4534 T template<class T> valarray<T> operator| (const valarray<T>&, const T&);
4535 T template<class T> valarray<T> operator| (const T&, const valarray<T>&);
4536 T template<class T> valarray<T> operator<<
4537 (const valarray<T>&, const valarray<T>&);
4538 T template<class T> valarray<T> operator<<(const valarray<T>&, const T&);
4539 T template<class T> valarray<T> operator<<(const T&, const valarray<T>&);
4540 T template<class T> valarray<T> operator>>
4541 (const valarray<T>&, const valarray<T>&);
4542 T template<class T> valarray<T> operator>>(const valarray<T>&, const T&);
4543 T template<class T> valarray<T> operator>>(const T&, const valarray<T>&);
4544 T template<class T> valarray<bool> operator&&
4545 (const valarray<T>&, const valarray<T>&);
4546 T template<class T> valarray<bool> operator&&(const valarray<T>&, const T&);
4547 T template<class T> valarray<bool> operator&&(const T&, const valarray<T>&);
4548 T template<class T> valarray<bool> operator||
4549 (const valarray<T>&, const valarray<T>&);
4550 T template<class T> valarray<bool> operator||(const valarray<T>&, const T&);
4551 T template<class T> valarray<bool> operator||(const T&, const valarray<T>&);
4553 T template<class T>
4554 valarray<bool> operator==(const valarray<T>&, const valarray<T>&);
4555 T template<class T> valarray<bool> operator==(const valarray<T>&, const T&);
4556 T template<class T> valarray<bool> operator==(const T&, const valarray<T>&);
4557 T template<class T>
4558 valarray<bool> operator!=(const valarray<T>&, const valarray<T>&);
4559 T template<class T> valarray<bool> operator!=(const valarray<T>&, const T&);
4560 T template<class T> valarray<bool> operator!=(const T&, const valarray<T>&);
4561 T template<class T>
4562 valarray<bool> operator< (const valarray<T>&, const valarray<T>&);
4563 T template<class T> valarray<bool> operator< (const valarray<T>&, const T&);
4564 T template<class T> valarray<bool> operator< (const T&, const valarray<T>&);
4565 T template<class T>
4566 valarray<bool> operator> (const valarray<T>&, const valarray<T>&);
4567 T template<class T> valarray<bool> operator> (const valarray<T>&, const T&);
4568 T template<class T> valarray<bool> operator> (const T&, const valarray<T>&);
4569 T template<class T>
4570 valarray<bool> operator<=(const valarray<T>&, const valarray<T>&);
4571 T template<class T> valarray<bool> operator<=(const valarray<T>&, const T&);
4572 T template<class T> valarray<bool> operator<=(const T&, const valarray<T>&);
4573 T template<class T>
4574 valarray<bool> operator>=(const valarray<T>&, const valarray<T>&);
4575 T template<class T> valarray<bool> operator>=(const valarray<T>&, const T&);
4576 T template<class T> valarray<bool> operator>=(const T&, const valarray<T>&);
4577 T template<class T> valarray<T> abs (const valarray<T>&);
4578 T template<class T> valarray<T> acos (const valarray<T>&);
4579 T template<class T> valarray<T> asin (const valarray<T>&);
4580 T template<class T> valarray<T> atan (const valarray<T>&);
4581 T template<class T> valarray<T> atan2
4582 (const valarray<T>&, const valarray<T>&);
4583 T template<class T> valarray<T> atan2(const valarray<T>&, const T&);
4584 T template<class T> valarray<T> atan2(const T&, const valarray<T>&);
4585 T template<class T> valarray<T> cos (const valarray<T>&);
4586 T template<class T> valarray<T> cosh (const valarray<T>&);
4587 T template<class T> valarray<T> exp (const valarray<T>&);
4588 T template<class T> valarray<T> log (const valarray<T>&);
4589 T template<class T> valarray<T> log10(const valarray<T>&);
4590 T template<class T> valarray<T> pow(const valarray<T>&, const valarray<T>&);
4591 T template<class T> valarray<T> pow(const valarray<T>&, const T&);
4592 T template<class T> valarray<T> pow(const T&, const valarray<T>&);
4593 T template<class T> valarray<T> sin (const valarray<T>&);
4594 T template<class T> valarray<T> sinh (const valarray<T>&);
4595 T template<class T> valarray<T> sqrt (const valarray<T>&);
4596 T template<class T> valarray<T> tan (const valarray<T>&);
4597 T template<class T> valarray<T> tanh (const valarray<T>&);
4601 26.3.2 Template class valarray [lib.template.valarray]
4603 T template<class T> class valarray {
4604 public:
4605 T typedef T value_type;
4607 // _lib.valarray.cons_ construct/destroy:
4608 T valarray();
4609 T explicit valarray(size_t);
4610 T valarray(const T&, size_t);
4611 T valarray(const T*, size_t);
4612 T valarray(const valarray&);
4613 T valarray(const slice_array<T>&);
4614 T valarray(const gslice_array<T>&);
4615 T valarray(const mask_array<T>&);
4616 T valarray(const indirect_array<T>&);
4617 T ~valarray();
4619 // _lib.valarray.assign_ assignment:
4620 T valarray<T>& operator=(const valarray<T>&);
4621 T valarray<T>& operator=(const T&);
4622 T valarray<T>& operator=(const slice_array<T>&);
4623 T valarray<T>& operator=(const gslice_array<T>&);
4624 T valarray<T>& operator=(const mask_array<T>&);
4625 T valarray<T>& operator=(const indirect_array<T>&);
4626 // _lib.valarray.access_ element access:
4627 T T operator[](size_t) const;
4628 T T& operator[](size_t);
4629 // _lib.valarray.sub_ subset operations:
4630 T valarray<T> operator[](slice) const;
4631 T slice_array<T> operator[](slice);
4632 T valarray<T> operator[](const gslice&) const;
4633 T gslice_array<T> operator[](const gslice&);
4634 T valarray<T> operator[](const valarray<bool>&) const;
4635 T mask_array<T> operator[](const valarray<bool>&);
4636 T valarray<T> operator[](const valarray<size_t>&) const;
4637 T indirect_array<T> operator[](const valarray<size_t>&);
4638 // _lib.valarray.unary_ unary operators:
4639 T valarray<T> operator+() const;
4640 T valarray<T> operator-() const;
4641 T valarray<T> operator~() const;
4642 T valarray<T> operator!() const;
4643 // _lib.valarray.cassign_ computed assignment:
4644 T valarray<T>& operator*= (const T&);
4645 T valarray<T>& operator/= (const T&);
4646 T valarray<T>& operator%= (const T&);
4647 T valarray<T>& operator+= (const T&);
4648 T valarray<T>& operator-= (const T&);
4649 T valarray<T>& operator^= (const T&);
4650 T valarray<T>& operator&= (const T&);
4651 T valarray<T>& operator|= (const T&);
4652 T valarray<T>& operator<<=(const T&);
4653 T valarray<T>& operator>>=(const T&);
4654 T valarray<T>& operator*= (const valarray<T>&);
4655 T valarray<T>& operator/= (const valarray<T>&);
4656 T valarray<T>& operator%= (const valarray<T>&);
4657 T valarray<T>& operator+= (const valarray<T>&);
4658 T valarray<T>& operator-= (const valarray<T>&);
4659 T valarray<T>& operator^= (const valarray<T>&);
4660 T valarray<T>& operator|= (const valarray<T>&);
4661 T valarray<T>& operator&= (const valarray<T>&);
4662 T valarray<T>& operator<<=(const valarray<T>&);
4663 T valarray<T>& operator>>=(const valarray<T>&);
4664 // _lib.valarray.members_ member functions:
4665 T size_t size() const;
4666 T T sum() const;
4667 T T min() const;
4668 T T max() const;
4670 T valarray<T> shift (int) const;
4671 T valarray<T> cshift(int) const;
4672 T valarray<T> apply(T func(T)) const;
4673 T valarray<T> apply(T func(const T&)) const;
4674 T void resize(size_t sz, T c = T());
4680 26.3.4 Class slice [lib.class.slice]
4682 T class slice {
4683 public:
4684 T slice();
4685 T slice(size_t, size_t, size_t);
4687 T size_t start() const;
4688 T size_t size() const;
4689 T size_t stride() const;
4695 26.3.5 Template class slice_array [lib.template.slice.array]
4697 T template <class T> class slice_array {
4698 public:
4699 T typedef T value_type;
4701 T void operator= (const valarray<T>&) const;
4702 T void operator*= (const valarray<T>&) const;
4703 T void operator/= (const valarray<T>&) const;
4704 T void operator%= (const valarray<T>&) const;
4705 T void operator+= (const valarray<T>&) const;
4706 T void operator-= (const valarray<T>&) const;
4707 T void operator^= (const valarray<T>&) const;
4708 T void operator&= (const valarray<T>&) const;
4709 T void operator|= (const valarray<T>&) const;
4710 T void operator<<=(const valarray<T>&) const;
4711 T void operator>>=(const valarray<T>&) const;
4712 T void operator=(const T&);
4713 T ~slice_array();
4714 private:
4715 T slice_array();
4716 T slice_array(const slice_array&);
4717 T slice_array& operator=(const slice_array&);
4723 26.3.6 The gslice class [lib.class.gslice]
4725 T class gslice {
4726 public:
4727 T gslice();
4728 T gslice(size_t s, const valarray<size_t>& l, const valarray<size_t>& d);
4730 T size_t start() const;
4731 T valarray<size_t> size() const;
4732 T valarray<size_t> stride() const;
4736 26.3.7 Template class gslice_array [lib.template.gslice.array]
4738 T template <class T> class gslice_array {
4739 public:
4740 T typedef T value_type;
4742 T void operator= (const valarray<T>&) const;
4743 T void operator*= (const valarray<T>&) const;
4744 T void operator/= (const valarray<T>&) const;
4745 T void operator%= (const valarray<T>&) const;
4746 T void operator+= (const valarray<T>&) const;
4747 T void operator-= (const valarray<T>&) const;
4748 T void operator^= (const valarray<T>&) const;
4749 T void operator&= (const valarray<T>&) const;
4750 T void operator|= (const valarray<T>&) const;
4751 T void operator<<=(const valarray<T>&) const;
4752 T void operator>>=(const valarray<T>&) const;
4753 T void operator=(const T&);
4754 T ~gslice_array();
4755 private:
4756 T gslice_array();
4757 T gslice_array(const gslice_array&);
4758 T gslice_array& operator=(const gslice_array&);
4762 26.3.8 Template class mask_array [lib.template.mask.array]
4764 T template <class T> class mask_array {
4765 public:
4766 T typedef T value_type;
4768 T void operator= (const valarray<T>&) const;
4769 T void operator*= (const valarray<T>&) const;
4770 T void operator/= (const valarray<T>&) const;
4771 T void operator%= (const valarray<T>&) const;
4772 T void operator+= (const valarray<T>&) const;
4773 T void operator-= (const valarray<T>&) const;
4774 T void operator^= (const valarray<T>&) const;
4775 T void operator&= (const valarray<T>&) const;
4776 T void operator|= (const valarray<T>&) const;
4777 T void operator<<=(const valarray<T>&) const;
4778 T void operator>>=(const valarray<T>&) const;
4779 T void operator=(const T&);
4780 T ~mask_array();
4781 private:
4782 T mask_array();
4783 T mask_array(const mask_array&);
4784 T mask_array& operator=(const mask_array&);
4785 // remainder implementation defined
4789 26.3.9 Template class [lib.template.indirect.array]
4790 indirect_array
4792 T template <class T> class indirect_array {
4793 public:
4794 T typedef T value_type;
4796 T void operator= (const valarray<T>&) const;
4797 T void operator*= (const valarray<T>&) const;
4798 T void operator/= (const valarray<T>&) const;
4799 T void operator%= (const valarray<T>&) const;
4800 T void operator+= (const valarray<T>&) const;
4801 T void operator-= (const valarray<T>&) const;
4802 T void operator^= (const valarray<T>&) const;
4803 T void operator&= (const valarray<T>&) const;
4804 T void operator|= (const valarray<T>&) const;
4805 T void operator<<=(const valarray<T>&) const;
4806 T void operator>>=(const valarray<T>&) const;
4807 T void operator=(const T&);
4808 T ~indirect_array();
4809 private:
4810 T indirect_array();
4811 T indirect_array(const indirect_array&);
4812 T indirect_array& operator=(const indirect_array&);
4813 // remainder implementation defined
4816 26.4 Generalized numeric operations [lib.numeric.ops]
4818 Header <numeric> synopsis
4820 T template <class InputIterator, class T>
4821 T accumulate(InputIterator first, InputIterator last, T init);
4823 T template <class InputIterator, class T, class BinaryOperation>
4824 T accumulate(InputIterator first, InputIterator last, T init,
4825 BinaryOperation binary_op);
4827 T template <class InputIterator1, class InputIterator2, class T>
4828 T inner_product(InputIterator1 first1, InputIterator1 last1,
4829 InputIterator2 first2, T init);
4831 T template <class InputIterator1, class InputIterator2, class T,
4832 class BinaryOperation1, class BinaryOperation2>
4833 T inner_product(InputIterator1 first1, InputIterator1 last1,
4834 InputIterator2 first2, T init,
4835 BinaryOperation1 binary_op1,
4836 BinaryOperation2 binary_op2);
4838 T template <class InputIterator, class OutputIterator>
4839 OutputIterator partial_sum(InputIterator first,
4840 InputIterator last,
4841 OutputIterator result);
4843 T template <class InputIterator, class OutputIterator,
4844 class BinaryOperation>
4845 OutputIterator partial_sum(InputIterator first,
4846 InputIterator last,
4847 OutputIterator result,
4848 BinaryOperation binary_op);
4850 T template <class InputIterator, class OutputIterator>
4851 OutputIterator adjacent_difference(InputIterator first,
4852 InputIterator last,
4853 OutputIterator result);
4855 T template <class InputIterator, class OutputIterator,
4856 class BinaryOperation>
4857 OutputIterator adjacent_difference(InputIterator first,
4858 InputIterator last,
4859 OutputIterator result,
4860 BinaryOperation binary_op);
4863 26.5 C Library [lib.c.math]
4865 Table 2--Header <cmath> synopsis
4866 X Macro: HUGE_VAL
4867 Functions:
4868 X acos cos fmod modf tan
4869 X asin cosh frexp pow tanh
4870 X atan exp ldexp sin
4871 X atan2 fabs log sinh
4872 X ceil floor log10 sqrt
4874 Table 3--Header <cstdlib> synopsis
4875 X Macros: RAND_MAX
4876 X Types: div_t ldiv_t
4877 Functions:
4878 X abs labs srand
4879 X div ldiv rand
4881 X long abs(long); // labs()
4882 X ldiv_t div(long, long); // ldiv()
4884 X float abs (float);
4885 X float acos (float);
4886 X float asin (float);
4887 X float atan (float);
4888 X float atan2(float, float);
4889 X float ceil (float);
4890 X float cos (float);
4891 X float cosh (float);
4892 X float exp (float);
4893 X float fabs (float);
4894 X float floor(float);
4895 X float fmod (float, float);
4896 X float frexp(float, int*);
4897 X float ldexp(float, int);
4898 X float log (float);
4899 X float log10(float);
4900 X float modf (float, float*);
4901 X float pow (float, float);
4902 X float pow (float, int);
4903 X float sin (float);
4904 X float sinh (float);
4905 X float sqrt (float);
4906 X float tan (float);
4907 X float tanh (float);
4909 X double abs(double); // fabs()
4910 X double pow(double, int);
4912 X long double abs (long double);
4913 X long double acos (long double);
4914 X long double asin (long double);
4915 X long double atan (long double);
4916 X long double atan2(long double, long double);
4917 X long double ceil (long double);
4918 X long double cos (long double);
4919 X long double cosh (long double);
4920 X long double exp (long double);
4921 X long double fabs (long double);
4922 X long double floor(long double);
4923 X long double fmod (long double, long double);
4924 X long double frexp(long double, int*);
4925 X long double ldexp(long double, int);
4926 X long double log (long double);
4927 X long double log10(long double);
4928 X long double modf (long double, long double*);
4929 X long double pow (long double, long double);
4930 X long double pow (long double, int);
4931 X long double sin (long double);
4932 X long double sinh (long double);
4933 X long double sqrt (long double);
4934 X long double tan (long double);
4935 X long double tanh (long double);
4937 Header <iosfwd> synopsis
4939 X template<class charT> class char_traits;
4940 X template<> class char_traits<char>;
4941 X template<> class char_traits<wchar_t>;
4942 X template<class T> class allocator;
4943 X template <class charT, class traits = char_traits<charT> >
4944 class basic_ios;
4946 X template <class charT, class traits = char_traits<charT> >
4947 class basic_streambuf;
4949 X template <class charT, class traits = char_traits<charT> >
4950 class basic_istream;
4952 X template <class charT, class traits = char_traits<charT> >
4953 class basic_ostream;
4955 X template <class charT, class traits = char_traits<charT> >
4956 class basic_iostream;
4958 X template <class charT, class traits = char_traits<charT>,
4959 class Allocator = allocator<charT> >
4960 class basic_stringbuf;
4962 X template <class charT, class traits = char_traits<charT>,
4963 class Allocator = allocator<charT> >
4964 class basic_istringstream;
4966 X template <class charT, class traits = char_traits<charT>,
4967 class Allocator = allocator<charT> >
4968 class basic_ostringstream;
4970 X template <class charT, class traits = char_traits<charT>,
4971 class Allocator = allocator<charT> >
4972 class basic_stringstream;
4974 X template <class charT, class traits = char_traits<charT> >
4975 class basic_filebuf;
4977 X template <class charT, class traits = char_traits<charT> >
4978 class basic_ifstream;
4980 X template <class charT, class traits = char_traits<charT> >
4981 class basic_ofstream;
4983 X template <class charT, class traits = char_traits<charT> >
4984 class basic_fstream;
4985 X template <class charT, class traits = char_traits<charT> >
4986 class istreambuf_iterator;
4988 X template <class charT, class traits = char_traits<charT> >
4989 class ostreambuf_iterator;
4990 X typedef basic_ios<char> ios;
4991 X typedef basic_ios<wchar_t> wios;
4992 X typedef basic_streambuf<char> streambuf;
4993 X typedef basic_istream<char> istream;
4994 X typedef basic_ostream<char> ostream;
4995 X typedef basic_iostream<char> iostream;
4996 X typedef basic_stringbuf<char> stringbuf;
4997 X typedef basic_istringstream<char> istringstream;
4998 X typedef basic_ostringstream<char> ostringstream;
4999 X typedef basic_stringstream<char> stringstream;
5000 X typedef basic_filebuf<char> filebuf;
5001 X typedef basic_ifstream<char> ifstream;
5002 X typedef basic_ofstream<char> ofstream;
5003 X typedef basic_fstream<char> fstream;
5004 X typedef basic_streambuf<wchar_t> wstreambuf;
5005 X typedef basic_istream<wchar_t> wistream;
5006 X typedef basic_ostream<wchar_t> wostream;
5007 X typedef basic_iostream<wchar_t> wiostream;
5008 X typedef basic_stringbuf<wchar_t> wstringbuf;
5009 X typedef basic_istringstream<wchar_t> wistringstream;
5010 X typedef basic_ostringstream<wchar_t> wostringstream;
5011 X typedef basic_stringstream<wchar_t> wstringstream;
5013 X typedef basic_filebuf<wchar_t> wfilebuf;
5014 X typedef basic_ifstream<wchar_t> wifstream;
5015 X typedef basic_ofstream<wchar_t> wofstream;
5016 X typedef basic_fstream<wchar_t> wfstream;
5017 X template <class state> class fpos;
5018 X typedef fpos<char_traits<char>::state_type> streampos;
5019 X typedef fpos<char_traits<wchar_t>::state_type> wstreampos;
5021 27.3 Standard iostream objects [lib.iostream.objects]
5023 Header <iostream> synopsis
5025 T [must also include <istream> and <ostream>]
5026 T extern istream cin;
5027 T extern ostream cout;
5028 T extern ostream cerr;
5029 T extern ostream clog;
5031 T extern wistream wcin;
5032 T extern wostream wcout;
5033 T extern wostream wcerr;
5034 T extern wostream wclog;
5036 27.4 Iostreams base classes [lib.iostreams.base]
5038 Header <ios> synopsis
5040 #include <iosfwd>
5042 T typedef OFF_T streamoff;
5043 T typedef SZ_T streamsize;
5044 T template <class stateT> class fpos;
5046 class ios_base;
5047 template <class charT, class traits = char_traits<charT> >
5048 class basic_ios;
5049 // _lib.std.ios.manip_, manipulators:
5050 T ios_base& boolalpha (ios_base& str);
5051 T ios_base& noboolalpha(ios_base& str);
5052 T ios_base& showbase (ios_base& str);
5053 T ios_base& noshowbase (ios_base& str);
5054 T ios_base& showpoint (ios_base& str);
5055 T ios_base& noshowpoint(ios_base& str);
5056 T ios_base& showpos (ios_base& str);
5057 T ios_base& noshowpos (ios_base& str);
5058 T ios_base& skipws (ios_base& str);
5059 T ios_base& noskipws (ios_base& str);
5060 T ios_base& nouppercase(ios_base& str);
5061 T ios_base& uppercase (ios_base& str);
5062 M ios_base& unitbuf (ios_base& str);
5063 M ios_base& nounitbuf (ios_base& str);
5064 // _lib.adjustfield.manip_ adjustfield:
5065 T ios_base& internal (ios_base& str);
5066 T ios_base& left (ios_base& str);
5067 T ios_base& right (ios_base& str);
5068 // _lib.basefield.manip_ basefield:
5069 T ios_base& dec (ios_base& str);
5070 T ios_base& hex (ios_base& str);
5071 T ios_base& oct (ios_base& str);
5073 // _lib.floatfield.manip_ floatfield:
5074 T ios_base& fixed (ios_base& str);
5075 T ios_base& scientific (ios_base& str);
5078 27.4.2 Class ios_base [lib.ios.base]
5080 T class ios_base {
5081 public:
5082 class failure;
5083 T typedef T1 fmtflags;
5084 T static const fmtflags boolalpha;
5085 T static const fmtflags dec;
5086 T static const fmtflags fixed;
5087 T static const fmtflags hex;
5088 T static const fmtflags internal;
5089 T static const fmtflags left;
5090 T static const fmtflags oct;
5091 T static const fmtflags right;
5092 T static const fmtflags scientific;
5093 T static const fmtflags showbase;
5094 T static const fmtflags showpoint;
5095 T static const fmtflags showpos;
5096 T static const fmtflags skipws;
5097 X static const fmtflags unitbuf;
5098 T static const fmtflags uppercase;
5099 T static const fmtflags adjustfield;
5100 T static const fmtflags basefield;
5101 T static const fmtflags floatfield;
5103 typedef T2 iostate;
5104 T static const iostate badbit;
5105 T static const iostate eofbit;
5106 T static const iostate failbit;
5107 T static const iostate goodbit;
5108 T typedef T3 openmode;
5109 T static const openmode app;
5110 T static const openmode ate;
5111 T static const openmode binary;
5112 T static const openmode in;
5113 T static const openmode out;
5114 T static const openmode trunc;
5115 T typedef T4 seekdir;
5116 T static const seekdir beg;
5117 T static const seekdir cur;
5118 T static const seekdir end;
5119 T class Init;
5120 // _lib.fmtflags.state_ fmtflags state:
5121 T fmtflags flags() const;
5122 T fmtflags flags(fmtflags fmtfl);
5123 T fmtflags setf(fmtflags fmtfl);
5124 T fmtflags setf(fmtflags fmtfl, fmtflags mask);
5125 T void unsetf(fmtflags mask);
5126 T streamsize precision() const;
5127 T streamsize precision(streamsize prec);
5128 T streamsize width() const;
5129 T streamsize width(streamsize wide);
5130 // _lib.ios.base.locales_ locales:
5131 T locale imbue(const locale& loc);
5132 T locale getloc() const;
5133 // _lib.ios.base.storage_ storage:
5134 T static int xalloc();
5135 T long& iword(int index);
5136 T void*& pword(int index);
5137 // destructor
5138 T virtual ~ios_base();
5139 // _lib.ios.base.callback_ callbacks;
5140 T enum event { erase_event, imbue_event, copyfmt_event };
5141 T typedef void (*event_callback)(event, ios_base&, int index);
5142 T void register_callback(event_call_back fn, int index);
5143 T static bool sync_with_stdio(bool sync = true);
5144 protected:
5145 T ios_base();
5148 27.4.2.1.1 Class ios_base::failure [lib.ios::failure]
5150 T class ios_base::failure : public exception {
5151 public:
5152 T explicit failure(const string& msg);
5153 T virtual ~failure();
5154 T virtual const char* what() const throw();
5158 27.4.2.1.6 Class ios_base::Init [lib.ios::Init]
5160 T class ios_base::Init {
5161 public:
5162 T Init();
5163 T ~Init();
5167 27.4.3 Template class fpos [lib.fpos]
5169 X template <class stateT> class fpos {
5170 public:
5171 // _lib.fpos.members_ Members
5172 T stateT state() const;
5173 T void state(stateT);
5174 private;
5175 T stateT st; // exposition only
5179 27.4.5 Template class basic_ios [lib.ios]
5181 template <class charT, class traits = char_traits<charT> >
5182 X class basic_ios : public ios_base {
5183 public:
5185 // Types:
5186 T typedef charT char_type;
5187 T typedef typename traits::int_type int_type;
5188 T typedef typename traits::pos_type pos_type;
5189 T typedef typename traits::off_type off_type;
5190 T typedef traits traits_type;
5191 T operator void*() const
5192 T bool operator!() const
5193 T iostate rdstate() const;
5194 T void clear(iostate state = goodbit);
5195 T void setstate(iostate state);
5196 T bool good() const;
5197 T bool eof() const;
5198 T bool fail() const;
5199 T bool bad() const;
5200 T iostate exceptions() const;
5201 T void exceptions(iostate except);
5202 // _lib.basic.ios.cons_ Constructor/destructor:
5203 T explicit basic_ios(basic_streambuf<charT,traits>* sb);
5204 T virtual ~basic_ios();
5205 // _lib.basic.ios.members_ Members:
5206 T basic_ostream<charT,traits>* tie() const;
5207 T basic_ostream<charT,traits>* tie(basic_ostream<charT,traits>* tiestr);
5208 T basic_streambuf<charT,traits>* rdbuf() const;
5209 T basic_streambuf<charT,traits>* rdbuf(basic_streambuf<charT,traits>* sb);
5210 X basic_ios& copyfmt(const basic_ios& rhs);
5211 T char_type fill() const;
5212 T char_type fill(char_type ch);
5213 // _lib.ios.base.locales_ locales:
5214 T locale imbue(const locale& loc);
5215 X char narrow(char_type c, char dfault) const;
5216 X char_type widen(char c) const;
5217 protected:
5218 basic_ios();
5219 T void init(basic_streambuf<charT,traits>* sb);
5220 private:
5221 T basic_ios(const basic_ios& ); // not defined
5222 T basic_ios& operator=(const basic_ios&); // not defined
5226 27.5 Stream buffers [lib.stream.buffers]
5228 Header <streambuf> synopsis
5230 X template <class charT, class traits = char_traits<charT> >
5231 class basic_streambuf;
5232 T typedef basic_streambuf<char> streambuf;
5233 T typedef basic_streambuf<wchar_t> wstreambuf;
5235 27.5.2 Template class [lib.streambuf]
5236 basic_streambuf<charT,traits>
5238 template <class charT, class traits = char_traits<charT> >
5239 X class basic_streambuf {
5240 public:
5242 // Types:
5243 T typedef charT char_type;
5244 T typedef typename traits::int_type int_type;
5245 T typedef typename traits::pos_type pos_type;
5246 T typedef typename traits::off_type off_type;
5247 T typedef traits traits_type;
5248 T virtual ~basic_streambuf();
5249 // _lib.streambuf.locales_ locales:
5250 T locale pubimbue(const locale &loc);
5251 T locale getloc() const;
5252 // _lib.streambuf.buffer_ buffer and positioning:
5253 T basic_streambuf<char_type,traits>*
5254 pubsetbuf(char_type* s, streamsize n);
5255 T pos_type pubseekoff(off_type off, ios_base::seekdir way,
5256 ios_base::openmode which =
5257 ios_base::in | ios_base::out);
5258 T pos_type pubseekpos(pos_type sp,
5259 ios_base::openmode which =
5260 ios_base::in | ios_base::out);
5261 T int pubsync();
5263 // Get and put areas:
5264 // _lib.streambuf.pub.get_ Get area:
5265 T streamsize in_avail();
5266 T int_type snextc();
5267 T int_type sbumpc();
5268 T int_type sgetc();
5269 T streamsize sgetn(char_type* s, streamsize n);
5270 // _lib.streambuf.pub.pback_ Putback:
5271 X int_type sputbackc(char_type c);
5272 X int_type sungetc();
5273 // _lib.streambuf.pub.put_ Put area:
5274 T int_type sputc(char_type c);
5275 X streamsize sputn(const char_type* s, streamsize n);
5276 protected:
5277 T basic_streambuf();
5278 // _lib.streambuf.get.area_ Get area:
5279 T char_type* eback() const;
5280 T char_type* gptr() const;
5281 T char_type* egptr() const;
5282 T void gbump(int n);
5283 T void setg(char_type* gbeg, char_type* gnext, char_type* gend);
5284 // _lib.streambuf.put.area_ Put area:
5285 T char_type* pbase() const;
5286 T char_type* pptr() const;
5287 T char_type* epptr() const;
5288 T void pbump(int n);
5289 T void setp(char_type* pbeg, char_type* pend);
5290 // _lib.streambuf.virtuals_ virtual functions:
5291 // _lib.streambuf.virt.locales_ Locales:
5292 T virtual void imbue(const locale &loc);
5293 // _lib.streambuf.virt.buffer_ Buffer management and positioning:
5294 T virtual basic_streambuf<char_type,traits>*
5295 setbuf(char_type* s, streamsize n);
5296 T virtual pos_type seekoff(off_type off, ios_base::seekdir way,
5297 ios_base::openmode which = ios_base::in | ios_base::out);
5298 T virtual pos_type seekpos(pos_type sp,
5299 ios_base::openmode which = ios_base::in | ios_base::out);
5300 T virtual int sync();
5301 // _lib.streambuf.virt.get_ Get area:
5302 T virtual int showmanyc();
5303 T virtual streamsize xsgetn(char_type* s, streamsize n);
5304 T virtual int_type underflow();
5305 T virtual int_type uflow();
5306 // _lib.streambuf.virt.pback_ Putback:
5307 T virtual int_type pbackfail(int_type c = traits::eof());
5308 // _lib.streambuf.virt.put_ Put area:
5309 X virtual streamsize xsputn(const char_type* s, streamsize n);
5310 T virtual int_type overflow (int_type c = traits::eof());
5313 27.6 Formatting and manipulators [lib.iostream.format]
5315 Header <istream> synopsis
5317 T template <class charT, class traits = char_traits<charT> >
5318 class basic_istream;
5319 T typedef basic_istream<char> istream;
5320 T typedef basic_istream<wchar_t> wistream;
5322 T template <class charT, class traits = char_traits<charT> >
5323 class basic_iostream;
5324 T typedef basic_iostream<char> iostream;
5325 T typedef basic_iostream<wchar_t> wiostream;
5327 X template <class charT, class traits>
5328 basic_istream<charT,traits>& ws(basic_istream<charT,traits>& is);
5330 Header <ostream> synopsis
5332 X template <class charT, class traits = char_traits<charT> >
5333 class basic_ostream;
5334 T typedef basic_ostream<char> ostream;
5335 T typedef basic_ostream<wchar_t> wostream;
5337 T template <class charT, class traits>
5338 basic_ostream<charT,traits>& endl(basic_ostream<charT,traits>& os);
5339 T template <class charT, class traits>
5340 basic_ostream<charT,traits>& ends(basic_ostream<charT,traits>& os);
5341 T template <class charT, class traits>
5342 basic_ostream<charT,traits>& flush(basic_ostream<charT,traits>& os);
5344 Header <iomanip> synopsis
5346 // Types T1, T2, ... are unspecified implementation types
5347 T T1 resetiosflags(ios_base::fmtflags mask);
5348 T T2 setiosflags (ios_base::fmtflags mask);
5349 T T3 setbase(int base);
5350 T template<charT> T4 setfill(charT c);
5351 T T5 setprecision(int n);
5352 T T6 setw(int n);
5355 27.6.1.1 Template class basic_istream [lib.istream]
5357 template <class charT, class traits = char_traits<charT> >
5358 T class basic_istream : virtual public basic_ios<charT,traits> {
5359 public:
5360 // Types (inherited from basic_ios (_lib.ios_)):
5361 T typedef charT char_type;
5362 T typedef typename traits::int_type int_type;
5363 T typedef typename traits::pos_type pos_type;
5364 T typedef typename traits::off_type off_type;
5365 T typedef traits traits_type;
5366 // _lib.istream.cons_ Constructor/destructor:
5367 T explicit basic_istream(basic_streambuf<charT,traits>* sb);
5368 T virtual ~basic_istream();
5369 // _lib.istream::sentry_ Prefix/suffix:
5370 T class sentry;
5372 // _lib.istream.formatted_ Formatted input:
5373 T basic_istream<charT,traits>& operator>>
5374 (basic_istream<charT,traits>& (*pf)(basic_istream<charT,traits>&))
5375 T basic_istream<charT,traits>& operator>>
5376 (basic_ios<charT,traits>& (*pf)(basic_ios<charT,traits>&))
5377 T basic_istream<charT,traits>& operator>>
5378 (ios_base& (*pf)(ios_base&))
5379 S basic_istream<charT,traits>& operator>>(bool& n);
5380 S basic_istream<charT,traits>& operator>>(short& n);
5381 S basic_istream<charT,traits>& operator>>(unsigned short& n);
5382 S basic_istream<charT,traits>& operator>>(int& n);
5383 S basic_istream<charT,traits>& operator>>(unsigned int& n);
5384 S basic_istream<charT,traits>& operator>>(long& n);
5385 S basic_istream<charT,traits>& operator>>(unsigned long& n);
5386 S basic_istream<charT,traits>& operator>>(float& f);
5387 S basic_istream<charT,traits>& operator>>(double& f);
5388 S basic_istream<charT,traits>& operator>>(long double& f);
5389 S basic_istream<charT,traits>& operator>>(void*& p);
5390 S basic_istream<charT,traits>& operator>>
5391 (basic_streambuf<char_type,traits>* sb);
5392 // _lib.istream.unformatted_ Unformatted input:
5393 T streamsize gcount() const;
5394 S int_type get();
5395 S basic_istream<charT,traits>& get(char_type& c);
5396 S basic_istream<charT,traits>& get(char_type* s, streamsize n);
5397 S basic_istream<charT,traits>& get(char_type* s, streamsize n,
5398 char_type delim);
5399 S basic_istream<charT,traits>& get(basic_streambuf<char_type,traits>& sb);
5400 S basic_istream<charT,traits>& get(basic_streambuf<char_type,traits>& sb,
5401 char_type delim);
5402 S basic_istream<charT,traits>& getline(char_type* s, streamsize n);
5403 S basic_istream<charT,traits>& getline(char_type* s, streamsize n,
5404 char_type delim);
5405 S basic_istream<charT,traits>& ignore
5406 (streamsize n = 1, int_type delim = traits::eof());
5407 S int_type peek();
5408 S basic_istream<charT,traits>& read (char_type* s, streamsize n);
5409 S streamsize readsome(char_type* s, streamsize n);
5410 S basic_istream<charT,traits>& putback(char_type c);
5411 S basic_istream<charT,traits>& unget();
5412 S int sync();
5414 S pos_type tellg();
5415 S basic_istream<charT,traits>& seekg(pos_type);
5416 S basic_istream<charT,traits>& seekg(off_type, ios_base::seekdir);
5419 // _lib.istream::extractors_ character extraction templates:
5420 S template<class charT, class traits>
5421 basic_istream<charT,traits>& operator>>(basic_istream<charT,traits>&,
5422 charT&);
5423 S template<class traits>
5424 basic_istream<char,traits>& operator>>(basic_istream<char,traits>&,
5425 unsigned char&);
5426 S template<class traits>
5427 basic_istream<char,traits>& operator>>(basic_istream<char,traits>&,
5428 signed char&);
5430 S template<class charT, class traits>
5431 basic_istream<charT,traits>& operator>>(basic_istream<charT,traits>&,
5432 charT*);
5433 S template<class traits>
5434 basic_istream<char,traits>& operator>>(basic_istream<char,traits>&,
5435 unsigned char*);
5436 S template<class traits>
5437 basic_istream<char,traits>& operator>>(basic_istream<char,traits>&,
5438 signed char*);
5440 27.6.1.1.2 Class basic_istream::sentry [lib.istream::sentry]
5443 template <class charT,class traits = char_traits<charT> >
5444 S class basic_istream<charT,traits>::sentry {
5445 typedef traits traits_type;
5446 S bool ok_; // exposition only
5447 public:
5448 S explicit sentry(basic_istream<charT,traits>& is, bool noskipws = false);
5449 S ~sentry();
5450 S operator bool() const { return ok_; }
5451 private:
5452 T sentry(const sentry&); // not defined
5453 T sentry& operator=(const sentry&); // not defined
5457 27.6.1.5 Template class basic_iostream [lib.iostreamclass]
5459 template <class charT, class traits = char_traits<charT> >
5460 T class basic_iostream :
5461 public basic_istream<charT,traits>,
5462 public basic_ostream<charT,traits> {
5463 public:
5464 // constructor/destructor
5465 T explicit basic_iostream(basic_streambuf<charT,traits>* sb);
5466 T virtual ~basic_iostream();
5470 27.6.2.1 Template class basic_ostream [lib.ostream]
5472 template <class charT, class traits = char_traits<charT> >
5473 X class basic_ostream : virtual public basic_ios<charT,traits> {
5474 public:
5475 // Types (inherited from basic_ios (_lib.ios_)):
5476 T typedef charT char_type;
5477 T typedef typename traits::int_type int_type;
5478 T typedef typename traits::pos_type pos_type;
5479 T typedef typename traits::off_type off_type;
5480 T typedef traits traits_type;
5481 // _lib.ostream.cons_ Constructor/destructor:
5482 T explicit basic_ostream(basic_streambuf<char_type,traits>* sb);
5483 T virtual ~basic_ostream();
5484 // _lib.ostream::sentry_ Prefix/suffix:
5485 T class sentry;
5486 // _lib.ostream.formatted_ Formatted output:
5487 T basic_ostream<charT,traits>& operator<<
5488 (basic_ostream<charT,traits>& (*pf)(basic_ostream<charT,traits>&));
5489 T basic_ostream<charT,traits>& operator<<
5490 (basic_ios<charT,traits>& (*pf)(basic_ios<charT,traits>&));
5491 T basic_ostream<charT,traits>& operator<<
5492 (ios_base& (*pf)(ios_base&));
5493 T basic_ostream<charT,traits>& operator<<(bool n);
5494 T basic_ostream<charT,traits>& operator<<(short n);
5495 T basic_ostream<charT,traits>& operator<<(unsigned short n);
5496 T basic_ostream<charT,traits>& operator<<(int n);
5497 T basic_ostream<charT,traits>& operator<<(unsigned int n);
5498 T basic_ostream<charT,traits>& operator<<(long n);
5499 T basic_ostream<charT,traits>& operator<<(unsigned long n);
5500 S basic_ostream<charT,traits>& operator<<(float f);
5501 S basic_ostream<charT,traits>& operator<<(double f);
5502 S basic_ostream<charT,traits>& operator<<(long double f);
5503 T basic_ostream<charT,traits>& operator<<(const void* p);
5504 X basic_ostream<charT,traits>& operator<<
5505 (basic_streambuf<char_type,traits>* sb);
5506 // _lib.ostream.unformatted_ Unformatted output:
5507 T basic_ostream<charT,traits>& put(char_type c);
5508 T basic_ostream<charT,traits>& write(const char_type* s, streamsize n);
5509 X basic_ostream<charT,traits>& flush();
5511 // _lib.ostream.seeks_ seeks:
5512 S pos_type tellp();
5513 S basic_ostream<charT,traits>& seekp(pos_type);
5514 S basic_ostream<charT,traits>& seekp(off_type, ios_base::seekdir);
5516 // _lib.ostream.inserters.character_ character inserters
5517 X template<class charT, class traits>
5518 basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>&,
5519 charT);
5520 X template<class charT, class traits>
5521 basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>&,
5522 char);
5523 // specialization
5524 X template<class traits>
5525 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5526 char);
5527 // signed and unsigned
5528 X template<class traits>
5529 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5530 signed char);
5531 X template<class traits>
5532 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5533 unsigned char)
5534 X template<class charT, class traits>
5535 basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>&,
5536 const charT*);
5537 X template<class charT, class traits>
5538 basic_ostream<charT,traits>& operator<<(basic_ostream<charT,traits>&,
5539 const char*);
5540 // partial specializationss
5541 X template<class traits>
5542 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5543 const char*);
5544 // signed and unsigned
5545 X template<class traits>
5546 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5547 const signed char*);
5548 X template<class traits>
5549 basic_ostream<char,traits>& operator<<(basic_ostream<char,traits>&,
5550 const unsigned char*);
5553 27.6.2.3 Class basic_ostream::sentry [lib.ostream::sentry]
5555 template <class charT,class traits = char_traits<charT> >
5556 X class basic_ostream<charT,traits>::sentry {
5557 bool ok_; // exposition only
5558 public:
5559 X explicit sentry(basic_ostream<charT,traits>& os);
5560 X ~sentry();
5561 X operator bool() const { return ok_; }
5562 private
5563 X sentry(const sentry&); // not defined
5564 X sentry& operator=(const sentry&); // not defined
5567 27.7 String-based streams [lib.string.streams]
5569 Header <sstream> synopsis
5571 X template <class charT, class traits = char_traits<charT>,
5572 class Allocator = allocator<charT> >
5573 class basic_stringbuf;
5575 T typedef basic_stringbuf<char> stringbuf;
5576 T typedef basic_stringbuf<wchar_t> wstringbuf;
5578 template <class charT, class traits = char_traits<charT>,
5579 class Allocator = allocator<charT> >
5580 X class basic_istringstream;
5582 T typedef basic_istringstream<char> istringstream;
5583 T typedef basic_istringstream<wchar_t> wistringstream;
5585 template <class charT, class traits = char_traits<charT>,
5586 class Allocator = allocator<charT> >
5587 X class basic_ostringstream;
5588 T typedef basic_ostringstream<char> ostringstream;
5589 T typedef basic_ostringstream<wchar_t> wostringstream;
5591 template <class charT, class traits = char_traits<charT>,
5592 class Allocator = allocator<charT> >
5593 X class basic_stringstream;
5594 T typedef basic_stringstream<char> stringstream;
5595 T typedef basic_stringstream<wchar_t> wstringstream;
5597 27.7.1 Template class basic_stringbuf [lib.stringbuf]
5599 template <class charT, class traits = char_traits<charT>,
5600 class Allocator = allocator<charT> >
5601 X class basic_stringbuf : public basic_streambuf<charT,traits> {
5602 public:
5603 T typedef charT char_type;
5604 T typedef typename traits::int_type int_type;
5605 T typedef typename traits::pos_type pos_type;
5606 T typedef typename traits::off_type off_type;
5607 T typedef traits traits_type;
5608 // _lib.stringbuf.cons_ Constructors:
5609 S explicit basic_stringbuf(ios_base::openmode which
5610 = ios_base::in | ios_base::out);
5611 S explicit basic_stringbuf
5612 (const basic_string<charT,traits,Allocator>& str,
5613 ios_base::openmode which = ios_base::in | ios_base::out);
5614 // _lib.stringbuf.members_ Get and set:
5615 S basic_string<charT,traits,Allocator> str() const;
5616 S void str(const basic_string<charT,traits,Allocator>& s);
5618 protected:
5619 // _lib.stringbuf.virtuals_ Overridden virtual functions:
5620 S virtual int_type underflow();
5621 S virtual int_type pbackfail(int_type c = traits::eof());
5622 S virtual int_type overflow (int_type c = traits::eof());
5623 S virtual basic_streambuf<charT,traits>* setbuf(charT*, streamsize);
5625 S virtual pos_type seekoff(off_type off, ios_base::seekdir way,
5626 ios_base::openmode which
5627 = ios_base::in | ios_base::out);
5628 S virtual pos_type seekpos(pos_type sp,
5629 ios_base::openmode which
5630 = ios_base::in | ios_base::out);
5634 27.7.2 Template class basic_istringstream [lib.istringstream]
5636 template <class charT, class traits = char_traits<charT>,
5637 class Allocator = allocator<charT> >
5638 X class basic_istringstream : public basic_istream<charT,traits> {
5639 public:
5640 T typedef charT char_type;
5641 T typedef typename traits::int_type int_type;
5642 T typedef typename traits::pos_type pos_type;
5643 T typedef typename traits::off_type off_type;
5644 T typedef traits traits_type;
5645 // _lib.istringstream.cons_ Constructors:
5646 S explicit basic_istringstream(ios_base::openmode which = ios_base::in);
5647 S explicit basic_istringstream(
5648 const basic_string<charT,traits,Allocator>& str,
5649 ios_base::openmode which = ios_base::in);
5651 // _lib.istringstream.members_ Members:
5652 S basic_stringbuf<charT,traits,Allocator>* rdbuf() const;
5653 S basic_string<charT,traits,Allocator> str() const;
5654 S void str(const basic_string<charT,traits,Allocator>& s);
5655 private:
5656 // basic_stringbuf<charT,traits,Allocator> sb; exposition only
5659 27.7.3 Class basic_ostringstream [lib.ostringstream]
5661 template <class charT, class traits = char_traits<charT>,
5662 class Allocator = allocator<charT> >
5663 X class basic_ostringstream : public basic_ostream<charT,traits> {
5664 public:
5666 // Types:
5667 T typedef charT char_type;
5668 T typedef typename traits::int_type int_type;
5669 T typedef typename traits::pos_type pos_type;
5670 T typedef typename traits::off_type off_type;
5671 // _lib.ostringstream.cons_ Constructors/destructor:
5672 S explicit basic_ostringstream(ios_base::openmode which = ios_base::out);
5673 S explicit basic_ostringstream(
5674 const basic_string<charT,traits,Allocator>& str,
5675 ios_base::openmode which = ios_base::out);
5676 // _lib.ostringstream.members_ Members:
5677 S basic_stringbuf<charT,traits,Allocator>* rdbuf() const;
5678 S basic_string<charT,traits,Allocator> str() const;
5679 S void str(const basic_string<charT,traits,Allocator>& s);
5683 27.7.4 Template class basic_stringstream [lib.stringstream]
5685 template <class charT, class traits = char_traits<charT>,
5686 class Allocator = allocator<charT> >
5687 X class basic_stringstream
5688 : public basic_iostream<charT,traits> {
5689 public:
5690 // Types
5691 T typedef charT char_type;
5692 T typedef typename traits::int_type int_type;
5693 T typedef typename traits::pos_type pos_type;
5694 T typedef typename traits::off_type off_type;
5695 // constructors/destructors
5696 S explicit basic_stringstream(
5697 ios_base::openmode which = ios_base::out|ios_base::in);
5698 S explicit basic_stringstream(
5699 const basic_string<charT,traits,Allocator>& str,
5700 ios_base::openmode which = ios_base::out|ios_base::in);
5701 // Members:
5702 S basic_stringbuf<charT,traits,Allocator>* rdbuf() const;
5703 S basic_string<charT,traits,Allocator> str() const;
5704 S void str(const basic_string<charT,traits,Allocator>& str);
5709 27.8.1 File streams [lib.fstreams]
5712 Header <fstream> synopsis
5714 X template <class charT, class traits = char_traits<charT> >
5715 class basic_filebuf;
5716 T typedef basic_filebuf<char> filebuf;
5717 T typedef basic_filebuf<wchar_t> wfilebuf;
5719 X template <class charT, class traits = char_traits<charT> >
5720 class basic_ifstream;
5721 T typedef basic_ifstream<char> ifstream;
5722 T typedef basic_ifstream<wchar_t> wifstream;
5724 X template <class charT, class traits = char_traits<charT> >
5725 class basic_ofstream;
5726 T typedef basic_ofstream<char> ofstream;
5727 T typedef basic_ofstream<wchar_t> wofstream;
5729 X template <class charT, class traits = char_traits<charT> >
5730 class basic_fstream;
5731 T typedef basic_fstream<char> fstream;
5732 T typedef basic_fstream<wchar_t> wfstream;
5734 27.8.1.1 Template class basic_filebuf [lib.filebuf]
5736 template <class charT, class traits = char_traits<charT> >
5737 X class basic_filebuf : public basic_streambuf<charT,traits> {
5738 public:
5739 T typedef charT char_type;
5740 T typedef typename traits::int_type int_type;
5741 T typedef typename traits::pos_type pos_type;
5742 T typedef typename traits::off_type off_type;
5743 T typedef traits traits_type;
5744 // _lib.filebuf.cons_ Constructors/destructor:
5745 X basic_filebuf();
5746 X virtual ~basic_filebuf();
5747 // _lib.filebuf.members_ Members:
5748 T bool is_open() const;
5749 X basic_filebuf<charT,traits>* open
5750 (const char* s, ios_base::openmode mode);
5751 X basic_filebuf<charT,traits>* close();
5752 protected:
5753 // _lib.filebuf.virtuals_ Overridden virtual functions:
5754 X virtual streamsize showmanyc();
5755 X virtual int_type underflow();
5756 X virtual int_type uflow();
5757 X virtual int_type pbackfail(int_type c = traits::eof());
5758 X virtual int_type overflow (int_type c = traits::eof());
5759 S virtual basic_streambuf<charT,traits>*
5760 setbuf(char_type* s, streamsize n);
5761 S virtual pos_type seekoff(off_type off, ios_base::seekdir way,
5762 ios_base::openmode which
5763 = ios_base::in | ios_base::out);
5764 S virtual pos_type seekpos(pos_type sp, ios_base::openmode which
5765 = ios_base::in | ios_base::out);
5766 S virtual int sync();
5767 S virtual void imbue(const locale& loc);
5772 27.8.1.5 Template class basic_ifstream [lib.ifstream]
5774 template <class charT, class traits = char_traits<charT> >
5775 X class basic_ifstream : public basic_istream<charT,traits> {
5776 public:
5777 T typedef charT char_type;
5778 T typedef typename traits::int_type int_type;
5779 T typedef typename traits::pos_type pos_type;
5780 T typedef typename traits::off_type off_type;
5781 T typedef traits traits_type;
5782 // _lib.ifstream.cons_ Constructors:
5783 S basic_ifstream();
5784 S explicit basic_ifstream(const char* s,
5785 ios_base::openmode mode = ios_base::in);
5786 // _lib.ifstream.members_ Members:
5787 S basic_filebuf<charT,traits>* rdbuf() const;
5788 S bool is_open();
5789 S void open(const char* s, ios_base::openmode mode = ios_base::in);
5790 S void close();
5794 27.8.1.8 Template class basic_ofstream [lib.ofstream]
5796 template <class charT, class traits = char_traits<charT> >
5797 X class basic_ofstream : public basic_ostream<charT,traits> {
5798 public:
5799 T typedef charT char_type;
5800 T typedef typename traits::int_type int_type;
5801 T typedef typename traits::pos_type pos_type;
5802 T typedef typename traits::off_type off_type;
5803 T typedef traits traits_type;
5804 // _lib.ofstream.cons_ Constructors:
5805 X basic_ofstream();
5806 X explicit basic_ofstream(const char* s,
5807 ios_base::openmode mode
5808 = ios_base::out);
5809 // _lib.ofstream.members_ Members:
5810 X basic_filebuf<charT,traits>* rdbuf() const;
5811 T bool is_open();
5812 X void open(const char* s, ios_base::openmode mode = ios_base::out);
5813 X void close();
5817 27.8.1.11 Template class basic_fstream [lib.fstream]
5819 template <class charT, class traits=char_traits<charT> >
5820 X class basic_fstream
5821 : public basic_iostream<charT,traits> {
5822 public:
5823 T typedef charT char_type;
5824 T typedef typename traits::int_type int_type;
5825 T typedef typename traits::pos_type pos_type;
5826 T typedef typename traits::off_type off_type;
5827 T typedef traits traits_type;
5828 // constructors/destructor
5829 S basic_fstream();
5830 S explicit basic_fstream(
5831 const char* s,
5832 ios_base::openmode mode = ios_base::in|ios_base::out);
5834 // Members:
5835 S basic_filebuf<charT,traits>* rdbuf() const;
5836 S bool is_open();
5837 S void open(
5838 const char* s,
5839 ios_base::openmode mode = ios_base::in|ios_base::out);
5840 S void close();
5845 27.8.2 C Library files [lib.c.files]
5848 Table 13--Header <cstdio> synopsis
5849 Macros:
5850 X BUFSIZ L_tmpnam SEEK_SET TMP_MAX
5851 X EOF NULL <cstdio> stderr _IOFBF
5852 X FILENAME_MAX SEEK_CUR stdin _IOLBF
5853 X FOPEN_MAX SEEK_END stdout _IONBF
5855 X Types: FILE fpos_t size_t <cstdio>
5856 Functions:
5857 X clearerr fgets fscanf gets rewind
5858 X fclose fopen fseek perror scanf tmpnam
5859 X feof fprintf fsetpos printf setbuf ungetc
5860 X ferror fputc ftell putc setvbuf vprintf
5861 X fflush fputs fwrite puts sprintf vfprintf
5862 X fgetc fread getc remove sscanf vsprintf
5863 X fgetpos freopen getchar putchar rename tmpfile
5868 1.5 Standard C library headers [depr.c.headers]
5870 X <assert.h> <iso646.h> <setjmp.h> <stdio.h> <wchar.h>
5871 <ctype.h> <limits.h> <signal.h> <stdlib.h> <wctype.h>
5872 <errno.h> <locale.h> <stdarg.h> <string.h>
5873 <float.h> <math.h> <stddef.h> <time.h>
5875 1.6 Old iostreams members [depr.ios.members]
5877 [Note: these should be #ifdef'd to permit diagnostics if used.]
5878 namespace std {
5879 class ios_base {
5880 public:
5881 T typedef T1 io_state;
5882 T typedef T2 open_mode;
5883 T typedef T3 seek_dir;
5884 T typedef OFF_T streamoff;
5885 T typedef OFF_T streampos;
5886 // remainder unchanged
5890 [Note: these should be #ifdef'd to permit diagnostics if used.]
5891 namespace std {
5892 template<class charT, class traits = char_traits<charT> >
5893 class basic_streambuf {
5894 public:
5895 T void stossc();
5896 // remainder unchanged
5900 8 An implementation may provide the following member functions that
5901 overload signatures specified in clause _lib.iostreams_:
5903 [Note: the following overloads should be #ifdef'd to permit
5904 diagnostics to be emitted, by default, if used.]
5906 template<class charT, class Traits> class basic_ios {
5907 public:
5908 M void clear(io_state state);
5909 M void setstate(io_state state);
5910 // remainder unchanged
5912 class ios_base {
5913 public:
5914 M void exceptions(io_state);
5915 // remainder unchanged
5917 template<class charT, class traits = char_traits<charT> >
5918 class basic_streambuf {
5919 public:
5920 M pos_type pubseekoff(off_type off, ios_base::seek_dir way,
5921 ios_base::open_mode which = ios_base::in | ios_base::out);
5922 M pos_type pubseekpos(pos_type sp,
5923 ios_base::open_mode which = ios_base::in | ios_base::out);
5924 // remainder unchanged
5926 template <class charT, class traits = char_traits<charT> >
5927 class basic_filebuf : public basic_streambuf<charT,traits> {
5928 public:
5929 M basic_filebuf<charT,traits>* open
5930 (const char* s, ios_base::open_mode mode);
5931 // remainder unchanged
5933 template <class charT, class traits = char_traits<charT> >
5934 class basic_ifstream : public basic_istream<charT,traits> {
5935 public:
5936 M void open(const char* s, ios_base::open_mode mode = in);
5937 // remainder unchanged
5939 template <class charT, class traits = char_traits<charT> >
5940 class basic_ofstream : public basic_ostream<charT,traits> {
5941 public:
5942 M void open(const char* s, ios_base::open_mode mode = out | trunc);
5943 // remainder unchanged
5949 1.7.1 Class strstreambuf [depr.strstreambuf]
5951 [Note: It should be possible to adopt these components with only
5952 minor changes from the 2.8 version of the library.]
5954 M class strstreambuf : public basic_streambuf<char> {
5955 public:
5956 M explicit strstreambuf(streamsize alsize_arg = 0);
5957 M strstreambuf(void* (*palloc_arg)(size_t), void (*pfree_arg)(void*));
5958 M strstreambuf(char* gnext_arg, streamsize n, char* pbeg_arg = 0);
5959 M strstreambuf(const char* gnext_arg, streamsize n);
5960 M strstreambuf(signed char* gnext_arg, streamsize n,
5961 signed char* pbeg_arg = 0);
5962 M strstreambuf(const signed char* gnext_arg, streamsize n);
5963 M strstreambuf(unsigned char* gnext_arg, streamsize n,
5964 unsigned char* pbeg_arg = 0);
5965 M strstreambuf(const unsigned char* gnext_arg, streamsize n);
5966 M virtual ~strstreambuf();
5967 M void freeze(bool freezefl = true);
5968 M char* str();
5969 M int pcount();
5970 protected:
5971 M virtual int_type overflow (int_type c = EOF);
5972 M virtual int_type pbackfail(int_type c = EOF);
5973 M virtual int_type underflow();
5974 M virtual pos_type seekoff(off_type off, ios_base::seekdir way,
5975 ios_base::openmode which
5976 = ios_base::in | ios_base::out);
5977 M virtual pos_type seekpos(pos_type sp, ios_base::openmode which
5978 = ios_base::in | ios_base::out);
5979 M virtual streambuf<char>* setbuf(char* s, streamsize n);
5982 1.7.4 Class strstream [depr.strstream]
5984 M class strstream
5985 : public basic_iostream<char> {
5986 public:
5987 // Types
5988 M typedef char char_type;
5989 M typedef typename char_traits<char>::int_type int_type
5990 M typedef typename char_traits<char>::pos_type pos_type;
5991 M typedef typename char_traits<char>::off_type off_type;
5992 // consturctors/destructor
5993 M strstream();
5994 M strstream(char* s, int n,
5995 ios_base::openmode mode = ios_base::in|ios_base::out);
5996 M virtual ~strstream();
5997 // Members:
5998 M strstreambuf* rdbuf() const;
5999 M void freeze(bool freezefl = true);
6000 M int pcount() const;
6001 M char* str();
6004 </pre>