Hello community,

here is the log from the commit of package yaml-cpp for openSUSE:Factory 
checked in at 2016-02-17 10:25:10
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yaml-cpp (Old)
 and      /work/SRC/openSUSE:Factory/.yaml-cpp.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yaml-cpp"

Changes:
--------
--- /work/SRC/openSUSE:Factory/yaml-cpp/yaml-cpp.changes        2015-11-16 
18:51:30.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.yaml-cpp.new/yaml-cpp.changes   2016-02-17 
12:26:48.000000000 +0100
@@ -1,0 +2,9 @@
+Fri Feb 12 21:14:16 UTC 2016 - [email protected]
+
+- Update to 0.5.3
+  * Bugfix release.
+  * This will be the last release that does not require C++11.
+- Drop upstreamed fix-node-regression.patch
+- Small spec file cleanups
+
+-------------------------------------------------------------------

Old:
----
  fix-node-regression.patch
  yaml-cpp-0.5.2.tar.gz

New:
----
  yaml-cpp-0.5.3.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ yaml-cpp.spec ++++++
--- /var/tmp/diff_new_pack.STFFkU/_old  2016-02-17 12:26:49.000000000 +0100
+++ /var/tmp/diff_new_pack.STFFkU/_new  2016-02-17 12:26:49.000000000 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package yaml-cpp
 #
-# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -17,16 +17,14 @@
 
 
 %define library_name libyaml-cpp0_5
-
 Name:           yaml-cpp
-Version:        0.5.2
+Version:        0.5.3
 Release:        0
 Summary:        YAML parser and emitter in C++
 License:        MIT
 Group:          Development/Libraries/C and C++
 Url:            https://github.com/jbeder/yaml-cpp/
 Source:         
https://github.com/jbeder/yaml-cpp/archive/release-%{version}/%{name}-%{version}.tar.gz
-Patch0:         fix-node-regression.patch
 BuildRequires:  boost-devel
 BuildRequires:  cmake
 BuildRequires:  gcc
@@ -55,30 +53,28 @@
 Development files for %{name} library.
 
 %prep
-%setup -qn %{name}-release-%{version}
-%patch0 -p1
+%setup -q -n %{name}-release-%{version}
 
 %build
-%cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ../
-make VERBOSE=1 %{?_smp_mflags}
+%cmake \
+  -DCMAKE_BUILD_TYPE=RelWithDebInfo
+make %{?_smp_mflags}
 
 %install
-cd build
-%makeinstall
+%cmake_install
 
 %post -n %{library_name} -p /sbin/ldconfig
-
 %postun -n %{library_name} -p /sbin/ldconfig
 
 %files -n %{library_name}
 %defattr(-,root,root,-)
-%doc license.txt
-%{_libdir}/lib*.so.*
+%doc LICENSE
+%{_libdir}/libyaml-cpp.so.*
 
 %files devel
 %defattr(-,root,root,-)
 %{_includedir}/yaml-cpp/
-%{_libdir}/lib*.so
-%{_libdir}/pkgconfig/*.pc
+%{_libdir}/libyaml-cpp.so
+%{_libdir}/pkgconfig/yaml-cpp.pc
 
 %changelog

++++++ yaml-cpp-0.5.2.tar.gz -> yaml-cpp-0.5.3.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/.gitignore 
new/yaml-cpp-release-0.5.3/.gitignore
--- old/yaml-cpp-release-0.5.2/.gitignore       1970-01-01 01:00:00.000000000 
+0100
+++ new/yaml-cpp-release-0.5.3/.gitignore       2016-01-10 19:11:40.000000000 
+0100
@@ -0,0 +1 @@
+build/
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/.hgeol 
new/yaml-cpp-release-0.5.3/.hgeol
--- old/yaml-cpp-release-0.5.2/.hgeol   2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/.hgeol   1970-01-01 01:00:00.000000000 +0100
@@ -1,4 +0,0 @@
-**.h = native
-**.c = native
-**.cpp = native
-**.txt = native
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/.hgignore 
new/yaml-cpp-release-0.5.3/.hgignore
--- old/yaml-cpp-release-0.5.2/.hgignore        2015-03-30 04:31:56.000000000 
+0200
+++ new/yaml-cpp-release-0.5.3/.hgignore        1970-01-01 01:00:00.000000000 
+0100
@@ -1 +0,0 @@
-syntax: glob
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/CMakeLists.txt 
new/yaml-cpp-release-0.5.3/CMakeLists.txt
--- old/yaml-cpp-release-0.5.2/CMakeLists.txt   2015-03-30 04:31:56.000000000 
+0200
+++ new/yaml-cpp-release-0.5.3/CMakeLists.txt   2016-01-10 19:11:40.000000000 
+0100
@@ -23,7 +23,7 @@
 
 set(YAML_CPP_VERSION_MAJOR "0")
 set(YAML_CPP_VERSION_MINOR "5")
-set(YAML_CPP_VERSION_PATCH "2")
+set(YAML_CPP_VERSION_PATCH "3")
 set(YAML_CPP_VERSION 
"${YAML_CPP_VERSION_MAJOR}.${YAML_CPP_VERSION_MINOR}.${YAML_CPP_VERSION_PATCH}")
 
 enable_testing()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/CONTRIBUTING.md 
new/yaml-cpp-release-0.5.3/CONTRIBUTING.md
--- old/yaml-cpp-release-0.5.2/CONTRIBUTING.md  1970-01-01 01:00:00.000000000 
+0100
+++ new/yaml-cpp-release-0.5.3/CONTRIBUTING.md  2016-01-10 19:11:40.000000000 
+0100
@@ -0,0 +1,17 @@
+# Style
+
+This project is formatted with [clang-format][fmt] using the style file at the 
root of the repository. Please run clang-format before sending a pull request.
+
+In general, try to follow the style of surrounding code.
+
+[fmt]: http://clang.llvm.org/docs/ClangFormat.html
+
+# Tests
+
+Please verify the tests pass by running the target `tests/run_tests`.
+
+If you are adding functionality, add tests accordingly.
+
+# Pull request process
+
+Every pull request undergoes a code review. Unfortunately, github's code 
review process isn't great, but we'll manage. During the code review, if you 
make changes, add new commits to the pull request for each change. Once the 
code review is complete, rebase against the master branch and squash into a 
single commit.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/LICENSE 
new/yaml-cpp-release-0.5.3/LICENSE
--- old/yaml-cpp-release-0.5.2/LICENSE  1970-01-01 01:00:00.000000000 +0100
+++ new/yaml-cpp-release-0.5.3/LICENSE  2016-01-10 19:11:40.000000000 +0100
@@ -0,0 +1,19 @@
+Copyright (c) 2008-2015 Jesse Beder.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/README.md 
new/yaml-cpp-release-0.5.3/README.md
--- old/yaml-cpp-release-0.5.2/README.md        1970-01-01 01:00:00.000000000 
+0100
+++ new/yaml-cpp-release-0.5.3/README.md        2016-01-10 19:11:40.000000000 
+0100
@@ -0,0 +1,52 @@
+# yaml-cpp
+
+yaml-cpp is a [YAML](http://www.yaml.org/) parser and emitter in C++ matching 
the [YAML 1.2 spec](http://www.yaml.org/spec/1.2/spec.html).
+
+To get a feel for how it can be used, see the 
[Tutorial](https://github.com/jbeder/yaml-cpp/wiki/Tutorial) or [How to Emit 
YAML](https://github.com/jbeder/yaml-cpp/wiki/How-To-Emit-YAML). For the old 
API (version < 0.5.0), see [How To Parse A 
Document](https://github.com/jbeder/yaml-cpp/wiki/How-To-Parse-A-Document-(Old-API)).
+
+
+# Problems? #
+
+If you find a bug, post an [issue](https://github.com/jbeder/yaml-cpp/issues)! 
If you have questions about how to use yaml-cpp, please post it on 
http://stackoverflow.com and tag it `yaml-cpp`.
+
+# How to Build #
+
+yaml-cpp uses [CMake](http://www.cmake.org) to support cross-platform 
building. The basic steps to build are:
+
+1. Download and install [CMake](http://www.cmake.org) (Resources -> Download).
+
+**Note:** If you don't use the provided installer for your platform, make sure 
that you add CMake's bin folder to your path.
+
+2. Navigate into the source directory, and type:
+
+```
+mkdir build
+cd build
+```
+
+3. Run CMake. The basic syntax is:
+
+```
+cmake [-G generator] [-DBUILD_SHARED_LIBS=ON|OFF] ..
+```
+
+  * The `generator` is whatever type of build system you'd like to use. To see 
a full list of generators on your platform, just run `cmake` (with no 
arguments). For example:
+    * On Windows, you might use "Visual Studio 12 2013" to generate a Visual 
Studio 2013 solution
+    * On OS X, you might use "Xcode" to generate an Xcode project
+    * On a UNIX-y system, simply omit the option to generate a makefile
+
+  * yaml-cpp defaults to building a static library, but you may build a shared 
library by specifying `-DBUILD_SHARED_LIBS=ON`.
+
+  * For more options on customizing the build, see the 
[CMakeLists.txt](https://github.com/jbeder/yaml-cpp/blob/master/CMakeLists.txt) 
file.
+
+4. Build it!
+
+5. To clean up, just remove the `build` directory.
+
+# Recent Release #
+
+[yaml-cpp 
0.5.2](https://github.com/jbeder/yaml-cpp/releases/tag/release-0.5.2) has been 
released! This is a bug fix release.
+
+[yaml-cpp 
0.3.0](https://github.com/jbeder/yaml-cpp/releases/tag/release-0.3.0) is still 
available if you want the old API.
+
+**The old API will continue to be supported, and will still receive 
bugfixes!** The 0.3.x and 0.4.x versions will be old API releases, and 0.5.x 
and above will all be new API releases.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/include/yaml-cpp/exceptions.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/exceptions.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/exceptions.h    2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/exceptions.h    2016-01-10 
19:11:40.000000000 +0100
@@ -120,6 +120,10 @@
  private:
   static const std::string build_what(const Mark& mark,
                                       const std::string& msg) {
+    if (mark.is_null()) {
+      return msg.c_str();
+    }
+
     std::stringstream output;
     output << "yaml-cpp: error at line " << mark.line + 1 << ", column "
            << mark.column + 1 << ": " << msg;
@@ -178,14 +182,14 @@
 
 class BadConversion : public RepresentationException {
  public:
-  BadConversion()
-      : RepresentationException(Mark::null_mark(), ErrorMsg::BAD_CONVERSION) {}
+  explicit BadConversion(const Mark& mark_)
+      : RepresentationException(mark_, ErrorMsg::BAD_CONVERSION) {}
 };
 
 template <typename T>
 class TypedBadConversion : public BadConversion {
  public:
-  TypedBadConversion() : BadConversion() {}
+  explicit TypedBadConversion(const Mark& mark_) : BadConversion(mark_) {}
 };
 
 class BadDereference : public RepresentationException {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/include/yaml-cpp/mark.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/mark.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/mark.h  2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/mark.h  2016-01-10 
19:11:40.000000000 +0100
@@ -15,6 +15,8 @@
 
   static const Mark null_mark() { return Mark(-1, -1, -1); }
 
+  bool is_null() const { return pos == -1 && line == -1 && column == -1; }
+
   int pos;
   int line, column;
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/convert.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/convert.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/convert.h  2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/convert.h  2016-01-10 
19:11:40.000000000 +0100
@@ -43,6 +43,17 @@
 }
 }
 
+// Node
+template <>
+struct convert<Node> {
+  static Node encode(const Node& rhs) { return rhs; }
+
+  static bool decode(const Node& node, Node& rhs) {
+    rhs.reset(node);
+    return true;
+  }
+};
+
 // std::string
 template <>
 struct convert<std::string> {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/impl.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/impl.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/impl.h      
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/impl.h      
2016-01-10 19:11:40.000000000 +0100
@@ -133,7 +133,7 @@
     return false;
 
   for (node_map::iterator it = m_map.begin(); it != m_map.end(); ++it) {
-    if (equals(*it->first, key, pMemory)) {
+    if (it->first->equals(key, pMemory)) {
       m_map.erase(it);
       return true;
     }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/memory.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/memory.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/memory.h    
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/memory.h    
2016-01-10 19:11:40.000000000 +0100
@@ -7,8 +7,6 @@
 #pragma once
 #endif
 
-#include <boost/shared_ptr.hpp>
-#include <boost/smart_ptr/shared_ptr.hpp>
 #include <set>
 
 #include "yaml-cpp/dll.h"
@@ -40,7 +38,7 @@
   void merge(memory_holder& rhs);
 
  private:
-  boost::shared_ptr<memory> m_pMemory;
+  shared_memory m_pMemory;
 };
 }
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node.h      
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node.h      
2016-01-10 19:11:40.000000000 +0100
@@ -25,6 +25,7 @@
   const node_ref* ref() const { return m_pRef.get(); }
 
   bool is_defined() const { return m_pRef->is_defined(); }
+  const Mark& mark() const { return m_pRef->mark(); }
   NodeType::value type() const { return m_pRef->type(); }
 
   const std::string& scalar() const { return m_pRef->scalar(); }
@@ -64,6 +65,10 @@
     m_pRef->set_data(*rhs.m_pRef);
   }
 
+  void set_mark(const Mark& mark) {
+    m_pRef->set_mark(mark);
+  }
+
   void set_type(NodeType::value type) {
     if (type != NodeType::Undefined)
       mark_defined();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node_data.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node_data.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node_data.h 
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node_data.h 
2016-01-10 19:11:40.000000000 +0100
@@ -34,6 +34,7 @@
   node_data();
 
   void mark_defined();
+  void set_mark(const Mark& mark);
   void set_type(NodeType::value type);
   void set_tag(const std::string& tag);
   void set_null();
@@ -41,6 +42,7 @@
   void set_style(EmitterStyle::value style);
 
   bool is_defined() const { return m_isDefined; }
+  const Mark& mark() const { return m_mark; }
   NodeType::value type() const {
     return m_isDefined ? m_type : NodeType::Undefined;
   }
@@ -97,6 +99,7 @@
 
  private:
   bool m_isDefined;
+  Mark m_mark;
   NodeType::value m_type;
   std::string m_tag;
   EmitterStyle::value m_style;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node_ref.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node_ref.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/detail/node_ref.h  
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/detail/node_ref.h  
2016-01-10 19:11:40.000000000 +0100
@@ -20,6 +20,7 @@
   node_ref() : m_pData(new node_data) {}
 
   bool is_defined() const { return m_pData->is_defined(); }
+  const Mark& mark() const { return m_pData->mark(); }
   NodeType::value type() const { return m_pData->type(); }
   const std::string& scalar() const { return m_pData->scalar(); }
   const std::string& tag() const { return m_pData->tag(); }
@@ -28,6 +29,7 @@
   void mark_defined() { m_pData->mark_defined(); }
   void set_data(const node_ref& rhs) { m_pData = rhs.m_pData; }
 
+  void set_mark(const Mark& mark) { m_pData->set_mark(mark); }
   void set_type(NodeType::value type) { m_pData->set_type(type); }
   void set_tag(const std::string& tag) { m_pData->set_tag(tag); }
   void set_null() { m_pData->set_null(); }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/impl.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/impl.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/impl.h     2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/impl.h     2016-01-10 
19:11:40.000000000 +0100
@@ -66,6 +66,13 @@
   return m_pNode ? m_pNode->is_defined() : true;
 }
 
+inline Mark Node::Mark() const {
+  if (!m_isValid) {
+    throw InvalidNode();
+  }
+  return m_pNode ? m_pNode->mark() : Mark::null_mark();
+}
+
 inline NodeType::value Node::Type() const {
   if (!m_isValid)
     throw InvalidNode();
@@ -80,7 +87,7 @@
   explicit as_if(const Node& node_) : node(node_) {}
   const Node& node;
 
-  const T operator()(const S& fallback) const {
+  T operator()(const S& fallback) const {
     if (!node.m_pNode)
       return fallback;
 
@@ -110,12 +117,12 @@
 
   const T operator()() const {
     if (!node.m_pNode)
-      throw TypedBadConversion<T>();
+      throw TypedBadConversion<T>(node.Mark());
 
     T t;
     if (convert<T>::decode(node, t))
       return t;
-    throw TypedBadConversion<T>();
+    throw TypedBadConversion<T>(node.Mark());
   }
 };
 
@@ -126,23 +133,23 @@
 
   const std::string operator()() const {
     if (node.Type() != NodeType::Scalar)
-      throw TypedBadConversion<std::string>();
+      throw TypedBadConversion<std::string>(node.Mark());
     return node.Scalar();
   }
 };
 
 // access functions
 template <typename T>
-inline const T Node::as() const {
+inline T Node::as() const {
   if (!m_isValid)
     throw InvalidNode();
   return as_if<T, void>(*this)();
 }
 
 template <typename T, typename S>
-inline const T Node::as(const S& fallback) const {
+inline T Node::as(const S& fallback) const {
   if (!m_isValid)
-    throw InvalidNode();
+    return fallback;
   return as_if<T, S>(*this)(fallback);
 }
 
@@ -275,26 +282,26 @@
 
 inline const_iterator Node::begin() const {
   if (!m_isValid)
-    throw InvalidNode();
+    return const_iterator();
   return m_pNode ? const_iterator(m_pNode->begin(), m_pMemory)
                  : const_iterator();
 }
 
 inline iterator Node::begin() {
   if (!m_isValid)
-    throw InvalidNode();
+    return iterator();
   return m_pNode ? iterator(m_pNode->begin(), m_pMemory) : iterator();
 }
 
 inline const_iterator Node::end() const {
   if (!m_isValid)
-    throw InvalidNode();
+    return const_iterator();
   return m_pNode ? const_iterator(m_pNode->end(), m_pMemory) : 
const_iterator();
 }
 
 inline iterator Node::end() {
   if (!m_isValid)
-    throw InvalidNode();
+    return iterator();
   return m_pNode ? iterator(m_pNode->end(), m_pMemory) : iterator();
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/node.h 
new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/node.h
--- old/yaml-cpp-release-0.5.2/include/yaml-cpp/node/node.h     2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/include/yaml-cpp/node/node.h     2016-01-10 
19:11:40.000000000 +0100
@@ -11,6 +11,7 @@
 
 #include "yaml-cpp/dll.h"
 #include "yaml-cpp/emitterstyle.h"
+#include "yaml-cpp/mark.h"
 #include "yaml-cpp/node/detail/bool_type.h"
 #include "yaml-cpp/node/detail/iterator_fwd.h"
 #include "yaml-cpp/node/ptr.h"
@@ -48,6 +49,7 @@
   Node(const Node& rhs);
   ~Node();
 
+  YAML::Mark Mark() const;
   NodeType::value Type() const;
   bool IsDefined() const;
   bool IsNull() const { return Type() == NodeType::Null; }
@@ -61,9 +63,9 @@
 
   // access
   template <typename T>
-  const T as() const;
+  T as() const;
   template <typename T, typename S>
-  const T as(const S& fallback) const;
+  T as(const S& fallback) const;
   const std::string& Scalar() const;
 
   const std::string& Tag() const;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/license.txt 
new/yaml-cpp-release-0.5.3/license.txt
--- old/yaml-cpp-release-0.5.2/license.txt      2015-03-30 04:31:56.000000000 
+0200
+++ new/yaml-cpp-release-0.5.3/license.txt      1970-01-01 01:00:00.000000000 
+0100
@@ -1,19 +0,0 @@
-Copyright (c) 2008 Jesse Beder.
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/src/emitterutils.cpp 
new/yaml-cpp-release-0.5.3/src/emitterutils.cpp
--- old/yaml-cpp-release-0.5.2/src/emitterutils.cpp     2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/src/emitterutils.cpp     2016-01-10 
19:11:40.000000000 +0100
@@ -375,14 +375,16 @@
 bool WriteChar(ostream_wrapper& out, char ch) {
   if (('a' <= ch && ch <= 'z') || ('A' <= ch && ch <= 'Z')) {
     out << ch;
-  } else if ((0x20 <= ch && ch <= 0x7e) || ch == ' ') {
-    out << "\"" << ch << "\"";
+  } else if (ch == '\"') {
+    out << "\"\\\"\"";
   } else if (ch == '\t') {
     out << "\"\\t\"";
   } else if (ch == '\n') {
     out << "\"\\n\"";
   } else if (ch == '\b') {
     out << "\"\\b\"";
+  } else if ((0x20 <= ch && ch <= 0x7e) || ch == ' ') {
+    out << "\"" << ch << "\"";
   } else {
     out << "\"";
     WriteDoubleQuoteEscapeSequence(out, ch);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/src/node_data.cpp 
new/yaml-cpp-release-0.5.3/src/node_data.cpp
--- old/yaml-cpp-release-0.5.2/src/node_data.cpp        2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/src/node_data.cpp        2016-01-10 
19:11:40.000000000 +0100
@@ -17,6 +17,7 @@
 
 node_data::node_data()
     : m_isDefined(false),
+      m_mark(Mark::null_mark()),
       m_type(NodeType::Null),
       m_style(EmitterStyle::Default),
       m_seqSize(0) {}
@@ -27,6 +28,10 @@
   m_isDefined = true;
 }
 
+void node_data::set_mark(const Mark& mark) {
+  m_mark = mark;
+}
+
 void node_data::set_type(NodeType::value type) {
   if (type == NodeType::Undefined) {
     m_type = type;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/src/nodebuilder.cpp 
new/yaml-cpp-release-0.5.3/src/nodebuilder.cpp
--- old/yaml-cpp-release-0.5.2/src/nodebuilder.cpp      2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/src/nodebuilder.cpp      2016-01-10 
19:11:40.000000000 +0100
@@ -28,8 +28,8 @@
 
 void NodeBuilder::OnDocumentEnd() {}
 
-void NodeBuilder::OnNull(const Mark& /* mark */, anchor_t anchor) {
-  detail::node& node = Push(anchor);
+void NodeBuilder::OnNull(const Mark& mark, anchor_t anchor) {
+  detail::node& node = Push(mark, anchor);
   node.set_null();
   Pop();
 }
@@ -40,18 +40,18 @@
   Pop();
 }
 
-void NodeBuilder::OnScalar(const Mark& /* mark */, const std::string& tag,
+void NodeBuilder::OnScalar(const Mark& mark, const std::string& tag,
                            anchor_t anchor, const std::string& value) {
-  detail::node& node = Push(anchor);
+  detail::node& node = Push(mark, anchor);
   node.set_scalar(value);
   node.set_tag(tag);
   Pop();
 }
 
-void NodeBuilder::OnSequenceStart(const Mark& /* mark */,
+void NodeBuilder::OnSequenceStart(const Mark& mark,
                                   const std::string& tag, anchor_t anchor,
                                   EmitterStyle::value style) {
-  detail::node& node = Push(anchor);
+  detail::node& node = Push(mark, anchor);
   node.set_tag(tag);
   node.set_type(NodeType::Sequence);
   node.set_style(style);
@@ -59,9 +59,9 @@
 
 void NodeBuilder::OnSequenceEnd() { Pop(); }
 
-void NodeBuilder::OnMapStart(const Mark& /* mark */, const std::string& tag,
+void NodeBuilder::OnMapStart(const Mark& mark, const std::string& tag,
                              anchor_t anchor, EmitterStyle::value style) {
-  detail::node& node = Push(anchor);
+  detail::node& node = Push(mark, anchor);
   node.set_type(NodeType::Map);
   node.set_tag(tag);
   node.set_style(style);
@@ -74,8 +74,9 @@
   Pop();
 }
 
-detail::node& NodeBuilder::Push(anchor_t anchor) {
+detail::node& NodeBuilder::Push(const Mark& mark, anchor_t anchor) {
   detail::node& node = m_pMemory->create_node();
+  node.set_mark(mark);
   RegisterAnchor(anchor, node);
   Push(node);
   return node;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/src/nodebuilder.h 
new/yaml-cpp-release-0.5.3/src/nodebuilder.h
--- old/yaml-cpp-release-0.5.2/src/nodebuilder.h        2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/src/nodebuilder.h        2016-01-10 
19:11:40.000000000 +0100
@@ -48,7 +48,7 @@
   virtual void OnMapEnd();
 
  private:
-  detail::node& Push(anchor_t anchor);
+  detail::node& Push(const Mark& mark, anchor_t anchor);
   void Push(detail::node& node);
   void Pop();
   void RegisterAnchor(anchor_t anchor, detail::node& node);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/yaml-cpp-release-0.5.2/test/integration/emitter_test.cpp 
new/yaml-cpp-release-0.5.3/test/integration/emitter_test.cpp
--- old/yaml-cpp-release-0.5.2/test/integration/emitter_test.cpp        
2015-03-30 04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/test/integration/emitter_test.cpp        
2016-01-10 19:11:40.000000000 +0100
@@ -962,6 +962,14 @@
   ExpectEmit("\"null\"");
 }
 
+TEST_F(EmitterTest, ValueOfDoubleQuote) {
+  out << YAML::BeginMap;
+  out << YAML::Key << "foo" << YAML::Value << '"';
+  out << YAML::EndMap;
+
+  ExpectEmit("foo: \"\\\"\"");
+}
+
 class EmitterErrorTest : public ::testing::Test {
  protected:
   void ExpectEmitError(const std::string& expectedError) {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/yaml-cpp-release-0.5.2/test/node/node_test.cpp 
new/yaml-cpp-release-0.5.3/test/node/node_test.cpp
--- old/yaml-cpp-release-0.5.2/test/node/node_test.cpp  2015-03-30 
04:31:56.000000000 +0200
+++ new/yaml-cpp-release-0.5.3/test/node/node_test.cpp  2016-01-10 
19:11:40.000000000 +0100
@@ -39,6 +39,13 @@
   EXPECT_TRUE(node.IsSequence());
 }
 
+TEST(NodeTest, MapElementRemoval) {
+  Node node;
+  node["foo"] = "bar";
+  node.remove("foo");
+  EXPECT_TRUE(!node["foo"]);
+}
+
 TEST(NodeTest, SimpleAssignSequence) {
   Node node;
   node[0] = 10;
@@ -73,6 +80,31 @@
   EXPECT_EQ(2, node.size());
 }
 
+TEST(NodeTest, MapForceInsert) {
+  Node node;
+  Node k1("k1");
+  Node k2("k2");
+  Node v1("v1");
+  Node v2("v2");
+  node[k1] = v1;
+  node[k2] = v1;
+  EXPECT_TRUE(node.IsMap());
+  EXPECT_EQ("v1", node["k1"].as<std::string>());
+  EXPECT_EQ("v1", node["k2"].as<std::string>());
+  EXPECT_EQ(2, node.size());
+
+  node.force_insert(k2, v2);
+  EXPECT_EQ("v1", node["k1"].as<std::string>());
+  EXPECT_EQ("v2", node["k2"].as<std::string>());
+  EXPECT_EQ(2, node.size());
+}
+
+TEST(NodeTest, UndefinedConstNodeWithFallback) {
+  Node node;
+  const Node& cn = node;
+  EXPECT_EQ(cn["undefined"].as<int>(3), 3);
+}
+
 TEST(NodeTest, MapIteratorWithUndefinedValues) {
   Node node;
   node["key"] = "value";
@@ -84,6 +116,32 @@
   EXPECT_EQ(1, count);
 }
 
+TEST(NodeTest, ConstIteratorOnConstUndefinedNode) {
+  Node node;
+  const Node& cn = node;
+  const Node& undefinedCn = cn["undefined"];
+
+  std::size_t count = 0;
+  for (const_iterator it = undefinedCn.begin(); it != undefinedCn.end(); ++it) 
{
+    count++;
+ }
+  EXPECT_EQ(0, count);
+}
+
+TEST(NodeTest, IteratorOnConstUndefinedNode) {
+  Node node;
+  const Node& cn = node;
+  const Node& undefinedCn = cn["undefined"];
+
+  Node& nonConstUndefinedNode = const_cast<Node&>(undefinedCn);
+
+  std::size_t count = 0;
+  for (iterator it = nonConstUndefinedNode.begin(); it != 
nonConstUndefinedNode.end(); ++it) {
+    count++;
+  }
+  EXPECT_EQ(0, count);
+}
+
 TEST(NodeTest, SimpleSubkeys) {
   Node node;
   node["device"]["udid"] = "12345";


Reply via email to