From: Angus Leeming Date: Sun, 2 Sep 2001 14:43:59 +0000 (+0000) Subject: Hacky fix for the boost::tie stuff. X-Git-Tag: 1.6.10~20689 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=3a0b382ba7b476f6b377eccf9abd8b44883d00d2;p=features.git Hacky fix for the boost::tie stuff. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2657 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/ChangeLog b/src/ChangeLog index 1cc42bcf86..b7f543d172 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -5,6 +5,9 @@ 2001-09-02 Angus Leeming + * buffer.C (getLists): replace boost::tie code with an explicit pair + as boost::tie can break some compilers. + * iterators.h: Added a std:: declaration to the return type of ParIterator::size. diff --git a/src/buffer.C b/src/buffer.C index de4866e3b9..d94e6b922e 100644 --- a/src/buffer.C +++ b/src/buffer.C @@ -32,8 +32,6 @@ #include #endif -#include - #ifdef __GNUG__ #pragma implementation #endif @@ -3576,10 +3574,21 @@ Buffer::Lists const Buffer::getLists() const { Lists l; Paragraph * par = paragraph; + +#if 1 + std::pair const tmp = + textclasslist.NumberOfLayout(params.textclass, "Caption"); + bool const found = tmp.first; + LyXTextClassList::size_type const cap = tmp.second; + +#else + // This is the prefered way to to this, but boost::tie can break + // some compilers bool found; LyXTextClassList::size_type cap; boost::tie(found, cap) = textclasslist .NumberOfLayout(params.textclass, "Caption"); +#endif while (par) { char const labeltype =