boost::property_tree::ordered_end() 缺失

boost::property_tree::ordered_end() missing

我正在尝试迭代 boost 属性 树。 docs 表示

You can get an ordered view of all children by using ordered_begin() and ordered_end().

然而,当我写

for ( boost::property_tree::ptree::const_assoc_iterator it =
            myPropTree.ordered_begin();
    it != myPropTree.ordered_end();
    it++ )

编译器报错

error: 'boost::property_tree::ptree' has no member named 'ordered_end'
升压 v1.55
明威
code::blocks

The ptree documentation says:

assoc_iterator ordered_begin();

Returns an iterator to the first child, in key order.

const_assoc_iterator ordered_begin() const;

Returns an iterator to the first child, in key order.

assoc_iterator not_found();

Returns the not-found iterator. Equivalent to end() in a real associative container.

const_assoc_iterator not_found() const;

Returns the not-found iterator. Equivalent to end() in a real associative container.

所以基本上 ordered_end 函数被调用 not_found