Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/EricPengShuai/Interview
/ Base
Method
Base
base_code/pure_virtual.cpp:10–10 ·
view source on GitHub ↗
纯虚函数
Source
from the content-addressed store, hash-verified
8
public:
9
virtual void fun() = 0; // 纯虚函数
10
explicit Base(int i) { x = i; }
11
virtual ~Base() {
12
cout <<
"Destructor: Base."
<< endl;
13
}
Callers
nothing calls this directly
Calls
no outgoing calls
Tested by
no test coverage detected