// PR c++/101029 // { dg-do compile { target c++11 } } // { dg-options "" } allow [0] template struct integral_constant { static constexpr int value = __v; typedef int value_type; constexpr operator value_type() { return __v; } }; template using __bool_constant = integral_constant<__v>; template struct conditional; template struct __and_; template struct __and_<_B1, _B2, _B3, _Bn...> : conditional<_B1::value, _B1> {}; template constexpr integral_constant __is_complete_or_unbounded(_Tp) { return {}; } template struct is_default_constructible : integral_constant { static_assert(__is_complete_or_unbounded(_Tp{}), ""); }; template struct is_same : integral_constant<__is_same_as(_Tp, _Up)> {}; template struct enable_if; template struct conditional { typedef _Iffalse type; }; struct pair { template , _U2, int>::valuebool>::type> pair(); }; class BucketLogger; struct __shared_ptr_access { using element_type = BucketLogger; element_type *operator->(); }; struct DcpProducer { __shared_ptr_access logger; void bufferAcknowledgement(); }; struct atomic { atomic(long); }; inline namespace v7 { template using conditional_t = typename conditional::type; template struct basic_string_view { basic_string_view(int, int); }; template struct formatter; template using has_formatter = __bool_constant<__is_constructible(void)>; struct fallback_formatter; template struct custom_value { using parse_context = typename Context::parse_context_type; void (*format)(const void *, parse_context &, Context &); }; template struct value { float float_value; custom_value custom; template value(T) { custom.format = format_custom_arg::value, typename Context::formatter_type, fallback_formatter>>; } template static void format_custom_arg(const void *arg, typename Context::parse_context_type &, Context &ctx) { Formatter f; f.format(*static_cast(arg), ctx); } }; enum { max_packed_args }; template struct basic_format_arg { value value_; }; template void visit_format_arg(Visitor vis, Context arg) { vis(arg.value_.float_value); } template basic_format_arg make_arg(T); struct basic_format_context { using char_type = int; using parse_context_type = int; template using formatter_type = formatter; }; struct format_arg_store { using value_type = conditional_t>; value_type data_; }; template auto make_args_checked(S, Args... args) -> format_arg_store { return {args...}; } struct basic_format_specs {}; template void write(OutputIt, T, Char) { if (is_same()) ; } struct arg_formatter_base { using iterator = int; using format_specs = basic_format_specs; iterator out_; template void operator()(T value) { auto specs = format_specs(); write(out_, value, specs); } }; struct arg_formatter : arg_formatter_base { using context_type = basic_format_context; arg_formatter(context_type, int *, format_specs *); }; template struct formatter { template void format(T val, FormatContext ctx) { using af = arg_formatter; basic_format_arg __trans_tmp_2 = make_arg(val); visit_format_arg(af(ctx, nullptr, &specs_), __trans_tmp_2); } basic_format_specs specs_; }; } // namespace v7 namespace level { enum level_enum { warn }; } struct BucketLogger { template void log(level::level_enum, const S &, Args &&...); template void warn(const char *, const Args &...); }; namespace v7 { struct fallback_formatter : formatter, int> { template void format(int, OutputIt ctx) { basic_string_view str(0, 0); formatter::format(str, ctx); } }; } // namespace v7 template void BucketLogger::log(level::level_enum, const S &fmt, Args &&...args) { make_args_checked(fmt, args...); } template void BucketLogger::warn(const char *fmt, const Args &...args) { log(level::warn, fmt, args...); } template struct AtomicHashArray { static void create(); atomic isFull_; atomic numErases_; pair cells_[0]; AtomicHashArray(int, KeyT, KeyT, KeyT, double, unsigned); }; template AtomicHashArray::AtomicHashArray(int, KeyT, KeyT, KeyT, double, unsigned) : isFull_(0), numErases_(0) {} template void AtomicHashArray::create() { int c_4, capacity; double c_3; char c_2, c_1, c_0; AtomicHashArray(capacity, c_0, c_1, c_2, c_3, c_4); } int bufferAcknowledgement_vbucket; void DcpProducer::bufferAcknowledgement() { logger->warn("", bufferAcknowledgement_vbucket); } void (*makeStreamsMap_p)() = AtomicHashArray::create;