diff options
author | Thomas Habets <thomas@habets.se> | 2020-03-14 12:01:44 +0000 |
---|---|---|
committer | Michael Dickens <michael.dickens@ettus.com> | 2020-04-01 11:44:45 -0400 |
commit | 7a9169fe8cca1cb378be0d0d403e03a338ffbfda (patch) | |
tree | fef77ae9c34538b78e4172580cb5ecdc24d40134 /gr-utils/python | |
parent | 82262753a56d15cfa6343044c726cf0035c38d9c (diff) |
Switch from boost pointers to std C++11 pointers
Most of this code is automated code changes:
```
set -e
SUB="s/dummy/dummy/"
for i in shared_ptr make_shared dynamic_pointer_cast weak_ptr enable_shared_from_this get_deleter; do
SUB="$SUB;s/boost::$i/std::$i/g"
done
SUB="$SUB;s^#include <boost/shared_ptr.hpp>^#include <memory>^g"
SUB="$SUB;s^namespace boost^namespace std^g"
find . \( -name "*.cc" -o -name "*.h" -o -name "*.i" -o -name "*.cxx" -o -name "*.py" \) -print0 | xargs -0 sed -i "$SUB"
```
Only one manual change. In `./gr-fec/lib/fec_mtrx_impl.cc`, add
`#include <algorithm>`.
Diffstat (limited to 'gr-utils/python')
-rw-r--r-- | gr-utils/python/modtool/templates/templates.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gr-utils/python/modtool/templates/templates.py b/gr-utils/python/modtool/templates/templates.py index a3a84ecda0..fe799cd026 100644 --- a/gr-utils/python/modtool/templates/templates.py +++ b/gr-utils/python/modtool/templates/templates.py @@ -275,7 +275,7 @@ namespace gr { class ${modname.upper()}_API ${blockname} : virtual public gr::${grblocktype} { public: - typedef boost::shared_ptr<${blockname}> sptr; + typedef std::shared_ptr<${blockname}> sptr; /*! * \brief Return a shared_ptr to a new instance of ${modname}::${blockname}. @@ -712,7 +712,7 @@ class ${modname.upper()}_API ${blockname} class ${modname}_${blockname}; -typedef boost::shared_ptr<${modname}_${blockname}> ${modname}_${blockname}_sptr; +typedef std::shared_ptr<${modname}_${blockname}> ${modname}_${blockname}_sptr; ${modname.upper()}_API ${modname}_${blockname}_sptr ${modname}_make_${blockname} (${arglist}); |