mirror of
https://forge.sourceware.org/marek/gcc.git
synced 2026-02-22 12:00:11 -05:00
* semantics.c (finish_id_expression): Remove special dependent case. Avoid some later pieces when dependent. (finish_qualified_id_expr): Do normal BASELINK handling in a template. Always build a SCOPE_REF for a destructor BIT_NOT_EXPR. (parsing_default_capturing_generic_lambda_in_template): Remove. * parser.c (cp_parser_postfix_dot_deref_expression): Always give an error for types that will never be complete. * mangle.c (write_expression): Add sanity check. * tree.c (build_qualified_name): Add sanity check. (cp_walk_subtrees): Walk into the class context of a BASELINK. * lambda.c (add_capture): Improve diagnostic for generic lambda capture failure. * call.c (build_new_method_call_1): Print the right constructor name. From-SVN: r251438
18 lines
285 B
C
18 lines
285 B
C
// PR c++/81236
|
|
// { dg-do compile { target c++14 } }
|
|
|
|
struct A { constexpr operator int() { return 24; } };
|
|
|
|
struct MyType {
|
|
void crash() {
|
|
auto l = [&](auto i){
|
|
MyType::make_crash<i>(); // Line (1)
|
|
};
|
|
|
|
l(A{});
|
|
}
|
|
|
|
template<int i>
|
|
void make_crash() {}
|
|
};
|