cp/
* cp-tree.h (SIZEOF_EXPR_TYPE_P): Define.
* tree.c (cp_tree_equal): Handle SIZEOF_EXPR with
SIZEOF_EXPR_TYPE_P.
* mangle.c (write_expression): Likewise.
* cxx-pretty-print.c (pp_cxx_unary_expression): Likewise.
* error.c (dump_expr): Likewise.
* parser.c (cp_parser_unary_expression): For sizeof call
cxx_sizeof_or_alignof_{type,expr} just for diagnostics and
return SIZEOF_EXPR with the operand.
* pt.c (tsubst_copy, tsubst_copy_and_build): For SIZEOF_EXPR,
call cxx_sizeof_or_alignof_{type,expr} for diagnostics, but
return SIZEOF_EXPR with tsubsted operand.
(value_dependent_expression_p): Handle SIZEOF_EXPR with
SIZEOF_EXPR_TYPE_P.
(instantiation_dependent_r): Likewise.
* call.c (null_ptr_cst_p): Call maybe_constant_value for C++98.
* semantics.c (finish_call_expr): Call
sizeof_pointer_memaccess_warning if needed.
(cxx_eval_constant_expression): Handle SIZEOF_EXPR.
(potential_constant_expression_1): Remove early exit for
C++98. Handle PROPERTY_REF.
* decl.c (duplicate_decls): When redeclaring a builtin function,
keep the merged decl builtin also if newdecl is a gnu_inline
inline definition.
(fold_sizeof_expr_r): New function.
(compute_array_index_type): Fold SIZEOF_EXPRs in itype.
* cp-gimplify.c (cp_genericize_r): Fold SIZEOF_EXPR.
* typeck.c (cp_build_binary_op): For warn_for_sign_compare
try harder using maybe_constant_value to get INTEGER_CSTs.
* decl.c (stabilize_vla_size): Call pointer_set_destroy
at the end.
testsuite/
* g++.dg/torture/Wsizeof-pointer-memaccess1.C: New test.
* g++.dg/torture/Wsizeof-pointer-memaccess2.C: New test.
* g++.dg/warn/Wsign-compare-5.C: New test.
* g++.dg/warn/Wsizeof-pointer-memaccess-1.C: New test.
* g++.dg/warn/Wnull-conversion-1.C: For c++11 add dg-error.
* g++.dg/ext/builtin30.C: New test.
* g++.dg/ext/vla12.C: New test.
* gcc.dg/builtins-85.c: New test.
libstdc++-v3/
* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Adjust line
numbers.
From-SVN: r192141
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| add_lvalue_reference | Loading commit data... | |
| add_rvalue_reference | Loading commit data... | |
| addressof | Loading commit data... | |
| aligned_storage | Loading commit data... | |
| allocator | Loading commit data... | |
| allocator_traits | Loading commit data... | |
| auto_ptr | Loading commit data... | |
| bad_function_call | Loading commit data... | |
| bind | Loading commit data... | |
| common_type/requirements | Loading commit data... | |
| conditional/requirements | Loading commit data... | |
| decay/requirements | Loading commit data... | |
| declval/requirements | Loading commit data... | |
| default_delete | Loading commit data... | |
| duration | Loading commit data... | |
| duration_cast | Loading commit data... | |
| enable_if/requirements | Loading commit data... | |
| enable_shared_from_this | Loading commit data... | |
| forward | Loading commit data... | |
| function | Loading commit data... | |
| function_objects | Loading commit data... | |
| has_trivial_copy_assign | Loading commit data... | |
| has_trivial_copy_constructor | Loading commit data... | |
| has_trivial_default_constructor | Loading commit data... | |
| hash | Loading commit data... | |
| headers | Loading commit data... | |
| is_assignable | Loading commit data... | |
| is_compound | Loading commit data... | |
| is_constructible | Loading commit data... | |
| is_convertible | Loading commit data... | |
| is_copy_assignable | Loading commit data... | |
| is_copy_constructible | Loading commit data... | |
| is_default_constructible | Loading commit data... | |
| is_destructible | Loading commit data... | |
| is_floating_point | Loading commit data... | |
| is_function | Loading commit data... | |
| is_fundamental | Loading commit data... | |
| is_integral | Loading commit data... | |
| is_literal_type | Loading commit data... | |
| is_lvalue_reference | Loading commit data... | |
| is_member_function_pointer | Loading commit data... | |
| is_member_object_pointer | Loading commit data... | |
| is_member_pointer | Loading commit data... | |
| is_move_assignable | Loading commit data... | |
| is_move_constructible | Loading commit data... | |
| is_nothrow_assignable | Loading commit data... | |
| is_nothrow_constructible | Loading commit data... | |
| is_nothrow_copy_assignable | Loading commit data... | |
| is_nothrow_copy_constructible | Loading commit data... | |
| is_nothrow_default_constructible | Loading commit data... | |
| is_nothrow_destructible | Loading commit data... | |
| is_nothrow_move_assignable | Loading commit data... | |
| is_nothrow_move_constructible | Loading commit data... | |
| is_object | Loading commit data... | |
| is_pod | Loading commit data... | |
| is_reference | Loading commit data... | |
| is_rvalue_reference | Loading commit data... | |
| is_scalar | Loading commit data... | |
| is_signed | Loading commit data... | |
| is_standard_layout | Loading commit data... | |
| is_trivial | Loading commit data... | |
| is_trivially_destructible | Loading commit data... | |
| is_unsigned | Loading commit data... | |
| make_signed/requirements | Loading commit data... | |
| make_unsigned/requirements | Loading commit data... | |
| move | Loading commit data... | |
| move_if_noexcept | Loading commit data... | |
| owner_less | Loading commit data... | |
| pair | Loading commit data... | |
| pointer_traits | Loading commit data... | |
| ratio | Loading commit data... | |
| raw_storage_iterator/requirements | Loading commit data... | |
| reference_wrapper | Loading commit data... | |
| remove_reference | Loading commit data... | |
| result_of | Loading commit data... | |
| scoped_allocator | Loading commit data... | |
| shared_ptr | Loading commit data... | |
| specialized_algorithms | Loading commit data... | |
| steady_clock | Loading commit data... | |
| system_clock | Loading commit data... | |
| time_point | Loading commit data... | |
| time_point_cast | Loading commit data... | |
| tuple | Loading commit data... | |
| typeindex | Loading commit data... | |
| underlying_type/requirements | Loading commit data... | |
| unique_ptr | Loading commit data... | |
| uses_allocator | Loading commit data... | |
| weak_ptr | Loading commit data... | |
| rel_ops.cc | Loading commit data... | |
| temporary_buffer.cc | Loading commit data... |