Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Language

C++

Compiler

clang HEAD 12.0.0 (https://github.com/llvm/llvm-project.git 1c19900f9417bd0b832c1cb70863b2439a18647f)

Options
Warnings
Boost 1.73.0
C++2a(GNU)
no pedantic

$ clang++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.73.0/clang-head/include -std=gnu++2a
prog.cc:7:14: warning: object backing the pointer will be destroyed at the end of the full-expression [-Wdangling-gsl]
    auto p = std::to_string(0).c_str();
             ^~~~~~~~~~~~~~~~~
prog.cc:8:12: warning: format string is not a string literal (potentially insecure) [-Wformat-security]
    printf(p);
           ^
prog.cc:8:12: note: treat the string as an argument to avoid this
    printf(p);
           ^
           "%s", 
2 warnings generated.
0
Exit Code:
0