2
0
mirror of https://github.com/boostorg/python.git synced 2026-01-20 04:42:28 +00:00

Compare commits

..

104 Commits

Author SHA1 Message Date
Stefan Seefeld
99022d2eb8 Merge branch 'develop' 2015-06-30 18:09:40 -04:00
Stefan Seefeld
37f8f37cda Merge pull request #16 from teeks99/main_crt_error
Fixes empty example
2015-06-24 18:01:24 -04:00
Stefan Seefeld
156054371b Merge pull request #24 from agnat/fix/cv_tag_volatile_constant
Fix is_volatile constant in detail::cv_tag<>
2015-05-27 11:42:39 -04:00
David Siegel
d06f4aeaca Fix is_volatile constant in detail::cv_tag<> 2015-05-27 17:30:09 +02:00
Stefan Seefeld
e8d7bb5027 Merge pull request #23 from jzmaddock/patch-1
Stop Using type_traits details.
2015-05-27 11:07:30 -04:00
Stefan Seefeld
b207fc1a04 Merge pull request #20 from Lastique/patch-2
Use _Py_fopen instead of fopen
2015-05-27 10:59:50 -04:00
jzmaddock
9742c30f47 Stop Using type_traits details.
The type_traits internal details used here are being moved to make it clear they are details and subject to change.  Old code will continue to work, but will warn about use of a deprecated header.
2015-05-21 19:20:31 +01:00
Stefan Seefeld
97f894bc1a Merge pull request #7 from PeterMartini/develop
Boost.Build now uses src/ instead of v2/
2015-05-08 13:18:33 -04:00
Andrey Semashev
eefc434bae Use _Py_fopen instead of fopen
A followup fix for the previous commit 36f8f69411.
2015-05-06 15:29:42 +03:00
Stefan Seefeld
226d1ac961 Merge pull request #19 from Lastique/patch-1
Fix compilation with python 3.0-3.3
2015-05-06 08:10:30 -04:00
Andrey Semashev
36f8f69411 Fix compilation with python 3.0-3.3
Backport commit 3e405b6fd5 to develop branch: Fix exec_file for Python 3 < 3.4. Also fix version check to actually fix compilation with python 3.4.
2015-05-06 15:06:29 +03:00
Tom Kent
97b0d9737c Fixes empty example
Uses of visual studio were getting a 'unresolved external symbol _mainCRTStartup' because there was no main() being linked into the test_embed.exe. I'm not a bjam expert, but I think that is because the embedding target is an executable (instead of an obj/lib?). I also have no idea if this was a problem on unix or if this fix will affect that platform.
2015-04-10 19:47:44 -05:00
Stefan Seefeld
3e405b6fd5 Fix exec_file for Python 3 < 3.4. 2015-04-09 08:57:08 -04:00
Stefan Seefeld
e1e9eb303a Merge pull request #13 from ax3l/fix-missingPlaceholderInclude
Fix Trac #10932 Missing Include: Bind Placeholders
2015-03-26 09:16:15 -04:00
Stefan Seefeld
9eee9ef461 Merge pull request #15 from mmatrosov/master
Fix #11100 and #8058: binary compatibility and leaked file handle in exec_file()
2015-03-26 08:23:15 -04:00
Mikhail Matrosov
fe24ab9dd5 [#8058] Close file handle before exec_file() routine returns. 2015-03-11 01:11:54 +03:00
Mikhail Matrosov
a911c17fd6 [#11100] Fix binary incompatibilities with fopen() in exec_file() routine. 2015-03-11 01:11:54 +03:00
Daniel James
8d5d777ebb Add metadata file. 2015-01-25 21:25:23 +02:00
Peter Dimov
ea87bfee8c Merge pull request #9 from danieljames/metadata
Create metadata file.
2015-01-25 20:31:16 +02:00
Axel Huebl
17a7655c74 Fix Missing Include: Bind Placeholders
boost/python/exception_translator.hpp(22): error: identifier "_1" is undefined
boost/python/exception_translator.hpp(22): error: identifier "_2" is undefined
2015-01-14 16:02:23 +01:00
Daniel James
0a47c583b1 Add metadata file. 2014-08-18 15:09:41 +01:00
Peter Martini
e445e193fe Boost.Build now uses src/ instead of v2/
Update examples to reflect this
2014-04-21 23:07:11 -04:00
Beman Dawes
832a1edd79 Merge 86392 from trunk. The spirit change was not applied because the file is not present in branches/release.
[SVN r86489]
2013-10-27 21:10:04 +00:00
John Maddock
6b7e0cc71f Remove all references to now defunct (and removed) header.
[SVN r86438]
2013-10-26 10:13:38 +00:00
Beman Dawes
74b9bcaaa5 Add Boost.Build support for the Git modular layout, using links to to new header locations, thus preventing breakage to vast amounts of user code and build setups. Being added to SVN so that changes will automatically propagate to Git and modular Boost. Thanks to Steven Watanabe, Jürgen Hunold, Vladimir Prus, and Bjørn Roald for developing this patch. Steven in particular conceived the approach and did the initial implementation, which was further refined by the other contributors.
[SVN r86392]
2013-10-22 15:23:42 +00:00
Stephen Kelly
371914a0e0 Remove use of obsolete BOOST_TT_BROKEN_COMPILER_SPEC
[SVN r86250]
2013-10-11 23:23:26 +00:00
Stephen Kelly
8021a21abb Remove remaining occurances of BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
These evaded scripting.

[SVN r86249]
2013-10-11 23:22:36 +00:00
Stephen Kelly
9ceb9c02f5 Remove BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
Process #ifdef...#else...#endif blocks.

[SVN r86246]
2013-10-11 23:19:17 +00:00
Stephen Kelly
97f9a10b9c Remove BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
Process #ifndef...#else...#endif blocks.

[SVN r86245]
2013-10-11 23:17:48 +00:00
Stephen Kelly
87f776b178 Remove obsolete files.
[SVN r86242]
2013-10-11 23:11:35 +00:00
Stephen Kelly
590b7887f4 Python: Fix build.
[SVN r86099]
2013-10-01 08:40:58 +00:00
Stephen Kelly
badedbebfc Python: Remove obsolete GCC version checks.
[SVN r86066]
2013-09-30 15:58:19 +00:00
Stephen Kelly
cc80f46a6d Python: Remove obsolete MSVC version check.
[SVN r86029]
2013-09-30 00:19:23 +00:00
Stephen Kelly
42e7d7bbb3 Python: Clean up some old MSVC related code.
[SVN r85922]
2013-09-25 21:17:17 +00:00
Stephen Kelly
5476f97d59 Python: Simplify object_operators implementation.
The old-MSVC-specific version is no longer needed.

[SVN r85898]
2013-09-25 11:20:43 +00:00
Stephen Kelly
da01e9b660 Remove use of obsolete BOOST_APPEND_EXPLICIT_TEMPLATE_TYPE{,_SPEC} macro.
[SVN r85896]
2013-09-25 10:29:44 +00:00
Stephen Kelly
a89bf7e9e8 Remove use of obsolete BOOST_EXPLICIT_TEMPLATE_TYPE{,_SPEC} macros.
[SVN r85894]
2013-09-25 10:28:56 +00:00
Vladimir Prus
52201f0cba Undo previous commit, it was meant for another branch
[SVN r85888]
2013-09-25 08:32:03 +00:00
Vladimir Prus
3480aee9e7 Initial modular patch, from Bjorn.
[SVN r85884]
2013-09-25 08:13:57 +00:00
Ralf W. Grosse-Kunstleve
ca18dc9daa merging current boost/python and libs/python from trunk into release branch
[SVN r82295]
2012-12-31 04:14:35 +00:00
Ralf W. Grosse-Kunstleve
8cc149f4f4 merging current boost/python and libs/python from trunk into release branch
[SVN r81965]
2012-12-15 01:25:41 +00:00
Ralf W. Grosse-Kunstleve
a3f478e9af boost.python: merging trunk to release
[SVN r81773]
2012-12-07 19:51:06 +00:00
Ralf W. Grosse-Kunstleve
46796f3413 merging current boost/python and libs/python from trunk into release branch
[SVN r79096]
2012-06-25 22:09:52 +00:00
Ralf W. Grosse-Kunstleve
0b8b88abc7 merging current boost/python and libs/python from trunk into release branch
[SVN r79011]
2012-06-19 20:01:25 +00:00
Ralf W. Grosse-Kunstleve
76db3311ed merging current boost/python and libs/python from trunk into release branch
[SVN r77125]
2012-02-27 02:49:42 +00:00
Ralf W. Grosse-Kunstleve
7acb544b47 merging current boost/python and libs/python from trunk into release branch
[SVN r76422]
2012-01-11 23:48:18 +00:00
Daniel James
f054b64315 Merge python doc rebuild to release.
[SVN r76359]
2012-01-08 10:07:09 +00:00
Ralf W. Grosse-Kunstleve
9064a063b2 merging current boost/python and libs/python from trunk into release branch
[SVN r75919]
2011-12-12 17:46:33 +00:00
Ralf W. Grosse-Kunstleve
fa24dbb88f merging current boost/python and libs/python from trunk into release branch
[SVN r75414]
2011-11-08 21:27:05 +00:00
Ralf W. Grosse-Kunstleve
49e8699b9f merging current boost/python and libs/python from trunk into release branch
[SVN r74931]
2011-10-12 21:38:53 +00:00
Ralf W. Grosse-Kunstleve
cfa2baf8c9 merging current boost/python and libs/python from trunk into release branch
[SVN r72464]
2011-06-07 04:15:33 +00:00
Ralf W. Grosse-Kunstleve
faf3cd0b78 merging current boost/python and libs/python from trunk into release branch
[SVN r72277]
2011-05-30 05:51:49 +00:00
Ralf W. Grosse-Kunstleve
a5e564be83 merging current boost/python and libs/python from trunk into release branch
[SVN r71226]
2011-04-13 17:34:35 +00:00
Dave Abrahams
dcc3590907 verifying commit privs
[SVN r71150]
2011-04-09 16:55:43 +00:00
Ralf W. Grosse-Kunstleve
74daea3d88 boost/libs/python/doc/PyConDC_2003: removing $Date$ and $Revision$ so they do not create noise on each merge to the release branch
[SVN r71004]
2011-04-05 16:49:31 +00:00
Ralf W. Grosse-Kunstleve
e28f0509d8 merging current boost/python and libs/python from trunk into release branch
[SVN r71002]
2011-04-05 16:31:51 +00:00
Ralf W. Grosse-Kunstleve
0a211a746d merging current boost/python and libs/python from trunk into release branch
[SVN r70448]
2011-03-23 00:14:55 +00:00
Ralf W. Grosse-Kunstleve
ba213663b6 merging current boost/python and libs/python from trunk into release branch
[SVN r67483]
2010-12-28 20:38:29 +00:00
Ralf W. Grosse-Kunstleve
736ba48c2b merging current boost/python and libs/python from trunk into release branch
[SVN r67446]
2010-12-24 17:31:05 +00:00
Eric Niebler
6066ffef9a Merged revisions 66606 via svnmerge from
https://svn.boost.org/svn/boost/trunk

........
  r66606 | rwgk | 2010-11-15 18:17:00 -0500 (Mon, 15 Nov 2010) | 1 line
  
  boost/python/object/make_instance.hpp: adding missing includes
........


[SVN r66614]
2010-11-16 18:30:39 +00:00
Ralf W. Grosse-Kunstleve
f759e9eb0e merging current boost/python and libs/python from trunk into release branch
[SVN r66066]
2010-10-18 04:04:52 +00:00
Douglas Gregor
846c5d9914 Add missing includes
[SVN r65142]
2010-08-31 04:50:56 +00:00
Ralf W. Grosse-Kunstleve
65b3aadc63 merging current boost/python and libs/python from trunk into release branch
[SVN r63937]
2010-07-12 22:29:41 +00:00
Hartmut Kaiser
e13ebcd0e8 Spirit: merging from trunk upto rev. 61489
[SVN r63640]
2010-07-04 22:38:38 +00:00
Marshall Clow
63a3f188b8 Merged changes for #2981, #4166, and #4377 to release branch
[SVN r63523]
2010-07-02 15:37:14 +00:00
Daniel James
34b162738f Merge documentation update.
[SVN r63517]
2010-07-02 08:27:42 +00:00
Daniel James
569b395cdd Merge documentation fixes.
* Use `doc/src/*.css` instead of `doc/html/*.css`.
* Remove wiki and people directories.
* Some documentation fixes.
* Left out `minimal.css` changes and boostbook changes because of clashes.


[SVN r63347]
2010-06-26 12:30:09 +00:00
Douglas Gregor
4b9cb5337d Include all of the headers needed for the BOOST_MPL_ASSERT that is failing for several compilers
[SVN r62015]
2010-05-16 01:27:58 +00:00
Ralf W. Grosse-Kunstleve
86db60255a libs/python/test/Jamfile.v2: disabling calling_conventions tests
[SVN r61034]
2010-04-04 05:23:15 +00:00
Ralf W. Grosse-Kunstleve
37b45d2baf merging current boost/python and libs/python from trunk into release branch
[SVN r61033]
2010-04-04 05:19:57 +00:00
Ralf W. Grosse-Kunstleve
471be524f4 boost.python: merging from trunk to release (gcc 4.4 -std=c++0x compatibility)
[SVN r57837]
2009-11-21 14:41:51 +00:00
Ralf W. Grosse-Kunstleve
e485244886 boost.python: merging from trunk to release (Troy Straszheim's fix for a long-standing bug)
[SVN r57621]
2009-11-13 00:40:01 +00:00
Troy D. Straszheim
b9cd3ff109 merge from trunk very minor fixes for ticket #2582
[SVN r57017]
2009-10-20 15:18:26 +00:00
Troy D. Straszheim
d804f1250e rm cmake from the release branch before it goes out broken. Policy dictates that you never commit to release, you commit to trunk and merge to release.
[SVN r56941]
2009-10-17 01:10:45 +00:00
Ralf W. Grosse-Kunstleve
89100353db boost/python, libs/python: all changes from trunk merged into branches/release
[SVN r56806]
2009-10-13 22:37:59 +00:00
Ralf W. Grosse-Kunstleve
46be73387c boost/python/object_operators.hpp: merging trunk rev. 55708 into release branch
[SVN r55742]
2009-08-23 21:22:52 +00:00
Ralf W. Grosse-Kunstleve
d685a5e8c5 python library: sync with trunk to adopt recent exec.cpp fixes
[SVN r55642]
2009-08-18 01:08:46 +00:00
Ralf W. Grosse-Kunstleve
e80224b1ad boost/python, libs/python: all changes from trunk merged into branches/release (without any manual modifications)
Commands used:
  svn merge https://svn.boost.org/svn/boost/branches/release/boost/python https://svn.boost.org/svn/boost/trunk/boost/python /net/chevy/raid1/rwgk/boost_release/merge_attempt/boost/boost/python

  svn merge https://svn.boost.org/svn/boost/branches/release/libs/python https://svn.boost.org/svn/boost/trunk/libs/python /net/chevy/raid1/rwgk/boost_release/merge_attempt/boost/libs/python

  svn, version 1.6.4 (r38063)
     compiled Aug 17 2009, 13:31:03


[SVN r55629]
2009-08-17 21:01:18 +00:00
Troy D. Straszheim
03fdf5b992 Add basic copyright/license to keep cmake out of the inspection report
[SVN r55095]
2009-07-22 21:51:01 +00:00
Jeremiah Willcock
73b4cd3325 Fixed almost all tab and min/max issues found by inspect tool
[SVN r53142]
2009-05-20 19:41:20 +00:00
Douglas Gregor
f7d31f6ead Fix Boost.Python tests
[SVN r52856]
2009-05-08 20:42:11 +00:00
Douglas Gregor
47bb3f55a7 Add the pyrun.py script used to run Boost.Python tests via CMake
[SVN r52818]
2009-05-07 04:44:23 +00:00
Joel de Guzman
6296bd5bc4 bumped wrong version
[SVN r52656]
2009-04-29 08:16:02 +00:00
John Maddock
217250f078 Merge PDF build changes from Trunk.
[SVN r51417]
2009-02-23 18:39:32 +00:00
Troy D. Straszheim
29152af56c merge of cmake build files from trunk per beman
[SVN r50756]
2009-01-24 18:57:20 +00:00
Daniel James
19846f5d79 Merge quickbook workaround and fix some links.
Merged revisions 48987,49230-49231 via svnmerge from 
https://svn.boost.org/svn/boost/trunk

........
  r48987 | danieljames | 2008-09-28 13:21:39 +0100 (Sun, 28 Sep 2008) | 1 line
  
  Clean up some link errors.
........
  r49230 | danieljames | 2008-10-09 23:13:48 +0100 (Thu, 09 Oct 2008) | 1 line
  
  position_iterator is meant to be a forward iterator, so avoid using operator+ with it.
........
  r49231 | danieljames | 2008-10-09 23:14:14 +0100 (Thu, 09 Oct 2008) | 4 lines
  
  Work around the problems with window newlines in position_iterator. (I'm
  about to fix them, but this will get quickbook working immediately).
  
  Fixes #2155
........


[SVN r49242]
2008-10-10 09:29:21 +00:00
Dave Abrahams
a1924a2a72 Merging all trunk changes in Boost.Python to release. The logs for
these changes follow.  r44807 is a merge from another branch; many of
those changes probably don't apply.

  ------------------------------------------------------------------------
  r43423 | danieljames | 2008-02-27 14:22:01 -0500 (Wed, 27 Feb 2008) | 1 line

  Fix incorrect links to copyright of the form 'http:#www.boost.org
  ------------------------------------------------------------------------
  r43546 | rwgk | 2008-03-08 23:30:13 -0500 (Sat, 08 Mar 2008) | 1 line

  map std::invalid_argument -> Python ValueError
  ------------------------------------------------------------------------
  r43799 | grafik | 2008-03-22 18:53:35 -0400 (Sat, 22 Mar 2008) | 1 line

  Remove svn exec property from files that should not be executable to fix permission problems in archives.
  ------------------------------------------------------------------------
  r43845 | dave | 2008-03-24 14:27:22 -0400 (Mon, 24 Mar 2008) | 1 line

  Work around vc9 bugs
  ------------------------------------------------------------------------
  r43901 | bemandawes | 2008-03-27 22:11:13 -0400 (Thu, 27 Mar 2008) | 1 line

  Remove per email from Dave
  ------------------------------------------------------------------------
  r44041 | rwgk | 2008-04-04 14:57:27 -0400 (Fri, 04 Apr 2008) | 1 line

  bogus VC8 warning C4180 disabled
  ------------------------------------------------------------------------
  r44449 | djowel | 2008-04-15 23:07:06 -0400 (Tue, 15 Apr 2008) | 1 line

  Andreas patch
  ------------------------------------------------------------------------
  r44450 | djowel | 2008-04-15 23:07:11 -0400 (Tue, 15 Apr 2008) | 1 line

  Andreas indexing suite patch
  ------------------------------------------------------------------------
  r44807 | danieljames | 2008-04-27 03:39:49 -0400 (Sun, 27 Apr 2008) | 78 lines

  Merge in documentation fixes.  Apart from the change to optional's documenation
  Jamfile, which I included by mistake.

  Fixes #1659, #1661, #1684, #1685, 1687, #1690, #1801

  I wrote about this at:

  http://lists.boost.org/Archives/boost/2008/04/136405.php

  Merged revisions 44585-44806 via svnmerge from 
  https://svn.boost.org/svn/boost/branches/doc

  ........
    r44585 | danieljames | 2008-04-19 16:25:27 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix broken link to vacpp in bjam docs. Refs #1512
  ........
    r44586 | danieljames | 2008-04-19 16:27:36 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix broken link to bcpp in bjam docs. Refs #1513
  ........
    r44587 | danieljames | 2008-04-19 16:33:58 +0100 (Sat, 19 Apr 2008) | 2 lines

    DateTime documentation - Fix a link to the serialization library. Refs #1659
  ........
    r44588 | danieljames | 2008-04-19 16:35:36 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix some links in interprocess & intrusive. Refs #1661
  ........
    r44589 | danieljames | 2008-04-19 16:37:39 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix some links in the python docs. Refs #1684.
  ........
    r44590 | danieljames | 2008-04-19 16:38:29 +0100 (Sat, 19 Apr 2008) | 2 lines

    Work around a quickbook bug which is affecting the python docs. Refs #1684.
  ........
    r44591 | danieljames | 2008-04-19 16:39:34 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix a broken link in the numeric conversion docs. Refs #1685
  ........
    r44592 | danieljames | 2008-04-19 16:40:45 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix some links in the optional docs. Refs #1687
  ........
    r44593 | danieljames | 2008-04-19 16:42:09 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix link to the hash documentation from bimap. Refs #1690
  ........
    r44599 | danieljames | 2008-04-19 18:07:33 +0100 (Sat, 19 Apr 2008) | 2 lines

    Fix a typo in the format library. Refs #1801
  ........
    r44600 | danieljames | 2008-04-19 19:20:59 +0100 (Sat, 19 Apr 2008) | 1 line

    Initialise svnmerge.
  ........
    r44641 | danieljames | 2008-04-20 18:59:47 +0100 (Sun, 20 Apr 2008) | 2 lines

    Fix the lincense url in shared container iterator documentation.
  ........
    r44642 | danieljames | 2008-04-20 19:00:00 +0100 (Sun, 20 Apr 2008) | 2 lines

    Fix image link in the mpi documentation.
  ........
    r44643 | danieljames | 2008-04-20 19:00:11 +0100 (Sun, 20 Apr 2008) | 2 lines

    Fix a typo in the spirit docs.
  ........
    r44644 | danieljames | 2008-04-20 19:00:23 +0100 (Sun, 20 Apr 2008) | 2 lines

    Escape the slash so that quickbook doesn't think it the start of an italic section, and mess up the link. Refs #1844
  ........
    r44647 | danieljames | 2008-04-20 19:39:47 +0100 (Sun, 20 Apr 2008) | 2 lines

    Fix another typo in spirit docs.
  ........

  ------------------------------------------------------------------------
  r45283 | danieljames | 2008-05-11 09:49:20 -0400 (Sun, 11 May 2008) | 1 line

  Quote href values - our tools don't support unquoted values.
  ------------------------------------------------------------------------
  r45359 | rwgk | 2008-05-14 15:38:08 -0400 (Wed, 14 May 2008) | 1 line

  braces added to resolve g++ 4.3.0 warning
  ------------------------------------------------------------------------
  r45918 | rwgk | 2008-05-29 15:48:55 -0400 (Thu, 29 May 2008) | 66 lines

  See Python C++-SIG thread: "object.attr(object& attrname) proposal"
  Started 2008-05-25 by hohehohe2@gmail.com.

  Excerpts:

  If char const* is passed to objecjt.attr(), it uses
  PyObject_GetAttrStrng() or PyObject_SetAttrStrng().  If object is
  passed to objecjt.attr(), it takes the object as a Python string
  object and uses PyObject_GetAttr() or PyObject_SetAttr().

  If attr() behaves like this, it can be useful when there are lots
  of objects which you know have the same attribute name. You can save
  time by first making a boost::python::object and passing it to every
  object's attr() inside a loop.

  I just made a bit of modification to boost:python locally and did a
  quick test, like

  test 1:
    for(int i = 0; i < n; ++i)
    {
      omain.attr(attrname) = 444; //attrname is a char const*
    }

  test 2:
    for(int i = 0; i < n; ++i)
    {
      object o = omain.attr(attrname); //attrname is a char const*
    }

  test 3:
    for(int i = 0; i < n; ++i)
    {
      omain.attr(oaaaa) = 444; //oaaaa is boost::python::object that represents a string
    }

  test 4:
    for(int i = 0; i < n; ++i)
    {
      object o = omain.attr(oaaaa); //oaaaa is boost::python::object that represents a string
    }

  and it reasonably reflected the difference between PyObject_*Attr() and PyObject_*AttrString.

  test 1 :2783ms
  test 2 :2357ms
  test 3 :1882ms
  test 4 :1267ms

  test5: PyObject_SetAttrString(po_main, "aaaa", po_num444);
  test6: Py_DECREF(PyObject_GetAttrString(po_main, "aaaa"));
  test7: PyObject_SetAttr(po_main, po_aaaa, po_num444);
  test8: Py_DECREF(PyObject_GetAttr(po_main, po_aaaa));
  (po_ prefixed variables are PyObject*),

  all inside each for loop, and the results were

  test 5 :2410ms
  test 6 :2277ms
  test 7 :1629ms
  test 8 :1094ms

  It's boost 1.35.0, Python 2.5 on linux(gcc4.1.2).
  I also did the same test on windows(vs8) and the tendency was not
  so different.

  ------------------------------------------------------------------------
  r45920 | rwgk | 2008-05-29 16:04:19 -0400 (Thu, 29 May 2008) | 1 line

  Projects using Boost.Python: PolyBoRi (text provided by Michael Brickenstein)
  ------------------------------------------------------------------------
  r46115 | schoepflin | 2008-06-04 11:11:05 -0400 (Wed, 04 Jun 2008) | 1 line

  Added missing ostream header file.
  ------------------------------------------------------------------------
  r46445 | dgregor | 2008-06-17 09:54:46 -0400 (Tue, 17 Jun 2008) | 1 line

  Add mime-type and eol-style properties as needed
  ------------------------------------------------------------------------
  r46721 | dave | 2008-06-26 12:41:34 -0400 (Thu, 26 Jun 2008) | 2 lines

  Compatibility with Apache STDCXX library.  Don't assume eh.h comes along with the other headers automatically.

  ------------------------------------------------------------------------
  r46808 | bemandawes | 2008-06-28 09:45:21 -0400 (Sat, 28 Jun 2008) | 1 line

  With his kind permission, change Jaakko "J<LATIN SMALL LETTER A WITH DIARESIS>rvi" to "Jarvi"
  ------------------------------------------------------------------------
  r46817 | djowel | 2008-06-28 14:24:17 -0400 (Sat, 28 Jun 2008) | 1 line

  added note on removing targets
  ------------------------------------------------------------------------
  r46844 | dave | 2008-06-29 08:26:17 -0400 (Sun, 29 Jun 2008) | 2 lines

  Make valid HTML

  ------------------------------------------------------------------------




[SVN r47459]
2008-07-15 21:05:24 +00:00
Joel de Guzman
c205cd86c6 added note on removing targets
[SVN r46900]
2008-06-30 12:14:28 +00:00
Dave Abrahams
8d86dc199c merged valid HTML from trunk
[SVN r46845]
2008-06-29 12:55:50 +00:00
Beman Dawes
55e9ff14a1 With his kind permission, change Jaakko "Järvi" to "Jarvi"
[SVN r46809]
2008-06-28 13:57:20 +00:00
Daniel James
4fea58f634 Add minor documentation fixes to the release branch.
(I left out the changes to the hash library).

Merged via svnmerge from 
https://svn.boost.org/svn/boost/trunk

................
  r44807 | danieljames | 2008-04-27 08:39:49 +0100 (Sun, 27 Apr 2008) | 78 lines
  
  Merge in documentation fixes.  Apart from the change to optional's documenation
  Jamfile, which I included by mistake.
  
  I wrote about this at:
  
  http://lists.boost.org/Archives/boost/2008/04/136405.php
  
  Merged revisions 44585-44806 via svnmerge from 
  https://svn.boost.org/svn/boost/branches/doc
  
  ........
    r44585 | danieljames | 2008-04-19 16:25:27 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix broken link to vacpp in bjam docs.
  ........
    r44586 | danieljames | 2008-04-19 16:27:36 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix broken link to bcpp in bjam docs.
  ........
    r44587 | danieljames | 2008-04-19 16:33:58 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    DateTime documentation - Fix a link to the serialization library.
  ........
    r44588 | danieljames | 2008-04-19 16:35:36 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix some links in interprocess & intrusive.
  ........
    r44589 | danieljames | 2008-04-19 16:37:39 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix some links in the python docs.
  ........
    r44590 | danieljames | 2008-04-19 16:38:29 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Work around a quickbook bug which is affecting the python docs.
  ........
    r44591 | danieljames | 2008-04-19 16:39:34 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix a broken link in the numeric conversion docs.
  ........
    r44592 | danieljames | 2008-04-19 16:40:45 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix some links in the optional docs.
  ........
    r44593 | danieljames | 2008-04-19 16:42:09 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix link to the hash documentation from bimap.
  ........
    r44599 | danieljames | 2008-04-19 18:07:33 +0100 (Sat, 19 Apr 2008) | 2 lines
    
    Fix a typo in the format library.
  ........
    r44600 | danieljames | 2008-04-19 19:20:59 +0100 (Sat, 19 Apr 2008) | 1 line
    
    Initialise svnmerge.
  ........
    r44641 | danieljames | 2008-04-20 18:59:47 +0100 (Sun, 20 Apr 2008) | 2 lines
    
    Fix the lincense url in shared container iterator documentation.
  ........
    r44642 | danieljames | 2008-04-20 19:00:00 +0100 (Sun, 20 Apr 2008) | 2 lines
    
    Fix image link in the mpi documentation.
  ........
    r44643 | danieljames | 2008-04-20 19:00:11 +0100 (Sun, 20 Apr 2008) | 2 lines
    
    Fix a typo in the spirit docs.
  ........
    r44644 | danieljames | 2008-04-20 19:00:23 +0100 (Sun, 20 Apr 2008) | 2 lines
    
    Escape the slash so that quickbook doesn't think it the start of an italic section, and mess up the link. Refs #1844
  ........
    r44647 | danieljames | 2008-04-20 19:39:47 +0100 (Sun, 20 Apr 2008) | 2 lines
    
    Fix another typo in spirit docs.
  ........
................
  r45232 | danieljames | 2008-05-08 22:50:19 +0100 (Thu, 08 May 2008) | 1 line
  
  Fix some invalid xml by replacing ampersands with character entities.
................
  r45576 | danieljames | 2008-05-20 16:39:25 +0100 (Tue, 20 May 2008) | 20 lines
  
  Merge some small documentation fixes from the doc branch, and mark some
  previously merged changes as merged.
  
  Merged revisions 44811,45129,45142,45154,45281-45282,45365 via svnmerge from 
  https://svn.boost.org/svn/boost/branches/doc
  
  ........
    r45129 | danieljames | 2008-05-05 12:36:50 +0100 (Mon, 05 May 2008) | 2 lines
    
    Update navbar links in boostbook.
  ........
    r45282 | danieljames | 2008-05-11 14:15:31 +0100 (Sun, 11 May 2008) | 2 lines
    
    Group functions in the hash header - requires Frank's free-function-group fix.
    (not included in release branch).
  ........
    r45365 | danieljames | 2008-05-14 21:39:00 +0100 (Wed, 14 May 2008) | 2 lines
    
    Add boost.root to standalone hash documentation.
    (not included in release branch).
  ........
................


[SVN r45622]
2008-05-21 20:57:05 +00:00
Beman Dawes
694ae13063 Merge from trunk 43901 at Dave's request
[SVN r43902]
2008-03-28 02:16:12 +00:00
Joel de Guzman
5168895803 Added note about --preserve-test-targets
[SVN r43849]
2008-03-24 23:04:36 +00:00
Joel de Guzman
c8bf94663c Added note about --preserve-test-targets
[SVN r43848]
2008-03-24 23:02:57 +00:00
Daniel James
928a9389ce Rebuild a lot of documentation.
[SVN r43650]
2008-03-16 11:38:32 +00:00
Daniel James
7d22435994 Merged revisions 43211,43214-43219,43222-43225,43227-43238,43242,43244-43245,43249-43250,43257-43259,43261,43263,43265,43267-43268,43270-43271,43273,43275-43279,43284-43289,43291,43295,43297-43298,43304-43305,43307,43313,43315,43324,43326-43327,43331,43333,43339-43343,43345,43348,43350,43352-43353,43355-43356,43358,43360,43366-43367,43369-43370,43372-43376,43378-43389,43394,43396-43398,43400-43401,43403-43404,43406-43408,43413-43415,43417-43418,43420,43422-43423 via svnmerge from
https://svn.boost.org/svn/boost/trunk

........
  r43417 | danieljames | 2008-02-26 22:04:55 +0000 (Tue, 26 Feb 2008) | 2 lines
  
  Fix a link to Boost.Bimap.
........
  r43418 | danieljames | 2008-02-26 22:07:25 +0000 (Tue, 26 Feb 2008) | 2 lines
  
  Change another link that's no longer in the repository to link to the website.
........
  r43422 | danieljames | 2008-02-27 18:51:14 +0000 (Wed, 27 Feb 2008) | 1 line
  
  Fix broken copyright urls. Fixes #1573.
........
  r43423 | danieljames | 2008-02-27 19:22:01 +0000 (Wed, 27 Feb 2008) | 1 line
  
  Fix incorrect links to copyright of the form 'http:#www.boost.org
........


[SVN r43425]
2008-02-27 20:00:24 +00:00
Daniel James
96dd880146 Merged revisions 43206,43208-43213 via svnmerge from
https://svn.boost.org/svn/boost/trunk

........
  r43206 | danieljames | 2008-02-10 09:55:03 +0000 (Sun, 10 Feb 2008) | 1 line
  
  Fix some broken links.
........
  r43209 | danieljames | 2008-02-10 14:56:22 +0000 (Sun, 10 Feb 2008) | 1 line
  
  Link to people pages on the website, as they've been removed from the download.
........
  r43210 | danieljames | 2008-02-10 15:02:17 +0000 (Sun, 10 Feb 2008) | 1 line
  
  Point links to the pages that used to be in 'more' to the site.
........
  r43212 | danieljames | 2008-02-10 16:10:16 +0000 (Sun, 10 Feb 2008) | 1 line
  
  Fix links on the home page as well.
........
  r43213 | danieljames | 2008-02-10 16:21:22 +0000 (Sun, 10 Feb 2008) | 1 line
  
  Generated documentation which is no longer generated.
........


[SVN r43214]
2008-02-10 16:39:38 +00:00
Jürgen Hunold
63f8e9f3d7 Merged revisions 41544-41546,41549-41551,41558-41561,41564,41567,41570,41573,41576-41579,41581,41583-41586,41589,41591,41594-41612,41614-41620,41622-41624,41628,41630-41635,41637,41640-41641,41643,41649-41650 via svnmerge from
https://svn.boost.org/svn/boost/trunk

........
  r41544 | jhunold | 2007-12-01 20:27:06 +0100 (Sa, 01 Dez 2007) | 2 lines
  
  Silence compiler by adding cosmetic virtual destructors.
........
  r41549 | jhunold | 2007-12-01 21:24:51 +0100 (Sa, 01 Dez 2007) | 2 lines
  
  Silence compiler by adding cosmetic virtual destructors.
........
  r41550 | jhunold | 2007-12-01 21:26:37 +0100 (Sa, 01 Dez 2007) | 3 lines
  
  Remove unused paramters.
  Add -Wextra to gcc flags to enable more warnings.
........
  r41577 | jhunold | 2007-12-02 12:51:08 +0100 (So, 02 Dez 2007) | 3 lines
  
  Revert revisions 41544 and 41549.
  See http://lists.boost.org/Archives/boost/2007/12/131116.php for details.
........
  r41649 | jhunold | 2007-12-03 19:47:17 +0100 (Mo, 03 Dez 2007) | 2 lines
  
  Silence unused paramter warning in release mode.
........
  r41650 | jhunold | 2007-12-03 19:51:26 +0100 (Mo, 03 Dez 2007) | 2 lines
  
  Add cosmetic virtual detructors to silence compile warnings.
........


[SVN r42094]
2007-12-16 10:12:07 +00:00
Beman Dawes
d9b4ada654 Full merge from trunk at revision 41356 of entire boost-root tree.
[SVN r41370]
2007-11-25 18:38:02 +00:00
Beman Dawes
f5df393360 Full merge from trunk at revision 41356 of entire boost-root tree.
[SVN r41369]
2007-11-25 18:07:19 +00:00
Rene Rivera
bf33b54638 Recreate release branch from fixed 1.34.1 tag.
[SVN r40341]
2007-10-23 06:42:50 +00:00
Douglas Gregor
87451007b9 Move Attic files back into their rightful places
[SVN r40311]
2007-10-23 01:47:48 +00:00
Beman Dawes
2392a6a3e2 Starting point for releases
[SVN r39706]
2007-10-05 14:25:06 +00:00
nobody
6c1e7decfa This commit was manufactured by cvs2svn to create tag
'Version_1_34_1'.

[SVN r38286]
2007-07-24 19:28:14 +00:00
142 changed files with 83 additions and 1091 deletions

0
doc/PyConDC_2003/bpl.html Normal file → Executable file
View File

0
doc/PyConDC_2003/bpl.pdf Normal file → Executable file
View File

0
doc/PyConDC_2003/python_cpp_mix.jpg Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

0
doc/PyConDC_2003/python_cpp_mix.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 6.1 KiB

0
doc/internals.html Normal file → Executable file
View File

0
doc/internals.rst Normal file → Executable file
View File

0
doc/tutorial/doc/html/images/alert.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 603 B

After

Width:  |  Height:  |  Size: 603 B

0
doc/tutorial/doc/html/images/home.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 358 B

After

Width:  |  Height:  |  Size: 358 B

0
doc/tutorial/doc/html/images/next.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 336 B

After

Width:  |  Height:  |  Size: 336 B

0
doc/tutorial/doc/html/images/note.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 658 B

After

Width:  |  Height:  |  Size: 658 B

0
doc/tutorial/doc/html/images/prev.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 334 B

After

Width:  |  Height:  |  Size: 334 B

0
doc/tutorial/doc/html/images/tip.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 640 B

After

Width:  |  Height:  |  Size: 640 B

0
doc/tutorial/doc/html/images/up.png Normal file → Executable file
View File

Before

Width:  |  Height:  |  Size: 370 B

After

Width:  |  Height:  |  Size: 370 B

0
doc/v2/instance_holder.html Normal file → Executable file
View File

0
doc/v2/lvalue_from_pytype.html Normal file → Executable file
View File

0
doc/v2/operators.html Normal file → Executable file
View File

0
doc/v2/raw_function.html Normal file → Executable file
View File

0
doc/v2/return_arg.html Normal file → Executable file
View File

0
doc/v2/stl_iterator.html Normal file → Executable file
View File

0
doc/v2/type_id.html Normal file → Executable file
View File

0
doc/v2/wrapper.html Normal file → Executable file
View File

4
example/boost-build.jam Normal file → Executable file
View File

@@ -2,6 +2,6 @@
# Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
# Edit this path to point at the tools/build/v2 subdirectory of your
# Edit this path to point at the tools/build/src subdirectory of your
# Boost installation. Absolute paths work, too.
boost-build ../../../tools/build/v2 ;
boost-build ../../../tools/build/src ;

View File

@@ -31,7 +31,7 @@ import testing ;
testing.make-test run-pyd : extending test_extending.py : : test_ext ;
# Declare a test of the embedding application
testing.run embedding
testing.run embedding embedding.cpp
: # any ordinary arguments
: script.py # any arguments that should be treated as relative paths
: # requirements

View File

@@ -2,6 +2,6 @@
# Software License, Version 1.0. (See accompanying
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
# Edit this path to point at the tools/build/v2 subdirectory of your
# Edit this path to point at the tools/build/src subdirectory of your
# Boost installation. Absolute paths work, too.
boost-build ../../../../tools/build/v2 ;
boost-build ../../../../tools/build/src ;

0
include/boost/python/arg_from_python.hpp Normal file → Executable file
View File

View File

@@ -102,7 +102,6 @@ namespace detail
return this->operator,(python::arg(name));
}
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
struct is_keywords
{
@@ -126,31 +125,6 @@ namespace detail
typedef mpl::bool_<value> type;
BOOST_PYTHON_MPL_LAMBDA_SUPPORT(1,is_reference_to_keywords,(T))
};
# else
typedef char (&yes_keywords_t)[1];
typedef char (&no_keywords_t)[2];
no_keywords_t is_keywords_test(...);
template<std::size_t nkeywords>
yes_keywords_t is_keywords_test(void (*)(keywords<nkeywords>&));
template<std::size_t nkeywords>
yes_keywords_t is_keywords_test(void (*)(keywords<nkeywords> const&));
template<typename T>
class is_reference_to_keywords
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_keywords_test( (void (*)(T))0 ))
== sizeof(detail::yes_keywords_t)));
typedef mpl::bool_<value> type;
BOOST_PYTHON_MPL_LAMBDA_SUPPORT(1,is_reference_to_keywords,(T))
};
# endif
}
inline detail::keywords<1> args(char const* name)

View File

@@ -29,7 +29,6 @@ struct back_reference
T m_value;
};
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
class is_back_reference
{
@@ -44,36 +43,6 @@ class is_back_reference<back_reference<T> >
BOOST_STATIC_CONSTANT(bool, value = true);
};
# else // no partial specialization
}} // namespace boost::python
#include <boost/type.hpp>
namespace boost { namespace python {
namespace detail
{
typedef char (&yes_back_reference_t)[1];
typedef char (&no_back_reference_t)[2];
no_back_reference_t is_back_reference_test(...);
template<typename T>
yes_back_reference_t is_back_reference_test(boost::type< back_reference<T> >);
}
template<typename T>
class is_back_reference
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_back_reference_test(boost::type<T>()))
== sizeof(detail::yes_back_reference_t)));
};
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
//
// implementations

0
include/boost/python/base_type_traits.hpp Normal file → Executable file
View File

View File

@@ -24,7 +24,6 @@ namespace boost { namespace python {
namespace detail
{
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T> struct specifies_bases
: mpl::false_
{
@@ -35,23 +34,6 @@ namespace boost { namespace python {
: mpl::true_
{
};
# else
template < BOOST_PP_ENUM_PARAMS(BOOST_PYTHON_MAX_BASES, class Base) >
static char is_bases_helper(bases< BOOST_PYTHON_BASE_PARAMS > const&);
static char (& is_bases_helper(...) )[256];
template <class T>
struct specifies_bases
{
private:
static typename add_reference<T>::type make();
BOOST_STATIC_CONSTANT(bool, non_ref = !is_reference<T>::value);
public:
BOOST_STATIC_CONSTANT(bool, value = non_ref & (sizeof(is_bases_helper(make())) == 1));
typedef mpl::bool_<value> type;
};
# endif
template <class T, class Prev = bases<> >
struct select_bases
: mpl::if_<

0
include/boost/python/borrowed.hpp Normal file → Executable file
View File

0
include/boost/python/cast.hpp Normal file → Executable file
View File

View File

@@ -45,8 +45,7 @@
# if BOOST_WORKAROUND(__MWERKS__, <= 0x3004) \
/* pro9 reintroduced the bug */ \
|| (BOOST_WORKAROUND(__MWERKS__, > 0x3100) \
&& BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3201))) \
|| BOOST_WORKAROUND(__GNUC__, < 3)
&& BOOST_WORKAROUND(__MWERKS__, BOOST_TESTED_AT(0x3201)))
# define BOOST_PYTHON_NO_MEMBER_POINTER_ORDERING 1
@@ -302,7 +301,6 @@ class class_ : public objects::class_base
}
// Property creation
# if !BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
template <class Get>
self& add_property(char const* name, Get fget, char const* docstr = 0)
{
@@ -317,47 +315,6 @@ class class_ : public objects::class_base
name, this->make_getter(fget), this->make_setter(fset), docstr);
return *this;
}
# else
private:
template <class Get>
self& add_property_impl(char const* name, Get fget, char const* docstr, int)
{
base::add_property(name, this->make_getter(fget), docstr);
return *this;
}
template <class Get, class Set>
self& add_property_impl(char const* name, Get fget, Set fset, ...)
{
base::add_property(
name, this->make_getter(fget), this->make_setter(fset), 0);
return *this;
}
public:
template <class Get>
self& add_property(char const* name, Get fget)
{
base::add_property(name, this->make_getter(fget), 0);
return *this;
}
template <class Get, class DocStrOrSet>
self& add_property(char const* name, Get fget, DocStrOrSet docstr_or_set)
{
this->add_property_impl(name, this->make_getter(fget), docstr_or_set, 0);
return *this;
}
template <class Get, class Set>
self&
add_property(char const* name, Get fget, Set fset, char const* docstr)
{
base::add_property(
name, this->make_getter(fget), this->make_setter(fset), docstr);
return *this;
}
# endif
template <class Get>
self& add_static_property(char const* name, Get fget)

View File

@@ -115,9 +115,9 @@ struct arg_rvalue_from_python
arg_rvalue_from_python(PyObject*);
bool convertible() const;
# if BOOST_MSVC < 1301 || _MSC_FULL_VER > 13102196
# if _MSC_FULL_VER > 13102196
typename arg_rvalue_from_python<T>::
# endif
# endif
result_type operator()();
private:

0
include/boost/python/converter/arg_to_python.hpp Normal file → Executable file
View File

View File

@@ -13,17 +13,9 @@ struct registration;
namespace detail
{
struct BOOST_PYTHON_DECL arg_to_python_base
# if !defined(BOOST_MSVC) || BOOST_MSVC <= 1300 || _MSC_FULL_VER > 13102179
: handle<>
# endif
{
arg_to_python_base(void const volatile* source, registration const&);
# if defined(BOOST_MSVC) && BOOST_MSVC > 1300 && _MSC_FULL_VER <= 13102179
PyObject* get() const { return m_ptr.get(); }
PyObject* release() { return m_ptr.release(); }
private:
handle<> m_ptr;
# endif
};
}

View File

View File

@@ -121,7 +121,6 @@ struct is_object_manager
{
};
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T>
struct is_reference_to_object_manager
: mpl::false_
@@ -151,79 +150,6 @@ struct is_reference_to_object_manager<T const volatile&>
: is_object_manager<T>
{
};
# else
namespace detail
{
typedef char (&yes_reference_to_object_manager)[1];
typedef char (&no_reference_to_object_manager)[2];
// A number of nastinesses go on here in order to work around MSVC6
// bugs.
template <class T>
struct is_object_manager_help
{
typedef typename mpl::if_<
is_object_manager<T>
, yes_reference_to_object_manager
, no_reference_to_object_manager
>::type type;
// If we just use the type instead of the result of calling this
// function, VC6 will ICE.
static type call();
};
// A set of overloads for each cv-qualification. The same argument
// is passed twice: the first one is used to unwind the cv*, and the
// second one is used to avoid relying on partial ordering for
// overload resolution.
template <class U>
typename is_object_manager_help<U>
is_object_manager_helper(U*, void*);
template <class U>
typename is_object_manager_help<U>
is_object_manager_helper(U const*, void const*);
template <class U>
typename is_object_manager_help<U>
is_object_manager_helper(U volatile*, void volatile*);
template <class U>
typename is_object_manager_help<U>
is_object_manager_helper(U const volatile*, void const volatile*);
template <class T>
struct is_reference_to_object_manager_nonref
: mpl::false_
{
};
template <class T>
struct is_reference_to_object_manager_ref
{
static T sample_object;
BOOST_STATIC_CONSTANT(
bool, value
= (sizeof(is_object_manager_helper(&sample_object, &sample_object).call())
== sizeof(detail::yes_reference_to_object_manager)
)
);
typedef mpl::bool_<value> type;
};
}
template <class T>
struct is_reference_to_object_manager
: mpl::if_<
is_reference<T>
, detail::is_reference_to_object_manager_ref<T>
, detail::is_reference_to_object_manager_nonref<T>
>::type
{
};
# endif
}}} // namespace boost::python::converter

0
include/boost/python/converter/pytype_function.hpp Normal file → Executable file
View File

View File

@@ -44,8 +44,7 @@ struct registered
{
};
# if !defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION) \
&& !BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1310))
# if !BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1310))
// collapses a few more types to the same static instance. MSVC7.1
// fails to strip cv-qualification from array types in typeid. For
// some reason we can't use this collapse there or array converters

View File

@@ -14,7 +14,6 @@ namespace boost { namespace python { namespace converter {
struct registration;
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T>
struct registered_pointee
: registered<
@@ -26,37 +25,6 @@ struct registered_pointee
>
{
};
# else
namespace detail
{
template <class T>
struct registered_pointee_base
{
static registration const& converters;
};
}
template <class T>
struct registered_pointee
: detail::registered_pointee_base<
typename add_reference<
typename add_cv<T>::type
>::type
>
{
};
//
// implementations
//
namespace detail
{
template <class T>
registration const& registered_pointee_base<T>::converters
= registry::lookup(pointer_type_id<T>());
}
# endif
}}} // namespace boost::python::converter
#endif // REGISTERED_POINTEE_DWA2002710_HPP

0
include/boost/python/converter/return_from_python.hpp Normal file → Executable file
View File

View File

@@ -16,7 +16,7 @@ namespace detail
{
template <class R>
struct copy_const_reference_expects_a_const_reference_return_type
# if defined(__GNUC__) && __GNUC__ >= 3 || defined(__EDG__)
# if defined(__GNUC__) || defined(__EDG__)
{}
# endif
;

View File

@@ -16,7 +16,7 @@ namespace detail
{
template <class R>
struct copy_non_const_reference_expects_a_non_const_reference_return_type
# if defined(__GNUC__) && __GNUC__ >= 3 || defined(__EDG__)
# if defined(__GNUC__) || defined(__EDG__)
{}
# endif
;

View File

@@ -270,7 +270,7 @@ inline object make_getter(D& x)
return detail::make_getter(x, policy, is_member_pointer<D>(), 0L);
}
# if !BOOST_WORKAROUND(__EDG_VERSION__, <= 238) && !BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
# if !BOOST_WORKAROUND(__EDG_VERSION__, <= 238)
template <class D>
inline object make_getter(D const& d)
{
@@ -305,7 +305,7 @@ inline object make_setter(D& x)
return detail::make_setter(x, default_call_policies(), is_member_pointer<D>(), 0);
}
# if !(BOOST_WORKAROUND(BOOST_MSVC, <= 1300) || BOOST_WORKAROUND(__EDG_VERSION__, <= 238))
# if BOOST_WORKAROUND(__EDG_VERSION__, <= 238)
template <class D>
inline object make_setter(D const& x)
{

0
include/boost/python/def_visitor.hpp Normal file → Executable file
View File

View File

@@ -23,7 +23,7 @@ namespace detail
{
// for "readable" error messages
template <class T> struct specify_a_return_value_policy_to_wrap_functions_returning
# if defined(__GNUC__) && __GNUC__ >= 3 || defined(__EDG__)
# if defined(__GNUC__) || defined(__EDG__)
{}
# endif
;

View File

@@ -19,7 +19,6 @@ template<class T> class borrowed
typedef T type;
};
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
struct is_borrowed_ptr
{
@@ -68,35 +67,6 @@ struct is_borrowed_ptr<T*>
};
# endif
# else // no partial specialization
typedef char (&yes_borrowed_ptr_t)[1];
typedef char (&no_borrowed_ptr_t)[2];
no_borrowed_ptr_t is_borrowed_ptr_test(...);
template <class T>
typename mpl::if_c<
is_pointer<T>::value
, T
, int
>::type
is_borrowed_ptr_test1(boost::type<T>);
template<typename T>
yes_borrowed_ptr_t is_borrowed_ptr_test(borrowed<T> const volatile*);
template<typename T>
class is_borrowed_ptr
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_borrowed_ptr_test(is_borrowed_ptr_test1(boost::type<T>())))
== sizeof(detail::yes_borrowed_ptr_t)));
};
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
}

View File

@@ -29,9 +29,6 @@
# endif
# if defined(BOOST_MSVC)
# if _MSC_VER < 1300
# define BOOST_MSVC6_OR_EARLIER 1
# endif
# pragma warning (disable : 4786) // disable truncated debug symbols
# pragma warning (disable : 4251) // disable exported dll function

View File

@@ -8,13 +8,7 @@
namespace boost { namespace python { namespace detail {
template <class T, class Arg>
void construct_pointee(void* storage, Arg& x
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
, T const volatile*
# else
, T const*
# endif
)
void construct_pointee(void* storage, Arg& x, T const volatile*)
{
new (storage) T(x);
}

0
include/boost/python/detail/convertible.hpp Normal file → Executable file
View File

0
include/boost/python/detail/copy_ctor_mutates_rhs.hpp Normal file → Executable file
View File

View File

@@ -12,7 +12,7 @@ template <bool is_const_, bool is_volatile_>
struct cv_tag
{
BOOST_STATIC_CONSTANT(bool, is_const = is_const_);
BOOST_STATIC_CONSTANT(bool, is_volatile = is_const_);
BOOST_STATIC_CONSTANT(bool, is_volatile = is_volatile_);
};
typedef cv_tag<false,false> cv_unqualified;

0
include/boost/python/detail/def_helper_fwd.hpp Normal file → Executable file
View File

View File

@@ -7,25 +7,12 @@
# include <boost/type_traits/is_array.hpp>
# include <boost/detail/workaround.hpp>
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
# include <boost/type_traits/is_enum.hpp>
# endif
namespace boost { namespace python { namespace detail {
template <
bool array
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
, bool enum_ // vc7 has a problem destroying enums
# endif
> struct value_destroyer;
template <bool array> struct value_destroyer;
template <>
struct value_destroyer<
false
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
, false
# endif
>
struct value_destroyer<false>
{
template <class T>
static void execute(T const volatile* p)
@@ -35,12 +22,7 @@ struct value_destroyer<
};
template <>
struct value_destroyer<
true
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
, false
# endif
>
struct value_destroyer<true>
{
template <class A, class T>
static void execute(A*, T const volatile* const first)
@@ -49,9 +31,6 @@ struct value_destroyer<
{
value_destroyer<
boost::is_array<T>::value
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
, boost::is_enum<T>::value
# endif
>::execute(p);
}
}
@@ -63,25 +42,6 @@ struct value_destroyer<
}
};
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
template <>
struct value_destroyer<true,true>
{
template <class T>
static void execute(T const volatile*)
{
}
};
template <>
struct value_destroyer<false,true>
{
template <class T>
static void execute(T const volatile*)
{
}
};
# endif
template <class T>
inline void destroy_referent_impl(void* p, T& (*)())
{
@@ -89,9 +49,6 @@ inline void destroy_referent_impl(void* p, T& (*)())
// must come *before* T for metrowerks
value_destroyer<
(boost::is_array<T>::value)
# if BOOST_WORKAROUND(BOOST_MSVC, == 1300)
, (boost::is_enum<T>::value)
# endif
>::execute((const volatile T*)p);
}

View File

@@ -7,40 +7,7 @@
# include <boost/python/detail/sfinae.hpp>
# include <boost/detail/workaround.hpp>
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
# include <boost/mpl/if.hpp>
namespace boost { namespace python { namespace detail {
template <class T> struct always_void { typedef void type; };
template <class C, class T = int>
struct enable_if_arg
{
typedef typename mpl::if_<C,T,int&>::type type;
};
template <class C, class T = int>
struct disable_if_arg
{
typedef typename mpl::if_<C,int&,T>::type type;
};
template <class C, class T = typename always_void<C>::type>
struct enable_if_ret
{
typedef typename mpl::if_<C,T,int[2]>::type type;
};
template <class C, class T = typename always_void<C>::type>
struct disable_if_ret
{
typedef typename mpl::if_<C,int[2],T>::type type;
};
}}} // namespace boost::python::detail
# elif !defined(BOOST_NO_SFINAE)
#if !defined(BOOST_NO_SFINAE)
# include <boost/utility/enable_if.hpp>
namespace boost { namespace python { namespace detail {

View File

@@ -10,23 +10,9 @@ namespace boost { namespace python { namespace detail {
// Allows us to force the argument to be instantiated without
// incurring unused variable warnings
# if !defined(BOOST_MSVC) || BOOST_MSVC < 1300 || _MSC_FULL_VER > 13102196
template <class T>
inline void force_instantiate(T const&) {}
# else
# pragma optimize("g", off)
inline void force_instantiate_impl(...) {}
# pragma optimize("", on)
template <class T>
inline void force_instantiate(T const& x)
{
detail::force_instantiate_impl(&x);
}
# endif
}}} // namespace boost::python::detail
#endif // FORCE_INSTANTIATE_DWA200265_HPP

View File

@@ -25,46 +25,11 @@ struct if_selected
};
};
# if defined(BOOST_MSVC) && (BOOST_MSVC == 1300)
namespace msvc70_aux {
template< bool > struct inherit_from
{
template< typename T > struct result
{
typedef T type;
};
};
template<> struct inherit_from<true>
{
template< typename T > struct result
{
struct type {};
};
};
template< typename T >
struct never_true
{
BOOST_STATIC_CONSTANT(bool, value = false);
};
} // namespace msvc70_aux
#endif // # if defined(BOOST_MSVC) && (BOOST_MSVC == 1300)
template <class T>
struct elif_selected
{
# if !(defined(BOOST_MSVC) && BOOST_MSVC <= 1300 || defined(__MWERKS__) && __MWERKS__ <= 0x2407)
# if !(defined(__MWERKS__) && __MWERKS__ <= 0x2407)
template <class U> class then;
# elif defined(BOOST_MSVC) && (BOOST_MSVC == 1300)
template <class U>
struct then : msvc70_aux::inherit_from< msvc70_aux::never_true<U>::value >
::template result< if_selected<T> >::type
{
};
# else
template <class U>
struct then : if_selected<T>
@@ -73,7 +38,7 @@ struct elif_selected
# endif
};
# if !(defined(BOOST_MSVC) && BOOST_MSVC <= 1300 || defined(__MWERKS__) && __MWERKS__ <= 0x2407)
# if !(defined(__MWERKS__) && __MWERKS__ <= 0x2407)
template <class T>
template <class U>
class elif_selected<T>::then : public if_selected<T>

0
include/boost/python/detail/is_shared_ptr.hpp Normal file → Executable file
View File

0
include/boost/python/detail/is_wrapper.hpp Normal file → Executable file
View File

View File

@@ -7,15 +7,18 @@
#include <typeinfo>
#include <boost/type.hpp>
#include <boost/type_traits/config.hpp>
//
// Fix for MSVC's broken typeid() implementation which doesn't strip
// Fix for icc's broken typeid() implementation which doesn't strip
// decoration. This fix doesn't handle cv-qualified array types. It
// could probably be done, but I haven't figured it out yet.
//
# if defined(BOOST_MSVC) && BOOST_MSVC <= 1300 || defined(BOOST_INTEL_CXX_VERSION) && BOOST_INTEL_CXX_VERSION <= 700
// Note: This file is badly named. It initially was MSVC specific, but was
// extended to cover intel too. Now the old version of MSVC is no longer
// supported, but the intel version is still supported.
# if defined(BOOST_INTEL_CXX_VERSION) && BOOST_INTEL_CXX_VERSION <= 700
namespace boost { namespace python { namespace detail {
@@ -44,8 +47,14 @@ inline typeinfo typeid_ref(type<T>*, ...)
return detail::typeid_ref_1((T(*)())0);
}
#if defined(BOOST_MSVC) || (defined(__BORLANDC__) && !defined(BOOST_DISABLE_WIN32))
# define BOOST_PYTT_DECL __cdecl
#else
# define BOOST_PYTT_DECL /**/
#endif
template< typename T > T&(* is_ref_tester1(type<T>) )(type<T>) { return 0; }
inline char BOOST_TT_DECL is_ref_tester1(...) { return 0; }
inline char BOOST_PYTT_DECL is_ref_tester1(...) { return 0; }
template <class T>
inline typeinfo msvc_typeid(boost::type<T>*)
@@ -71,5 +80,5 @@ inline typeinfo assert_array_typeid_compiles()
}}} // namespace boost::python::detail
# endif // BOOST_MSVC
# endif // BOOST_INTEL_CXX_VERSION
#endif // MSVC_TYPEINFO_DWA200222_HPP

View File

0
include/boost/python/detail/prefix.hpp Normal file → Executable file
View File

0
include/boost/python/detail/python_type.hpp Normal file → Executable file
View File

View File

@@ -42,7 +42,6 @@ union aligned_storage
// but sizeof() is broken in CodeWarriors <= 8.0
template <class T> struct referent_size;
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T>
struct referent_size<T&>
@@ -51,15 +50,6 @@ union aligned_storage
std::size_t, value = sizeof(T));
};
# else
template <class T> struct referent_size
{
static T f();
BOOST_STATIC_CONSTANT(std::size_t, value = sizeof(f()));
};
# endif
// A metafunction returning a POD type which can store U, where T ==
// U&. If T is not a reference type, returns a POD which can store T.

View File

@@ -43,9 +43,7 @@ namespace boost { namespace python { namespace detail {
template <class R, class T>
boost::type<R>* result(R (T::*), int = 0) { return 0; }
# if (defined(BOOST_MSVC) && _MSC_FULL_VER <= 13102140) \
|| (defined(__GNUC__) && __GNUC__ < 3) \
|| (defined(__MWERKS__) && __MWERKS__ < 0x3000)
# if (defined(__MWERKS__) && __MWERKS__ < 0x3000)
// This code actually works on all implementations, but why use it when we don't have to?
template <class T>
struct get_result_type

0
include/boost/python/detail/sfinae.hpp Normal file → Executable file
View File

View File

@@ -14,7 +14,6 @@
namespace boost { namespace python { namespace detail {
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T>
struct is_string_literal : mpl::false_
{
@@ -45,43 +44,6 @@ struct is_string_literal<T[n]>
{
};
# endif
# else
template <bool is_array = true>
struct string_literal_helper
{
typedef char (&yes_string_literal)[1];
typedef char (&no_string_literal)[2];
template <class T>
struct apply
{
typedef apply<T> self;
static T x;
static yes_string_literal check(char const*);
static no_string_literal check(char*);
static no_string_literal check(void const volatile*);
BOOST_STATIC_CONSTANT(
bool, value = sizeof(self::check(x)) == sizeof(yes_string_literal));
typedef mpl::bool_<value> type;
};
};
template <>
struct string_literal_helper<false>
{
template <class T>
struct apply : mpl::false_
{
};
};
template <class T>
struct is_string_literal
: string_literal_helper<is_array<T>::value>::apply<T>
{
};
# endif
}}} // namespace boost::python::detail

View File

@@ -30,10 +30,6 @@
# include <boost/mpl/vector/vector10.hpp>
# endif
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
# include <boost/python/detail/type_list_impl.hpp>
# else
# include <boost/python/detail/type_list_impl_no_pts.hpp>
# endif
#endif // TYPE_LIST_DWA2002913_HPP

View File

@@ -1,107 +0,0 @@
#ifndef BOOST_PP_IS_ITERATING
// Copyright David Abrahams 2002.
// Distributed under the Boost Software License, Version 1.0. (See
// accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
# ifndef TYPE_LIST_IMPL_NO_PTS_DWA2002913_HPP
# define TYPE_LIST_IMPL_NO_PTS_DWA2002913_HPP
# include <boost/python/detail/type_list.hpp>
# include <boost/preprocessor/enum_params.hpp>
# include <boost/preprocessor/enum_params_with_a_default.hpp>
# include <boost/preprocessor/cat.hpp>
# include <boost/preprocessor/repeat.hpp>
# include <boost/preprocessor/empty.hpp>
# include <boost/preprocessor/iterate.hpp>
# include <boost/mpl/void.hpp>
namespace boost { namespace python { namespace detail {
template< typename T >
struct is_list_arg
{
enum { value = true };
};
template<>
struct is_list_arg<mpl::void_>
{
enum { value = false };
};
template<int> struct type_list_impl_chooser;
# define BOOST_PYTHON_LIST_ACTUAL_PARAMS BOOST_PP_ENUM_PARAMS_Z(1,BOOST_PYTHON_LIST_SIZE,T)
# define BOOST_PYTHON_LIST_FORMAL_PARAMS BOOST_PP_ENUM_PARAMS_Z(1,BOOST_PYTHON_LIST_SIZE,class T)
# define BOOST_PP_ITERATION_PARAMS_1 \
(3, (0, BOOST_PYTHON_LIST_SIZE, <boost/python/detail/type_list_impl_no_pts.hpp>))
# include BOOST_PP_ITERATE()
# define BOOST_PYTHON_PLUS() +
# define BOOST_PYTHON_IS_LIST_ARG(z, n, data) \
BOOST_PP_IF(n, BOOST_PYTHON_PLUS, BOOST_PP_EMPTY)() \
is_list_arg< BOOST_PP_CAT(T,n) >::value
template<
BOOST_PYTHON_LIST_FORMAL_PARAMS
>
struct type_list_count_args
{
enum { value =
BOOST_PP_REPEAT_1(BOOST_PYTHON_LIST_SIZE, BOOST_PYTHON_IS_LIST_ARG, _)
};
};
template<
BOOST_PYTHON_LIST_FORMAL_PARAMS
>
struct type_list_impl
{
typedef type_list_count_args< BOOST_PYTHON_LIST_ACTUAL_PARAMS > arg_num_;
typedef typename detail::type_list_impl_chooser< arg_num_::value >
::template result_< BOOST_PYTHON_LIST_ACTUAL_PARAMS >::type type;
};
template<
BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT(BOOST_PYTHON_LIST_SIZE, class T, mpl::void_)
>
struct type_list
: detail::type_list_impl< BOOST_PYTHON_LIST_ACTUAL_PARAMS >::type
{
typedef typename detail::type_list_impl<
BOOST_PYTHON_LIST_ACTUAL_PARAMS
>::type type;
};
# undef BOOST_PYTHON_IS_LIST_ARG
# undef BOOST_PYTHON_PLUS
# undef BOOST_PYTHON_LIST_FORMAL_PARAMS
# undef BOOST_PYTHON_LIST_ACTUAL_PARAMS
}}} // namespace boost::python::detail
# endif // TYPE_LIST_IMPL_NO_PTS_DWA2002913_HPP
#else // BOOST_PP_IS_ITERATING
# define N BOOST_PP_ITERATION()
template<>
struct type_list_impl_chooser<N>
{
template<
BOOST_PYTHON_LIST_FORMAL_PARAMS
>
struct result_
{
typedef typename BOOST_PP_CAT(mpl::vector,N)<
BOOST_PP_ENUM_PARAMS(N, T)
>::type type;
};
};
# undef N
#endif // BOOST_PP_IS_ITERATING

0
include/boost/python/detail/unwind_type.hpp Normal file → Executable file
View File

0
include/boost/python/detail/unwrap_type_id.hpp Normal file → Executable file
View File

0
include/boost/python/detail/unwrap_wrapper.hpp Normal file → Executable file
View File

0
include/boost/python/detail/value_arg.hpp Normal file → Executable file
View File

View File

@@ -9,35 +9,6 @@
# include <boost/mpl/bool.hpp>
# include <boost/preprocessor/enum_params.hpp>
# if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
# include <boost/type_traits/is_reference.hpp>
# include <boost/type_traits/add_reference.hpp>
# define BOOST_PYTHON_VALUE_IS_XXX_DEF(name, qualified_name, nargs) \
template <class X_> \
struct value_is_##name \
{ \
typedef char yes; \
typedef char (&no)[2]; \
\
static typename add_reference<X_>::type dummy; \
\
template < BOOST_PP_ENUM_PARAMS_Z(1, nargs, class U) > \
static yes test( \
qualified_name< BOOST_PP_ENUM_PARAMS_Z(1, nargs, U) > const&, int \
); \
\
template <class U> \
static no test(U&, ...); \
\
BOOST_STATIC_CONSTANT( \
bool, value \
= (sizeof(test(dummy, 0)) == sizeof(yes))); \
\
typedef mpl::bool_<value> type; \
};
# else
# include <boost/type_traits/remove_reference.hpp>
# include <boost/type_traits/remove_cv.hpp>
@@ -57,6 +28,5 @@ struct value_is_##name \
\
};
# endif
#endif // VALUE_IS_XXX_DWA2003224_HPP

0
include/boost/python/detail/wrapper_base.hpp Normal file → Executable file
View File

0
include/boost/python/docstring_options.hpp Normal file → Executable file
View File

View File

@@ -8,6 +8,7 @@
# include <boost/python/detail/prefix.hpp>
# include <boost/bind.hpp>
# include <boost/bind/placeholders.hpp>
# include <boost/type.hpp>
# include <boost/python/detail/translate_exception.hpp>
# include <boost/python/detail/exception_handler.hpp>

View File

@@ -21,8 +21,7 @@
# include <boost/python/detail/void_return.hpp>
# include <boost/call_traits.hpp>
#if BOOST_WORKAROUND(BOOST_MSVC, <= 1300) || BOOST_WORKAROUND(BOOST_INTEL_WIN, <= 900)
// workaround for VC++ 6.x or 7.0
#if BOOST_WORKAROUND(BOOST_INTEL_WIN, <= 900)
# define BOOST_EXTRACT_WORKAROUND ()
#else
# define BOOST_EXTRACT_WORKAROUND

View File

@@ -87,8 +87,6 @@ class handle
return *this;
}
#if !defined(BOOST_MSVC) || (BOOST_MSVC >= 1300)
template<typename Y>
handle& operator=(handle<Y> const & r) // never throws
{
@@ -97,8 +95,6 @@ class handle
return *this;
}
#endif
template <typename Y>
handle(handle<Y> const& r)
: m_p(python::xincref(python::upcast<T>(r.get())))
@@ -159,7 +155,6 @@ typedef handle<PyTypeObject> type_handle;
//
// Compile-time introspection
//
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
class is_handle
{
@@ -173,28 +168,6 @@ class is_handle<handle<T> >
public:
BOOST_STATIC_CONSTANT(bool, value = true);
};
# else
namespace detail
{
typedef char (&yes_handle_t)[1];
typedef char (&no_handle_t)[2];
no_handle_t is_handle_test(...);
template<typename T>
yes_handle_t is_handle_test(boost::type< handle<T> >);
}
template<typename T>
class is_handle
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_handle_test(boost::type<T>()))
== sizeof(detail::yes_handle_t)));
};
# endif
//
// implementations

0
include/boost/python/handle_fwd.hpp Normal file → Executable file
View File

View File

@@ -76,27 +76,6 @@ namespace detail
//
// This metaprogram checks if T is an optional
//
#if defined(BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION)
template <class T>
struct is_optional {
private:
template <BOOST_PYTHON_OVERLOAD_TYPES>
static boost::type_traits::yes_type f(optional<BOOST_PYTHON_OVERLOAD_ARGS>);
static boost::type_traits::no_type f(...);
static T t();
public:
BOOST_STATIC_CONSTANT(
bool, value =
sizeof(f(t())) == sizeof(::boost::type_traits::yes_type));
typedef mpl::bool_<value> type;
};
#else
template <class T>
struct is_optional
@@ -108,7 +87,6 @@ namespace detail
: mpl::true_
{};
#endif
template <int NDefaults>
struct define_class_init_helper;

View File

@@ -104,14 +104,6 @@ namespace detail
// If the BasePolicy_ supplied a result converter it would be
// ignored; issue an error if it's not the default.
#if defined _MSC_VER && _MSC_VER < 1300
typedef is_same<
typename BasePolicy_::result_converter
, default_result_converter
> same_result_converter;
//see above for explanation
BOOST_STATIC_ASSERT(same_result_converter::value) ;
#else
BOOST_MPL_ASSERT_MSG(
(is_same<
typename BasePolicy_::result_converter
@@ -120,7 +112,6 @@ namespace detail
, MAKE_CONSTRUCTOR_SUPPLIES_ITS_OWN_RESULT_CONVERTER_THAT_WOULD_OVERRIDE_YOURS
, (typename BasePolicy_::result_converter)
);
#endif
typedef constructor_result_converter result_converter;
typedef offset_args<typename BasePolicy_::argument_package, mpl::int_<1> > argument_package;
};

View File

@@ -17,7 +17,7 @@ namespace detail
{
template <class R>
struct manage_new_object_requires_a_pointer_return_type
# if defined(__GNUC__) && __GNUC__ >= 3 || defined(__EDG__)
# if defined(__GNUC__) || defined(__EDG__)
{}
# endif
;

0
include/boost/python/object.hpp Normal file → Executable file
View File

View File

@@ -53,11 +53,7 @@ struct register_base_of
template <class Base>
inline void operator()(Base*) const
{
# if !BOOST_WORKAROUND(BOOST_MSVC, == 1200)
BOOST_MPL_ASSERT_NOT((is_same<Base,Derived>));
# else
BOOST_STATIC_ASSERT(!(is_same<Base,Derived>::value));
# endif
// Register the Base class
register_dynamic_id<Base>();

View File

@@ -12,13 +12,7 @@
# include <boost/ref.hpp>
# include <boost/python/detail/value_arg.hpp>
# include <boost/python/detail/copy_ctor_mutates_rhs.hpp>
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
# include <boost/type_traits/is_enum.hpp>
# include <boost/mpl/and.hpp>
# include <boost/mpl/not.hpp>
# else
# include <boost/mpl/or.hpp>
# endif
# include <boost/mpl/or.hpp>
namespace boost { namespace python { namespace objects {
@@ -42,24 +36,13 @@ struct reference_to_value
template <class T>
struct forward
: mpl::if_<
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
// vc6 chokes on unforwarding enums nested in classes
mpl::and_<
is_scalar<T>
, mpl::not_<
is_enum<T>
>
>
# else
mpl::or_<python::detail::copy_ctor_mutates_rhs<T>, is_scalar<T> >
# endif
, T
, reference_to_value<T>
>
{
};
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
struct unforward
{
@@ -86,88 +69,6 @@ struct unforward_cref<reference_to_value<T> >
{
};
# else // no partial specialization
namespace detail
{
typedef char (&yes_reference_to_value_t)[1];
typedef char (&no_reference_to_value_t)[2];
no_reference_to_value_t is_reference_to_value_test(...);
template<typename T>
yes_reference_to_value_t is_reference_to_value_test(boost::type< reference_to_value<T> >);
template<bool wrapped>
struct unforwarder
{
template <class T>
struct apply
{
typedef typename unwrap_reference<T>::type& type;
};
};
template<>
struct unforwarder<true>
{
template <class T>
struct apply
{
typedef typename T::reference type;
};
};
template<bool wrapped = false>
struct cref_unforwarder
{
template <class T>
struct apply
: python::detail::value_arg<
typename unwrap_reference<T>::type
>
{
};
};
template<>
struct cref_unforwarder<true>
{
template <class T>
struct apply
: python::detail::value_arg<
typename T::reference
>
{
};
};
template<typename T>
struct is_reference_to_value
{
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(is_reference_to_value_test(boost::type<T>()))
== sizeof(yes_reference_to_value_t)));
typedef mpl::bool_<value> type;
};
}
template <typename T>
struct unforward
: public detail::unforwarder<
detail::is_reference_to_value<T>::value
>::template apply<T>
{};
template <typename T>
struct unforward_cref
: public detail::cref_unforwarder<
detail::is_reference_to_value<T>::value
>::template apply<T>
{};
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T>
typename reference_to_value<T>::reference

0
include/boost/python/object/function_doc_signature.hpp Normal file → Executable file
View File

0
include/boost/python/object/inheritance_query.hpp Normal file → Executable file
View File

View File

@@ -71,35 +71,7 @@ struct iterator_range
# endif
};
# ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
// for compilers which can't deduce the value_type of pointers, we
// have a special implementation of next. This takes advantage of
// the fact that T* results are treated like T& results by
// Boost.Python's function wrappers.
struct next_ptr
{
typedef Iterator result_type;
result_type
operator()(iterator_range<NextPolicies,Iterator>& self)
{
if (self.m_start == self.m_finish)
stop_iteration_error();
return self.m_start++;
}
};
typedef mpl::if_<
is_same<
boost::detail::please_invoke_BOOST_TT_BROKEN_COMPILER_SPEC_on_cv_unqualified_pointee<Iterator>
, typename traits_t::value_type
>
, next_ptr
, next
>::type next_fn;
# else
typedef next next_fn;
# endif
object m_sequence; // Keeps the sequence alive while iterating.
Iterator m_start;

View File

@@ -46,11 +46,7 @@ template <class T> class wrapper;
namespace boost { namespace python { namespace objects {
# if BOOST_WORKAROUND(__GNUC__, == 2)
# define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) (typename unforward<A##n>::type)objects::do_unforward(a##n,0)
# else
# define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) objects::do_unforward(a##n,0)
# endif
#define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) objects::do_unforward(a##n,0)
template <class Pointer, class Value>
struct pointer_holder : instance_holder

0
include/boost/python/object/stl_iterator_core.hpp Normal file → Executable file
View File

View File

@@ -33,11 +33,7 @@
namespace boost { namespace python { namespace objects {
# if BOOST_WORKAROUND(__GNUC__, == 2)
# define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) (typename unforward<A##n>::type)objects::do_unforward(a##n,0)
# else
# define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) objects::do_unforward(a##n,0)
# endif
#define BOOST_PYTHON_UNFORWARD_LOCAL(z, n, _) BOOST_PP_COMMA_IF(n) objects::do_unforward(a##n,0)
template <class Value>
struct value_holder : instance_holder

View File

@@ -36,12 +36,6 @@
# include <boost/type_traits/is_convertible.hpp>
# include <boost/type_traits/remove_reference.hpp>
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
# include <boost/type_traits/add_pointer.hpp>
# endif
# include <boost/mpl/if.hpp>
namespace boost { namespace python {
namespace detail
@@ -98,11 +92,7 @@ namespace api
class object_operators : public def_visitor<U>
{
protected:
# if !defined(BOOST_MSVC) || BOOST_MSVC >= 1300
typedef object const& object_cref;
# else
typedef object object_cref;
# endif
public:
// function call
//
@@ -139,25 +129,11 @@ namespace api
template <class T>
const_object_item
operator[](T const& key) const
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
;
# else
{
return (*this)[object(key)];
}
# endif
operator[](T const& key) const;
template <class T>
object_item
operator[](T const& key)
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
;
# else
{
return (*this)[object(key)];
}
# endif
operator[](T const& key);
// slicing
//
@@ -175,29 +151,11 @@ namespace api
template <class T, class V>
const_object_slice
slice(T const& start, V const& end) const
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
;
# else
{
return this->slice(
slice_bound<T>::type(start)
, slice_bound<V>::type(end));
}
# endif
slice(T const& start, V const& end) const;
template <class T, class V>
object_slice
slice(T const& start, V const& end)
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
;
# else
{
return this->slice(
slice_bound<T>::type(start)
, slice_bound<V>::type(end));
}
# endif
slice(T const& start, V const& end);
private: // def visitation for adding callable objects as class methods
@@ -248,26 +206,6 @@ namespace api
PyObject* m_ptr;
};
# ifdef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template <class T, class U>
struct is_derived_impl
{
static T x;
template <class X>
static X* to_pointer(X const&);
static char test(U const*);
typedef char (&no)[2];
static no test(...);
BOOST_STATIC_CONSTANT(bool, value = sizeof(test(to_pointer(x))) == 1);
};
template <class T, class U>
struct is_derived
: mpl::bool_<is_derived_impl<T,U>::value>
{};
# else
template <class T, class U>
struct is_derived
: is_convertible<
@@ -275,28 +213,13 @@ namespace api
, U const*
>
{};
# endif
template <class T>
typename objects::unforward_cref<T>::type do_unforward_cref(T const& x)
{
# if BOOST_WORKAROUND(__GNUC__, == 2)
typedef typename objects::unforward_cref<T>::type ret;
return ret(x);
# else
return x;
# endif
}
# if BOOST_WORKAROUND(__GNUC__, == 2)
// GCC 2.x has non-const string literals; this hacks around that problem.
template <unsigned N>
char const (& do_unforward_cref(char const(&x)[N]) )[N]
{
return x;
}
# endif
class object;
template <class T>
@@ -323,14 +246,7 @@ namespace api
// explicit conversion from any C++ object to Python
template <class T>
explicit object(
T const& x
# if BOOST_WORKAROUND(BOOST_MSVC, < 1300)
// use some SFINAE to un-confuse MSVC about its
// copy-initialization ambiguity claim.
, typename mpl::if_<is_proxy<T>,int&,int>::type* = 0
# endif
)
explicit object(T const& x)
: object_base(object_base_initializer(x))
{
}

View File

@@ -44,7 +44,6 @@ object_operators<U>::operator[](object_cref key) const
return const_object_item(x, key);
}
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
template <class U>
template <class T>
inline const_object_item
@@ -60,8 +59,6 @@ object_operators<U>::operator[](T const& key)
{
return (*this)[object(key)];
}
# endif
inline object const_item_policies::get(object const& target, object const& key)
{

0
include/boost/python/object_protocol_core.hpp Normal file → Executable file
View File

View File

@@ -99,7 +99,7 @@ object_operators<U>::slice(object_cref start, slice_nil) const
object_cref2 x = *static_cast<U const*>(this);
return const_object_slice(x, api::slice_key(borrowed(start.ptr()), allow_null((PyObject*)0)));
}
# if !defined(BOOST_MSVC) || BOOST_MSVC > 1300
template <class U>
template <class T, class V>
inline const_object_slice
@@ -119,8 +119,6 @@ object_operators<U>::slice(T const& start, V const& end)
typename slice_bound<T>::type(start)
, typename slice_bound<V>::type(end));
}
# endif
inline object const_slice_policies::get(object const& target, key_type const& key)
{

View File

@@ -172,12 +172,6 @@ PyTypeObject opaque<Pointee>::type_object =
};
}} // namespace boost::python
# if BOOST_WORKAROUND(BOOST_MSVC, <= 1300)
# define BOOST_PYTHON_OPAQUE_SPECIALIZED_TYPE_ID(Pointee)
# else
// If you change the below, don't forget to alter the end of type_id.hpp
# define BOOST_PYTHON_OPAQUE_SPECIALIZED_TYPE_ID(Pointee) \
namespace boost { namespace python { \
@@ -193,6 +187,4 @@ PyTypeObject opaque<Pointee>::type_object =
} \
}}
# endif
# endif // OPAQUE_POINTER_CONVERTER_HPP_

View File

@@ -7,9 +7,7 @@
// accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
# if _MSC_VER+0 >= 1020
# pragma once
# endif
# pragma once
# include <boost/config.hpp>
@@ -20,7 +18,6 @@ template<class T> struct other
typedef T type;
};
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
namespace detail
{
template<typename T>
@@ -51,63 +48,6 @@ namespace detail
typedef T type;
};
}
# else // no partial specialization
}} // namespace boost::python
#include <boost/type.hpp>
namespace boost { namespace python {
namespace detail
{
typedef char (&yes_other_t)[1];
typedef char (&no_other_t)[2];
no_other_t is_other_test(...);
template<typename T>
yes_other_t is_other_test(type< other<T> >);
template<bool wrapped>
struct other_unwrapper
{
template <class T>
struct apply
{
typedef T type;
};
};
template<>
struct other_unwrapper<true>
{
template <class T>
struct apply
{
typedef typename T::type type;
};
};
template<typename T>
class is_other
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_other_test(type<T>()))
== sizeof(detail::yes_other_t)));
};
template <typename T>
class unwrap_other
: public detail::other_unwrapper<
is_other<T>::value
>::template apply<T>
{};
}
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
}} // namespace boost::python

View File

@@ -15,11 +15,7 @@ class proxy : public object_operators<proxy<Policies> >
{
typedef typename Policies::key_type key_type;
# if !defined(BOOST_MSVC) || BOOST_MSVC >= 1300
typedef proxy const& assignment_self;
# else
typedef proxy assignment_self;
# endif
public:
proxy(object const& target, key_type const& key);
operator object() const;

View File

@@ -11,9 +11,7 @@
// Copyright (C) 1999, 2000 Jaakko Jarvi (jaakko.jarvi@cs.utu.fi)
// Copyright (C) 2001 Peter Dimov
# if _MSC_VER+0 >= 1020
# pragma once
# endif
# pragma once
# include <boost/config.hpp>
# include <boost/mpl/bool.hpp>
@@ -38,7 +36,6 @@ inline pointer_wrapper<T> ptr(T t)
return pointer_wrapper<T>(t);
}
# ifndef BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
template<typename T>
class is_pointer_wrapper
: public mpl::false_
@@ -64,64 +61,6 @@ class unwrap_pointer<pointer_wrapper<T> >
public:
typedef T type;
};
# else // no partial specialization
}} // namespace boost::python
#include <boost/type.hpp>
namespace boost { namespace python {
namespace detail
{
typedef char (&yes_pointer_wrapper_t)[1];
typedef char (&no_pointer_wrapper_t)[2];
no_pointer_wrapper_t is_pointer_wrapper_test(...);
template<typename T>
yes_pointer_wrapper_t is_pointer_wrapper_test(boost::type< pointer_wrapper<T> >);
template<bool wrapped>
struct pointer_unwrapper
{
template <class T>
struct apply
{
typedef T type;
};
};
template<>
struct pointer_unwrapper<true>
{
template <class T>
struct apply
{
typedef typename T::type type;
};
};
}
template<typename T>
class is_pointer_wrapper
{
public:
BOOST_STATIC_CONSTANT(
bool, value = (
sizeof(detail::is_pointer_wrapper_test(boost::type<T>()))
== sizeof(detail::yes_pointer_wrapper_t)));
typedef mpl::bool_<value> type;
};
template <typename T>
class unwrap_pointer
: public detail::pointer_unwrapper<
is_pointer_wrapper<T>::value
>::template apply<T>
{};
# endif // BOOST_NO_TEMPLATE_PARTIAL_SPECIALIZATION
}} // namespace boost::python

Some files were not shown because too many files have changed in this diff Show More