mirror of
https://github.com/changkun/modern-cpp-tutorial.git
synced 2025-12-17 12:44:40 +03:00
add: contributing guidelines & Typo fix (#60)
* fix: typo * update: pdf builds & website builds * update: contributing guidelines
This commit is contained in:
@@ -47,7 +47,7 @@ int main()
|
||||
}
|
||||
```
|
||||
|
||||
`std::shared_ptr` 可以通过 `get()` 方法来获取原始指针,通过 `reset()` 来减少一个引用计数,并通过`get_count()`来查看一个对象的引用计数。例如:
|
||||
`std::shared_ptr` 可以通过 `get()` 方法来获取原始指针,通过 `reset()` 来减少一个引用计数,并通过`use_count()`来查看一个对象的引用计数。例如:
|
||||
|
||||
```cpp
|
||||
auto pointer = std::make_shared<int>(10);
|
||||
|
||||
Reference in New Issue
Block a user