online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#define PRINT(x) ; Print(#x, ":", string(x)) #ifdef __cplusplus #include<iostream> #endif template<typename T> class A{ }; template<typename T> class B : public A<T>{ }; template<typename T> void func(B<T> &it1){ printf("C++:1"); //MQL:2 } ////ERRROR: 'func' - template functions overloading is not supported yet //template<typename T> //void func(T &it1){ // printf("C++:2"); //} template<typename T> void func(T &it1, T* = NULL){ printf("C++:2"); //MQL:1 } template<typename T> void func(A<T> &it1){ printf("C++:3"); //MQL:3 } void OnStart(){ B<int> b; func(b); } int main(){ OnStart(); 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