# Compilation error with boost 1.77

**URL:** https://discourse.gplates.org/t/compilation-error-with-boost-1-77/452
**Category:** Bug Reports
**Created:** [20 December 2021 22:43 UTC](https://discourse.gplates.org/t/compilation-error-with-boost-1-77/452 "2021-12-20T22:43:51Z")
**Posts on this page:** 1
**Showing post:** 1

<div class="post-metadata">

### Author: ![dotlambda](https://discourse.gplates.org/letter_avatar_proxy/v4/letter/d/b487fb/32.png) [@dotlambda](https://discourse.gplates.org/u/dotlambda)
#### Post date: [20 December 2021 22:43 UTC](https://discourse.gplates.org/t/compilation-error-with-boost-1-77/452/1 "2021-12-20T22:43:52Z")

</div>

After upgrading to boost 1.77, GPlates fails to compile with

```auto
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc: In member function 'boost::optional< __gnu_cxx::__ normal_iterator<const GPlatesGui::TopologyTools::VisibleSection*, std::vector<GPlatesGui::TopologyTools::VisibleSection> > > GPlatesGui::TopologyTools::is_section_visible_boundary(std::vector<GPlatesGui::TopologyTools::SectionInfo>::size_type) const':
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc:3451: error: '_1' was not declared in this scope
 3451 | boost::bind(&VisibleSection::d_section_info_index, _1) ==
      | 
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc:3451: note: suggested alternatives:
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/utility/compare_pointees.hpp:15,
                 from include/boost/optional/optional.hpp:55,
                 from include/boost/optional.hpp:15,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:38:
/nix/store/v819nrv8d33ns36gm4v9vqydq1v95axi-gcc-10.3.0/include/c++/10.3.0/functional:221:34: note: 'std::placeholders::_1'
  221 | extern const _Placeholder<1> _1;
      | ^~
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/bind/bind.hpp:2336,
                 from /build/gplates_2.3.0_src/src/utils/ReferenceCount.h:29,
                 from /build/gplates_2.3.0_src/src/model/WeakReferenceCallback.h:35,
                 from /build/gplates_2.3.0_src/src/model/WeakReference.h:37,
                 from /build/gplates_2.3.0_src/src/model/Model.h:29,
                 from /build/gplates_2.3.0_src/src/model/BasicHandle.h:39,
                 from /build/gplates_2.3.0_src/src/model/FeatureHandle.h:35,
                 from /build/gplates_2.3.0_src/src/gui/TopologySectionsContainer.h:37,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.h:37,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:54:
include/boost/bind/placeholders.hpp:58:38: note: 'boost::placeholders::_1'
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/lambda/bind.hpp:15,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:35:
include/boost/lambda/core.hpp:71:60: note: 'boost::lambda::{anonymous}::_1'
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc: In member function 'boost::optional< __gnu_cxx::__ normal_iterator<const GPlatesGui::TopologyTools::VisibleSection*, std::vector<GPlatesGui::TopologyTools::VisibleSection> > > GPlatesGui::TopologyTools::is_section_visible_interior(std::vector<GPlatesGui::TopologyTools::SectionInfo>::size_type) const':
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc:3470: error: '_1' was not declared in this scope
 3470 | boost::bind(&VisibleSection::d_section_info_index, _1) ==
      | 
/build/gplates_2.3.0_src/src/gui/TopologyTools.cc:3470: note: suggested alternatives:
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/utility/compare_pointees.hpp:15,
                 from include/boost/optional/optional.hpp:55,
                 from include/boost/optional.hpp:15,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:38:
/nix/store/v819nrv8d33ns36gm4v9vqydq1v95axi-gcc-10.3.0/include/c++/10.3.0/functional:221:34: note: 'std::placeholders::_1'
  221 | extern const _Placeholder<1> _1;
      | ^~
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/bind/bind.hpp:2336,
                 from /build/gplates_2.3.0_src/src/utils/ReferenceCount.h:29,
                 from /build/gplates_2.3.0_src/src/model/WeakReferenceCallback.h:35,
                 from /build/gplates_2.3.0_src/src/model/WeakReference.h:37,
                 from /build/gplates_2.3.0_src/src/model/Model.h:29,
                 from /build/gplates_2.3.0_src/src/model/BasicHandle.h:39,
                 from /build/gplates_2.3.0_src/src/model/FeatureHandle.h:35,
                 from /build/gplates_2.3.0_src/src/gui/TopologySectionsContainer.h:37,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.h:37,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:54:
include/boost/bind/placeholders.hpp:58:38: note: 'boost::placeholders::_1'
In file included from include/boost/mpl/aux_/include_preprocessed.hpp:37,
                 from include/boost/mpl/placeholders.hpp:43,
                 from include/boost/iterator/iterator_categories.hpp:16,
                 from include/boost/iterator/iterator_adaptor.hpp:14,
                 from include/boost/iterator/reverse_iterator.hpp:10,
                 from include/boost/range/reverse_iterator.hpp:21,
                 from include/boost/range/rend.hpp:19,
                 from include/boost/foreach.hpp:82,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:33:
include/boost/mpl/aux_/preprocessed/gcc/placeholders.hpp:29:16: note: 'mpl_::_1'
In file included from include/boost/lambda/bind.hpp:15,
                 from /build/gplates_2.3.0_src/src/gui/TopologyTools.cc:35:
include/boost/lambda/core.hpp:71:60: note: 'boost::lambda::{anonymous}::_1'
make[2]: *** [src/CMakeFiles/gplates-lib.dir/build.make:6210: src/CMakeFiles/gplates-lib.dir/gui/TopologyTools.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:591: src/CMakeFiles/gplates-lib.dir/all] Error 2
make: *** [Makefile:156: all] Error 2

```

---

_[View the full topic](https://discourse.gplates.org/t/compilation-error-with-boost-1-77/452)._
