brintos

brintos / llvm-project-archived public Read only

0
0
Text · 887 B · 630799b Raw
33 lines · cpp
1//===----------------------------------------------------------------------===//2//3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.4// See https://llvm.org/LICENSE.txt for license information.5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception6//7//===----------------------------------------------------------------------===//8 9// UNSUPPORTED: c++03, c++11, c++1410 11// <charconv>12 13// In14//15// to_chars_result to_chars(char* first, char* last, Integral value,16//                          int base = 10)17//18// Integral cannot be bool.19 20#include <charconv>21 22int main(int, char**)23{24    using std::to_chars;25    char buf[10];26    bool lv = true;27 28    to_chars(buf, buf + sizeof(buf), false);   // expected-error {{call to deleted function}}29    to_chars(buf, buf + sizeof(buf), lv, 16);  // expected-error {{call to deleted function}}30 31  return 0;32}33