diff options
author | Chao-ying Fu <fu@mips.com> | 2007-05-04 00:47:49 +0000 |
---|---|---|
committer | Chao-ying Fu <fu@mips.com> | 2007-05-04 00:47:49 +0000 |
commit | b5dedd05596b3c88bafcbb3cb5051435a112ff90 (patch) | |
tree | 2633e98fce35702a5fe1750de5c6c6065fa6a283 /libstdc++-v3 | |
parent | b1319141745fb4b21b294b3396e7ed3ab4734f5e (diff) |
Merged revisions 124254-124401 via svnmerge from
svn+ssh://chaoyingfu@sources.redhat.com/svn/gcc/trunk
........
r124254 | jvdelisle | 2007-04-27 19:04:35 -0700 (Fri, 27 Apr 2007) | 5 lines
2007-04-27 Jerry DeLisle
* gfortran.dg/inquire_5.f90: Update test.
........
r124255 | jvdelisle | 2007-04-27 19:10:46 -0700 (Fri, 27 Apr 2007) | 5 lines
2007-04-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
* gfortran.dg/secnds.f: Use real*8.
* gfortran.dg/secnds-1.f: Use real*8.
........
r124257 | rakdver | 2007-04-28 01:00:44 -0700 (Sat, 28 Apr 2007) | 4 lines
* tree-cfg.c (move_block_to_fn): Release bb from dominance
info. Update last_basic_block correctly.
........
r124258 | hubicka | 2007-04-28 01:20:08 -0700 (Sat, 28 Apr 2007) | 50 lines
* config/alpha/alpha.c (alpha_output_mi_thunk_osf): Use
insn_locators_alloc instead of insn_locators_initialize;
call reset_block_changes.
* config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
* config/sh/sh.c (sparc_output_mi_thunk): Likewise.
* config/is64/ia64.c (ia64_output_mi_thunk): Likewise.
* config/rs6000/rs6000.c (rs6000_output_mi_thunk): Likewise.
* config/score/score.c (th_output_mi_thunk): Likewise.
* config/mips/mips.c (mips_output_mi_thunk): Likewise.
* cfglyaout.c (set_curr_insn_source_location, set_curr_insn_block):
tolerate uninitialized locator info.
Re-apply:
* function.c (init_function_start): Don't init line number info.
(expand_function_end): Update.
(reset_block_changes, record_block_change, finalize_block_changes,
check_block_change, free_block_changes): Kill.
* function.h (reset_block_changes, record_block_change,
finalize_block_changes, check_block_change, free_block_changes): Remove
prototypes.
(struct function): Remove ib_boundaries_block.
* emit-rtl.c (make_insn_raw, make_jump_insn_raw, make_call_insn_raw):
Use curr_insn_locator to initialize locator.
(emit_line_note): Remove.
* cfgexpand.c (expand_gimple_cond_expr): Update.
(construct_exit_block): Likewise.
(tree_expand_cfg): Initialize/finalize locators.
* expr.c (expand_expr_real): Update.
* cfglayout.c (line_locators_locs, line_locators_lines,
file_locators_locs, file_locators_files): Remove.
(set_block_levels): Move to cfgexpand.c.
(insn_locators_initialize): Remove.
(pass_insn_locators_initialize): Remove.
(locations_locators_locs, locations_locators_vals): New static vars.
(curr_location, last_location, curr_block, last_block, curr_rtl_loc):
Likewise.
(insn_locators_alloc, insn_locators_finalize,
set_curr_insn_source_location, set_curr_insn_block, curr_insn_locator):
New functions.
(locator_location): New.
(locator_line, locator_file): Rewrite.
* rtl.h (emit_line_note): Kill.
(insn_locators_alloc, insn_locators_finalize,
set_curr_insn_source_location, set_curr_insn_block, curr_insn_locator):
Declare.
* tree-inline.c (initialize_cfun): Do not initialize
ib_boundaries_block.
* passes.c (pass_insn_locators_initialize): Remove.
........
r124260 | tobi | 2007-04-28 06:17:07 -0700 (Sat, 28 Apr 2007) | 3 lines
* options.c (gfc_handle_option): Ensure requested free form line
length is not too small.
........
r124261 | sandra | 2007-04-28 10:47:28 -0700 (Sat, 28 Apr 2007) | 6 lines
2007-04-28 Sandra Loosemore <sandra@codesourcery.com>
Nigel Stephens <nigel@mips.com>
gcc/
* config/mips/mips.h (SLOW_BYTE_ACCESS): Turn off for MIPS16.
........
r124264 | gccadmin | 2007-04-28 16:17:40 -0700 (Sat, 28 Apr 2007) | 1 line
Daily bump.
........
r124266 | jvdelisle | 2007-04-28 16:23:35 -0700 (Sat, 28 Apr 2007) | 11 lines
2007-04-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
* io/list_read.c (next_char): Fix whitespace.
* io/io.h: Remove prototypes and define macros for is_array_io,
is_stream_io, and is_internal_unit.
* io/unit.c (is_array_io), (is_internal_unit), (is_stream_io): Delete
these functions.
* io/transfer.c (read_sf): Change handling of internal_unit to make a
single call to salloc_r and use memcpy to transfer the data.
........
r124269 | pault | 2007-04-28 22:10:22 -0700 (Sat, 28 Apr 2007) | 11 lines
2007-04-29 Paul Thomas <pault@gcc.gnu.org>
* trans-array.c (gfc_conv_resolve_dependencies): Create a temp
whenever a dependency is found.
2007-04-29 Paul Thomas <pault@gcc.gnu.org>
* gfortran.dg/dependency_21.f90: New test.
........
r124271 | pinskia | 2007-04-28 23:22:14 -0700 (Sat, 28 Apr 2007) | 14 lines
2007-04-28 Andrew Pinski <andrew_pinski@playstation.sony.com>
* decl.c (reshape_init_r): Don't reshape the first element if it
is a pointer to member function.
2007-04-28 Andrew Pinski <andrew_pinski@playstation.sony.com>
* g++.dg/init/ptrfn2.C: New test.
* g++.dg/init/ptrfn3.C: New test.
........
r124274 | fxcoudert | 2007-04-29 03:45:57 -0700 (Sun, 29 Apr 2007) | 14 lines
* scanner.c (load_file): Discard the byte order mark if one is
found on the first non-preprocessor line of a file.
* testsuite/gfortran.dg/bom_error.f90: New test.
* testsuite/gfortran.dg/bom_include.f90: New test.
* testsuite/gfortran.dg/bom_UTF16-LE.f90: New test.
* testsuite/gfortran.dg/bom_UTF16-BE.f90: New test.
* testsuite/gfortran.dg/bom_UTF-8.f90: New test.
* testsuite/gfortran.dg/bom_UTF-32.f90: New test.
* testsuite/gfortran.dg/bom_UTF-8.F90: New test.
* testsuite/gfortran.dg/bom_include.inc: New file.
........
r124275 | dfranke | 2007-04-29 03:49:08 -0700 (Sun, 29 Apr 2007) | 7 lines
2007-04-29 Daniel Franke <franke.daniel@gmail.com>
* gfortran.texi: Cleaned up keyword index.
* invoke.texi: Likewise.
* intrinsic.texi: Likewise.
........
r124277 | steven | 2007-04-29 04:47:11 -0700 (Sun, 29 Apr 2007) | 3 lines
* regclass.c (scan_one_insn): Remove splitting of
two address insns.
........
r124280 | bernds | 2007-04-29 06:22:04 -0700 (Sun, 29 Apr 2007) | 15 lines
* rtl.def (SS_ABS): New code.
* config/bfin/bfin.c (print_operand): New modifier 'v'.
(enum bfin_builtins): Add BFIN_BUILTIN_SUM_2X16, BFIN_BUILTIN_ABS_1x32,
BFIN_BUILTIN_ROUND_1x32, BFIN_BUILTIN_MULT_1x32x32,
BFIN_BUILTIN_MULT_1x32x32NS, BFIN_BUILTIN_SSASHIFT_1x32.
(bfin_init_builtins): Define them.
(bdesc_1arg, bdesc_2arg): Add some of them here, ...
(bfin_expand_builtin): ... and handle the others here.
* config/bfin/bfin.md (ssabssi2, ssroundsi2, ssashiftsi3,
flag_mul_macv2hi_parts_acconly_andcc0): New patterns.
(ss_absv2hi2): Renamed from absv2hi; use ss_abs code.
(ssashiftv2hi3, ssashifthi3, lshiftv2hi3, lshifthi3): Shift count
operand is only HImode.
........
r124281 | fxcoudert | 2007-04-29 09:03:58 -0700 (Sun, 29 Apr 2007) | 8 lines
* simplify.c (simplify_bound_dim): New function.
(simplify_bound): Use the above. Perform simplification of LBOUND
and UBOUND when DIM argument is not present.
* gfortran.dg/bound_simplification_1.f90: New test.
........
r124282 | paolo | 2007-04-29 09:06:09 -0700 (Sun, 29 Apr 2007) | 9 lines
2007-04-29 Paolo Carlini <pcarlini@suse.de>
* include/bits/localefwd.h: Remove redundant inline qualifiers.
(__check_facet): Move...
* include/bits/basic_ios.h: ... here.
(widen(char), narrow(char_type, char)): Define inline.
* include/bits/basic_ios.tcc (widen(char), narrow(char_type, char)):
Remove.
........
r124283 | rakdver | 2007-04-29 10:33:34 -0700 (Sun, 29 Apr 2007) | 4 lines
* df-scan.c (record_nonlocal_goto_receiver_defs): New function.
(df_refs_record): Call it.
........
r124284 | rakdver | 2007-04-29 10:34:11 -0700 (Sun, 29 Apr 2007) | 3 lines
changelog entry fix.
........
r124287 | geoffk | 2007-04-29 15:44:11 -0700 (Sun, 29 Apr 2007) | 2 lines
Fix problem on case-sensitive file systems.
........
r124290 | gccadmin | 2007-04-29 16:17:28 -0700 (Sun, 29 Apr 2007) | 1 line
Daily bump.
........
r124292 | fxcoudert | 2007-04-30 00:54:41 -0700 (Mon, 30 Apr 2007) | 3 lines
* doc/trouble.texi (Interoperation): Remove note about Ultrix
Fortran compiler.
........
r124293 | charlet | 2007-04-30 03:14:24 -0700 (Mon, 30 Apr 2007) | 3 lines
* Makefile.in: No longer build gprmake
........
r124294 | paolo | 2007-04-30 03:27:31 -0700 (Mon, 30 Apr 2007) | 12 lines
2007-04-30 Paolo Carlini <pcarlini@suse.de>
* include/tr1/type_traits (is_pod): Use __is_pod.
* testsuite/tr1/4_metaprogramming/type_properties/
has_trivial_destructor/has_trivial_destructor.cc: Adjust.
* testsuite/tr1/4_metaprogramming/type_properties/
has_nothrow_constructor/has_nothrow_constructor.cc: Likewise.
* testsuite/tr1/4_metaprogramming/type_properties/
has_trivial_constructor/has_trivial_constructor.cc: Likewise.
* testsuite/tr1/4_metaprogramming/type_properties/
is_pod/is_pod.cc: Likewise.
........
r124295 | paolo | 2007-04-30 06:10:54 -0700 (Mon, 30 Apr 2007) | 22 lines
2007-04-30 Paolo Carlini <pcarlini@suse.de>
* include/bits/stl_algobase.h (struct __niter_base): Add.
(copy(_II, _II, _OI), copy_backward(_BI1, _BI1, _BI2),
fill(_ForwardIterator, _ForwardIterator, const _Tp&),
fill_n(_OI, _Size, const _Tp&), equal(_II1, _II1, _II2)):
Use it.
(struct __copy_normal, __copy_backward_normal,
struct __fill_normal, struct __fill_n_normal): Remove.
(struct __equal, struct __equal_aux): Add.
* include/bits/stl_iterator.h: Add _Iterator_type typedef.
* include/bits/stl_algobase.h (__fill_aux(wchar_t*,
wchar_t*, wchar_t), __fill_n_aux(wchar_t*, _Size, wchar_t)):
Remove.
* testsuite/23_containers/requirements/sequences/dr438/vector/
constructor_1_neg.cc: Adjust dg-error line number.
* testsuite/23_containers/requirements/sequences/dr438/vector/
constructor_2_neg.cc: Likewise.
........
r124297 | dfranke | 2007-04-30 08:04:56 -0700 (Mon, 30 Apr 2007) | 9 lines
2007-04-30 Daniel Franke <franke.daniel@gmail.com>
* intrinsic.texi (IERRNO): Changed class to non-elemental function.
(LOG10): Removed COMPLEX as accepted argument type.
(NEW_LINE): Changed class from elemental to inquiry function.
(SIGN): Removed requirement of scalar arguments.
(SNGL): Changed class to elemental function.
........
r124298 | hp | 2007-04-30 09:12:48 -0700 (Mon, 30 Apr 2007) | 3 lines
* testsuite/lib/libstdc++.exp (v3_target_compile_as_c): Correct
regexp to filter out -nostdinc++.
........
r124300 | pinskia | 2007-04-30 10:01:18 -0700 (Mon, 30 Apr 2007) | 12 lines
2007-04-30 Andrew Pinski <andrew_pinski@playstation.sony.com>
* tree.c (reconstruct_complex_type): Reconstruct a reference
correctly.
Also use the same mode for the pointer as the old pointer type.
2007-04-30 Andrew pinski <andrew_pinski@playstation.sony.com>
* g++.dg/ext/vector7.C: New testcase.
........
r124302 | aoliva | 2007-04-30 10:41:11 -0700 (Mon, 30 Apr 2007) | 43 lines
Temporarily revert:
2007-04-06 Andreas Tobler <a.tobler@schweiz.org>
2007-04-05 Alexandre Oliva <aoliva@redhat.com>
* tree-sra.c (try_instantiate_multiple_fields): Needlessly
initialize align to silence bogus warning.
2007-04-05 Alexandre Oliva <aoliva@redhat.com>
* tree-sra.c (struct sra_elt): Add in_bitfld_block. Remove
all_no_warning.
(struct sra_walk_fns): Remove use_all parameter from use.
(sra_hash_tree): Handle BIT_FIELD_REFs.
(sra_elt_hash): Don't hash bitfld blocks.
(sra_elt_eq): Skip them in parent compares as well. Handle
BIT_FIELD_REFs.
(sra_walk_expr): Don't maintain or pass down use_all_p.
(scan_use): Remove use_all parameter.
(scalarize_use): Likewise. Re-expand assignment to
BIT_FIELD_REF of gimple_reg. De-scalarize before input or
output, and re-scalarize after output. Don't mark anything
for no warning.
(scalarize_ldst): Adjust.
(scalarize_walk_gimple_modify_statement): Likewise.
(build_element_name_1): Handle BIT_FIELD_REFs.
(instantiate_element): Don't warn for any element whose parent
is used as a whole.
(instantiate_missing_elements_1): Return the sra_elt.
(canon_type_for_field): New.
(try_instantiate_multiple_fields): New.
(instantiate_missing_elemnts): Use them.
(mark_no_warning): Removed.
(generate_one_element_ref): Handle BIT_FIELD_REFs.
(REPLDUP, sra_build_elt_assignment): New.
(generate_copy_inout): Use them.
(generate_element_copy): Likewise. Handle bitfld differences.
(generate_element_zero): Don't recurse for blocks. Use
sra_build_elt_assignment.
(generate_one_element_int): Take elt instead of var. Use
sra_build_elt_assignment.
(generate_element_init_1): Adjust.
(scalarize_use, scalarize_copy): Use REPLDUP.
(scalarize_ldst): Move assert before dereference.
(dump_sra_elt_name): Handle BIT_FIELD_REFs.
........
r124303 | bwilson | 2007-04-30 10:59:10 -0700 (Mon, 30 Apr 2007) | 3 lines
* config/xtensa/lib1funcs.asm (__umodsi3, __modsi3): Rearrange so that
DIV0 exception can fall through to a normal return.
........
r124304 | brooks | 2007-04-30 12:14:04 -0700 (Mon, 30 Apr 2007) | 17 lines
* double-int.c (mpz_set_double_int): Moved from
tree-ssa-loop-niter.c.
(mpz_get_double_int): Likewise; also, add option to wrap
out-of-range integers.
* double-int.h: New prototypes for above.
* tree.c (get_static_type_bounds): Moved from
tree-ssa-loop-niter.c; now returns TYPE_MIN_VALUE and
TYPE_MAX_VALUE if they exist..
* tree.h: New prototype for above.
* tree-ssa-loop-niter.c: Adjust mpz_to_double_int and
get_type_bounds calls.
(mpz_set_double_int): Move to double-int.c.
(get_type_bounds): Move to tree.c, rename to
get_static_type_bounds.
(mpz_to_double_int): Move to double-int.c, rename to
mpz_get_double_int.
........
r124305 | brooks | 2007-04-30 12:17:59 -0700 (Mon, 30 Apr 2007) | 7 lines
* trans-const.c (gfc_conv_mpz_to_tree): Use mpz_get_double_int.
(gfc_conv_tree_to_mpz): New function.
(gfc_conv_mpfr_to_tree): Use real_from_mpfr.
(gfc_conv_tree_to_mpfr): New function.
* trans-const.h: (gfc_conv_tree_to_mpz): New prototype.
(gfc_conv_tree_to_mpfr): New prototype.
........
r124306 | kazu | 2007-04-30 14:13:58 -0700 (Mon, 30 Apr 2007) | 4 lines
* gcc.c-torture/execute/ieee/20000320-1.c: Use
__LONG_LONG_MAX__ and its friends instead of those supplied by
limits.h.
........
r124307 | bkoz | 2007-04-30 15:41:00 -0700 (Mon, 30 Apr 2007) | 8 lines
2007-04-30 Benjamin Kosnik <bkoz@redhat.com>
Directory layout flattening.
........
r124308 | bkoz | 2007-04-30 15:45:19 -0700 (Mon, 30 Apr 2007) | 6 lines
2007-04-30 Benjamin Kosnik <bkoz@redhat.com>
Directory layout flattening.
........
r124311 | gccadmin | 2007-04-30 16:16:59 -0700 (Mon, 30 Apr 2007) | 1 line
Daily bump.
........
r124313 | kseitz | 2007-04-30 19:50:02 -0700 (Mon, 30 Apr 2007) | 6 lines
* interpret-run.cc (NEXT_INSN)[DEBUG]: Advance PC before
executing the instruction.
* include/java-interp.h (_Jv_InterpFrame::get_pc): Subtract
one insn from the frame's PC. _Jv_InterpMethod::run et al
will advance the PC before executing the instruction.
........
r124315 | dorit | 2007-04-30 23:58:59 -0700 (Mon, 30 Apr 2007) | 17 lines
* gcc.dg/vect/vect-iv-9.c: Added vect_int_mult target keyword to
dg-final test.
* gcc.dg/vect/vect-reduc-dot-u16b.c: Added vect_pack_trunc target
keyword to dg-final test.
* gcc.dg/vect/vect-iv-4.c: Likewise.
* gcc.dg/vect/vect-widen-mult-u16.c: Likewise.
* gcc.dg/vect/pr30771.c: Added vect_unapck target keyword to dg-final
test.
* gcc.dg/vect/vect-reduc-dot-u16a.c: Change variable type to avoid a
cast.
* gcc.dg/vect/no-section-anchors-vect-69.c: xfail on is64.
* lib/target-supports.exp
(check_effective_target_vect_widen_sum_hi_to_si): Added ia64.
(check_effective_target_vect_widen_sum_qi_to_hi): Added ia64.
........
r124316 | dorit | 2007-05-01 00:01:12 -0700 (Tue, 01 May 2007) | 6 lines
2007-05-01 Dorit Nuzman <dorit@il.ibm.com>
* gfortran.dg/vect/vect-5.f90: Fix dg-final test.
........
r124317 | bkoz | 2007-05-01 01:37:16 -0700 (Tue, 01 May 2007) | 6 lines
2007-05-01 Benjamin Kosnik <bkoz@redhat.com>
* tr1/4_metaprogramming/*/explicit_instantiations.cc: Change
"basic_ofstream" in comment to type_traits.
........
r124318 | bkoz | 2007-05-01 01:50:44 -0700 (Tue, 01 May 2007) | 7 lines
2007-05-01 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/*/explicit_instantiations.cc: Change to...
* testsuite/*/explicit_instantiation.cc: ... this.
........
r124319 | bkoz | 2007-05-01 02:04:35 -0700 (Tue, 01 May 2007) | 12 lines
2007-05-01 Benjamin Kosnik <bkoz@redhat.com>
* 23_containers/requirements/sequences/dr438/deque/*: Move to...
* 23_containers/deque/requirements/dr438: ...here.
* 23_containers/requirements/sequences/dr438/list/*: Move to...
* 23_containers/list/requirements/dr438: ...here.
* 23_containers/requirements/sequences/dr438/vector/*: Move to...
* 23_containers/vector/requirements/dr438: ...here.
........
r124320 | dfranke | 2007-05-01 02:12:29 -0700 (Tue, 01 May 2007) | 10 lines
2007-05-01 Daniel Franke <franke.daniel@gmail.com>
* intrinsic.c (add_functions): Fixed ELEMENTAL specifications.
(add_subroutines): Replaced magic numbers in function calls by
ELEMENTAL and NOT_ELEMENTAL respectively.
* intrinsic.texi (MVBITS): Changed class to elemental subroutine.
(RANDOM_NUMBER): Changed class to subroutine.
(HUGE, TINY): Changed class to inquiry function.
........
r124321 | rguenth | 2007-05-01 02:32:34 -0700 (Tue, 01 May 2007) | 18 lines
2007-05-01 Richard Guenther <rguenther@suse.de>
* tree-vrp.c (set_value_range): Do not allocate equiv bitmap
if it is not about to be set.
(get_value_range): Do not pre-allocate equiv bitmap.
(update_value_range): No need to clear equiv field.
(add_equivalence): Change prototype to get bitmap pointer.
Allocate bitmap here if it is not already.
(extract_range_from_assert): Do not allocate bitmap here.
Update callers to add_equivalence.
(extract_range_from_ssa_name): Likewise.
(get_vr_for_comparison): New static helper.
(compare_name_with_value): Handle NULL equiv bitmap by
peeling the first iteration of the comparison loop.
Use get_vr_for_comparison.
(compare_names): Handle NULL equiv bitmaps by using fake
ones. Use get_vr_for_comparison.
........
r124322 | rakdver | 2007-05-01 03:17:43 -0700 (Tue, 01 May 2007) | 15 lines
* tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Use
bsi_after_labels. Always insert statements before bsi.
* tree-vect-transform.c (vect_create_epilog_for_reduction): Ditto.
* predict.c (apply_return_prediction): Check for empty blocks.
* cfgexpand.c (lab_rtx_for_bb): New variable.
(label_rtx_for_bb): Do not create new tree labels.
(expand_gimple_basic_block): Add labels recorded in lab_rtx_for_bb.
(tree_expand_cfg): Initialize lab_rtx_for_bb.
* tree-cfg.c (build_tree_cfg): Call cleanup_dead_labels after
creating edges.
(label_for_bb): Add field used.
(update_eh_label, main_block_label): Mark the label used.
(cleanup_dead_labels): Remove unused labels.
........
r124323 | hubicka | 2007-05-01 04:18:01 -0700 (Tue, 01 May 2007) | 16 lines
* tree.h (maybe_fold_offset_to_component_ref): Remove.
(maybe_fold_offset_to_reference): Declare.
* fold-const.c (fold_unary): Do not fold
(type *)&A into &A->field_of_type_and_offset_0
* tree-ssa-ccp.c (maybe_fold_offset_to_array_ref): When base type
size is unknown, give up.
(maybe_fold_offset_to_component_ref): Ignore firelds with unknown
offsets.
(maybe_fold_offset_to_reference): New.
(maybe_fold_stmt_indirect): Use it.
(fold_stmt_r): Fold (type *)&A+offset into A->field_if_type_and_offset.
* gimplify.c (gimplify_conversion): Canonicalize conversions to
field references.
(gimplify_expr): Likewise for plus_expr.
........
r124324 | hubicka | 2007-05-01 04:19:59 -0700 (Tue, 01 May 2007) | 3 lines
* tree-vectorize.c (vect_is_simple_use): gimple_min_invariant is
invariant.
........
r124326 | tkoenig | 2007-05-01 06:11:36 -0700 (Tue, 01 May 2007) | 13 lines
2007-05-01 Thomas Koenig <tkoenig@gcc.gnu.org>
* dependency.c (gfc_full_array_ref_p): If the reference is
to a single element, check that the array has a single
element and that the correct element is referenced.
2007-05-01 Thomas Koenig <tkoenig@gcc.gnu.org>
* gfortran.dg/array_memset_2: New test case.
........
r124327 | kgallowa | 2007-05-01 06:28:00 -0700 (Tue, 01 May 2007) | 7 lines
2007-05-01 Kyle Galloway <kgallowa@redhat.com>
* classpath/lib/gnu/classpath/jdwp/VMIdManager.class: Regenerated.
* classpath/lib/gnu/classpath/jdwp/VMIdManager$ReferenceKey.class: Regenerated.
* classpath/lib/gnu/classpath/jdwp/VMIdManager$IdFactory.class: Regenerated.
........
r124328 | jsm28 | 2007-05-01 06:44:56 -0700 (Tue, 01 May 2007) | 2 lines
* config/rs6000/libgcc-ppc-glibc.ver (__gcc_qgt): Fix typo.
........
r124329 | rguenth | 2007-05-01 07:54:30 -0700 (Tue, 01 May 2007) | 5 lines
2007-05-01 Richard Guenther <rguenther@suse.de>
* tree-ssa-loop-manip.c (ip_normal_pos): Check if last stmt
is NULL.
........
r124330 | dwarak | 2007-05-01 08:29:10 -0700 (Tue, 01 May 2007) | 6 lines
* config/i386/i386.c (override_options): Tuning 32-byte loop
alignment for amdfam10 architecture. Increasing the max loop
alignment padding to 24 bytes.
........
r124332 | jsm28 | 2007-05-01 10:41:48 -0700 (Tue, 01 May 2007) | 9 lines
* config/rs6000/darwin-ldouble.c (__gcc_qunord): Define if
__NO_FPRS__, not just if _SOFT_DOUBLE.
* config/rs6000/libgcc-ppc-glibc.ver (__gcc_qunord): Likewise.
* config/rs6000/rs6000.c (rs6000_init_libfuncs): Use __gcc_qunord
also for E500 double.
* config/rs6000/rs6000.md (buneq, bunge, bungt, bunle, bunlt,
suneq, sunge, sungt, sunle, sunlt): Disable for (TARGET_HARD_FLOAT
&& !TARGET_FPRS).
........
r124333 | mmitchel | 2007-05-01 10:51:21 -0700 (Tue, 01 May 2007) | 11 lines
* config/i386/gmon-sol2.c (size_t): New type.
(intptr_t): Likewise.
(s_textsize): Declare as size_t.
(sbrk): Declare.
(monstartup): Use size_t for sizes.
(_mcount): Save and restore registers.
(internal_mcount): Pass 0 as the first argument to monstartup
in 64-bit mode.
(moncontrol): Convert pointer to appropriately sized integer
before passing to profil.
........
r124334 | ian | 2007-05-01 10:51:56 -0700 (Tue, 01 May 2007) | 13 lines
* tree-vrp.c (vrp_val_is_max): New static function.
(vrp_val_is_min): New static function.
(set_value_range_to_value): Use TYPE_{MAX,MIN}_VALUE rather than
copying the node.
(set_value_range): Use vrp_val_is_{max,min}.
(extract_range_from_assert): Likewise.
(extract_range_from_binary_expr): Likewise.
(extract_range_from_unary_expr): Likewise.
(dump_value_range, vrp_meet): Likewise.
(vrp_visit_phi_node): Likewise.
* tree.c (build_distinct_type_copy): Revert change of 2007-04-27.
........
r124335 | kazu | 2007-05-01 10:54:15 -0700 (Tue, 01 May 2007) | 7 lines
* config/m68k/constraints.md: New.
* config/m68k/m68k.h (REG_CLASS_FROM_LETTER,
CONST_OK_FOR_LETTER_P, CONST_DOUBLE_OK_FOR_LETTER_P,
EXTRA_CONSTRAINT): Remove.
* config/m68k/m68k.md: Include constraints.md.
* expr.c (expand_expr_real_1): Copy DECL_RTL before using it.
........
r124336 | dwarak | 2007-05-01 11:29:39 -0700 (Tue, 01 May 2007) | 1 line
Tuning 32-byte loop alignment for amdfam10 architecture
........
r124337 | pinskia | 2007-05-01 11:34:32 -0700 (Tue, 01 May 2007) | 7 lines
2007-05-01 Andrew Pinski <andrew_pinski@playstation.sony.com>
* gcc.c-torture/compile/20070501-1.c: New testcase.
........
r124339 | dwarak | 2007-05-01 12:34:19 -0700 (Tue, 01 May 2007) | 8 lines
2007-05-01 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
* config/i386/i386.c (override_options): Accept k8-sse3, opteron-sse3
and athlon64-sse3 as improved versions of k8, opteron and athlon64
with SSE3 instruction set support.
* doc/invoke.texi: Likewise.
........
r124340 | dwarak | 2007-05-01 12:48:29 -0700 (Tue, 01 May 2007) | 1 line
Accept k8-sse3, opteron-sse3 and athlon64-sse3 as improved versions of k8,opteron and athlon64 with SSE3 instruction set support
........
r124341 | dwarak | 2007-05-01 12:53:40 -0700 (Tue, 01 May 2007) | 7 lines
2007-05-01 Dwarakanath Rajagopal <dwarak.rajagopal@amd.com>
* doc/invoke.texi: Fix typo, 'AMD Family 10h core' instead of
'AMD Family 10 core'.
........
r124342 | geoffk | 2007-05-01 15:42:08 -0700 (Tue, 01 May 2007) | 2 lines
Add ChangeLog entry for commit r124287.
........
r124343 | geoffk | 2007-05-01 15:44:08 -0700 (Tue, 01 May 2007) | 15 lines
* gcc.c-torture/compile/limits-blockid.c: New.
* gcc.c-torture/compile/limits-caselabels.c: New.
* gcc.c-torture/compile/limits-declparen.c: New.
* gcc.c-torture/compile/limits-enumconst.c: New.
* gcc.c-torture/compile/limits-exprparen.c: New.
* gcc.c-torture/compile/limits-externalid.c: New.
* gcc.c-torture/compile/limits-fnargs.c: New.
* gcc.c-torture/compile/limits-fndefn.c: New.
* gcc.c-torture/compile/limits-idexternal.c: New.
* gcc.c-torture/compile/limits-idinternal.c: New.
* gcc.c-torture/compile/limits-pointer.c: New.
* gcc.c-torture/compile/limits-stringlit.c: New.
* gcc.c-torture/compile/limits-structmem.c: New.
* gcc.c-torture/compile/limits-structnest.c: New.
........
r124344 | hjl | 2007-05-01 17:37:51 -0700 (Tue, 01 May 2007) | 5 lines
2007-05-01 H.J. Lu <hongjiu.lu@intel.com>
* config/i386/i386.c (ix86_expand_sse_comi): Remove unused
variable.
........
r124347 | charlet | 2007-05-02 01:43:30 -0700 (Wed, 02 May 2007) | 15 lines
2007-04-20 Pascal Obry <obry@adacore.com>
* gnatchop.adb (Write_Source_Reference_Pragma): Change implementation
to use Stream_IO.File_Type. This is needed to make use of the UTF-8
encoding support of Stream_IO.
(Write_Unit): Idem.
* adaint.h, adaint.c (__gnat_os_filename): New routine. Returns the
filename and corresponding encoding to match the OS requirement.
(__gnat_file_exists): Do not call __gnat_stat() on Windows as this
routine will fail on specific devices like CON: AUX: ...
........
r124349 | rguenth | 2007-05-02 02:12:49 -0700 (Wed, 02 May 2007) | 11 lines
2007-05-02 Richard Guenther <rguenther@suse.de>
* tree-ssa-forwprop.c (forward_propagate_addr_expr_1): New
argument, single_use_p. If we have a single use that is
a conversion to the definition rhs type, propagate that rhs.
(forward_propagate_addr_expr): Pass single_use_p argument
to forward_propagate_addr_expr_1.
* g++.dg/tree-ssa/pr31146-2.C: New testcase.
........
r124352 | nickc | 2007-05-02 10:00:19 -0700 (Wed, 02 May 2007) | 2 lines
* config/frv/predicates.md (symbolic_operand): Accept CONSTs.
........
r124353 | pinskia | 2007-05-02 10:47:06 -0700 (Wed, 02 May 2007) | 6 lines
2007-05-02 Andrew Pinski <andrew_pinski@playstation.sony.com>
* fold-const.c (fold_comparision): Remove the "foo++ == CONST"
transformation.
........
r124354 | pinskia | 2007-05-02 10:47:50 -0700 (Wed, 02 May 2007) | 8 lines
Forgot to add the PR number to the last changelog entry:
2007-05-02 Andrew Pinski <andrew_pinski@playstation.sony.com>
* fold-const.c (fold_comparision): Remove the "foo++ == CONST"
transformation.
........
r124355 | paolo | 2007-05-02 11:37:00 -0700 (Wed, 02 May 2007) | 6 lines
2007-05-02 Paolo Carlini <pcarlini@suse.de>
* include/ext/pool_allocator.h (__pool_alloc<>::allocate,
__pool_alloc<>::deallocate): Fix _S_force_new check.
........
r124356 | tromey | 2007-05-02 12:33:44 -0700 (Wed, 02 May 2007) | 7 lines
libcpp
* macro.c (paste_tokens): Remove PASTE_LEFT from the old lhs.
gcc/testsuite
* gcc.dg/cpp/pr28709.c: New file.
........
r124358 | echristo | 2007-05-02 14:57:50 -0700 (Wed, 02 May 2007) | 10 lines
2007-05-02 Eric Christopher <echristo@apple.com>
* gcc.dg/cpp/if-div.c: New file.
2007-05-02 Eric Christopher <echristo@apple.com>
* expr.c (num_div_op): Don't overflow if the result is
zero.
........
r124361 | pbrook | 2007-05-02 15:16:21 -0700 (Wed, 02 May 2007) | 9 lines
2007-05-02 Paul Brook <paul@codesourcery.com>
gcc/
* config/arm/bpabi.S (aeabi_lcmp): Fix result on overflow.
gcc/testsuite/
* gcc.dg/arm-eabi1.c: Move debug output. Augment lcmp/ulcmp tests.
........
r124362 | rakdver | 2007-05-02 15:34:38 -0700 (Wed, 02 May 2007) | 4 lines
* tree-cfg.c (move_block_to_fn): Assign bb to the correct index.
........
r124363 | spark | 2007-05-02 16:11:13 -0700 (Wed, 02 May 2007) | 22 lines
gcc/ChangeLog:
2007-05-02 Seongbae Park <seongbae.park@gmail.com>
* c-common.c (strip_pointer_or_array_types): New function.
* c-common.h (strip_pointer_or_array_types): New function declaration.
gcc/cp/ChangeLog:
2007-05-02 Seongbae Park <seongbae.park@gmail.com>
* decl2.c (constrain_class_visibility):
Use strip_pointer_or_array_types instead of strip_array_types.
gcc/testsuite/ChangeLog:
2007-05-02 Seongbae Park <seongbae.park@gmail.com>
* g++.dg/warn/anonymous-namespace-2.C: New.
* g++.dg/warn/anonymous-namespace-2.h: New.
........
r124367 | gccadmin | 2007-05-02 16:17:26 -0700 (Wed, 02 May 2007) | 1 line
Daily bump.
........
r124370 | tromey | 2007-05-02 16:27:03 -0700 (Wed, 02 May 2007) | 9 lines
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=238755
* java/lang/natCharacter.cc (Character::getType): Handle negative
code points.
(Character::toLowerCase): Likewise.
(Character::toUpperCase): Likewise.
(Character::digit): Likewise.
(Character::getNumericValue): Likewise.
(Character::getDirectionality): Likewise.
(Character::toTitleCase): Likewise.
........
r124371 | geoffk | 2007-05-02 17:25:18 -0700 (Wed, 02 May 2007) | 2 lines
* gcc.c-torture/compile-limits-stringlit.c: Reduce size of string.
........
r124372 | echristo | 2007-05-02 19:09:58 -0700 (Wed, 02 May 2007) | 6 lines
2007-05-02 Eric Christopher <echristo@apple.com>
* config/darwin.h (TARGET_OPTION_TRANSLATE_TABLE): Translate
-shared to -Zdynamiclib.
........
r124373 | brooks | 2007-05-02 23:14:52 -0700 (Wed, 02 May 2007) | 7 lines
* system.h: Remove inclusion of double-int.h
* tree.h: Include double-int.h
* gengtype.c: Likewise
* cfgloop.h: Likewise
* Makefile.in: Adjust dependencies on double-int.h
........
r124374 | bkoz | 2007-05-03 04:49:12 -0700 (Thu, 03 May 2007) | 83 lines
2007-05-03 Benjamin Kosnik <bkoz@redhat.com>
* include/std/type_traits (enable_if): New.
(conditional): New.
(__decay_selector, decay): New.
(__cv_selector, __match_cv_qualifiers): New.
(__make_unsigned, __make_unsigned_selector, make_unsigned): New.
(__make_signed, __make_signed_selector, make_signed): New.
(has_trivial_constructor): ... to has_trivial_default_constructor.
(has_nothrow_constructor): ... to has_nothrow_default_constructor.
(has_trivial_copy): ... to has_trivial_copy_constructor.
(has_nothrow_copy): ... to has_nothrow_copy_constructor.
* include/tr1/type_traits_fwd: Move to...
* include/tr1/type_traitsfwd: ... this, consistency with
ios/string/locale forward headers.
* include/tr1/type_traits: Adjust include.
* include/Makefile.am (tr1_headers): Change type_traits_fwd.h to
type_traitsfwd.h.
* include/Makefile.in: Regenerate.
* testsuite/23_containers/tuple: Move...
* testsuite/20_util/tuple:... here.
* testsuite/20_util/conditional: New.
* testsuite/20_util/conditional/requirements: Same.
* testsuite/20_util/conditional/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/conditional/requirements/typedefs.cc: Same.
* testsuite/20_util/decay: Same.
* testsuite/20_util/decay/requirements: Same.
* testsuite/20_util/decay/requirements/explicit_instantiation.cc: Same.
* testsuite/20_util/decay/requirements/typedefs.cc: Same.
* testsuite/20_util/enable_if: Same.
* testsuite/20_util/enable_if/requirements: Same.
* testsuite/20_util/enable_if/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/enable_if/requirements/typedefs.cc: Same.
* testsuite/20_util/enable_if/requirements/typedefs_neg.cc: Same.
* testsuite/20_util/has_nothrow_copy_constructor: Same.
* testsuite/20_util/has_nothrow_copy_constructor/requirements: Same.
* testsuite/20_util/has_nothrow_copy_constructor/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/has_nothrow_copy_constructor/requirements/
typedefs.cc: Same.
* testsuite/20_util/has_nothrow_copy_constructor/value.cc: Same.
* testsuite/20_util/has_nothrow_default_constructor: Same.
* testsuite/20_util/has_nothrow_default_constructor/requirements: Same.
* testsuite/20_util/has_nothrow_default_constructor/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/has_nothrow_default_constructor/requirements/
typedefs.cc: Same.
* testsuite/20_util/has_nothrow_default_constructor/value.cc: Same.
* testsuite/20_util/has_trivial_copy_constructor: Same.
* testsuite/20_util/has_trivial_copy_constructor/requirements: Same.
* testsuite/20_util/has_trivial_copy_constructor/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/has_trivial_copy_constructor/requirements/
typedefs.cc: Same.
* testsuite/20_util/has_trivial_copy_constructor/value.cc: Same.
* testsuite/20_util/has_trivial_default_constructor: Same.
* testsuite/20_util/has_trivial_default_constructor/requirements: Same.
* testsuite/20_util/has_trivial_default_constructor/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/has_trivial_default_constructor/requirements/
typedefs.cc: Same.
* testsuite/20_util/has_trivial_default_constructor/value.cc: Same.
* testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Same.
* testsuite/20_util/make_signed: Same.
* testsuite/20_util/make_signed/requirements: Same.
* testsuite/20_util/make_signed/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/make_signed/requirements/typedefs.cc: Same.
* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Same.
* testsuite/20_util/make_unsigned: Same.
* testsuite/20_util/make_unsigned/requirements: Same.
* testsuite/20_util/make_unsigned/requirements/
explicit_instantiation.cc: Same.
* testsuite/20_util/make_unsigned/requirements/typedefs.cc: Same.
* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Same.
........
r124375 | dorit | 2007-05-03 05:54:45 -0700 (Thu, 03 May 2007) | 8 lines
* tree-vect-analyze.c (vect_update_misalignment_for_peel): Remove wrong
code.
(vect_enhance_data_refs_alignment): Compute peel amount using
TYPE_VECTOR_SUBPARTS instead of vf.
* tree-vect-transform.c (vect_gen_niters_for_prolog_loop): Likewise.
........
r124376 | bernds | 2007-05-03 06:17:51 -0700 (Thu, 03 May 2007) | 6 lines
* config/bfin/bfin.md (addpdi3, us_truncpdisi2): New patterns.
(umulsi3_highpart): Use them.
* config/bfin/lib1funcs.asm (__umulsi3_highpart): Use unsigned move
for final accumulator to D regisster tranfser.
........
r124377 | bernds | 2007-05-03 06:24:03 -0700 (Thu, 03 May 2007) | 6 lines
* gcc.target/bfin/frmul.c (__v2hi): Use short as base type, not itn.
* gcc.target/bfin/arith.c (__v2hi): Likewise.
* gcc.target/bfin/mul-combine.c (__v2hi): Likewise.
* gcc.target/bfin/shift.c (__v2hi): Likewise.
........
r124378 | rakdver | 2007-05-03 06:27:26 -0700 (Thu, 03 May 2007) | 6 lines
* lambda-code.c (perfect_nestify): Fix updating of dominators.
* gcc.dg/tree-ssa/loop-27.c: New test.
........
r124379 | uros | 2007-05-03 07:32:25 -0700 (Thu, 03 May 2007) | 5 lines
* config/i386/i386.c (print_operand) ['z']: Output 'w' for
operands of size 2 when operand is not MEM_P.
........
r124380 | uros | 2007-05-03 07:50:34 -0700 (Thu, 03 May 2007) | 4 lines
* tree-vect-transform.c (vect_update_inits_of_drs): Use
vect_print_dump_info() to output debug information.
........
r124381 | ian | 2007-05-03 10:37:19 -0700 (Thu, 03 May 2007) | 3 lines
* config/rs6000/rs6000.c (rs6000_override_options): Don't se
MASK_PPC_GFXOPT for 8540 or 8548.
........
r124383 | aph | 2007-05-03 11:30:33 -0700 (Thu, 03 May 2007) | 8 lines
2007-05-03 Andrew Haley <aph@redhat.com>
* gnu/javax/management/Server.java (Server): Record the delegate.
(registerMBean): Notify the delegate.
(unregisterMBean): Likewise.
(notify): New method.
........
r124385 | aph | 2007-05-03 11:35:55 -0700 (Thu, 03 May 2007) | 8 lines
2007-05-03 Andrew Haley <aph@redhat.com>
* gnu/javax/management/Server.java (Server): Record the delegate.
(registerMBean): Notify the delegate.
(unregisterMBean): Likewise.
(notify): New method.
........
r124386 | aph | 2007-05-03 11:38:37 -0700 (Thu, 03 May 2007) | 8 lines
2007-05-03 Andrew Haley <aph@redhat.com>
* gnu/javax/management/Server.java (Server): Record the delegate.
(registerMBean): Notify the delegate.
(unregisterMBean): Likewise.
(notify): New method.
........
r124387 | fitzsim | 2007-05-03 12:02:52 -0700 (Thu, 03 May 2007) | 14 lines
2007-05-03 Thomas Fitzsimmons <fitzsim@redhat.com>
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=237304
* Makefile.in: Regenerate.
* scripts/makemake.tcl (scan_directory): Treat default.css as a
property file.
* classpath/javax/swing/text/html/default.css: Move to...
* classpath/resource/javax/swing/text/html/default.css: New file.
* classpath/javax/swing/text/html/HTMLEditorKit.java
(getStyleSheet): Throw RuntimeException when style loading fails.
* sources.am (property_files): Add
classpath/resource/javax/swing/text/html/default.css.
........
r124388 | jsm28 | 2007-05-03 12:05:39 -0700 (Thu, 03 May 2007) | 7 lines
* config/soft-fp/double.h, config/soft-fp/extended.h,
config/soft-fp/floatundidf.c, config/soft-fp/floatundisf.c,
config/soft-fp/floatunsidf.c, config/soft-fp/floatunsisf.c,
config/soft-fp/op-2.h, config/soft-fp/op-4.h,
config/soft-fp/op-common.h, config/soft-fp/quad.h: Update from
glibc CVS.
........
r124392 | janis | 2007-05-03 14:32:52 -0700 (Thu, 03 May 2007) | 2 lines
* doc/sourcebuild.texi (Test Directives) Clarify dg-excess-errors.
........
r124395 | gccadmin | 2007-05-03 16:17:04 -0700 (Thu, 03 May 2007) | 1 line
Daily bump.
........
r124399 | brobecke | 2007-05-03 16:39:35 -0700 (Thu, 03 May 2007) | 6 lines
* filename_cmp.c: Replace include of ctype.h by include of
safe-ctype.h.
(filename_cmp): Use TOLOWER instead of tolower for conversions
that are locale-independent.
* Makefile.in (filename_cmp.o): Add dependency on safe-ctype.h.
........
r124400 | mueller | 2007-05-03 17:08:53 -0700 (Thu, 03 May 2007) | 10 lines
2007-05-03 Dirk Mueller <dmueller@suse.de>
* doc/invoke.texi (-m386,-m486,-mpentium,-mpentiumpro): Remove.
* config/i386/i386.h (CC1_CPU_SPEC): Remove handling for deprecated
options.
* config/i386/i386.opt (m386,m486,mpentium,mpentiumpro): Remove.
........
r124401 | mueller | 2007-05-03 17:16:02 -0700 (Thu, 03 May 2007) | 5 lines
2007-05-04 Dirk Mueller <dmueller@suse.de>
* ChangeLog: split old changelogs by year
........
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/fixed-point@124405 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3')
219 files changed, 4663 insertions, 287 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 8084c5c4c98..48a0494cb5b 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,753 @@ +2007-05-03 Benjamin Kosnik <bkoz@redhat.com> + + * include/std/type_traits (enable_if): New. + (conditional): New. + (__decay_selector, decay): New. + (__cv_selector, __match_cv_qualifiers): New. + (__make_unsigned, __make_unsigned_selector, make_unsigned): New. + (__make_signed, __make_signed_selector, make_signed): New. + (has_trivial_constructor): ... to has_trivial_default_constructor. + (has_nothrow_constructor): ... to has_nothrow_default_constructor. + (has_trivial_copy): ... to has_trivial_copy_constructor. + (has_nothrow_copy): ... to has_nothrow_copy_constructor. + + * include/tr1/type_traits_fwd: Move to... + * include/tr1/type_traitsfwd: ... this, consistency with + ios/string/locale forward headers. + * include/tr1/type_traits: Adjust include. + * include/Makefile.am (tr1_headers): Change type_traits_fwd.h to + type_traitsfwd.h. + * include/Makefile.in: Regenerate. + + * testsuite/23_containers/tuple: Move... + * testsuite/20_util/tuple:... here. + + * testsuite/20_util/conditional: New. + * testsuite/20_util/conditional/requirements: Same. + * testsuite/20_util/conditional/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/conditional/requirements/typedefs.cc: Same. + * testsuite/20_util/decay: Same. + * testsuite/20_util/decay/requirements: Same. + * testsuite/20_util/decay/requirements/explicit_instantiation.cc: Same. + * testsuite/20_util/decay/requirements/typedefs.cc: Same. + * testsuite/20_util/enable_if: Same. + * testsuite/20_util/enable_if/requirements: Same. + * testsuite/20_util/enable_if/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/enable_if/requirements/typedefs.cc: Same. + * testsuite/20_util/enable_if/requirements/typedefs_neg.cc: Same. + * testsuite/20_util/has_nothrow_copy_constructor: Same. + * testsuite/20_util/has_nothrow_copy_constructor/requirements: Same. + * testsuite/20_util/has_nothrow_copy_constructor/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/has_nothrow_copy_constructor/requirements/ + typedefs.cc: Same. + * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Same. + * testsuite/20_util/has_nothrow_default_constructor: Same. + * testsuite/20_util/has_nothrow_default_constructor/requirements: Same. + * testsuite/20_util/has_nothrow_default_constructor/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/has_nothrow_default_constructor/requirements/ + typedefs.cc: Same. + * testsuite/20_util/has_nothrow_default_constructor/value.cc: Same. + * testsuite/20_util/has_trivial_copy_constructor: Same. + * testsuite/20_util/has_trivial_copy_constructor/requirements: Same. + * testsuite/20_util/has_trivial_copy_constructor/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/has_trivial_copy_constructor/requirements/ + typedefs.cc: Same. + * testsuite/20_util/has_trivial_copy_constructor/value.cc: Same. + * testsuite/20_util/has_trivial_default_constructor: Same. + * testsuite/20_util/has_trivial_default_constructor/requirements: Same. + * testsuite/20_util/has_trivial_default_constructor/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/has_trivial_default_constructor/requirements/ + typedefs.cc: Same. + * testsuite/20_util/has_trivial_default_constructor/value.cc: Same. + * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Same. + * testsuite/20_util/make_signed: Same. + * testsuite/20_util/make_signed/requirements: Same. + * testsuite/20_util/make_signed/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/make_signed/requirements/typedefs.cc: Same. + * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Same. + * testsuite/20_util/make_unsigned: Same. + * testsuite/20_util/make_unsigned/requirements: Same. + * testsuite/20_util/make_unsigned/requirements/ + explicit_instantiation.cc: Same. + * testsuite/20_util/make_unsigned/requirements/typedefs.cc: Same. + * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Same. + +2007-05-02 Paolo Carlini <pcarlini@suse.de> + + PR libstdc++/31777 + * include/ext/pool_allocator.h (__pool_alloc<>::allocate, + __pool_alloc<>::deallocate): Fix _S_force_new check. + +2007-05-01 Benjamin Kosnik <bkoz@redhat.com> + + * 23_containers/requirements/sequences/dr438/deque/*: Move to... + * 23_containers/deque/requirements/dr438: ...here. + + * 23_containers/requirements/sequences/dr438/list/*: Move to... + * 23_containers/list/requirements/dr438: ...here. + + * 23_containers/requirements/sequences/dr438/vector/*: Move to... + * 23_containers/vector/requirements/dr438: ...here. + +2007-05-01 Benjamin Kosnik <bkoz@redhat.com> + + * testsuite/*/explicit_instantiations.cc: Change to... + * testsuite/*/explicit_instantiation.cc: ... this. + +2007-05-01 Benjamin Kosnik <bkoz@redhat.com> + + * testsuite/tr1/4_metaprogramming/*/explicit_instantiations.cc: Change + "basic_ofstream" in comment to type_traits. + +2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + + Directory layout flattening. + + Added in testsuite: + * tr1/4_metaprogramming/add_const + * tr1/4_metaprogramming/add_const/requirements + * tr1/4_metaprogramming/add_const/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/add_const/requirements/typedefs.cc + * tr1/4_metaprogramming/add_cv + * tr1/4_metaprogramming/add_cv/requirements + * tr1/4_metaprogramming/add_cv/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/add_cv/requirements/typedefs.cc + * tr1/4_metaprogramming/add_pointer + * tr1/4_metaprogramming/add_pointer/requirements + * tr1/4_metaprogramming/add_pointer/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/add_pointer/requirements/typedefs.cc + * tr1/4_metaprogramming/add_reference + * tr1/4_metaprogramming/add_reference/requirements + * tr1/4_metaprogramming/add_reference/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/add_reference/requirements/typedefs.cc + * tr1/4_metaprogramming/add_volatile + * tr1/4_metaprogramming/add_volatile/requirements + * tr1/4_metaprogramming/add_volatile/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/add_volatile/requirements/typedefs.cc + * tr1/4_metaprogramming/aligned_storage + * tr1/4_metaprogramming/aligned_storage/requirements + * tr1/4_metaprogramming/aligned_storage/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/aligned_storage/requirements/typedefs.cc + * tr1/4_metaprogramming/alignment_of + * tr1/4_metaprogramming/alignment_of/requirements + * tr1/4_metaprogramming/alignment_of/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/alignment_of/requirements/typedefs.cc + * tr1/4_metaprogramming/alignment_of/value.cc + * tr1/4_metaprogramming/extent + * tr1/4_metaprogramming/extent/requirements + * tr1/4_metaprogramming/extent/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/extent/requirements/typedefs.cc + * tr1/4_metaprogramming/extent/value.cc + * tr1/4_metaprogramming/has_nothrow_assign + * tr1/4_metaprogramming/has_nothrow_assign/requirements + * tr1/4_metaprogramming/has_nothrow_assign/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/has_nothrow_assign/requirements/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_assign/value.cc + * tr1/4_metaprogramming/has_nothrow_constructor + * tr1/4_metaprogramming/has_nothrow_constructor/requirements + * tr1/4_metaprogramming/has_nothrow_constructor/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/has_nothrow_constructor/ + requirements/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_constructor/value.cc + * tr1/4_metaprogramming/has_nothrow_copy + * tr1/4_metaprogramming/has_nothrow_copy/requirements + * tr1/4_metaprogramming/has_nothrow_copy/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/has_nothrow_copy/requirements/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_copy/value.cc + * tr1/4_metaprogramming/has_trivial_assign + * tr1/4_metaprogramming/has_trivial_assign/requirements + * tr1/4_metaprogramming/has_trivial_assign/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/has_trivial_assign/requirements/typedefs.cc + * tr1/4_metaprogramming/has_trivial_assign/value.cc + * tr1/4_metaprogramming/has_trivial_constructor + * tr1/4_metaprogramming/has_trivial_constructor/requirements + * tr1/4_metaprogramming/has_trivial_constructor/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/has_trivial_constructor/ + requirements/typedefs.cc + * tr1/4_metaprogramming/has_trivial_constructor/value.cc + * tr1/4_metaprogramming/has_trivial_copy + * tr1/4_metaprogramming/has_trivial_copy/requirements + * tr1/4_metaprogramming/has_trivial_copy/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/has_trivial_copy/requirements/typedefs.cc + * tr1/4_metaprogramming/has_trivial_copy/value.cc + * tr1/4_metaprogramming/has_trivial_destructor + * tr1/4_metaprogramming/has_trivial_destructor/requirements + * tr1/4_metaprogramming/has_trivial_destructor/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/has_trivial_destructor/requirements/typedefs.cc + * tr1/4_metaprogramming/has_trivial_destructor/value.cc + * tr1/4_metaprogramming/has_virtual_destructor + * tr1/4_metaprogramming/has_virtual_destructor/requirements + * tr1/4_metaprogramming/has_virtual_destructor/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/has_virtual_destructor/requirements/typedefs.cc + * tr1/4_metaprogramming/has_virtual_destructor/value.cc + * tr1/4_metaprogramming/integral_constant + * tr1/4_metaprogramming/integral_constant/requirements + * tr1/4_metaprogramming/integral_constant/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/integral_constant/requirements/typedefs.cc + * tr1/4_metaprogramming/integral_constant/true_false_value.cc + * tr1/4_metaprogramming/is_abstract + * tr1/4_metaprogramming/is_abstract/requirements + * tr1/4_metaprogramming/is_abstract/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_abstract/requirements/typedefs.cc + * tr1/4_metaprogramming/is_abstract/value.cc + * tr1/4_metaprogramming/is_arithmetic + * tr1/4_metaprogramming/is_arithmetic/requirements + * tr1/4_metaprogramming/is_arithmetic/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_arithmetic/requirements/typedefs.cc + * tr1/4_metaprogramming/is_arithmetic/value.cc + * tr1/4_metaprogramming/is_array + * tr1/4_metaprogramming/is_array/requirements + * tr1/4_metaprogramming/is_array/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_array/requirements/typedefs.cc + * tr1/4_metaprogramming/is_array/value.cc + * tr1/4_metaprogramming/is_base_of + * tr1/4_metaprogramming/is_base_of/requirements + * tr1/4_metaprogramming/is_base_of/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_base_of/requirements/typedefs.cc + * tr1/4_metaprogramming/is_base_of/value.cc + * tr1/4_metaprogramming/is_class + * tr1/4_metaprogramming/is_class/requirements + * tr1/4_metaprogramming/is_class/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_class/requirements/typedefs.cc + * tr1/4_metaprogramming/is_class/value.cc + * tr1/4_metaprogramming/is_compound + * tr1/4_metaprogramming/is_compound/requirements + * tr1/4_metaprogramming/is_compound/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_compound/requirements/typedefs.cc + * tr1/4_metaprogramming/is_compound/value.cc + * tr1/4_metaprogramming/is_const + * tr1/4_metaprogramming/is_const/requirements + * tr1/4_metaprogramming/is_const/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_const/requirements/typedefs.cc + * tr1/4_metaprogramming/is_const/value.cc + * tr1/4_metaprogramming/is_convertible + * tr1/4_metaprogramming/is_convertible/requirements + * tr1/4_metaprogramming/is_convertible/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_convertible/requirements/typedefs.cc + * tr1/4_metaprogramming/is_convertible/value.cc + * tr1/4_metaprogramming/is_empty + * tr1/4_metaprogramming/is_empty/requirements + * tr1/4_metaprogramming/is_empty/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_empty/requirements/typedefs.cc + * tr1/4_metaprogramming/is_empty/value.cc + * tr1/4_metaprogramming/is_enum + * tr1/4_metaprogramming/is_enum/requirements + * tr1/4_metaprogramming/is_enum/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_enum/requirements/typedefs.cc + * tr1/4_metaprogramming/is_enum/value.cc + * tr1/4_metaprogramming/is_floating_point + * tr1/4_metaprogramming/is_floating_point/requirements + * tr1/4_metaprogramming/is_floating_point/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_floating_point/requirements/typedefs.cc + * tr1/4_metaprogramming/is_floating_point/value.cc + * tr1/4_metaprogramming/is_function + * tr1/4_metaprogramming/is_function/requirements + * tr1/4_metaprogramming/is_function/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_function/requirements/typedefs.cc + * tr1/4_metaprogramming/is_function/value.cc + * tr1/4_metaprogramming/is_fundamental + * tr1/4_metaprogramming/is_fundamental/requirements + * tr1/4_metaprogramming/is_fundamental/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_fundamental/requirements/typedefs.cc + * tr1/4_metaprogramming/is_fundamental/value.cc + * tr1/4_metaprogramming/is_integral + * tr1/4_metaprogramming/is_integral/requirements + * tr1/4_metaprogramming/is_integral/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_integral/requirements/typedefs.cc + * tr1/4_metaprogramming/is_integral/value.cc + * tr1/4_metaprogramming/is_member_function_pointer + * tr1/4_metaprogramming/is_member_function_pointer/requirements + * tr1/4_metaprogramming/is_member_function_pointer/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_member_function_pointer/ + requirements/typedefs.cc + * tr1/4_metaprogramming/is_member_function_pointer/value.cc + * tr1/4_metaprogramming/is_member_object_pointer + * tr1/4_metaprogramming/is_member_object_pointer/requirements + * tr1/4_metaprogramming/is_member_object_pointer/ + requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_member_object_pointer/ + requirements/typedefs.cc + * tr1/4_metaprogramming/is_member_object_pointer/value.cc + * tr1/4_metaprogramming/is_member_pointer + * tr1/4_metaprogramming/is_member_pointer/requirements + * tr1/4_metaprogramming/is_member_pointer/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_member_pointer/requirements/typedefs.cc + * tr1/4_metaprogramming/is_member_pointer/value.cc + * tr1/4_metaprogramming/is_object + * tr1/4_metaprogramming/is_object/requirements + * tr1/4_metaprogramming/is_object/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_object/requirements/typedefs.cc + * tr1/4_metaprogramming/is_object/value.cc + * tr1/4_metaprogramming/is_pod + * tr1/4_metaprogramming/is_pod/requirements + * tr1/4_metaprogramming/is_pod/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_pod/requirements/typedefs.cc + * tr1/4_metaprogramming/is_pod/value.cc + * tr1/4_metaprogramming/is_pointer + * tr1/4_metaprogramming/is_pointer/requirements + * tr1/4_metaprogramming/is_pointer/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_pointer/requirements/typedefs.cc + * tr1/4_metaprogramming/is_pointer/value.cc + * tr1/4_metaprogramming/is_polymorphic + * tr1/4_metaprogramming/is_polymorphic/requirements + * tr1/4_metaprogramming/is_polymorphic/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_polymorphic/requirements/typedefs.cc + * tr1/4_metaprogramming/is_polymorphic/value.cc + * tr1/4_metaprogramming/is_reference + * tr1/4_metaprogramming/is_reference/requirements + * tr1/4_metaprogramming/is_reference/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_reference/requirements/typedefs.cc + * tr1/4_metaprogramming/is_reference/value.cc + * tr1/4_metaprogramming/is_same + * tr1/4_metaprogramming/is_same/requirements + * tr1/4_metaprogramming/is_same/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_same/requirements/typedefs.cc + * tr1/4_metaprogramming/is_same/value.cc + * tr1/4_metaprogramming/is_scalar + * tr1/4_metaprogramming/is_scalar/requirements + * tr1/4_metaprogramming/is_scalar/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_scalar/requirements/typedefs.cc + * tr1/4_metaprogramming/is_scalar/value.cc + * tr1/4_metaprogramming/is_signed + * tr1/4_metaprogramming/is_signed/requirements + * tr1/4_metaprogramming/is_signed/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_signed/requirements/typedefs.cc + * tr1/4_metaprogramming/is_signed/value.cc + * tr1/4_metaprogramming/is_union + * tr1/4_metaprogramming/is_union/requirements + * tr1/4_metaprogramming/is_union/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_union/requirements/typedefs.cc + * tr1/4_metaprogramming/is_union/value.cc + * tr1/4_metaprogramming/is_unsigned + * tr1/4_metaprogramming/is_unsigned/requirements + * tr1/4_metaprogramming/is_unsigned/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_unsigned/requirements/typedefs.cc + * tr1/4_metaprogramming/is_unsigned/value.cc + * tr1/4_metaprogramming/is_void + * tr1/4_metaprogramming/is_void/requirements + * tr1/4_metaprogramming/is_void/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/is_void/requirements/typedefs.cc + * tr1/4_metaprogramming/is_void/value.cc + * tr1/4_metaprogramming/is_volatile + * tr1/4_metaprogramming/is_volatile/requirements + * tr1/4_metaprogramming/is_volatile/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/is_volatile/requirements/typedefs.cc + * tr1/4_metaprogramming/is_volatile/value.cc + * tr1/4_metaprogramming/rank + * tr1/4_metaprogramming/rank/requirements + * tr1/4_metaprogramming/rank/requirements/explicit_instantiations.cc + * tr1/4_metaprogramming/rank/requirements/typedefs.cc + * tr1/4_metaprogramming/rank/value.cc + * tr1/4_metaprogramming/remove_all_extents + * tr1/4_metaprogramming/remove_all_extents/requirements + * tr1/4_metaprogramming/remove_all_extents/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_all_extents/value.cc + * tr1/4_metaprogramming/remove_const + * tr1/4_metaprogramming/remove_const/requirements + * tr1/4_metaprogramming/remove_const/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_const/value.cc + * tr1/4_metaprogramming/remove_cv + * tr1/4_metaprogramming/remove_cv/requirements + * tr1/4_metaprogramming/remove_cv/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_cv/value.cc + * tr1/4_metaprogramming/remove_extent + * tr1/4_metaprogramming/remove_extent/requirements + * tr1/4_metaprogramming/remove_extent/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_extent/value.cc + * tr1/4_metaprogramming/remove_pointer + * tr1/4_metaprogramming/remove_pointer/requirements + * tr1/4_metaprogramming/remove_pointer/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_pointer/value.cc + * tr1/4_metaprogramming/remove_reference + * tr1/4_metaprogramming/remove_reference/requirements + * tr1/4_metaprogramming/remove_reference/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_reference/value.cc + * tr1/4_metaprogramming/remove_volatile + * tr1/4_metaprogramming/remove_volatile/requirements + * tr1/4_metaprogramming/remove_volatile/requirements/ + explicit_instantiations.cc + * tr1/4_metaprogramming/remove_volatile/value.cc + + Deleted in testsuite: + * tr1/4_metaprogramming/alignment_of/alignment_of.cc + * tr1/4_metaprogramming/alignment_of/typedefs.cc + * tr1/4_metaprogramming/array_modifications + * tr1/4_metaprogramming/array_modifications/remove_all_extents.cc + * tr1/4_metaprogramming/array_modifications/remove_extent.cc + * tr1/4_metaprogramming/composite_type_traits + * tr1/4_metaprogramming/composite_type_traits/is_arithmetic + * tr1/4_metaprogramming/composite_type_traits/is_arithmetic/ + is_arithmetic.cc + * tr1/4_metaprogramming/composite_type_traits/is_arithmetic/typedefs.cc + * tr1/4_metaprogramming/composite_type_traits/is_compound + * tr1/4_metaprogramming/composite_type_traits/is_compound/ + is_compound.cc + * tr1/4_metaprogramming/composite_type_traits/is_compound/typedefs.cc + * tr1/4_metaprogramming/composite_type_traits/is_fundamental + * tr1/4_metaprogramming/composite_type_traits/is_fundamental/ + is_fundamental.cc + * tr1/4_metaprogramming/composite_type_traits/is_fundamental/ + typedefs.cc + * tr1/4_metaprogramming/composite_type_traits/is_member_pointer + * tr1/4_metaprogramming/composite_type_traits/is_member_pointer/ + is_member_pointer.cc + * tr1/4_metaprogramming/composite_type_traits/is_member_pointer/ + typedefs.cc + * tr1/4_metaprogramming/composite_type_traits/is_object + * tr1/4_metaprogramming/composite_type_traits/is_object/24808.cc + * tr1/4_metaprogramming/composite_type_traits/is_object/is_object.cc + * tr1/4_metaprogramming/composite_type_traits/is_object/typedefs.cc + * tr1/4_metaprogramming/composite_type_traits/is_scalar + * tr1/4_metaprogramming/composite_type_traits/is_scalar/is_scalar.cc + * tr1/4_metaprogramming/composite_type_traits/is_scalar/typedefs.cc + * tr1/4_metaprogramming/const_volatile_modifications + * tr1/4_metaprogramming/const_volatile_modifications/add_const.cc + * tr1/4_metaprogramming/const_volatile_modifications/add_cv.cc + * tr1/4_metaprogramming/const_volatile_modifications/add_volatile.cc + * tr1/4_metaprogramming/const_volatile_modifications/remove_const.cc + * tr1/4_metaprogramming/const_volatile_modifications/remove_cv.cc + * tr1/4_metaprogramming/const_volatile_modifications/remove_volatile.cc + * tr1/4_metaprogramming/extent/extent.cc + * tr1/4_metaprogramming/extent/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_assign/has_nothrow_assign.cc + * tr1/4_metaprogramming/has_nothrow_assign/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_constructor/ + has_nothrow_constructor.cc + * tr1/4_metaprogramming/has_nothrow_constructor/typedefs.cc + * tr1/4_metaprogramming/has_nothrow_copy/has_nothrow_copy.cc + * tr1/4_metaprogramming/has_nothrow_copy/typedefs.cc + * tr1/4_metaprogramming/has_trivial_assign/has_trivial_assign.cc + * tr1/4_metaprogramming/has_trivial_assign/typedefs.cc + * tr1/4_metaprogramming/has_trivial_constructor/ + has_trivial_constructor.cc + * tr1/4_metaprogramming/has_trivial_constructor/typedefs.cc + * tr1/4_metaprogramming/has_trivial_copy/has_trivial_copy.cc + * tr1/4_metaprogramming/has_trivial_copy/typedefs.cc + * tr1/4_metaprogramming/has_trivial_destructor/ + has_trivial_destructor.cc + * tr1/4_metaprogramming/has_trivial_destructor/typedefs.cc + * tr1/4_metaprogramming/has_virtual_destructor/ + has_virtual_destructor.cc + * tr1/4_metaprogramming/has_virtual_destructor/typedefs.cc + * tr1/4_metaprogramming/helper_classes + * tr1/4_metaprogramming/helper_classes/static_definition.cc + * tr1/4_metaprogramming/helper_classes/true_false_type.cc + * tr1/4_metaprogramming/helper_classes/true_false_type_typedefs.cc + * tr1/4_metaprogramming/helper_classes/typedefs.cc + * tr1/4_metaprogramming/integral_constant/true_false_type.cc + * tr1/4_metaprogramming/integral_constant/typedefs.cc + * tr1/4_metaprogramming/is_abstract/is_abstract.cc + * tr1/4_metaprogramming/is_abstract/typedefs.cc + * tr1/4_metaprogramming/is_arithmetic/is_arithmetic.cc + * tr1/4_metaprogramming/is_arithmetic/typedefs.cc + * tr1/4_metaprogramming/is_array/is_array.cc + * tr1/4_metaprogramming/is_array/typedefs.cc + * tr1/4_metaprogramming/is_base_of/is_base_of.cc + * tr1/4_metaprogramming/is_base_of/typedefs.cc + * tr1/4_metaprogramming/is_class/is_class.cc + * tr1/4_metaprogramming/is_class/typedefs.cc + * tr1/4_metaprogramming/is_compound/is_compound.cc + * tr1/4_metaprogramming/is_compound/typedefs.cc + * tr1/4_metaprogramming/is_const/is_const.cc + * tr1/4_metaprogramming/is_const/typedefs.cc + * tr1/4_metaprogramming/is_convertible/is_convertible.cc + * tr1/4_metaprogramming/is_convertible/typedefs.cc + * tr1/4_metaprogramming/is_empty/is_empty.cc + * tr1/4_metaprogramming/is_empty/typedefs.cc + * tr1/4_metaprogramming/is_enum/is_enum.cc + * tr1/4_metaprogramming/is_enum/typedefs.cc + * tr1/4_metaprogramming/is_floating_point/is_floating_point.cc + * tr1/4_metaprogramming/is_floating_point/typedefs.cc + * tr1/4_metaprogramming/is_function/is_function.cc + * tr1/4_metaprogramming/is_function/typedefs.cc + * tr1/4_metaprogramming/is_fundamental/is_fundamental.cc + * tr1/4_metaprogramming/is_fundamental/typedefs.cc + * tr1/4_metaprogramming/is_integral/is_integral.cc + * tr1/4_metaprogramming/is_integral/typedefs.cc + * tr1/4_metaprogramming/is_member_function_pointer/ + is_member_function_pointer.cc + * tr1/4_metaprogramming/is_member_function_pointer/typedefs.cc + * tr1/4_metaprogramming/is_member_object_pointer/ + is_member_object_pointer.cc + * tr1/4_metaprogramming/is_member_object_pointer/typedefs.cc + * tr1/4_metaprogramming/is_member_pointer/is_member_pointer.cc + * tr1/4_metaprogramming/is_member_pointer/typedefs.cc + * tr1/4_metaprogramming/is_object/is_object.cc + * tr1/4_metaprogramming/is_object/typedefs.cc + * tr1/4_metaprogramming/is_pod/is_pod.cc + * tr1/4_metaprogramming/is_pod/typedefs.cc + * tr1/4_metaprogramming/is_pointer/is_pointer.cc + * tr1/4_metaprogramming/is_pointer/typedefs.cc + * tr1/4_metaprogramming/is_polymorphic/is_polymorphic.cc + * tr1/4_metaprogramming/is_polymorphic/typedefs.cc + * tr1/4_metaprogramming/is_reference/is_reference.cc + * tr1/4_metaprogramming/is_reference/typedefs.cc + * tr1/4_metaprogramming/is_same/is_same.cc + * tr1/4_metaprogramming/is_same/typedefs.cc + * tr1/4_metaprogramming/is_scalar/is_scalar.cc + * tr1/4_metaprogramming/is_scalar/typedefs.cc + * tr1/4_metaprogramming/is_signed/is_signed.cc + * tr1/4_metaprogramming/is_signed/typedefs.cc + * tr1/4_metaprogramming/is_union/is_union.cc + * tr1/4_metaprogramming/is_union/typedefs.cc + * tr1/4_metaprogramming/is_unsigned/is_unsigned.cc + * tr1/4_metaprogramming/is_unsigned/typedefs.cc + * tr1/4_metaprogramming/is_void/is_void.cc + * tr1/4_metaprogramming/is_void/typedefs.cc + * tr1/4_metaprogramming/is_volatile/is_volatile.cc + * tr1/4_metaprogramming/is_volatile/typedefs.cc + * tr1/4_metaprogramming/other_transformations + * tr1/4_metaprogramming/other_transformations/aligned_storage + * tr1/4_metaprogramming/other_transformations/aligned_storage/ + aligned_storage.cc + * tr1/4_metaprogramming/other_transformations/aligned_storage/ + typedefs.cc + * tr1/4_metaprogramming/pointer_modifications + * tr1/4_metaprogramming/pointer_modifications/add_pointer.cc + * tr1/4_metaprogramming/pointer_modifications/remove_pointer.cc + * tr1/4_metaprogramming/primary_type_categories + * tr1/4_metaprogramming/primary_type_categories/is_array + * tr1/4_metaprogramming/primary_type_categories/is_array/is_array.cc + * tr1/4_metaprogramming/primary_type_categories/is_array/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_class + * tr1/4_metaprogramming/primary_type_categories/is_class/is_class.cc + * tr1/4_metaprogramming/primary_type_categories/is_class/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_enum + * tr1/4_metaprogramming/primary_type_categories/is_enum/24808.cc + * tr1/4_metaprogramming/primary_type_categories/is_enum/is_enum.cc + * tr1/4_metaprogramming/primary_type_categories/is_enum/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_floating_point + * tr1/4_metaprogramming/primary_type_categories/is_floating_point/ + is_floating_point.cc + * tr1/4_metaprogramming/primary_type_categories/is_floating_point/ + typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_function + * tr1/4_metaprogramming/primary_type_categories/is_function/24808.cc + * tr1/4_metaprogramming/primary_type_categories/is_function/ + is_function.cc + * tr1/4_metaprogramming/primary_type_categories/is_function/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_integral + * tr1/4_metaprogramming/primary_type_categories/is_integral/ + is_integral.cc + * tr1/4_metaprogramming/primary_type_categories/is_integral/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/ + is_member_function_pointer + * tr1/4_metaprogramming/primary_type_categories/ + is_member_function_pointer/is_member_function_pointer.cc + * tr1/4_metaprogramming/primary_type_categories/ + is_member_function_pointer/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/ + is_member_object_pointer + * tr1/4_metaprogramming/primary_type_categories/ + is_member_object_pointer/is_member_object_pointer.cc + * tr1/4_metaprogramming/primary_type_categories/ + is_member_object_pointer/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_pointer + * tr1/4_metaprogramming/primary_type_categories/is_pointer/ + is_pointer.cc + * tr1/4_metaprogramming/primary_type_categories/is_pointer/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_reference + * tr1/4_metaprogramming/primary_type_categories/is_reference/ + is_reference.cc + * tr1/4_metaprogramming/primary_type_categories/is_reference/ + typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_union + * tr1/4_metaprogramming/primary_type_categories/is_union/is_union.cc + * tr1/4_metaprogramming/primary_type_categories/is_union/typedefs.cc + * tr1/4_metaprogramming/primary_type_categories/is_void + * tr1/4_metaprogramming/primary_type_categories/is_void/is_void.cc + * tr1/4_metaprogramming/primary_type_categories/is_void/typedefs.cc + * tr1/4_metaprogramming/rank/rank.cc + * tr1/4_metaprogramming/rank/typedefs.cc + * tr1/4_metaprogramming/reference_modifications/add_reference.cc + * tr1/4_metaprogramming/reference_modifications/remove_reference.cc + * tr1/4_metaprogramming/relationships_between_types + * tr1/4_metaprogramming/relationships_between_types/is_base_of + * tr1/4_metaprogramming/relationships_between_types/is_base_of/ + is_base_of.cc + * tr1/4_metaprogramming/relationships_between_types/is_base_of/ + typedefs.cc + * tr1/4_metaprogramming/relationships_between_types/is_convertible + * tr1/4_metaprogramming/relationships_between_types/is_convertible/ + is_convertible.cc + * tr1/4_metaprogramming/relationships_between_types/is_convertible/ + typedefs.cc + * tr1/4_metaprogramming/relationships_between_types/is_same + * tr1/4_metaprogramming/relationships_between_types/is_same/is_same.cc + * tr1/4_metaprogramming/relationships_between_types/is_same/typedefs.cc + * tr1/4_metaprogramming/type_properties + * tr1/4_metaprogramming/type_properties/alignment_of + * tr1/4_metaprogramming/type_properties/alignment_of/alignment_of.cc + * tr1/4_metaprogramming/type_properties/alignment_of/typedefs.cc + * tr1/4_metaprogramming/type_properties/extent + * tr1/4_metaprogramming/type_properties/extent/extent.cc + * tr1/4_metaprogramming/type_properties/extent/typedefs.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_assign + * tr1/4_metaprogramming/type_properties/has_nothrow_assign/ + has_nothrow_assign.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_assign/typedefs.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_constructor + * tr1/4_metaprogramming/type_properties/has_nothrow_constructor/ + has_nothrow_constructor.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_constructor/ + typedefs.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_copy + * tr1/4_metaprogramming/type_properties/has_nothrow_copy/ + has_nothrow_copy.cc + * tr1/4_metaprogramming/type_properties/has_nothrow_copy/typedefs.cc + * tr1/4_metaprogramming/type_properties/has_trivial_assign + * tr1/4_metaprogramming/type_properties/has_trivial_assign/ + has_trivial_assign.cc + * tr1/4_metaprogramming/type_properties/has_trivial_assign/typedefs.cc + * tr1/4_metaprogramming/type_properties/has_trivial_constructor + * tr1/4_metaprogramming/type_properties/has_trivial_constructor/ + has_trivial_constructor.cc + * tr1/4_metaprogramming/type_properties/has_trivial_constructor/ + typedefs.cc + * tr1/4_metaprogramming/type_properties/has_trivial_copy + * tr1/4_metaprogramming/type_properties/has_trivial_copy/ + has_trivial_copy.cc + * tr1/4_metaprogramming/type_properties/has_trivial_copy/typedefs.cc + * tr1/4_metaprogramming/type_properties/has_trivial_destructor + * tr1/4_metaprogramming/type_properties/has_trivial_destructor/ + has_trivial_destructor.cc + * tr1/4_metaprogramming/type_properties/has_trivial_destructor/ + typedefs.cc + * tr1/4_metaprogramming/type_properties/has_virtual_destructor + * tr1/4_metaprogramming/type_properties/has_virtual_destructor/ + has_virtual_destructor.cc + * tr1/4_metaprogramming/type_properties/has_virtual_destructor/ + typedefs.cc + * tr1/4_metaprogramming/type_properties/is_abstract + * tr1/4_metaprogramming/type_properties/is_abstract/is_abstract.cc + * tr1/4_metaprogramming/type_properties/is_abstract/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_const + * tr1/4_metaprogramming/type_properties/is_const/is_const.cc + * tr1/4_metaprogramming/type_properties/is_const/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_empty + * tr1/4_metaprogramming/type_properties/is_empty/is_empty.cc + * tr1/4_metaprogramming/type_properties/is_empty/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_pod + * tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc + * tr1/4_metaprogramming/type_properties/is_pod/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_polymorphic + * tr1/4_metaprogramming/type_properties/is_polymorphic/24809.cc + * tr1/4_metaprogramming/type_properties/is_polymorphic/ + is_polymorphic.cc + * tr1/4_metaprogramming/type_properties/is_polymorphic/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_signed + * tr1/4_metaprogramming/type_properties/is_signed/is_signed.cc + * tr1/4_metaprogramming/type_properties/is_signed/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_unsigned + * tr1/4_metaprogramming/type_properties/is_unsigned/is_unsigned.cc + * tr1/4_metaprogramming/type_properties/is_unsigned/typedefs.cc + * tr1/4_metaprogramming/type_properties/is_volatile + * tr1/4_metaprogramming/type_properties/is_volatile/is_volatile.cc + * tr1/4_metaprogramming/type_properties/is_volatile/typedefs.cc + * tr1/4_metaprogramming/type_properties/rank + * tr1/4_metaprogramming/type_properties/rank/rank.cc + * tr1/4_metaprogramming/type_properties/rank/typedefs.cc + +2007-04-30 Hans-Peter Nilsson <hp@axis.com> + + * testsuite/lib/libstdc++.exp (v3_target_compile_as_c): Correct + regexp to filter out -nostdinc++. + +2007-04-30 Paolo Carlini <pcarlini@suse.de> + + PR libstdc++/30449 (equal) + * include/bits/stl_algobase.h (struct __niter_base): Add. + (copy(_II, _II, _OI), copy_backward(_BI1, _BI1, _BI2), + fill(_ForwardIterator, _ForwardIterator, const _Tp&), + fill_n(_OI, _Size, const _Tp&), equal(_II1, _II1, _II2)): + Use it. + (struct __copy_normal, __copy_backward_normal, + struct __fill_normal, struct __fill_n_normal): Remove. + (struct __equal, struct __equal_aux): Add. + * include/bits/stl_iterator.h: Add _Iterator_type typedef. + + * include/bits/stl_algobase.h (__fill_aux(wchar_t*, + wchar_t*, wchar_t), __fill_n_aux(wchar_t*, _Size, wchar_t)): + Remove. + + * testsuite/23_containers/requirements/sequences/dr438/vector/ + constructor_1_neg.cc: Adjust dg-error line number. + * testsuite/23_containers/requirements/sequences/dr438/vector/ + constructor_2_neg.cc: Likewise. + +2007-04-30 Paolo Carlini <pcarlini@suse.de> + + * include/tr1/type_traits (is_pod): Use __is_pod. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_trivial_destructor/has_trivial_destructor.cc: Adjust. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_nothrow_constructor/has_nothrow_constructor.cc: Likewise. + * testsuite/tr1/4_metaprogramming/type_properties/ + has_trivial_constructor/has_trivial_constructor.cc: Likewise. + * testsuite/tr1/4_metaprogramming/type_properties/ + is_pod/is_pod.cc: Likewise. + +2007-04-29 Paolo Carlini <pcarlini@suse.de> + + * include/bits/localefwd.h: Remove redundant inline qualifiers. + (__check_facet): Move... + * include/bits/basic_ios.h: ... here. + (widen(char), narrow(char_type, char)): Define inline. + * include/bits/basic_ios.tcc (widen(char), narrow(char_type, char)): + Remove. + 2007-04-27 Paolo Carlini <pcarlini@suse.de> DR 438, [DR]. diff --git a/libstdc++-v3/include/Makefile.am b/libstdc++-v3/include/Makefile.am index 75be19a5f78..ea27464432e 100644 --- a/libstdc++-v3/include/Makefile.am +++ b/libstdc++-v3/include/Makefile.am @@ -592,7 +592,7 @@ tr1_headers = \ ${tr1_srcdir}/tgmath.h \ ${tr1_srcdir}/tuple \ ${tr1_srcdir}/type_traits \ - ${tr1_srcdir}/type_traits_fwd.h \ + ${tr1_srcdir}/type_traitsfwd.h \ ${tr1_srcdir}/unordered_set \ ${tr1_srcdir}/unordered_map \ ${tr1_srcdir}/utility \ diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in index 5b4ad599218..4402d84c67f 100644 --- a/libstdc++-v3/include/Makefile.in +++ b/libstdc++-v3/include/Makefile.in @@ -822,7 +822,7 @@ tr1_headers = \ ${tr1_srcdir}/tgmath.h \ ${tr1_srcdir}/tuple \ ${tr1_srcdir}/type_traits \ - ${tr1_srcdir}/type_traits_fwd.h \ + ${tr1_srcdir}/type_traitsfwd.h \ ${tr1_srcdir}/unordered_set \ ${tr1_srcdir}/unordered_map \ ${tr1_srcdir}/utility \ diff --git a/libstdc++-v3/include/bits/basic_ios.h b/libstdc++-v3/include/bits/basic_ios.h index d078431b9fd..ea9c0dc6565 100644 --- a/libstdc++-v3/include/bits/basic_ios.h +++ b/libstdc++-v3/include/bits/basic_ios.h @@ -1,6 +1,7 @@ // Iostreams base classes -*- C++ -*- -// Copyright (C) 1997, 1998, 1999, 2001, 2002, 2003, 2004, 2005 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, +// 2006, 2007 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -38,13 +39,22 @@ #pragma GCC system_header -#include <bits/streambuf_iterator.h> #include <bits/localefwd.h> #include <bits/locale_classes.h> #include <bits/locale_facets.h> +#include <bits/streambuf_iterator.h> _GLIBCXX_BEGIN_NAMESPACE(std) + template<typename _Facet> + inline const _Facet& + __check_facet(const _Facet* __f) + { + if (!__f) + __throw_bad_cast(); + return *__f; + } + // 27.4.5 Template class basic_ios /** * @brief Virtual base class for all stream classes. @@ -255,7 +265,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) explicit basic_ios(basic_streambuf<_CharT, _Traits>* __sb) : ios_base(), _M_tie(0), _M_fill(), _M_fill_init(false), _M_streambuf(0), - _M_ctype(0), _M_num_put(0), _M_num_get(0) + _M_ctype(0), _M_num_put(0), _M_num_get(0) { this->init(__sb); } /** @@ -413,7 +423,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) * http://gcc.gnu.org/onlinedocs/libstdc++/22_locale/howto.html */ char - narrow(char_type __c, char __dfault) const; + narrow(char_type __c, char __dfault) const + { return __check_facet(_M_ctype).narrow(__c, __dfault); } /** * @brief Widens characters. @@ -431,7 +442,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) * http://gcc.gnu.org/onlinedocs/libstdc++/22_locale/howto.html */ char_type - widen(char __c) const; + widen(char __c) const + { return __check_facet(_M_ctype).widen(__c); } protected: // 27.4.5.1 basic_ios constructors @@ -443,7 +455,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) */ basic_ios() : ios_base(), _M_tie(0), _M_fill(char_type()), _M_fill_init(false), - _M_streambuf(0), _M_ctype(0), _M_num_put(0), _M_num_get(0) + _M_streambuf(0), _M_ctype(0), _M_num_put(0), _M_num_get(0) { } /** diff --git a/libstdc++-v3/include/bits/basic_ios.tcc b/libstdc++-v3/include/bits/basic_ios.tcc index e8434a5bdf0..399e93ae737 100644 --- a/libstdc++-v3/include/bits/basic_ios.tcc +++ b/libstdc++-v3/include/bits/basic_ios.tcc @@ -1,6 +1,6 @@ // basic_ios member functions -*- C++ -*- -// Copyright (C) 1999, 2001, 2002, 2003, 2004, 2005 +// Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -112,16 +112,6 @@ _GLIBCXX_BEGIN_NAMESPACE(std) return *this; } - template<typename _CharT, typename _Traits> - char - basic_ios<_CharT, _Traits>::narrow(char_type __c, char __dfault) const - { return __check_facet(_M_ctype).narrow(__c, __dfault); } - - template<typename _CharT, typename _Traits> - _CharT - basic_ios<_CharT, _Traits>::widen(char __c) const - { return __check_facet(_M_ctype).widen(__c); } - // Locales: template<typename _CharT, typename _Traits> locale diff --git a/libstdc++-v3/include/bits/localefwd.h b/libstdc++-v3/include/bits/localefwd.h index aff3e23e16d..94a73639cbb 100644 --- a/libstdc++-v3/include/bits/localefwd.h +++ b/libstdc++-v3/include/bits/localefwd.h @@ -1,6 +1,7 @@ // Locale support -*- C++ -*- -// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2005, 2006, 2007 +// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, +// 2006, 2007 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -43,67 +44,74 @@ #pragma GCC system_header #include <bits/c++config.h> -#include <bits/c++locale.h> // Defines __c_locale, config-specific includes -#include <iosfwd> // For ostreambuf_iterator, istreambuf_iterator +#include <bits/c++locale.h> // Defines __c_locale, config-specific include +#include <iosfwd> // For ostreambuf_iterator, istreambuf_iterator #include <cctype> -#include <bits/functexcept.h> _GLIBCXX_BEGIN_NAMESPACE(std) // 22.1.1 Locale class locale; + template<typename _Facet> + bool + has_facet(const locale&) throw(); + + template<typename _Facet> + const _Facet& + use_facet(const locale&); + // 22.1.3 Convenience interfaces template<typename _CharT> - inline bool + bool isspace(_CharT, const locale&); template<typename _CharT> - inline bool + bool isprint(_CharT, const locale&); template<typename _CharT> - inline bool + bool iscntrl(_CharT, const locale&); template<typename _CharT> - inline bool + bool isupper(_CharT, const locale&); template<typename _CharT> - inline bool + bool islower(_CharT, const locale&); template<typename _CharT> - inline bool + bool isalpha(_CharT, const locale&); template<typename _CharT> - inline bool + bool isdigit(_CharT, const locale&); template<typename _CharT> - inline bool + bool ispunct(_CharT, const locale&); template<typename _CharT> - inline bool + bool isxdigit(_CharT, const locale&); template<typename _CharT> - inline bool + bool isalnum(_CharT, const locale&); template<typename _CharT> - inline bool + bool isgraph(_CharT, const locale&); template<typename _CharT> - inline _CharT + _CharT toupper(_CharT, const locale&); template<typename _CharT> - inline _CharT + _CharT tolower(_CharT, const locale&); // 22.2.1 and 22.2.1.3 ctype @@ -175,23 +183,6 @@ _GLIBCXX_END_LDBL_NAMESPACE template<typename _CharT> class messages_byname; - template<typename _Facet> - bool - has_facet(const locale& __loc) throw(); - - template<typename _Facet> - const _Facet& - use_facet(const locale& __loc); - - template<typename _Facet> - inline const _Facet& - __check_facet(const _Facet* __f) - { - if (!__f) - __throw_bad_cast(); - return *__f; - } - _GLIBCXX_END_NAMESPACE #endif diff --git a/libstdc++-v3/include/bits/stl_algobase.h b/libstdc++-v3/include/bits/stl_algobase.h index 52d09883699..6be1eb123e1 100644 --- a/libstdc++-v3/include/bits/stl_algobase.h +++ b/libstdc++-v3/include/bits/stl_algobase.h @@ -64,7 +64,6 @@ #include <bits/c++config.h> #include <cstring> -#include <cwchar> #include <cstddef> #include <bits/functexcept.h> #include <bits/stl_pair.h> @@ -161,9 +160,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std) _ReferenceType1; typedef typename iterator_traits<_ForwardIterator2>::reference _ReferenceType2; - std::__iter_swap<__are_same<_ValueType1, _ValueType2>::__value && - __are_same<_ValueType1 &, _ReferenceType1>::__value && - __are_same<_ValueType2 &, _ReferenceType2>::__value>:: + std::__iter_swap<__are_same<_ValueType1, _ValueType2>::__value + && __are_same<_ValueType1&, _ReferenceType1>::__value + && __are_same<_ValueType2&, _ReferenceType2>::__value>:: iter_swap(__a, __b); } @@ -285,6 +284,26 @@ _GLIBCXX_BEGIN_NAMESPACE(std) return __a; } + + // If _Iterator is a __normal_iterator return its base (a plain pointer, + // normally) otherwise return it untouched. See copy, fill, ... + template<typename _Iterator, + bool _BoolType = __is_normal_iterator<_Iterator>::__value> + struct __niter_base + { + static const _Iterator& + __b(const _Iterator& __it) + { return __it; } + }; + + template<typename _Iterator> + struct __niter_base<_Iterator, true> + { + static const typename _Iterator::_Iterator_type& + __b(const _Iterator& __it) + { return __it.base(); } + }; + // All of these auxiliary structs serve two purposes. (1) Replace // calls to copy with memmove whenever possible. (Memmove, not memcpy, // because the input and output ranges are permitted to overlap.) @@ -378,43 +397,6 @@ _GLIBCXX_BEGIN_NAMESPACE(std) __copy_aux(istreambuf_iterator<_CharT, char_traits<_CharT> >, istreambuf_iterator<_CharT, char_traits<_CharT> >, _CharT*); - template<bool, bool> - struct __copy_normal - { - template<typename _II, typename _OI> - static _OI - __copy_n(_II __first, _II __last, _OI __result) - { return std::__copy_aux(__first, __last, __result); } - }; - - template<> - struct __copy_normal<true, false> - { - template<typename _II, typename _OI> - static _OI - __copy_n(_II __first, _II __last, _OI __result) - { return std::__copy_aux(__first.base(), __last.base(), __result); } - }; - - template<> - struct __copy_normal<false, true> - { - template<typename _II, typename _OI> - static _OI - __copy_n(_II __first, _II __last, _OI __result) - { return _OI(std::__copy_aux(__first, __last, __result.base())); } - }; - - template<> - struct __copy_normal<true, true> - { - template<typename _II, typename _OI> - static _OI - __copy_n(_II __first, _II __last, _OI __result) - { return _OI(std::__copy_aux(__first.base(), __last.base(), - __result.base())); } - }; - /** * @brief Copies the range [first,last) into result. * @param first An input iterator. @@ -431,23 +413,22 @@ _GLIBCXX_BEGIN_NAMESPACE(std) * Note that the end of the output range is permitted to be contained * within [first,last). */ - template<typename _InputIterator, typename _OutputIterator> - inline _OutputIterator - copy(_InputIterator __first, _InputIterator __last, - _OutputIterator __result) + template<typename _II, typename _OI> + inline _OI + copy(_II __first, _II __last, _OI __result) { // concept requirements - __glibcxx_function_requires(_InputIteratorConcept<_InputIterator>) - __glibcxx_function_requires(_OutputIteratorConcept<_OutputIterator, - typename iterator_traits<_InputIterator>::value_type>) + __glibcxx_function_requires(_InputIteratorConcept<_II>) + __glibcxx_function_requires(_OutputIteratorConcept<_OI, + typename iterator_traits<_II>::value_type>) __glibcxx_requires_valid_range(__first, __last); - const bool __in = __is_normal_iterator<_InputIterator>::__value; - const bool __out = __is_normal_iterator<_OutputIterator>::__value; - return std::__copy_normal<__in, __out>::__copy_n(__first, __last, - __result); + return _OI(std::__copy_aux(__niter_base<_II>::__b(__first), + __niter_base<_II>::__b(__last), + __niter_base<_OI>::__b(__result))); } + template<bool, typename> struct __copy_backward { @@ -505,45 +486,6 @@ _GLIBCXX_BEGIN_NAMESPACE(std) __result); } - template<bool, bool> - struct __copy_backward_normal - { - template<typename _BI1, typename _BI2> - static _BI2 - __copy_b_n(_BI1 __first, _BI1 __last, _BI2 __result) - { return std::__copy_backward_aux(__first, __last, __result); } - }; - - template<> - struct __copy_backward_normal<true, false> - { - template<typename _BI1, typename _BI2> - static _BI2 - __copy_b_n(_BI1 __first, _BI1 __last, _BI2 __result) - { return std::__copy_backward_aux(__first.base(), __last.base(), - __result); } - }; - - template<> - struct __copy_backward_normal<false, true> - { - template<typename _BI1, typename _BI2> - static _BI2 - __copy_b_n(_BI1 __first, _BI1 __last, _BI2 __result) - { return _BI2(std::__copy_backward_aux(__first, __last, - __result.base())); } - }; - - template<> - struct __copy_backward_normal<true, true> - { - template<typename _BI1, typename _BI2> - static _BI2 - __copy_b_n(_BI1 __first, _BI1 __last, _BI2 __result) - { return _BI2(std::__copy_backward_aux(__first.base(), __last.base(), - __result.base())); } - }; - /** * @brief Copies the range [first,last) into result. * @param first A bidirectional iterator. @@ -573,11 +515,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std) typename iterator_traits<_BI2>::value_type>) __glibcxx_requires_valid_range(__first, __last); - const bool __bi1 = __is_normal_iterator<_BI1>::__value; - const bool __bi2 = __is_normal_iterator<_BI2>::__value; - return std::__copy_backward_normal<__bi1, __bi2>::__copy_b_n(__first, - __last, - __result); + return _BI2(std::__copy_backward_aux(__niter_base<_BI1>::__b(__first), + __niter_base<_BI1>::__b(__last), + __niter_base<_BI2>::__b(__result))); } @@ -617,7 +557,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) std::__fill<__scalar>::fill(__first, __last, __value); } - // Specialization: for char types we can use memset (wmemset). + // Specialization: for char types we can use memset. inline void __fill_aux(unsigned char* __first, unsigned char* __last, unsigned char __c) { std::memset(__first, __c, __last - __first); } @@ -630,32 +570,6 @@ _GLIBCXX_BEGIN_NAMESPACE(std) __fill_aux(char* __first, char* __last, char __c) { std::memset(__first, static_cast<unsigned char>(__c), __last - __first); } -#ifdef _GLIBCXX_USE_WCHAR_T - inline void - __fill_aux(wchar_t* __first, wchar_t* __last, wchar_t __c) - { std::wmemset(__first, __c, __last - __first); } -#endif - - template<bool> - struct __fill_normal - { - template<typename _ForwardIterator, typename _Tp> - static void - __fill_n(_ForwardIterator __first, _ForwardIterator __last, - const _Tp& __value) - { std::__fill_aux(__first, __last, __value); } - }; - - template<> - struct __fill_normal<true> - { - template<typename _ForwardIterator, typename _Tp> - static void - __fill_n(_ForwardIterator __first, _ForwardIterator __last, - const _Tp& __value) - { std::__fill_aux(__first.base(), __last.base(), __value); } - }; - /** * @brief Fills the range [first,last) with copies of value. * @param first A forward iterator. @@ -676,8 +590,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) _ForwardIterator>) __glibcxx_requires_valid_range(__first, __last); - const bool __fi = __is_normal_iterator<_ForwardIterator>::__value; - std::__fill_normal<__fi>::__fill_n(__first, __last, __value); + std::__fill_aux(__niter_base<_ForwardIterator>::__b(__first), + __niter_base<_ForwardIterator>::__b(__last), __value); } @@ -740,34 +654,6 @@ _GLIBCXX_BEGIN_NAMESPACE(std) return __first + __n; } -#ifdef _GLIBCXX_USE_WCHAR_T - template<typename _Size> - inline wchar_t* - __fill_n_aux(wchar_t* __first, _Size __n, wchar_t __c) - { - std::__fill_aux(__first, __first + __n, __c); - return __first + __n; - } -#endif - - template<bool> - struct __fill_n_normal - { - template<typename _OI, typename _Size, typename _Tp> - static _OI - __fill_n_n(_OI __first, _Size __n, const _Tp& __value) - { return std::__fill_n_aux(__first, __n, __value); } - }; - - template<> - struct __fill_n_normal<true> - { - template<typename _OI, typename _Size, typename _Tp> - static _OI - __fill_n_n(_OI __first, _Size __n, const _Tp& __value) - { return _OI(std::__fill_n_aux(__first.base(), __n, __value)); } - }; - /** * @brief Fills the range [first,first+n) with copies of value. * @param first An output iterator. @@ -779,15 +665,15 @@ _GLIBCXX_BEGIN_NAMESPACE(std) * types filling contiguous areas of memory, this becomes an inline call * to @c memset or @ wmemset. */ - template<typename _OutputIterator, typename _Size, typename _Tp> - inline _OutputIterator - fill_n(_OutputIterator __first, _Size __n, const _Tp& __value) + template<typename _OI, typename _Size, typename _Tp> + inline _OI + fill_n(_OI __first, _Size __n, const _Tp& __value) { // concept requirements - __glibcxx_function_requires(_OutputIteratorConcept<_OutputIterator, _Tp>) + __glibcxx_function_requires(_OutputIteratorConcept<_OI, _Tp>) - const bool __oi = __is_normal_iterator<_OutputIterator>::__value; - return std::__fill_n_normal<__oi>::__fill_n_n(__first, __n, __value); + return _OI(std::__fill_n_aux(__niter_base<_OI>::__b(__first), __n, + __value)); } /** @@ -856,6 +742,47 @@ _GLIBCXX_BEGIN_NAMESPACE(std) return pair<_InputIterator1, _InputIterator2>(__first1, __first2); } + + template<bool _BoolType> + struct __equal + { + template<typename _II1, typename _II2> + static bool + equal(_II1 __first1, _II1 __last1, _II2 __first2) + { + for (; __first1 != __last1; ++__first1, ++__first2) + if (!(*__first1 == *__first2)) + return false; + return true; + } + }; + + template<> + struct __equal<true> + { + template<typename _Tp> + static bool + equal(const _Tp* __first1, const _Tp* __last1, const _Tp* __first2) + { + return !std::memcmp(__first1, __first2, sizeof(_Tp) + * (__last1 - __first1)); + } + }; + + template<typename _II1, typename _II2> + inline bool + __equal_aux(_II1 __first1, _II1 __last1, _II2 __first2) + { + typedef typename iterator_traits<_II1>::value_type _ValueType1; + typedef typename iterator_traits<_II2>::value_type _ValueType2; + const bool __simple = (__is_integer<_ValueType1>::__value + && __is_pointer<_II1>::__value + && __is_pointer<_II2>::__value + && __are_same<_ValueType1, _ValueType2>::__value); + + return std::__equal<__simple>::equal(__first1, __last1, __first2); + } + /** * @brief Tests a range for element-wise equality. * @param first1 An input iterator. @@ -867,23 +794,21 @@ _GLIBCXX_BEGIN_NAMESPACE(std) * false depending on whether all of the corresponding elements of the * ranges are equal. */ - template<typename _InputIterator1, typename _InputIterator2> + template<typename _II1, typename _II2> inline bool - equal(_InputIterator1 __first1, _InputIterator1 __last1, - _InputIterator2 __first2) + equal(_II1 __first1, _II1 __last1, _II2 __first2) { // concept requirements - __glibcxx_function_requires(_InputIteratorConcept<_InputIterator1>) - __glibcxx_function_requires(_InputIteratorConcept<_InputIterator2>) + __glibcxx_function_requires(_InputIteratorConcept<_II1>) + __glibcxx_function_requires(_InputIteratorConcept<_II2>) __glibcxx_function_requires(_EqualOpConcept< - typename iterator_traits<_InputIterator1>::value_type, - typename iterator_traits<_InputIterator2>::value_type>) + typename iterator_traits<_II1>::value_type, + typename iterator_traits<_II2>::value_type>) __glibcxx_requires_valid_range(__first1, __last1); - - for (; __first1 != __last1; ++__first1, ++__first2) - if (!(*__first1 == *__first2)) - return false; - return true; + + return std::__equal_aux(__niter_base<_II1>::__b(__first1), + __niter_base<_II1>::__b(__last1), + __niter_base<_II2>::__b(__first2)); } /** diff --git a/libstdc++-v3/include/bits/stl_iterator.h b/libstdc++-v3/include/bits/stl_iterator.h index f9425aa14bc..06aa105ece4 100644 --- a/libstdc++-v3/include/bits/stl_iterator.h +++ b/libstdc++-v3/include/bits/stl_iterator.h @@ -1,6 +1,6 @@ // Iterators -*- C++ -*- -// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 +// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -647,6 +647,8 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) typedef typename iterator_traits<_Iterator>::reference reference; typedef typename iterator_traits<_Iterator>::pointer pointer; + typedef _Iterator _Iterator_type; + __normal_iterator() : _M_current(_Iterator()) { } explicit diff --git a/libstdc++-v3/include/ext/pool_allocator.h b/libstdc++-v3/include/ext/pool_allocator.h index e78bf21778c..f9dcc7fc88d 100644 --- a/libstdc++-v3/include/ext/pool_allocator.h +++ b/libstdc++-v3/include/ext/pool_allocator.h @@ -1,6 +1,6 @@ // Allocators -*- C++ -*- -// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 +// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 // Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free @@ -212,7 +212,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) } const size_t __bytes = __n * sizeof(_Tp); - if (__bytes > size_t(_S_max_bytes) || _S_force_new == 1) + if (__bytes > size_t(_S_max_bytes) || _S_force_new > 0) __ret = static_cast<_Tp*>(::operator new(__bytes)); else { @@ -241,7 +241,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) if (__builtin_expect(__n != 0 && __p != 0, true)) { const size_t __bytes = __n * sizeof(_Tp); - if (__bytes > static_cast<size_t>(_S_max_bytes) || _S_force_new == 1) + if (__bytes > static_cast<size_t>(_S_max_bytes) || _S_force_new > 0) ::operator delete(__p); else { diff --git a/libstdc++-v3/include/std/type_traits b/libstdc++-v3/include/std/type_traits index 1d83dabd861..0d7e85e5300 100644 --- a/libstdc++-v3/include/std/type_traits +++ b/libstdc++-v3/include/std/type_traits @@ -42,5 +42,305 @@ # include <c++0x_warning.h> #endif +_GLIBCXX_BEGIN_NAMESPACE(std) + + // Define a nested type if some predicate holds. + template<bool, typename _Tp = void> + struct enable_if + { }; + + template<typename _Tp> + struct enable_if<true, _Tp> + { typedef _Tp type; }; + + + // Like a conditional expression, but for types. If true, first, if + // false, second. + template<bool _Cond, typename _Iftrue, typename _Iffalse> + struct conditional + { typedef _Iftrue type; }; + + template<typename _Iftrue, typename _Iffalse> + struct conditional<false, _Iftrue, _Iffalse> + { typedef _Iffalse type; }; + + + // Decay trait for arrays and functions, used for perfect forwarding + // in make_pair, make_tuple, etc. + template<typename _Up, + bool _IsArray = is_array<_Up>::value, + bool _IsFunction = is_function<_Up>::value> + struct __decay_selector; + + template<typename _Up> + struct __decay_selector<_Up, false, false> + { typedef _Up __type; }; + + template<typename _Up> + struct __decay_selector<_Up, true, false> + { typedef typename remove_extent<_Up>::type* __type; }; + + + template<typename _Up> + struct __decay_selector<_Up, false, true> + { typedef typename add_pointer<_Up>::type __type; }; + + template<typename _Tp> + struct decay + { + private: + typedef typename remove_reference<_Tp>::type __remove_type; + + public: + typedef typename __decay_selector<__remove_type>::__type type; + }; + + + // Utility for constructing identically cv-qualified types. + template<typename _Unqualified, bool _IsConst, bool _IsVol> + struct __cv_selector; + + template<typename _Unqualified> + struct __cv_selector<_Unqualified, false, false> + { typedef _Unqualified __type; }; + + template<typename _Unqualified> + struct __cv_selector<_Unqualified, false, true> + { typedef volatile _Unqualified __type; }; + + template<typename _Unqualified> + struct __cv_selector<_Unqualified, true, false> + { typedef const _Unqualified __type; }; + + template<typename _Unqualified> + struct __cv_selector<_Unqualified, true, true> + { typedef const volatile _Unqualified __type; }; + + template<typename _Qualified, typename _Unqualified, + bool _IsConst = is_const<_Qualified>::value, + bool _IsVol = is_volatile<_Qualified>::value> + struct __match_cv_qualifiers + { + private: + typedef __cv_selector<_Unqualified, _IsConst, _IsVol> __match; + + public: + typedef typename __match::__type __type; + }; + + + // Utility for finding the unsigned versions of signed integral types. + template<typename _Tp> + struct __make_unsigned; + + template<> + struct __make_unsigned<char> + { typedef unsigned char __type; }; + + template<> + struct __make_unsigned<signed char> + { typedef unsigned char __type; }; + + template<> + struct __make_unsigned<wchar_t> + { typedef unsigned wchar_t __type; }; + + template<> + struct __make_unsigned<short> + { typedef unsigned short __type; }; + + template<> + struct __make_unsigned<int> + { typedef unsigned int __type; }; + + template<> + struct __make_unsigned<long> + { typedef unsigned long __type; }; + + template<> + struct __make_unsigned<long long> + { typedef unsigned long long __type; }; + + + // Select between integral and enum: not possible to be both. + template<typename _Tp, + bool _IsInt = is_integral<_Tp>::value, + bool _IsUnsigned = is_unsigned<_Tp>::value, + bool _IsEnum = is_enum<_Tp>::value> + struct __make_unsigned_selector; + + template<typename _Tp> + struct __make_unsigned_selector<_Tp, true, true, false> + { typedef _Tp __type; }; + + template<typename _Tp> + struct __make_unsigned_selector<_Tp, true, false, false> + { + private: + typedef __make_unsigned<typename remove_cv<_Tp>::type> __unsignedt; + typedef typename __unsignedt::__type __unsigned_type; + typedef __match_cv_qualifiers<_Tp, __unsigned_type> __cv_unsigned; + + public: + typedef typename __cv_unsigned::__type __type; + }; + + template<typename _Tp> + struct __make_unsigned_selector<_Tp, false, true, false> + { + private: + // GNU floating point types start with sizeof int. + static const bool __b1 = sizeof(_Tp) <= sizeof(unsigned int); + static const bool __b2 = sizeof(_Tp) <= sizeof(unsigned long); + typedef conditional<__b2, unsigned long, unsigned long long> __cond; + typedef typename __cond::type __cond_type; + typedef unsigned int __ui_type; + + public: + typedef typename conditional<__b1, __ui_type, __cond_type>::type __type; + }; + + template<typename _Tp> + struct __make_unsigned_selector<_Tp, false, false, true> + { + private: + // GNU enums start with sizeof int. + static const bool __b1 = sizeof(_Tp) <= sizeof(unsigned int); + static const bool __b2 = sizeof(_Tp) <= sizeof(unsigned long); + typedef conditional<__b2, unsigned long, unsigned long long> __cond; + typedef typename __cond::type __cond_type; + typedef unsigned int __ui_type; + + public: + typedef typename conditional<__b1, __ui_type, __cond_type>::type __type; + }; + + // Primary class template. + // Given an integral/enum type, return the corresponding unsigned + // integer type. + template<typename _Tp> + struct make_unsigned + { typedef typename __make_unsigned_selector<_Tp>::__type type; }; + + // Integral, but don't define. + template<> + struct make_unsigned<bool>; + + + // Utility for finding the signed versions of unsigned integral types. + template<typename _Tp> + struct __make_signed; + + template<> + struct __make_signed<char> + { typedef signed char __type; }; + + template<> + struct __make_signed<unsigned char> + { typedef signed char __type; }; + + template<> + struct __make_signed<wchar_t> + { typedef signed wchar_t __type; }; + + template<> + struct __make_signed<unsigned short> + { typedef signed short __type; }; + + template<> + struct __make_signed<unsigned int> + { typedef signed int __type; }; + + template<> + struct __make_signed<unsigned long> + { typedef signed long __type; }; + + template<> + struct __make_signed<unsigned long long> + { typedef signed long long __type; }; + + + // Select between arithmetic and enum: not possible to be both. + template<typename _Tp, + bool _IsInt = is_integral<_Tp>::value, + bool _IsSigned = is_signed<_Tp>::value, + bool _IsEnum = is_enum<_Tp>::value> + struct __make_signed_selector; + + template<typename _Tp> + struct __make_signed_selector<_Tp, true, true, false> + { typedef _Tp __type; }; + + template<typename _Tp> + struct __make_signed_selector<_Tp, true, false, false> + { + private: + typedef __make_signed<typename remove_cv<_Tp>::type> __signedt; + typedef typename __signedt::__type __signed_type; + typedef __match_cv_qualifiers<_Tp, __signed_type> __cv_signed; + + public: + typedef typename __cv_signed::__type __type; + }; + + template<typename _Tp> + struct __make_signed_selector<_Tp, false, true, false> + { + // GNU floating point types start with sizeof int. + static const bool __b1 = sizeof(_Tp) <= sizeof(signed int); + static const bool __b2 = sizeof(_Tp) <= sizeof(signed long); + typedef conditional<__b2, signed long, signed long long> __cond; + typedef typename __cond::type __cond_type; + typedef unsigned int __i_type; + + public: + typedef typename conditional<__b1, __i_type, __cond_type>::type __type; + }; + + template<typename _Tp> + struct __make_signed_selector<_Tp, false, false, true> + { + private: + // GNU enums start with sizeof int. + static const bool __b1 = sizeof(_Tp) <= sizeof(signed int); + static const bool __b2 = sizeof(_Tp) <= sizeof(signed long); + typedef conditional<__b2, signed long, signed long long> __cond; + typedef typename __cond::type __cond_type; + typedef int __i_type; + + public: + typedef typename conditional<__b1, __i_type, __cond_type>::type __type; + }; + + // Primary class template. + // Given an integral/enum type, return the corresponding signed + // integer type. + template<typename _Tp> + struct make_signed + { typedef typename __make_signed_selector<_Tp>::__type type; }; + + // Integral, but don't define. + template<> + struct make_signed<bool>; + + + template<typename _Tp> + struct has_nothrow_default_constructor + : public integral_constant<bool, is_pod<_Tp>::value> { }; + + template<typename _Tp> + struct has_nothrow_copy_constructor + : public integral_constant<bool, is_pod<_Tp>::value> { }; + + template<typename _Tp> + struct has_trivial_default_constructor + : public integral_constant<bool, is_pod<_Tp>::value> { }; + + template<typename _Tp> + struct has_trivial_copy_constructor + : public integral_constant<bool, is_pod<_Tp>::value> { }; + +_GLIBCXX_END_NAMESPACE + #endif diff --git a/libstdc++-v3/include/tr1/type_traits b/libstdc++-v3/include/tr1/type_traits index 8645427c63a..41edc3adbc0 100644 --- a/libstdc++-v3/include/tr1/type_traits +++ b/libstdc++-v3/include/tr1/type_traits @@ -37,7 +37,7 @@ #pragma GCC system_header #include <bits/c++config.h> -#include <tr1/type_traits_fwd.h> +#include <tr1/type_traitsfwd.h> // namespace std::tr1 namespace std @@ -249,9 +249,7 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) template<typename _Tp> struct is_pod - : public integral_constant<bool, (is_void<_Tp>::value - || is_scalar<typename - remove_all_extents<_Tp>::type>::value)> + : public integral_constant<bool, __is_pod(_Tp) || is_void<_Tp>::value> { }; template<typename _Tp> diff --git a/libstdc++-v3/include/tr1/type_traits_fwd.h b/libstdc++-v3/include/tr1/type_traitsfwd.h index c6e80a3a4b9..497801447b1 100644 --- a/libstdc++-v3/include/tr1/type_traits_fwd.h +++ b/libstdc++-v3/include/tr1/type_traitsfwd.h @@ -27,13 +27,13 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -/** @file tr1/type_traits_fwd.h +/** @file tr1/type_traitsfwd.h * This is an internal header file, included by other library headers. * You should not attempt to use it directly. */ -#ifndef _TYPE_TRAITS_FWD_H -#define _TYPE_TRAITS_FWD_H 1 +#ifndef _TYPE_TRAITSFWD_H +#define _TYPE_TRAIT_FWD_H 1 #include <cstddef> diff --git a/libstdc++-v3/testsuite/20_util/conditional/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/conditional/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..079d366590e --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/conditional/requirements/explicit_instantiation.cc @@ -0,0 +1,41 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct conditional<true, test_type, test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/conditional/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/conditional/requirements/typedefs.cc new file mode 100644 index 00000000000..980cd6dd986 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/conditional/requirements/typedefs.cc @@ -0,0 +1,42 @@ +// { dg-options "-std=gnu++0x" } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_hooks.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::conditional; + + typedef conditional<true, char, int>::type test1_type; + VERIFY( (std::is_same<test1_type, char>::value) ); + + typedef conditional<false, char, int>::type test2_type; + VERIFY( (std::is_same<test2_type, int>::value) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/decay/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/decay/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..d804d11ffb8 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/decay/requirements/explicit_instantiation.cc @@ -0,0 +1,41 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct decay<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/decay/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/decay/requirements/typedefs.cc new file mode 100644 index 00000000000..162ddd2ff42 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/decay/requirements/typedefs.cc @@ -0,0 +1,52 @@ +// { dg-options "-std=gnu++0x" } + +// 2007-05-03 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <cstdlib> +#include <type_traits> +#include <testsuite_hooks.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::decay; + using std::is_same; + + // Positive tests. + typedef decay<bool>::type test1_type; + VERIFY( (is_same<test1_type, bool>::value) ); + + typedef decay<const int>::type test2_type; + VERIFY( (is_same<test2_type, const int>::value) ); + + typedef decay<int[4]>::type test3_type; + VERIFY( (is_same<test3_type, std::remove_extent<int[4]>::type*>::value) ); + + typedef void (fn_type) (); + typedef decay<fn_type>::type test4_type; + VERIFY( (is_same<test4_type, std::add_pointer<fn_type>::type>::value) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/enable_if/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/enable_if/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..f236eabadfc --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/enable_if/requirements/explicit_instantiation.cc @@ -0,0 +1,41 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct enable_if<true>; +} diff --git a/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs.cc new file mode 100644 index 00000000000..34deb210354 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs.cc @@ -0,0 +1,33 @@ +// { dg-do compile } +// { dg-options "-std=gnu++0x" } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::enable_if; + + // Positive tests. + typedef enable_if<true, int>::type test1_type; +} diff --git a/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs_neg.cc b/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs_neg.cc new file mode 100644 index 00000000000..daff6ad3fb4 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/enable_if/requirements/typedefs_neg.cc @@ -0,0 +1,36 @@ +// { dg-do compile } +// { dg-options "-std=gnu++0x" } + +// 2007-05-02 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_hooks.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::enable_if; + + // Negative tests. + typedef enable_if<false, int>::type test2_type; +} + +// { dg-error "does not name a type" "" { target *-*-* } 33 } diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..dff484e9d6e --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct has_nothrow_copy_constructor<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/typedefs.cc new file mode 100644 index 00000000000..02c30d9f3aa --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/requirements/typedefs.cc @@ -0,0 +1,37 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-30 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +// { dg-do compile } + +void test01() +{ + // Check for required typedefs + typedef std::has_nothrow_copy_constructor<int> test_type; + typedef test_type::value_type value_type; + typedef test_type::type type; + typedef test_type::type::value_type type_value_type; + typedef test_type::type::type type_type; +} diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/value.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/value.cc new file mode 100644 index 00000000000..ac793178ac5 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_copy_constructor/value.cc @@ -0,0 +1,54 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-30 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_hooks.h> +#include <testsuite_tr1.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::has_nothrow_copy_constructor; + using namespace __gnu_test; + + VERIFY( (test_category<has_nothrow_copy_constructor, void>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, float>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, EnumType>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int*>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int(*)(int)>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int (ClassType::*)>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int (ClassType::*) (int)>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int[2]>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, float[][3]>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, EnumType[2][3][4]>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int*[3]>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int(*[][2])(int)>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, int (ClassType::*[2][3])>(true)) ); + VERIFY( (test_category<has_nothrow_copy_constructor, + int (ClassType::*[][2][3]) (int)>(true)) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..e56d7090bf8 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct has_nothrow_default_constructor<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/typedefs.cc new file mode 100644 index 00000000000..6eeb6f06501 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/requirements/typedefs.cc @@ -0,0 +1,37 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-29 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +// { dg-do compile } + +void test01() +{ + // Check for required typedefs + typedef std::has_nothrow_default_constructor<int> test_type; + typedef test_type::value_type value_type; + typedef test_type::type type; + typedef test_type::type::value_type type_value_type; + typedef test_type::type::type type_type; +} diff --git a/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/value.cc b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/value.cc new file mode 100644 index 00000000000..fccbcf74d28 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_nothrow_default_constructor/value.cc @@ -0,0 +1,59 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-29 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// 4.5.3 Type properties + +#include <type_traits> +#include <testsuite_hooks.h> +#include <testsuite_tr1.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::has_nothrow_default_constructor; + using namespace __gnu_test; + + VERIFY( (test_category<has_nothrow_default_constructor, void>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, float>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, EnumType>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int*>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int(*)(int)>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int (ClassType::*)>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, + int (ClassType::*) (int)>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int[2]>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, float[][3]>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, EnumType[2][3][4]>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int*[3]>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, int(*[][2])(int)>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, + int (ClassType::*[2][3])>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, + int (ClassType::*[][2][3]) (int)>(true)) ); + VERIFY( (test_category<has_nothrow_default_constructor, ClassType>(true)) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..a6bb87dc7c3 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct has_trivial_copy_constructor<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/typedefs.cc new file mode 100644 index 00000000000..7b49ff3ed2e --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/requirements/typedefs.cc @@ -0,0 +1,37 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-30 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +// { dg-do compile } + +void test01() +{ + // Check for required typedefs + typedef std::has_trivial_copy_constructor<int> test_type; + typedef test_type::value_type value_type; + typedef test_type::type type; + typedef test_type::type::value_type type_value_type; + typedef test_type::type::type type_type; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/value.cc b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/value.cc new file mode 100644 index 00000000000..2ea418a2e9c --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_copy_constructor/value.cc @@ -0,0 +1,56 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-30 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// 4.5.3 Type properties + +#include <type_traits> +#include <testsuite_hooks.h> +#include <testsuite_tr1.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::has_trivial_copy_constructor; + using namespace __gnu_test; + + VERIFY( (test_category<has_trivial_copy_constructor, void>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, float>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, EnumType>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int*>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int(*)(int)>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int (ClassType::*)>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int (ClassType::*) (int)>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int[2]>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, float[][3]>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, EnumType[2][3][4]>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int*[3]>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int(*[][2])(int)>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, int (ClassType::*[2][3])>(true)) ); + VERIFY( (test_category<has_trivial_copy_constructor, + int (ClassType::*[][2][3]) (int)>(true)) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..03b3050495e --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct has_trivial_default_constructor<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/typedefs.cc new file mode 100644 index 00000000000..af8e7265532 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/requirements/typedefs.cc @@ -0,0 +1,37 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-26 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +// { dg-do compile } + +void test01() +{ + // Check for required typedefs + typedef std::has_trivial_default_constructor<int> test_type; + typedef test_type::value_type value_type; + typedef test_type::type type; + typedef test_type::type::value_type type_value_type; + typedef test_type::type::type type_type; +} diff --git a/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/value.cc b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/value.cc new file mode 100644 index 00000000000..fae5ace9f76 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/has_trivial_default_constructor/value.cc @@ -0,0 +1,59 @@ +// { dg-options "-std=gnu++0x" } +// 2004-12-26 Paolo Carlini <pcarlini@suse.de> +// +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// 4.5.3 Type properties + +#include <type_traits> +#include <testsuite_hooks.h> +#include <testsuite_tr1.h> + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::has_trivial_default_constructor; + using namespace __gnu_test; + + VERIFY( (test_category<has_trivial_default_constructor, void>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, float>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, EnumType>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int*>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int(*)(int)>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int (ClassType::*)>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, + int (ClassType::*) (int)>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int[2]>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, float[][3]>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, EnumType[2][3][4]>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int*[3]>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, int(*[][2])(int)>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, + int (ClassType::*[2][3])>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, + int (ClassType::*[][2][3]) (int)>(true)) ); + VERIFY( (test_category<has_trivial_default_constructor, ClassType>(true)) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc b/libstdc++-v3/testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc new file mode 100644 index 00000000000..37c5a0346d1 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc @@ -0,0 +1,37 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> + +namespace gnu +{ + // C++0x changes from TR1. + using std::has_trivial_constructor; + using std::has_nothrow_constructor; + using std::has_trivial_copy; + using std::has_nothrow_copy; +} + +// { dg-error "has not been declared" "" { target *-*-* } 27 } +// { dg-error "has not been declared" "" { target *-*-* } 28 } +// { dg-error "has not been declared" "" { target *-*-* } 29 } +// { dg-error "has not been declared" "" { target *-*-* } 30 } + diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..ca0ed884051 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct make_signed<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs.cc new file mode 100644 index 00000000000..826e47ed3e8 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs.cc @@ -0,0 +1,68 @@ +// { dg-options "-std=gnu++0x" } + +// 2007-05-03 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_hooks.h> + +enum test_enum { first_selection }; + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::make_signed; + using std::is_same; + + // Positive tests. + typedef make_signed<const int>::type test2_type; + VERIFY( (is_same<test2_type, const int>::value) ); + + typedef make_signed<const unsigned int>::type test21c_type; + VERIFY( (is_same<test21c_type, const signed int>::value) ); + + typedef make_signed<volatile unsigned int>::type test21v_type; + VERIFY( (is_same<test21v_type, volatile signed int>::value) ); + + typedef make_signed<const volatile unsigned int>::type test21cv_type; + VERIFY( (is_same<test21cv_type, const volatile signed int>::value) ); + + typedef make_signed<const char>::type test22_type; + VERIFY( (is_same<test22_type, const signed char>::value) ); + + typedef make_signed<volatile wchar_t>::type test23_type; + VERIFY( (is_same<test23_type, volatile signed wchar_t>::value) ); + +#if 0 + // XXX + // When is_signed works for floating points types this should pass + typedef make_signed<volatile float>::type test24_type; + VERIFY( (is_same<test24_type, volatile int>::value) ); +#endif + + typedef make_signed<test_enum>::type test25_type; + VERIFY( (is_same<test25_type, int>::value) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs_neg.cc b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs_neg.cc new file mode 100644 index 00000000000..aa94f2a4708 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_signed/requirements/typedefs_neg.cc @@ -0,0 +1,53 @@ +// { dg-do compile } +// { dg-options "-std=gnu++0x" } + +// 2007-05-03 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_character.h> + +enum test_enum { first_selection }; + +void test01() +{ + using std::make_signed; + + // Negative tests. + typedef make_signed<bool>::type test1_type; + + typedef make_signed<__gnu_test::pod_uint>::type test2_type; + + typedef make_signed<int[4]>::type test3_type; + + typedef void (fn_type) (); + typedef make_signed<fn_type>::type test4_type; +} + +// { dg-error "does not name a type" "" { target *-*-* } 34 } +// { dg-error "instantiated from here" "" { target *-*-* } 36 } +// { dg-error "instantiated from here" "" { target *-*-* } 38 } +// { dg-error "instantiated from here" "" { target *-*-* } 41 } + +// { dg-error "invalid use of incomplete type" "" { target *-*-* } 320 } +// { dg-error "declaration of" "" { target *-*-* } 268 } + +// { dg-excess-errors "At global scope" } +// { dg-excess-errors "In instantiation of" } diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..bc836a7d64a --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/explicit_instantiation.cc @@ -0,0 +1,40 @@ +// { dg-options "-std=gnu++0x" } +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <type_traits> + +namespace std +{ + typedef short test_type; + template struct make_unsigned<test_type>; +} diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs.cc new file mode 100644 index 00000000000..b09d3e93aa4 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs.cc @@ -0,0 +1,68 @@ +// { dg-options "-std=gnu++0x" } + +// 2007-05-03 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_hooks.h> + +enum test_enum { first_selection }; + +void test01() +{ + bool test __attribute__((unused)) = true; + using std::make_unsigned; + using std::is_same; + + // Positive tests. + typedef make_unsigned<const unsigned int>::type test2_type; + VERIFY( (is_same<test2_type, const unsigned int>::value) ); + + typedef make_unsigned<const signed int>::type test21c_type; + VERIFY( (is_same<test21c_type, const unsigned int>::value) ); + + typedef make_unsigned<volatile signed int>::type test21v_type; + VERIFY( (is_same<test21v_type, volatile unsigned int>::value) ); + + typedef make_unsigned<const volatile signed int>::type test21cv_type; + VERIFY( (is_same<test21cv_type, const volatile unsigned int>::value) ); + + typedef make_unsigned<const char>::type test22_type; + VERIFY( (is_same<test22_type, const unsigned char>::value) ); + + typedef make_unsigned<volatile wchar_t>::type test23_type; + VERIFY( (is_same<test23_type, volatile unsigned wchar_t>::value) ); + +#if 0 + // XXX + // When is_unsigned works for floating points types this should pass + typedef make_unsigned<volatile float>::type test24_type; + VERIFY( (is_same<test24_type, volatile unsigned int>::value) ); +#endif + + typedef make_unsigned<test_enum>::type test25_type; + VERIFY( (is_same<test25_type, unsigned int>::value) ); +} + +int main() +{ + test01(); + return 0; +} diff --git a/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc new file mode 100644 index 00000000000..cc07d616954 --- /dev/null +++ b/libstdc++-v3/testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc @@ -0,0 +1,53 @@ +// { dg-do compile } +// { dg-options "-std=gnu++0x" } + +// 2007-05-03 Benjamin Kosnik <bkoz@redhat.com> +// +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. +// +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +#include <type_traits> +#include <testsuite_character.h> + +enum test_enum { first_selection }; + +void test01() +{ + using std::make_unsigned; + + // Negative tests. + typedef make_unsigned<bool>::type test1_type; + + typedef make_unsigned<__gnu_test::pod_uint>::type test2_type; + + typedef make_unsigned<int[4]>::type test3_type; + + typedef void (fn_type) (); + typedef make_unsigned<fn_type>::type test4_type; +} + +// { dg-error "does not name a type" "" { target *-*-* } 34 } +// { dg-error "instantiated from here" "" { target *-*-* } 36 } +// { dg-error "instantiated from here" "" { target *-*-* } 38 } +// { dg-error "instantiated from here" "" { target *-*-* } 41 } + +// { dg-error "invalid use of incomplete type" "" { target *-*-* } 223 } +// { dg-error "declaration of" "" { target *-*-* } 170 } + +// { dg-excess-errors "At global scope" } +// { dg-excess-errors "In instantiation of" } diff --git a/libstdc++-v3/testsuite/23_containers/tuple/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/20_util/tuple/requirements/explicit_instantiation.cc index cdead8f1ead..cdead8f1ead 100644 --- a/libstdc++-v3/testsuite/23_containers/tuple/requirements/explicit_instantiation.cc +++ b/libstdc++-v3/testsuite/20_util/tuple/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/money_get/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/money_get/requirements/explicit_instantiation.cc index dc7f85968c8..dc7f85968c8 100644 --- a/libstdc++-v3/testsuite/22_locale/money_get/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/money_get/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/num_put/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/num_put/requirements/explicit_instantiation.cc index 08008ee8c89..08008ee8c89 100644 --- a/libstdc++-v3/testsuite/22_locale/num_put/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/num_put/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/numpunct/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/numpunct/requirements/explicit_instantiation.cc index 279633a3ea0..279633a3ea0 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/numpunct_byname/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/numpunct_byname/requirements/explicit_instantiation.cc index 799541de6cb..799541de6cb 100644 --- a/libstdc++-v3/testsuite/22_locale/numpunct_byname/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/numpunct_byname/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/time_get/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/time_get/requirements/explicit_instantiation.cc index 170e9e75472..170e9e75472 100644 --- a/libstdc++-v3/testsuite/22_locale/time_get/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/time_get/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/22_locale/time_put/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/22_locale/time_put/requirements/explicit_instantiation.cc index a1b365c597b..a1b365c597b 100644 --- a/libstdc++-v3/testsuite/22_locale/time_put/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/22_locale/time_put/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/assign_neg.cc b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/assign_neg.cc index 0c47da04033..0c47da04033 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/assign_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/assign_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor.cc b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor.cc index f378b0b1178..f378b0b1178 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor_1_neg.cc b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor_1_neg.cc index fc0beffae3e..fc0beffae3e 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor_1_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor_1_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor_2_neg.cc b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor_2_neg.cc index 403f6473f6b..403f6473f6b 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/constructor_2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/constructor_2_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/insert_neg.cc b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/insert_neg.cc index 2e2abc56c4b..2e2abc56c4b 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/deque/insert_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/deque/requirements/dr438/insert_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/assign_neg.cc b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/assign_neg.cc index 4ad1127b9e5..4ad1127b9e5 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/assign_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/assign_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor.cc b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor.cc index c20ac14e202..c20ac14e202 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor.cc +++ b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor_1_neg.cc b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc index 5df6fc8532c..5df6fc8532c 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor_1_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor_2_neg.cc b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc index 6783727be7a..6783727be7a 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/constructor_2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/insert_neg.cc b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/insert_neg.cc index c8f2026052e..c8f2026052e 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/list/insert_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/list/requirements/dr438/insert_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/assign_neg.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/assign_neg.cc index 873c27f86ed..873c27f86ed 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/assign_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/assign_neg.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/bool/constructor.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/bool/constructor.cc index 15b4a77a10b..15b4a77a10b 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/bool/constructor.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/bool/constructor.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor.cc index 74968bd4b64..74968bd4b64 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor.cc diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor_1_neg.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor_1_neg.cc index c66faaec941..b850c71cf84 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor_1_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor_1_neg.cc @@ -19,7 +19,7 @@ // USA. // { dg-do compile } -// { dg-error "no match" "" { target *-*-* } 706 } +// { dg-error "no match" "" { target *-*-* } 620 } // { dg-excess-errors "" } #include <vector> diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor_2_neg.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor_2_neg.cc index 8e0130bc9cf..194da7342a4 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/constructor_2_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/constructor_2_neg.cc @@ -19,7 +19,7 @@ // USA. // { dg-do compile } -// { dg-error "no match" "" { target *-*-* } 706 } +// { dg-error "no match" "" { target *-*-* } 620 } // { dg-excess-errors "" } #include <vector> diff --git a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/insert_neg.cc b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/insert_neg.cc index c82a5c4602d..c82a5c4602d 100644 --- a/libstdc++-v3/testsuite/23_containers/requirements/sequences/dr438/vector/insert_neg.cc +++ b/libstdc++-v3/testsuite/23_containers/vector/requirements/dr438/insert_neg.cc diff --git a/libstdc++-v3/testsuite/27_io/basic_ofstream/requirements/explicit_instantiations.cc b/libstdc++-v3/testsuite/27_io/basic_ofstream/requirements/explicit_instantiation.cc index f1395e9a80b..f1395e9a80b 100644 --- a/libstdc++-v3/testsuite/27_io/basic_ofstream/requirements/explicit_instantiations.cc +++ b/libstdc++-v3/testsuite/27_io/basic_ofstream/requirements/explicit_instantiation.cc diff --git a/libstdc++-v3/testsuite/lib/libstdc++.exp b/libstdc++-v3/testsuite/lib/libstdc++.exp index 85f256672be..70f2cb6f3d2 100644 --- a/libstdc++-v3/testsuite/lib/libstdc++.exp +++ b/libstdc++-v3/testsuite/lib/libstdc++.exp @@ -391,7 +391,7 @@ proc v3_target_compile_as_c { source dest type options } { set cxxlibglossflags [libgloss_link_flags] set cc_final [concat $cc_final $cxxlibglossflags] set cc_final [concat $cc_final $includes] - regsub -all ".nostdinc.." $cc_final "" cc_final + regsub -all {\s[-]nostdinc[+][+]} $cc_final "" cc_final # This is needed for "C" tests, as this type of test may need the # C++ includes. And if we're not testing in the build directory, diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_const/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_const/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..bf3481ab2e7 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_const/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct add_const<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_const.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_const/requirements/typedefs.cc index 8669098bc3d..8669098bc3d 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_const.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_const/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_cv/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_cv/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..fdcd16545d3 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_cv/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct add_cv<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_cv.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_cv/requirements/typedefs.cc index c197501b08e..c197501b08e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_cv.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_cv/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..65f695b174c --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct add_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/pointer_modifications/add_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_pointer/requirements/typedefs.cc index d87cd2e4271..d87cd2e4271 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/pointer_modifications/add_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_pointer/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_reference/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_reference/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..1cc7149fd07 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_reference/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct add_reference<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/reference_modifications/add_reference.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_reference/requirements/typedefs.cc index 29ad8c3d994..29ad8c3d994 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/reference_modifications/add_reference.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_reference/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_volatile/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_volatile/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..0aefd05dcb3 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_volatile/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct add_volatile<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_volatile.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_volatile/requirements/typedefs.cc index 489b05950b9..489b05950b9 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/add_volatile.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/add_volatile/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/aligned_storage/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/aligned_storage/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..1469e1eb32a --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/aligned_storage/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct aligned_storage<1, alignment_of<test_type>::value>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/other_transformations/aligned_storage/aligned_storage.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/aligned_storage/requirements/typedefs.cc index bbc336c24c8..bbc336c24c8 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/other_transformations/aligned_storage/aligned_storage.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/aligned_storage/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..8a040e1f536 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct alignment_of<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/alignment_of/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/requirements/typedefs.cc index 8df7bba0a1d..8df7bba0a1d 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/alignment_of/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/alignment_of/alignment_of.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/value.cc index 6da2822c6ee..6da2822c6ee 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/alignment_of/alignment_of.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/alignment_of/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..972a2b4b231 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct extent<test_type, 2>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/extent/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/requirements/typedefs.cc index c7d4b958c57..c7d4b958c57 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/extent/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/extent/extent.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/value.cc index 6ccecacc06b..6ccecacc06b 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/extent/extent.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/extent/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..4537d495d4f --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_nothrow_assign<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_assign/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/requirements/typedefs.cc index 7251a3aaa63..7251a3aaa63 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_assign/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_assign/has_nothrow_assign.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/value.cc index b74d932c148..b74d932c148 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_assign/has_nothrow_assign.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_assign/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..9e2e076b01c --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_nothrow_constructor<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/requirements/typedefs.cc index 9e119845981..9e119845981 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/value.cc index 8296867fad9..02743a14e95 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_constructor/has_nothrow_constructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_constructor/value.cc @@ -1,6 +1,6 @@ // 2004-12-29 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_nothrow_constructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_nothrow_constructor, ClassType>(false)) ); + VERIFY( (test_category<has_nothrow_constructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..a5d16f3cfa6 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_nothrow_copy<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_copy/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/requirements/typedefs.cc index 4ec8cb0ab2f..4ec8cb0ab2f 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_copy/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_copy/has_nothrow_copy.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/value.cc index 2ba1d9e073c..2ba1d9e073c 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_nothrow_copy/has_nothrow_copy.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_nothrow_copy/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..22312840fc2 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_trivial_assign<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_assign/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/requirements/typedefs.cc index 124131d95bc..124131d95bc 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_assign/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_assign/has_trivial_assign.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/value.cc index ac3553562c8..ac3553562c8 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_assign/has_trivial_assign.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_assign/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..061647be2b5 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_trivial_constructor<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/requirements/typedefs.cc index f6a57fcb63d..f6a57fcb63d 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/value.cc index 77dcf1fb8e8..f6b1a1aa526 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_constructor/has_trivial_constructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_constructor/value.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_trivial_constructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_trivial_constructor, ClassType>(false)) ); + VERIFY( (test_category<has_trivial_constructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..5adf42a0442 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_trivial_copy<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_copy/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/requirements/typedefs.cc index 0996f4648d0..0996f4648d0 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_copy/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_copy/has_trivial_copy.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/value.cc index 8158c183200..8158c183200 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_copy/has_trivial_copy.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_copy/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..41f594d7384 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_trivial_destructor<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/requirements/typedefs.cc index 948658943e7..948658943e7 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/value.cc index 3af9c2673dd..197de982b2b 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_trivial_destructor/has_trivial_destructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_trivial_destructor/value.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -48,9 +48,7 @@ void test01() int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<has_trivial_destructor, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<has_trivial_destructor, ClassType>(false)) ); + VERIFY( (test_category<has_trivial_destructor, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..458ed7ed6eb --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct has_virtual_destructor<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_virtual_destructor/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/requirements/typedefs.cc index 94d81eafb21..94d81eafb21 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_virtual_destructor/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_virtual_destructor/has_virtual_destructor.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/value.cc index 910aeded2d5..910aeded2d5 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/has_virtual_destructor/has_virtual_destructor.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/has_virtual_destructor/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..701b320432e --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct integral_constant<test_type, -3>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/requirements/typedefs.cc index e96c322ead0..e96c322ead0 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/static_definition.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/static_definition.cc index bb2b3cd87cb..bb2b3cd87cb 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/static_definition.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/static_definition.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/true_false_type_typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/true_false_type_typedefs.cc index 853ea723c7a..853ea723c7a 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/true_false_type_typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/true_false_type_typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/true_false_type.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/true_false_value.cc index f3a65d62070..f3a65d62070 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/helper_classes/true_false_type.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/integral_constant/true_false_value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..04707156c95 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_abstract<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_abstract/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/requirements/typedefs.cc index 49bb463de2e..49bb463de2e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_abstract/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_abstract/is_abstract.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/value.cc index 89a10b3d3d3..89a10b3d3d3 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_abstract/is_abstract.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_abstract/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..e18948c37b7 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_arithmetic<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_arithmetic/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/requirements/typedefs.cc index 17cd0a06866..17cd0a06866 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_arithmetic/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_arithmetic/is_arithmetic.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc index ddf0854ba77..ddf0854ba77 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_arithmetic/is_arithmetic.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_arithmetic/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..c70df4629c8 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_array<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_array/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/requirements/typedefs.cc index 660403d4958..660403d4958 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_array/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_array/is_array.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/value.cc index c38d1598100..c38d1598100 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_array/is_array.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_array/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..29853f2a051 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_base_of<test_type, test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_base_of/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/requirements/typedefs.cc index 37ad6c68ef5..37ad6c68ef5 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_base_of/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_base_of/is_base_of.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/value.cc index 07c17948df0..07c17948df0 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_base_of/is_base_of.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_base_of/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..448ec8611a4 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_class<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_class/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/requirements/typedefs.cc index 8ad546ac3b6..8ad546ac3b6 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_class/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_class/is_class.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/value.cc index 5e88fb5b6d5..5e88fb5b6d5 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_class/is_class.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_class/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..f15cd270981 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_compound<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_compound/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/requirements/typedefs.cc index 906076e3ca4..906076e3ca4 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_compound/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_compound/is_compound.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc index 1708f580eb9..1708f580eb9 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_compound/is_compound.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_compound/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..78174906f40 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_const<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_const/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/requirements/typedefs.cc index 3a5dd667c2e..3a5dd667c2e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_const/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_const/is_const.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/value.cc index 55f36566887..55f36566887 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_const/is_const.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_const/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..b2ada0391f9 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_convertible<test_type, test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_convertible/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/requirements/typedefs.cc index 6ee1de162b9..6ee1de162b9 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_convertible/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_convertible/is_convertible.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/value.cc index 7d98b016773..7d98b016773 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_convertible/is_convertible.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_convertible/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..cfe503a3e09 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_empty<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_empty/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/requirements/typedefs.cc index 346581d1628..346581d1628 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_empty/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_empty/is_empty.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/value.cc index 62b83a473d8..62b83a473d8 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_empty/is_empty.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_empty/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/24808.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/24808.cc index 88a3cdceda6..88a3cdceda6 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/24808.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/24808.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..1df9091bab9 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_enum<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/requirements/typedefs.cc index fc4e11bd4ab..fc4e11bd4ab 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/is_enum.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/value.cc index 97a77db1146..97a77db1146 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_enum/is_enum.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_enum/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..e43a8e17619 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_floating_point<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_floating_point/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/requirements/typedefs.cc index b19cf1f09f1..b19cf1f09f1 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_floating_point/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_floating_point/is_floating_point.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc index 9b8e8463e5a..9b8e8463e5a 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_floating_point/is_floating_point.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_floating_point/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/24808.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/24808.cc index 6ba9969a2ee..6ba9969a2ee 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/24808.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/24808.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..fcc695745e1 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_function<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/requirements/typedefs.cc index db70185bf6f..db70185bf6f 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/is_function.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/value.cc index 1ada9120b22..1ada9120b22 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_function/is_function.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_function/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..26c5b1da3b0 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_fundamental<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_fundamental/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/requirements/typedefs.cc index a4744eda21a..a4744eda21a 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_fundamental/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_fundamental/is_fundamental.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc index 8a756c5ee86..8a756c5ee86 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_fundamental/is_fundamental.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_fundamental/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..d7396637295 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_integral<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_integral/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/requirements/typedefs.cc index 19d6a67422e..19d6a67422e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_integral/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_integral/is_integral.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc index 2876c6d11a2..2876c6d11a2 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_integral/is_integral.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_integral/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..c9f35284e47 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_member_function_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_function_pointer/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/requirements/typedefs.cc index 48f1f22cb30..48f1f22cb30 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_function_pointer/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_function_pointer/is_member_function_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/value.cc index b0b3f802046..b0b3f802046 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_function_pointer/is_member_function_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_function_pointer/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..a57fe7de22c --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_member_object_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_object_pointer/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/requirements/typedefs.cc index 0add4a0ad53..0add4a0ad53 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_object_pointer/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_object_pointer/is_member_object_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/value.cc index e873edfa9a5..e873edfa9a5 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_member_object_pointer/is_member_object_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_object_pointer/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..4d13bd7542e --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_member_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_member_pointer/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/requirements/typedefs.cc index 65a882ca996..65a882ca996 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_member_pointer/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_member_pointer/is_member_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/value.cc index 0b194bbcb66..0b194bbcb66 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_member_pointer/is_member_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_member_pointer/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/24808.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/24808.cc index 70ba0167388..70ba0167388 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/24808.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/24808.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..c0e4ed7049b --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_object<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/requirements/typedefs.cc index 61cf43f534c..61cf43f534c 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/is_object.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/value.cc index 6283ece6876..6283ece6876 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_object/is_object.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_object/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..05fe8a1a3d6 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_pod<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/requirements/typedefs.cc index 8dbfd3c38d4..8dbfd3c38d4 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/value.cc index 116af85d2d8..12a4a4533e7 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_pod/is_pod.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pod/value.cc @@ -1,6 +1,6 @@ // 2004-12-26 Paolo Carlini <pcarlini@suse.de> // -// Copyright (C) 2004 Free Software Foundation, Inc. +// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -45,9 +45,7 @@ void test01() VERIFY( (test_category<is_pod, int(*[][2])(int)>(true)) ); VERIFY( (test_category<is_pod, int (ClassType::*[2][3])>(true)) ); VERIFY( (test_category<is_pod, int (ClassType::*[][2][3]) (int)>(true)) ); - - // Sanity check. - VERIFY( (test_category<is_pod, ClassType>(false)) ); + VERIFY( (test_category<is_pod, ClassType>(true)) ); } int main() diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..9f90dd27709 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_pointer/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/requirements/typedefs.cc index 6ba35d16024..6ba35d16024 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_pointer/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_pointer/is_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/value.cc index 7435647d54d..7435647d54d 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_pointer/is_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_pointer/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/24809.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/24809.cc index 0b8ab0f7167..0b8ab0f7167 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/24809.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/24809.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..57235b16f65 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_polymorphic<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/requirements/typedefs.cc index 14ba6903180..14ba6903180 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/is_polymorphic.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/value.cc index 6dc5c1c2c6d..6dc5c1c2c6d 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_polymorphic/is_polymorphic.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_polymorphic/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..e8c31fd4548 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_reference<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_reference/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/requirements/typedefs.cc index 30c9e275a33..30c9e275a33 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_reference/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_reference/is_reference.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/value.cc index 8a799b7c424..8a799b7c424 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_reference/is_reference.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_reference/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..17e63d6a181 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_same<test_type, test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_same/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/requirements/typedefs.cc index 460ebbbd5c7..460ebbbd5c7 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_same/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_same/is_same.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/value.cc index 0fbae2eb357..0fbae2eb357 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/relationships_between_types/is_same/is_same.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_same/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..d88abf37f61 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_scalar<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_scalar/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/requirements/typedefs.cc index b684c7cb185..b684c7cb185 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_scalar/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_scalar/is_scalar.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/value.cc index e0cb20c2c4f..e0cb20c2c4f 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/composite_type_traits/is_scalar/is_scalar.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_scalar/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..1132721ee5d --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_signed<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_signed/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/requirements/typedefs.cc index 86730aeea7e..86730aeea7e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_signed/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_signed/is_signed.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc index 351dde8d1a1..351dde8d1a1 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_signed/is_signed.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_signed/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..19fb2eb6467 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_union<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_union/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/requirements/typedefs.cc index 9f24c5e9786..9f24c5e9786 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_union/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_union/is_union.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/value.cc index e381f888b27..e381f888b27 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_union/is_union.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_union/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..5e245024873 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_unsigned<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_unsigned/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/requirements/typedefs.cc index 4c90eced4bb..4c90eced4bb 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_unsigned/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_unsigned/is_unsigned.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc index 19bb97526ef..19bb97526ef 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_unsigned/is_unsigned.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_unsigned/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..bfd42f3ed73 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_void<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_void/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/requirements/typedefs.cc index 24d19130887..24d19130887 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_void/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_void/is_void.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc index 6f0450869e0..6f0450869e0 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/primary_type_categories/is_void/is_void.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_void/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..98b62365546 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct is_volatile<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_volatile/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/requirements/typedefs.cc index 28794427b8c..28794427b8c 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_volatile/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_volatile/is_volatile.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/value.cc index 6336ab7bf1e..6336ab7bf1e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/is_volatile/is_volatile.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/is_volatile/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/other_transformations/aligned_storage/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/other_transformations/aligned_storage/typedefs.cc deleted file mode 100644 index 4e51378e4d4..00000000000 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/other_transformations/aligned_storage/typedefs.cc +++ /dev/null @@ -1,33 +0,0 @@ -// 2005-01-11 Paolo Carlini <pcarlini@suse.de> -// -// Copyright (C) 2005 Free Software Foundation, Inc. -// -// This file is part of the GNU ISO C++ Library. This library is free -// software; you can redistribute it and/or modify it under the -// terms of the GNU General Public License as published by the -// Free Software Foundation; either version 2, or (at your option) -// any later version. -// -// This library is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License along -// with this library; see the file COPYING. If not, write to the Free -// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, -// USA. - -// -// NB: This file is for testing tr1/type_traits with NO OTHER INCLUDES. - -#include <tr1/type_traits> - -// { dg-do compile } - -void test01() -{ - // Check for required typedefs - typedef std::tr1::aligned_storage<1, 1> test_type; - typedef test_type::type type; -} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..d147481469a --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct rank<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/rank/typedefs.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/requirements/typedefs.cc index 800c316979f..800c316979f 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/rank/typedefs.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/requirements/typedefs.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/rank/rank.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/value.cc index 334de47f8ef..334de47f8ef 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/type_properties/rank/rank.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/rank/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_all_extents/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_all_extents/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..bb1717830e0 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_all_extents/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_all_extents<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/array_modifications/remove_all_extents.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_all_extents/value.cc index 8d0504e0485..8d0504e0485 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/array_modifications/remove_all_extents.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_all_extents/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_const/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_const/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..46af25ecd98 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_const/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_const<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_const.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_const/value.cc index 792596ef290..792596ef290 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_const.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_const/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_cv/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_cv/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..be648a835a7 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_cv/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_cv<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_cv.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_cv/value.cc index 1afcc788eae..1afcc788eae 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_cv.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_cv/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_extent/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_extent/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..3446aea3f87 --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_extent/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_extent<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/array_modifications/remove_extent.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_extent/value.cc index 886f844405b..886f844405b 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/array_modifications/remove_extent.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_extent/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_pointer/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_pointer/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..d8c9deebafb --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_pointer/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_pointer<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/pointer_modifications/remove_pointer.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_pointer/value.cc index 6c17d024f5f..6c17d024f5f 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/pointer_modifications/remove_pointer.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_pointer/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_reference/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_reference/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..40bc4fb9a1a --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_reference/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_reference<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/reference_modifications/remove_reference.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_reference/value.cc index e32312f812e..e32312f812e 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/reference_modifications/remove_reference.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_reference/value.cc diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_volatile/requirements/explicit_instantiation.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_volatile/requirements/explicit_instantiation.cc new file mode 100644 index 00000000000..db3d3ec06cb --- /dev/null +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_volatile/requirements/explicit_instantiation.cc @@ -0,0 +1,42 @@ +// { dg-do compile } +// 2007-04-30 Benjamin Kosnik <bkoz@redhat.com> + +// Copyright (C) 2007 Free Software Foundation, Inc. +// +// This file is part of the GNU ISO C++ Library. This library is free +// software; you can redistribute it and/or modify it under the +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 2, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// You should have received a copy of the GNU General Public License along +// with this library; see the file COPYING. If not, write to the Free +// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, +// USA. + +// As a special exception, you may use this file as part of a free software +// library without restriction. Specifically, if other files instantiate +// templates or use macros or inline functions from this file, or you compile +// this file and link it with other files to produce an executable, this +// file does not by itself cause the resulting executable to be covered by +// the GNU General Public License. This exception does not however +// invalidate any other reasons why the executable file might be covered by +// the GNU General Public License. + +// NB: This file is for testing type_traits with NO OTHER INCLUDES. + +#include <tr1/type_traits> + +namespace std +{ + namespace tr1 + { + typedef short test_type; + template struct remove_volatile<test_type>; + } +} diff --git a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_volatile.cc b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_volatile/value.cc index 35c3d8e0994..35c3d8e0994 100644 --- a/libstdc++-v3/testsuite/tr1/4_metaprogramming/const_volatile_modifications/remove_volatile.cc +++ b/libstdc++-v3/testsuite/tr1/4_metaprogramming/remove_volatile/value.cc |