Capture adjustments for P0588R1.
commit297de7bc513f3f2eb82dde14ecc7f0661aa667db
authorjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 13 Nov 2017 22:34:38 +0000 (13 22:34 +0000)
committerjason <jason@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 13 Nov 2017 22:34:38 +0000 (13 22:34 +0000)
treefd734eba6bb7c4373c5a32b46fdb8e5256e42335
parent0744a0c1155bca3b0fee47ad2ac40a2652968bd4
Capture adjustments for P0588R1.

* semantics.c (process_outer_var_ref): Capture variables when
they are named; complain about non-capture uses when odr-used.
* expr.c (mark_use): Rvalue use looks through capture proxy.
* constexpr.c (potential_constant_expression_1): Improve error about
use of captured variable.
* lambda.c (need_generic_capture, dependent_capture_r)
(do_dependent_capture, processing_nonlambda_template): Remove.
* call.c (build_this): Remove uses of the above.
* decl.c (cp_finish_decl): Likewise.
* semantics.c (maybe_cleanup_point_expr)
(maybe_cleanup_point_expr_void, finish_goto_stmt)
(maybe_convert_cond): Likewise.
* typeck.c (check_return_expr): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254713 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/cp/ChangeLog
gcc/cp/call.c
gcc/cp/constexpr.c
gcc/cp/cp-tree.h
gcc/cp/decl.c
gcc/cp/expr.c
gcc/cp/lambda.c
gcc/cp/pt.c
gcc/cp/semantics.c
gcc/cp/typeck.c