]> git.lyx.org Git - lyx.git/blobdiff - boost/boost/format/format_class.hpp
Don't allow newline characters in document settings.
[lyx.git] / boost / boost / format / format_class.hpp
index 563926556f2be543a692827df4594b1694d1d086..4555e56ec37cb07d8fa050af5d177e4350a25bbb 100644 (file)
@@ -68,6 +68,31 @@ namespace boost {
             { return io::detail::feed<CharT, Tr, Alloc, T&>(*this,x); }
 #endif
 
+#if defined(__GNUC__)
+        // GCC can't handle anonymous enums without some help
+        // ** arguments passing ** //
+        basic_format&   operator%(const int& x)
+            { return io::detail::feed<CharT, Tr, Alloc, const int&>(*this,x); }
+
+#ifndef BOOST_NO_OVERLOAD_FOR_NON_CONST
+        basic_format&   operator%(int& x)
+            { return io::detail::feed<CharT, Tr, Alloc, int&>(*this,x); }
+#endif
+#endif
+
+        // The total number of arguments expected to be passed to the format objectt
+        int expected_args() const
+            { return num_args_; }
+        // The number of arguments currently bound (see bind_arg(..) )
+        int bound_args() const;
+        // The number of arguments currently fed to the format object
+        int fed_args() const;
+        // The index (1-based) of the current argument (i.e. next to be formatted)
+        int cur_arg() const;
+        // The number of arguments still required to be fed
+        int remaining_args() const; // same as expected_args() - bound_args() - fed_args()
+
+
         // ** object modifying **//
         template<class T>
         basic_format&  bind_arg(int argN, const T& val) 
@@ -84,7 +109,7 @@ namespace boost {
 #if !defined( BOOST_NO_MEMBER_TEMPLATE_FRIENDS )  \
     && !BOOST_WORKAROUND(__BORLANDC__, <= 0x570) \
     && !BOOST_WORKAROUND( _CRAYC, != 0) \
-    && !BOOST_WORKAROUND(__DECCXX_VER, <= 60590041)
+    && !BOOST_WORKAROUND(__DECCXX_VER, BOOST_TESTED_AT(60590042))
         // use friend templates and private members only if supported
 
 #ifndef  BOOST_NO_TEMPLATE_STD_STREAM