online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include <iostream> struct Custom { Custom(std::size_t) { } }; int main() { //-----------v---->constant expression Custom c{3}; //no warning/error here as there is no narrowing conversion int i = 3; //not a constant expressoion //-----------v---->not a constant expression and so we get warning/error Custom d{i}; //warning here of narrowing conversion here constexpr int j = 3; //constant expression //-----------v------>no warning here as j is a constant expression and so there is no narrowing conversion Custom e{j}; return 0; }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue