Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Language

C++

Compiler

clang HEAD 12.0.0 (https://github.com/llvm/llvm-project.git 2ac06241d277c969c0dee0f40fb4f00971a4d7f7)

Options
Warnings
Boost 1.73.0
C++2a
no pedantic
Raw compiler options
-Wshadow

$ clang++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.73.0/clang-head/include -std=c++2a -Wshadow
prog.cc:7:25: warning: declaration shadows a field of 'S' [-Wshadow]
    void member_fn(long x) {   // C4458
                        ^
prog.cc:5:9: note: previous declaration is here
    int x;
        ^
prog.cc:8:16: warning: declaration shadows a field of 'S' [-Wshadow]
        double y;  // C4458
               ^
prog.cc:6:11: note: previous declaration is here
    float y;
          ^
2 warnings generated.
Exit Code:
0