mirror of
https://github.com/jbeder/yaml-cpp.git
synced 2025-09-10 04:51:17 +00:00
Change NULL to nullptr (#805)
This commit is contained in:
@@ -15,7 +15,7 @@ class Parser;
|
|||||||
|
|
||||||
// GraphBuilderInterface
|
// GraphBuilderInterface
|
||||||
// . Abstraction of node creation
|
// . Abstraction of node creation
|
||||||
// . pParentNode is always NULL or the return value of one of the NewXXX()
|
// . pParentNode is always nullptr or the return value of one of the NewXXX()
|
||||||
// functions.
|
// functions.
|
||||||
class GraphBuilderInterface {
|
class GraphBuilderInterface {
|
||||||
public:
|
public:
|
||||||
@@ -73,9 +73,9 @@ class GraphBuilder : public GraphBuilderInterface {
|
|||||||
typedef typename Impl::Map Map;
|
typedef typename Impl::Map Map;
|
||||||
|
|
||||||
GraphBuilder(Impl &impl) : m_impl(impl) {
|
GraphBuilder(Impl &impl) : m_impl(impl) {
|
||||||
Map *pMap = NULL;
|
Map *pMap = nullptr;
|
||||||
Sequence *pSeq = NULL;
|
Sequence *pSeq = nullptr;
|
||||||
Node *pNode = NULL;
|
Node *pNode = nullptr;
|
||||||
|
|
||||||
// Type consistency checks
|
// Type consistency checks
|
||||||
pNode = pMap;
|
pNode = pMap;
|
||||||
|
@@ -119,7 +119,7 @@ class node {
|
|||||||
template <typename Key>
|
template <typename Key>
|
||||||
node* get(const Key& key, shared_memory_holder pMemory) const {
|
node* get(const Key& key, shared_memory_holder pMemory) const {
|
||||||
// NOTE: this returns a non-const node so that the top-level Node can wrap
|
// NOTE: this returns a non-const node so that the top-level Node can wrap
|
||||||
// it, and returns a pointer so that it can be NULL (if there is no such
|
// it, and returns a pointer so that it can be nullptr (if there is no such
|
||||||
// key).
|
// key).
|
||||||
return static_cast<const node_ref&>(*m_pRef).get(key, pMemory);
|
return static_cast<const node_ref&>(*m_pRef).get(key, pMemory);
|
||||||
}
|
}
|
||||||
@@ -136,7 +136,7 @@ class node {
|
|||||||
|
|
||||||
node* get(node& key, shared_memory_holder pMemory) const {
|
node* get(node& key, shared_memory_holder pMemory) const {
|
||||||
// NOTE: this returns a non-const node so that the top-level Node can wrap
|
// NOTE: this returns a non-const node so that the top-level Node can wrap
|
||||||
// it, and returns a pointer so that it can be NULL (if there is no such
|
// it, and returns a pointer so that it can be nullptr (if there is no such
|
||||||
// key).
|
// key).
|
||||||
return static_cast<const node_ref&>(*m_pRef).get(key, pMemory);
|
return static_cast<const node_ref&>(*m_pRef).get(key, pMemory);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user