Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Shadow pointer member variable
Language:
Ada
Assembly
Bash
C#
C++ (gcc)
C++ (clang)
C++ (vc++)
C (gcc)
C (clang)
C (vc)
Client Side
Clojure
Common Lisp
D
Elixir
Erlang
F#
Fortran
Go
Haskell
Java
Javascript
Kotlin
Lua
MySql
Node.js
Ocaml
Octave
Objective-C
Oracle
Pascal
Perl
Php
PostgreSQL
Prolog
Python
Python 3
R
Rust
Ruby
Scala
Scheme
Sql Server
Swift
Tcl
Visual Basic
Layout:
Vertical
Horizontal
//Microsoft (R) C/C++ Optimizing Compiler Version 19.00.23506 for x64 #include <iostream> class MyClass { public: MyClass() : m_pVar(nullptr) { } void Run() { std::cout << "m_pVar= " << m_pVar<< std::endl; int* m_pVar = static_cast<int*>(malloc(4)); } private: int* m_pVar; }; int main() { MyClass m; m.Run(); m.Run(); }
cl.exe
Show compiler warnings
[
+
] Compiler args
[
+
]
Show input
Compilation time: 1,75 sec, absolute running time: 1,9 sec, absolute service time: 3,66 sec
edit mode
|
history
|
discussion
m_pVar= 0000000000000000 m_pVar= 0000000000000000