pygccxml-commit Mailing List for C++ Python language bindings (Page 78)
Brought to you by:
mbaas,
roman_yakovenko
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
(190) |
Apr
(166) |
May
(170) |
Jun
(75) |
Jul
(105) |
Aug
(131) |
Sep
(99) |
Oct
(84) |
Nov
(67) |
Dec
(54) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(66) |
Feb
(49) |
Mar
(25) |
Apr
(62) |
May
(21) |
Jun
(34) |
Jul
(9) |
Aug
(21) |
Sep
(5) |
Oct
|
Nov
(63) |
Dec
(34) |
2008 |
Jan
(10) |
Feb
(42) |
Mar
(26) |
Apr
(25) |
May
(6) |
Jun
(40) |
Jul
(18) |
Aug
(29) |
Sep
(6) |
Oct
(32) |
Nov
(14) |
Dec
(56) |
2009 |
Jan
(127) |
Feb
(52) |
Mar
(2) |
Apr
(10) |
May
(29) |
Jun
(3) |
Jul
|
Aug
(16) |
Sep
(4) |
Oct
(11) |
Nov
(8) |
Dec
(14) |
2010 |
Jan
(31) |
Feb
(1) |
Mar
(7) |
Apr
(9) |
May
(1) |
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
(8) |
Mar
(4) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2014 |
Jan
|
Feb
|
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Roman <rom...@us...> - 2006-04-06 15:25:46
|
Update of /cvsroot/pygccxml/source/pyplusplus/decl_wrappers In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19758/pyplusplus/decl_wrappers Modified Files: decl_wrapper.py Log Message: changing calldef to self Index: decl_wrapper.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/decl_wrappers/decl_wrapper.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** decl_wrapper.py 6 Apr 2006 06:15:59 -0000 1.5 --- decl_wrapper.py 6 Apr 2006 15:25:38 -0000 1.6 *************** *** 90,94 **** #raise ! def readme( calldef ): """This function will returns some hints/tips/description of problems that applied to the declarations. For example function that has argument --- 90,94 ---- #raise ! def readme( self ): """This function will returns some hints/tips/description of problems that applied to the declarations. For example function that has argument |
From: Roman <rom...@us...> - 2006-04-06 13:24:00
|
Update of /cvsroot/pygccxml/source/pyplusplus/docs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31779/pyplusplus/docs Removed Files: pyplusplus_demo.png Log Message: This file will be moved to new location --- pyplusplus_demo.png DELETED --- |
From: Roman <rom...@us...> - 2006-04-06 13:15:36
|
Update of /cvsroot/pygccxml/source/pyplusplus/gui In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25089/pyplusplus/gui Modified Files: ui.py Added Files: ui_runner.py Log Message: 1. fixing small bug in ui.py 2. adding quick runner Index: ui.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/gui/ui.py,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** ui.py 6 Apr 2006 06:16:08 -0000 1.23 --- ui.py 6 Apr 2006 13:15:22 -0000 1.24 *************** *** 41,45 **** self._gccxml_location = Tkinter.Entry( self, width=35 ) self._gccxml_location.grid(row=2, column=0, columnspan=2) - self._gccxml_location.insert( 0, gccxml ) temp = Tkinter.Button( self, text="...", command=self._select_gccxml_executable ) --- 41,44 ---- --- NEW FILE: ui_runner.py --- import os import sys sys.path.append( os.path.abspath( './../../' ) ) import ui ui.show_demo() |
From: Roman <rom...@us...> - 2006-04-06 12:34:58
|
Update of /cvsroot/pygccxml/source/pyplusplus/docs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28483/pyplusplus/docs Modified Files: pyplusplus.rest Added Files: quotes.rest Log Message: Fixing introduction to pyplusplus. --- NEW FILE: quotes.rest --- =============================== What they say about pyplusplus? =============================== "... If you can, use pyplusplus over pyste. I say that for ALL users of pyste, pyplusplus is now mature enough to be useful as well as being actively developed. It can also do quite a few tricks pyste cannot. " Niall Douglas, the author of `TnFOX`_ library "... On a related note, I highly suggest that any users out there that have tried/used Pyste but have found it to be too lacking in power should really give pyplusplus a try. It has allowed me to do everything I ever wanted to do with Pyste and couldn't and then some. It is really a great tool and I can't thank Roman enough for taking the time to create it and make it available. " Allen Bierbaum, the author of `PyOpenSG`_ library .. _`TnFOX`: http://www.nedprod.com/TnFOX/ .. _`PyOpenSG`: https://realityforge.vrsource.org/view/PyOpenSG/WebHome .. Local Variables: mode: indented-text indent-tabs-mode: nil sentence-end-double-space: t fill-column: 70 End: Index: pyplusplus.rest =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/docs/pyplusplus.rest,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** pyplusplus.rest 6 Apr 2006 06:15:59 -0000 1.5 --- pyplusplus.rest 6 Apr 2006 12:34:45 -0000 1.6 *************** *** 42,47 **** Only very small and simple projects could be exported as is. Most of the projects ! still require human invocation. Basically there are 2 questions that an user ! should answer: 1. which declarations should be exported --- 42,47 ---- Only very small and simple projects could be exported as is. Most of the projects ! still require human invocation. Basically there are 2 questions that you should ! answer: 1. which declarations should be exported *************** *** 49,55 **** Of course `pyplusplus`_ can not answer those question, but it provides maximum ! help for the developer to implement/translate an user requirements to code. So ! what help a developer get from `pyplusplus`_ in order to deal with first question? ! `pyplusplus`_ provides very powerful query interface. For example in one line of code you can select all free functions that have --- 49,56 ---- Of course `pyplusplus`_ can not answer those question, but it provides maximum ! help for you to implement an user requirements. ! ! How can `pyplusplus`_ help you with first question? `pyplusplus`_ provides very ! powerful and simple query interface. For example in one line of code you can select all free functions that have *************** *** 75,102 **** mb.decls( lambda decl: 'impl' in decl.name ).exclude() ! Okay, enough with code. If you want to read more code please read the tutorials. ! I am sure you already noted some interesting detail: all queries does not specify ! declaration name. It is possible, but still, why I did not? Because this form ! allows you to setup few rules, that will continue to work even after C++ has ! been changed. Thus you don't have to modify code generator source code, every ! time exported C++ code was changed. So far, so good what about second question? Well, by default `pyplusplus`_ ! generates a code that will satisfy almost all developers. But sometimes a developer ! need to modify generated code. `pyplusplus`_ relevant classes could be configured ! in many ways. But sometimes this is still not enough. Sometimes a developer need ! full control over generated code. One of the bigest problems, that I believe ! `pyplusplus`_ solved, is modifying generated code. How many code generators did ! you use, that allow you to put your code any where, to reorder generated code as ! you wish? `pyplusplus`_ allows you to do that. `pyplusplus`_ introduces new concept: code creator and code creator's tree. ! Code creator responsibility is to create small well defined piece of code. ! For example *include_t* code creator is responsible to create code for C++ ! include directive. Code creators tree is an ordered set of code creators. ! Some of code creators can contain others. Module is the top level code creator. ! A developer is able to add, delete or modify single/group of code creators. ! Here you can find UML diagram of almost all code creators: `class diagram`_. .. _`class diagram`: ./code_creators.png --- 76,100 ---- mb.decls( lambda decl: 'impl' in decl.name ).exclude() ! Please, note the way queries were built. You can think about those queries as ! the rules, that will continue to work even after exported C++ code was changed. ! It means that you don't have to change code generator source code every time. So far, so good what about second question? Well, by default `pyplusplus`_ ! generates a code that will satisfy almost all developers. `pyplusplus`_ relevant ! classes could be configured in many ways to satisfy your needs. But sometimes ! this is still not enough. There are use cases when you need full control over ! generated code. One of the bigest problems, with code generators in general, is ! modifying generated code and preserving changes. How many code generators did ! you use or know, that allow you to put your code any where or to reorder generated ! code as you wish? `pyplusplus`_ allows you to do that. `pyplusplus`_ introduces new concept: code creator and code creator's tree. ! You can think about code creator's tree as some kind of `AST`_. The only difference ! is that code creator's tree has higher interface. For example ``include_t`` code ! creator is responsible to create C++ ``include`` directive code. You have full ! control over code creators tree, before it is written to disc. Here you ! can find UML diagram of almost all code creators: `class diagram`_. + .. _`AST`: http://en.wikipedia.org/wiki/Abstract_syntax_tree .. _`class diagram`: ./code_creators.png |
From: Roman <rom...@us...> - 2006-04-06 10:51:32
|
Update of /cvsroot/pygccxml/source/pygccxml/docs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19558/pygccxml/docs Modified Files: default.css generate_docs.py Log Message: fixing generated documentation look Index: generate_docs.py =================================================================== RCS file: /cvsroot/pygccxml/source/pygccxml/docs/generate_docs.py,v retrieving revision 1.34 retrieving revision 1.35 diff -C2 -d -r1.34 -r1.35 *** generate_docs.py 6 Apr 2006 06:15:57 -0000 1.34 --- generate_docs.py 6 Apr 2006 10:51:25 -0000 1.35 *************** *** 21,25 **** , '--docformat epytext' , '--url http://www.language-binding.net' - , '--css default.css' , '--name pygccxml' , ' '.join( packages ) ] --- 21,24 ---- Index: default.css =================================================================== RCS file: /cvsroot/pygccxml/source/pygccxml/docs/default.css,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** default.css 6 Apr 2006 06:15:57 -0000 1.5 --- default.css 6 Apr 2006 10:51:25 -0000 1.6 *************** *** 1,42 **** ! h1{ ! font-size: 120%; ! text-align: left; ! } ! caption { font-weight: bold } ! div.block { ! border: 1px solid #84b0c7; ! text-align: left; ! margin: 5px; ! margin-bottom: 10px; ! padding: 2px; } ! div.block ul { ! margin-top: 10px; ! margin-bottom: 10px; } ! div.title { ! border: 1px solid #84b0c7; ! text-align: center; ! margin: 2px; ! padding: 2px; } ! div.section h2{ ! text-decoration: none; ! font-size: 100%; } ! a.reference { ! color: #1a419d; ! text-align: right; } ! a{ color: #1a419d } ! a:visited{ color: #1a419d } - a:hover{ background-color: #ddddff } --- 1,327 ---- ! /* ! :Authors: David Goodger, David Abrahams ! :Contact: go...@us..., da...@bo... ! :date: $Date$ ! :version: $Revision$ ! :copyright: This stylesheet has been placed in the public domain. ! This stylesheet is for the use of ReStructuredText in a Boost context. ! It is basically an agglomeration of boost.css and the default.css that ! comes from docutils. ! */ ! ! .first { ! margin-top: 0 } ! ! .last { ! margin-bottom: 0 } ! ! a.toc-backref { ! text-decoration: none ; ! color: black } ! ! dd { ! margin-bottom: 0.5em } ! ! div.abstract { ! margin: 2em 5em } ! ! div.abstract p.topic-title { ! font-weight: bold ; ! text-align: center } ! ! div.attention, div.caution, div.danger, div.error, div.hint, ! div.important, div.note, div.tip, div.warning, div.admonition { ! margin: 2em ; ! border: medium outset ; ! padding: 1em } ! ! div.attention p.admonition-title, div.caution p.admonition-title, ! div.danger p.admonition-title, div.error p.admonition-title, ! div.warning p.admonition-title { ! color: red ; ! font-weight: bold ; ! font-family: sans-serif } ! ! div.hint p.admonition-title, div.important p.admonition-title, ! div.note p.admonition-title, div.tip p.admonition-title, ! div.admonition p.admonition-title { ! font-weight: bold ; ! font-family: sans-serif } ! ! div.dedication { ! margin: 2em 5em ; ! text-align: center ; ! font-style: italic } ! ! div.dedication p.topic-title { ! font-weight: bold ; ! font-style: normal } ! ! div.figure { ! margin-left: 2em } ! ! div.footer, div.header { ! font-size: smaller } ! ! div.line-block { display: block } ! div.line-block div.line-block { margin-left: 1.5em } ! ! div.sidebar { ! margin-left: 1em ; ! border: medium outset ; ! padding: 0em 1em ; ! background-color: #ffffee ; ! width: 40% ; ! float: right ; ! clear: right } ! ! div.sidebar p.rubric { ! font-family: sans-serif ; ! font-size: medium } ! ! div.system-messages { ! margin: 5em } ! ! div.system-messages h1 { ! color: red } ! ! div.system-message { ! border: medium outset ; ! padding: 1em } ! ! div.system-message p.system-message-title { ! color: red ; ! font-weight: bold } ! ! div.topic { ! margin: 2em } ! ! dt { ! font-weight: bold } ! H1.title ! { ! FONT-SIZE: 200%; ! COLOR: #00008B; ! text-align: center ! } ! H1 ! { ! FONT-SIZE: 150%; ! } ! H2 ! { ! FONT-SIZE: 125%; ! } ! h2.subtitle { ! text-align: center } ! H3 ! { ! FONT-SIZE: 108%; ! } ! BODY ! { ! FONT-SIZE: 100%; ! BACKGROUND-COLOR: #ffffff; ! } ! PRE ! { ! MARGIN-LEFT: 2em; ! FONT-FAMILY: Courier; ! } ! CODE ! { ! FONT-FAMILY: Courier; ! white-space: pre; ! } ! .pre ! { ! FONT-FAMILY: Courier; ! white-space: pre; ! } ! .index ! { ! TEXT-ALIGN: left; ! } ! .page-index ! { ! TEXT-ALIGN: left; ! } ! .definition ! { ! TEXT-ALIGN: left; ! } ! .footnote ! { ! FONT-SIZE: 80%; ! VERTICAL-ALIGN: super; ! TEXT-DECORATION: none; ! } ! .function-semantics ! { ! CLEAR: left; } ! hr { ! width: 75% } ! ! ol.simple, ul.simple { ! margin-bottom: 1em } ! ! ol.arabic { ! list-style: decimal } ! ! ol.loweralpha { ! list-style: lower-alpha } ! ! ol.upperalpha { ! list-style: upper-alpha } ! ! ol.lowerroman { ! list-style: lower-roman } ! ! ol.upperroman { ! list-style: upper-roman } ! ! p.attribution { ! text-align: right ; ! margin-left: 50% } ! ! p.caption { ! font-style: italic } ! ! p.credits { ! font-style: italic ; ! font-size: smaller } ! ! p.label { ! white-space: nowrap } ! ! p.rubric { ! font-weight: bold ; ! font-size: larger ; ! color: maroon ; ! text-align: center } ! ! p.sidebar-title { ! font-family: sans-serif ; ! font-weight: bold ; ! font-size: larger } ! ! p.sidebar-subtitle { ! font-family: sans-serif ; ! font-weight: bold } ! ! p.topic-title { ! font-weight: bold } ! ! pre.address { ! margin-bottom: 0 ; ! margin-top: 0 ; ! font-family: serif ; ! font-size: 100% } ! ! pre.line-block { ! font-family: serif ; ! font-size: 100% } ! ! pre.literal-block, pre.doctest-block { ! margin-left: 2em ; ! margin-right: 2em ; ! background-color: #eeeeee } ! ! span.class { ! font-family: monospace; } ! span.classifier { ! font-family: sans-serif ; ! font-style: oblique } ! ! span.classifier-delimiter { ! font-family: sans-serif ; ! font-weight: bold } ! ! span.doublesize { ! font-size: 200% } ! span.interpreted { ! font-family: sans-serif } ! ! span.concept { ! font-family: sans-serif } ! ! span.function { ! font-family: monospace; } ! span.option { ! white-space: nowrap } ! span.option-argument { ! font-style: italic } ! ! span.pre { ! white-space: pre } ! ! span.problematic { ! color: red } ! ! /* Firefox, at least, seems to need some help lowering ! subscripts. Without the following, subscripts seem not to drop ! at all when in a preformatted block. -- DWA ! */ ! ! sub { ! vertical-align: -20% ! } ! ! table { ! margin-top: 0.5em ; ! margin-bottom: 0.5em } ! ! table.citation { ! border-left: solid thin gray ; ! padding-left: 0.5ex } ! ! table.docinfo { ! margin: 2em 4em } ! ! table.footnote { ! border-left: solid thin black ; ! padding-left: 0.5ex } ! ! td, th { ! padding-left: 0.5em ; ! padding-right: 0.5em ; ! vertical-align: top } ! ! th.docinfo-name, th.field-name { ! font-weight: bold ; ! text-align: left ; ! white-space: nowrap } ! ! /* ! dwa 2003/7/29 -- commented out so that it wouldn't override earlier ! styles from boost.css ! ! h1 tt, h2 tt, h3 tt, h4 tt, h5 tt, h6 tt { ! font-size: 100% } ! */ ! ! ul.auto-toc { ! list-style-type: none } ! ! img.boost-logo { ! border: none; ! vertical-align: middle ! } ! ! pre.literal-block span.concept { ! font-style: italic; ! } |
From: Matthias B. <mb...@us...> - 2006-04-06 09:25:44
|
Update of /cvsroot/pygccxml/source/pyplusplus/experimental In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv21842 Modified Files: pypp_api.py Log Message: Extended the check for missing policies by a 'sanity check' that reports functions that probably won't work in Python (functions that take pointer or reference args to fundamental C++ types) Index: pypp_api.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/experimental/pypp_api.py,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** pypp_api.py 28 Mar 2006 12:13:24 -0000 1.13 --- pypp_api.py 6 Apr 2006 09:25:38 -0000 1.14 *************** *** 407,418 **** # Check for missing policies... if self.mVerbose: ! print "Checking policies..." creators = code_creators.make_flatten(self.mExtModule) fmfunctions = filter(lambda creator: isinstance(creator, code_creators.function_t), creators) missing_flag = False for creator in fmfunctions: if not creator.call_policies: print "Missing policy:", declarations.full_name(creator.declaration) missing_flag = True if missing_flag: print "*** Aborting because of missing policies!" --- 407,426 ---- # Check for missing policies... if self.mVerbose: ! print "Sanity check..." creators = code_creators.make_flatten(self.mExtModule) fmfunctions = filter(lambda creator: isinstance(creator, code_creators.function_t), creators) missing_flag = False + sanity_failed = [] for creator in fmfunctions: if not creator.call_policies: print "Missing policy:", declarations.full_name(creator.declaration) missing_flag = True + if not self._declSanityCheck(creator.declaration): + sanity_failed.append(creator.declaration) + if len(sanity_failed)>0: + print "***Warning*** The following %d declarations may produce code that compiles, but"%len(sanity_failed) + print "that does not have the desired effect in Python:" + for decl in sanity_failed: + print " ",decl if missing_flag: print "*** Aborting because of missing policies!" *************** *** 536,539 **** --- 544,562 ---- return content + # _declSanityCheck + def _declSanityCheck(self, decl): + """Check if a declaration will produce code that won't work in Python. + """ + # Check if there's a pointer or reference to a fundamental type among the args... + args = getattr(decl, "arguments") + for arg in args: + t = arg.type + if isinstance(t, declarations.pointer_t) or isinstance(t, declarations.array_t) or isinstance(t, declarations.reference_t): + if isinstance(t.base, declarations.fundamental_t) and not (isinstance(t.base, declarations.char_t) or isinstance(t.base, declarations.unsigned_char_t)): + return False + + return True + + # _time2str def _time2str(self, t): |
From: Matthias B. <mb...@us...> - 2006-04-06 09:24:00
|
Update of /cvsroot/pygccxml/source/pyplusplus/experimental In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20497 Modified Files: filters.py Log Message: Compare the rreturn type to the result of __str__ instead of decl_string Index: filters.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/experimental/filters.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** filters.py 16 Mar 2006 14:49:29 -0000 1.5 --- filters.py 6 Apr 2006 09:23:56 -0000 1.6 *************** *** 292,296 **** if rettype==None: return False ! return self.matcher.match(rettype.decl_string) # ArgsFilter --- 292,296 ---- if rettype==None: return False ! return self.matcher.match(str(rettype)) # ArgsFilter *************** *** 314,318 **** return False for arg,argument in zip(args, declargs): ! if arg!=argument.type.decl_string: return False return True --- 314,318 ---- return False for arg,argument in zip(args, declargs): ! if arg!=str(argument.type): return False return True |
From: Matthias B. <mb...@us...> - 2006-04-06 09:23:08
|
Update of /cvsroot/pygccxml/source/pyplusplus/experimental In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19825 Modified Files: declwrapper.py Log Message: Some minor bug fixes Index: declwrapper.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/experimental/declwrapper.py,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** declwrapper.py 28 Mar 2006 12:12:09 -0000 1.8 --- declwrapper.py 6 Apr 2006 09:22:59 -0000 1.9 *************** *** 417,421 **** if args!=None: filters.append(ArgsFilter(args)) ! type |= CALLABLE # anyarg filter if anyarg!=None: --- 417,421 ---- if args!=None: filters.append(ArgsFilter(args)) ! itype |= CALLABLE # anyarg filter if anyarg!=None: *************** *** 431,435 **** if accesstype!=None: addFilter(accesstype, AccessTypeFilter) ! type |= METHOD # custom filters if filter!=None: --- 431,435 ---- if accesstype!=None: addFilter(accesstype, AccessTypeFilter) ! itype |= METHOD # custom filters if filter!=None: *************** *** 443,447 **** if type==None: type = 0 ! type |= itype addFilter(type, TypeFilter) --- 443,448 ---- if type==None: type = 0 ! if (type & CALLABLE)==0: ! type |= itype addFilter(type, TypeFilter) *************** *** 502,522 **** return self.Decls(name=name, type=type|NAMESPACE, **args) ! # Class def Classes(self, name=None, type=0, **args): return self.Decls(name=name, type=type|CLASS, **args) ! # Method def Methods(self, name=None, type=0, **args): ! return self.Decls(name=name, type=type|METHOD, **args) ! # Constructor def Constructors(self, name=None, type=0, **args): return self.Decls(name=name, type=type|CONSTRUCTOR, **args) ! # Function def Functions(self, name=None, type=0, **args): return self.Decls(name=name, type=type|FUNCTION, **args) ! # Enum def Enums(self, name=None, type=0, **args): return self.Decls(name=name, type=type|ENUM, **args) --- 503,523 ---- return self.Decls(name=name, type=type|NAMESPACE, **args) ! # Classes def Classes(self, name=None, type=0, **args): return self.Decls(name=name, type=type|CLASS, **args) ! # Methods def Methods(self, name=None, type=0, **args): ! return self.Decls(name=name, type=type|METHOD|CONSTRUCTOR, **args) ! # Constructors def Constructors(self, name=None, type=0, **args): return self.Decls(name=name, type=type|CONSTRUCTOR, **args) ! # Functions def Functions(self, name=None, type=0, **args): return self.Decls(name=name, type=type|FUNCTION, **args) ! # Enums def Enums(self, name=None, type=0, **args): return self.Decls(name=name, type=type|ENUM, **args) |
From: Matthias B. <mb...@us...> - 2006-04-06 09:22:17
|
Update of /cvsroot/pygccxml/source/pyplusplus/experimental In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv19304 Modified Files: decltypes.py Log Message: Added a class 'cpp' that allows to specify C++ source code as default value in an 'arg' statement. Index: decltypes.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/experimental/decltypes.py,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** decltypes.py 14 Mar 2006 10:25:11 -0000 1.1 --- decltypes.py 6 Apr 2006 09:22:07 -0000 1.2 *************** *** 21,24 **** --- 21,41 ---- CALLABLE = METHOD | FUNCTION | CONSTRUCTOR + # cpp + class cpp: + """This class wraps C++ source code for default values. + + This class is used together with the 'arg' class to provide + C++ source code as default value. Example: + + method.cdef("foo", "&Foo::foo", arg("ptr", cpp("bp::object()"))) + + The cpp class prevents the generation of apostrophes (as it would + happen when only a string would be passed). + """ + def __init__(self, src): + self.src = src + + def __str__(self): + return self.src # arg |
From: Roman <rom...@us...> - 2006-04-06 07:19:31
|
Update of /cvsroot/pygccxml/source In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv4616 Added Files: sf-how-to.txt Log Message: few hints from Phil Schwartz for sf project managment --- NEW FILE: sf-how-to.txt --- How to load web pages on SF ? Phil Schwartz wrote: I will add it shortly. As for the SF website interface, perhaps I can help a bit. It took me some time to figure it out, but I've been a SF user for several years so I know a lot about their interface. Basically, you need to ssh into your shell acount on SF. The easiest way to do it is: $ ssh rom...@py... Once you're logged in (after supplying your password, of course). You can then cd to your website directory: $ cd /home/groups/p/py/pygccxml/htdocs You can verify the existence of your web directory as such: $ l -d /home/groups/p/py/pygccxml You can then simply edit the index.html page with your favorite editor (vi, emacs, pico, etc). Additionally, you can edit the files on your local system and use scp to transfer them to your project's homepage. This is the method that I use to update my websites (kodos, releaseforge, scratchy, denyhosts, faqtor, etc...). cd www scp * rom...@py...:/home/groups/p/py/pygccxml/htdocs |
From: Roman <rom...@us...> - 2006-04-06 06:40:04
|
Update of /cvsroot/pygccxml/source/pygccxml/declarations In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12250/pygccxml/declarations Modified Files: filters.py Log Message: fixing spell errors Index: filters.py =================================================================== RCS file: /cvsroot/pygccxml/source/pygccxml/declarations/filters.py,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** filters.py 6 Apr 2006 06:15:56 -0000 1.8 --- filters.py 6 Apr 2006 06:39:54 -0000 1.9 *************** *** 296,300 **** class calldef_matcher_t( declaration_matcher_t ): """ ! Instance of this class will match callables by next criteria: - L{declaration_matcher_t} criteria - return type. Example: L{int_t} or 'int' --- 296,300 ---- class calldef_matcher_t( declaration_matcher_t ): """ ! Instance of this class will match callable by next criteria: - L{declaration_matcher_t} criteria - return type. Example: L{int_t} or 'int' |
From: Roman <rom...@us...> - 2006-04-06 06:40:03
|
Update of /cvsroot/pygccxml/source/pygccxml/unittests/data In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12250/pygccxml/unittests/data Modified Files: core_cache.hpp Log Message: fixing spell errors Index: core_cache.hpp =================================================================== RCS file: /cvsroot/pygccxml/source/pygccxml/unittests/data/core_cache.hpp,v retrieving revision 1.51 retrieving revision 1.52 diff -C2 -d -r1.51 -r1.52 *** core_cache.hpp 6 Apr 2006 06:15:58 -0000 1.51 --- core_cache.hpp 6 Apr 2006 06:39:54 -0000 1.52 *************** *** 24,26 **** ! //touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch \ No newline at end of file --- 24,26 ---- ! //touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch//touch \ No newline at end of file |
From: Roman <rom...@us...> - 2006-04-06 06:39:59
|
Update of /cvsroot/pygccxml/source/pygccxml/unittests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12250/pygccxml/unittests Modified Files: autoconfig.py Log Message: fixing spell errors Index: autoconfig.py =================================================================== RCS file: /cvsroot/pygccxml/source/pygccxml/unittests/autoconfig.py,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** autoconfig.py 6 Apr 2006 06:15:58 -0000 1.14 --- autoconfig.py 6 Apr 2006 06:39:54 -0000 1.15 *************** *** 78,81 **** --- 78,84 ---- , 'pyplusplus' , 'pygccxml' + , 'calldef' + , 'XXX' + , 'wstring' ] ) except ImportError: |
From: Roman <rom...@us...> - 2006-04-06 06:38:45
|
Update of /cvsroot/pygccxml/source/pyplusplus/unittests/data In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11530/pyplusplus/unittests/data Added Files: tnfox_bugs.hpp tnfox_bugs_to_be_exported.hpp Log Message: for code from file tnfox_bugs.hpp py++ generates code that could not be compiled This will be fixed for next release --- NEW FILE: tnfox_bugs.hpp --- #include <string> #include <iostream> namespace FX { struct FXWinShellLink { struct Header { unsigned int length; char guid[16]; union Flags { struct { unsigned int hasItemIdList : 1; unsigned int pointsToFileOrDir : 1; unsigned int hasDescription : 1; unsigned int hasRelativePath : 1; unsigned int hasWorkingDir : 1; unsigned int hasCmdLineArgs : 1; unsigned int hasCustomIcon : 1; unsigned int useWorkingDir : 1; // Seems to need to be set to enable working dir unsigned int unused : 24; }; unsigned int raw; } flags; union FileAttribs { // = return from GetFileAttributes() struct { unsigned int isReadOnly : 1; unsigned int isHidden : 1; unsigned int isSystem : 1; unsigned int isVolumeLabel : 1; unsigned int isDir : 1; unsigned int isModified : 1; // =archive bit set, ie; is a file normally unsigned int isEncrypted : 1; unsigned int isNormal : 1; // Doesn't seem to get set unsigned int isTemporary : 1; unsigned int isSparse : 1; unsigned int hasReparsePoint : 1; unsigned int isCompressed : 1; unsigned int isOffline : 1; unsigned int unused : 19; }; unsigned int raw; } fileattribs; // in GetFileAttributes() format unsigned long creation, modified, lastAccess; // in FILETIME format unsigned int filelength; unsigned int iconno; enum ShowWnd { HIDE=0, NORMAL, SHOWMINIMIZED, SHOWMAXIMIZED }; ShowWnd showWnd; unsigned int hotkey; unsigned int unknown1, unknown2; Header(); friend std::ostream &operator<<(std::ostream &s, const Header &i); friend std::istream &operator>>(std::istream &s, Header &i); } header; struct ItemIdListTag { unsigned short length; char path1[260]; // In ASCII char path2[260]; // In unicode ItemIdListTag(); char originalPath[260]; // [not in lnk file] Used so code knows the non-decoded path } itemIdList; struct FileLocationTag { unsigned int length; // to end of whole tag unsigned int firstOffset; // to end of this tag header union Flags { struct { unsigned int onLocalVolume : 1; unsigned int onNetworkShare : 1; unsigned int unused : 30; }; unsigned int raw; } flags; struct LocalVolume { unsigned int length; enum Type { Unknown=0, NoRoot, Removable, // ie; floppy, usb drive etc. Fixed, // ie; hard disc Remote, // ie; network share CDROM, RamDrive }; Type type; unsigned int serialNo; char volumeLabel[64]; LocalVolume(); } localVolume; char basePath[260]; struct NetworkVolume { unsigned int length; unsigned int type; char shareName[260]; NetworkVolume(); } networkVolume; char remainingPath[64]; FileLocationTag(); } fileLocation; struct StringTag { unsigned short length; // in characters char string[260]; // Unicode string StringTag(); }; StringTag description; StringTag relativePath; StringTag workingDir; StringTag cmdLineArgs; StringTag customIcon; }; } // namespace --- NEW FILE: tnfox_bugs_to_be_exported.hpp --- #include <string> #include <iostream> namespace FX { struct FXWinShellLink { struct Header { unsigned int length; char guid[16]; union Flags { struct impl { unsigned int hasItemIdList : 1; unsigned int pointsToFileOrDir : 1; unsigned int hasDescription : 1; unsigned int hasRelativePath : 1; unsigned int hasWorkingDir : 1; unsigned int hasCmdLineArgs : 1; unsigned int hasCustomIcon : 1; unsigned int useWorkingDir : 1; // Seems to need to be set to enable working dir unsigned int unused : 24; }; unsigned int raw; } flags; }; }; } // namespace |
From: Roman <rom...@us...> - 2006-04-06 06:38:39
|
Update of /cvsroot/pygccxml/source/pyplusplus/unittests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11530/pyplusplus/unittests Added Files: tnfox_bugs_tester.py Log Message: for code from file tnfox_bugs.hpp py++ generates code that could not be compiled This will be fixed for next release --- NEW FILE: tnfox_bugs_tester.py --- # Copyright 2004 Roman Yakovenko. # 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) import os import sys import unittest import fundamental_tester_base #this is compilation test class tester_t(fundamental_tester_base.fundamental_tester_base_t): EXTENSION_NAME = 'tnfox_bugs' def __init__( self, *args ): fundamental_tester_base.fundamental_tester_base_t.__init__( self , tester_t.EXTENSION_NAME , *args ) def run_tests(self, module): pass def create_suite(): suite = unittest.TestSuite() suite.addTest( unittest.makeSuite(tester_t)) return suite def run_suite(): unittest.TextTestRunner(verbosity=2).run( create_suite() ) if __name__ == "__main__": run_suite() |
From: Roman <rom...@us...> - 2006-04-06 06:29:41
|
Update of /cvsroot/pygccxml/source/pyplusplus/examples/py_date_time In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6271/pyplusplus/examples/py_date_time Added Files: build_setup.py generate_code.py Log Message: --- NEW FILE: generate_code.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) import os import sys import time import shutil from environment import settings from pygccxml import parser from pygccxml import declarations from pyplusplus import code_creators import customization_data from pyplusplus import module_builder class exporter_t(object): def __init__(self): self.__file = os.path.join( settings.date_time_pypp_include, 'date_time.pypp.hpp' ) def _create_xml_file( self ): #On windows I have some problems to compile boost.date_time #library, so I will use xml files generated on linux config = parser.config_t( gccxml_path=settings.gccxml_path , include_paths=[settings.boost_path] , define_symbols=settings.defined_symbols , undefine_symbols=settings.undefined_symbols ) reader = parser.source_reader_t( config ) destination = os.path.join( settings.date_time_pypp_include, 'date_time.pypp.xml' ) if sys.platform == 'linux2': reader.create_xml_file( self.__file, destination ) return destination def create_module_builder(self): date_time_xml_file = self._create_xml_file() mb = module_builder.module_builder_t( [ parser.create_gccxml_fc( date_time_xml_file ) ] , gccxml_path=settings.gccxml_path , include_paths=[settings.boost_path] , define_symbols=settings.defined_symbols , undefine_symbols=settings.undefined_symbols , optimize_queries=False) if sys.platform == 'win32': linux_name = "time_duration<boost::posix_time::time_duration,boost::date_time::time_resolution_traits<boost::date_time::time_resolution_traits_adapted64_impl, micro, 1000000, 6, int> >" win_name = "time_duration<boost::posix_time::time_duration,boost::date_time::time_resolution_traits<boost::date_time::time_resolution_traits_adapted64_impl, micro, 1000000, 6, long int> >" time_duration_impl = mb.class_( linux_name ) #small price for generating code from xml and not from sources time_duration_impl.name = win_name mb.run_query_optimizer() for name, alias in customization_data.name2alias.items(): decl = mb.class_( name ) decl.alias = alias if isinstance( decl, declarations.class_t ): decl.wrapper_alias = alias + '_wrapper' return mb def filter_declarations(self, mb ): mb.global_ns.exclude() mb.global_ns.namespace( 'pyplusplus', recursive=False ).include() boost_ns = mb.global_ns.namespace( 'boost', recursive=False ) boost_ns.namespace( 'posix_time', recursive=False ).include() boost_ns.namespace( 'date_time', recursive=False ).include() boost_ns.namespace( 'gregorian', recursive=False ).include() boost_ns.namespace( 'local_time', recursive=False ).include() boost_ns.classes( lambda decl: decl.name.startswith( 'constrained_value<' ) ).include() to_be_removed = [ 'month_str_to_ushort', 'from_stream_type', 'parse_date' ] boost_ns.calldefs( lambda decl: decl.name in to_be_removed ).exclude() to_be_removed = [ 'c_time' , 'duration_traits_long' , 'duration_traits_adapted' , 'posix_time_system_config' #TODO find out link bug , 'millisec_posix_time_system_config' ] boost_ns.classes( lambda decl: decl.name in to_be_removed ).exclude() starts_with = [ 'time_resolution_traits<' , 'counted_time_rep<' , 'date_facet<' , 'period_formatter<' , 'date_generator_formatter<' , 'special_values_formatter<' ] for name in starts_with: boost_ns.classes( lambda decl: decl.name.startswith( name ) ).exclude() ends_with = [ '_impl', '_config'] for name in ends_with: boost_ns.classes( lambda decl: decl.name.endswith( name ) ).exclude() #boost.date_time has problem to create local_[micro]sec_clock #variable, it has nothing to do with pyplusplus empty_classes = ['local_microsec_clock', 'local_sec_clock'] for alias in empty_classes: class_ = boost_ns.class_( customization_data.alias2name[alias] ) class_.exclude() class_.ignore = False for alias in [ 'microsec_clock', 'second_clock' ]: class_ = boost_ns.class_( customization_data.alias2name[alias] ) class_.calldefs().create_with_signature = True tdi = mb.class_( lambda decl: decl.alias == 'time_duration_impl' ) tdi_init = tdi.constructor( arg_types=[None, None, None, None], recursive=False) tdi_init.ignore=True def fix_free_template_functions(self, mb): boost_ns = mb.global_ns.namespace( 'boost', recursive=False ) boost_ns.free_functions().create_with_signature = True #This function fixes some boost.date_time function signatures tmpl_on_return_type = [ 'parse_iso_time' , 'parse_undelimited_time_duration' , 'parse_delimited_time' , 'parse_delimited_time_duration' , 'parse_undelimited_date' , 'str_from_delimited_time_duration'] functions = boost_ns.free_functions( lambda decl: decl.name in tmpl_on_return_type ) for function in functions: function.alias = function.name function.name = declarations.templates.join( function.name , [ function.return_type.decl_string ] ) #template on second argument functions = boost_ns.free_functions( 'from_simple_string_type' ) functions.create_with_signature = False for function in functions: function.alias = function.name return_args = declarations.templates.split( function.return_type.decl_string )[1] args = [ return_args[0] ] if 'wchar_t' in function.arguments[0].type.decl_string: args.append( 'wchar_t' ) else: args.append( 'char' ) function.name = declarations.templates.join( function.name, args ) tmpl_on_char_type = [ 'to_iso_extended_string_type' , 'to_iso_string_type' , 'to_simple_string_type' , 'to_sql_string_type' ] functions = boost_ns.free_functions( lambda decl: decl.name in tmpl_on_char_type ) for function in functions: function.alias = function.name args = [] if 'wchar_t' in function.return_type.decl_string: args.append( 'wchar_t' ) function.alias = function.alias + '_w' else: args.append( 'char' ) function.name = declarations.templates.join( function.name, args ) def replace_include_directives( self, mb ): extmodule = mb.code_creator includes = filter( lambda creator: isinstance( creator, code_creators.include_t ) , extmodule.creators ) includes = includes[1:] #all includes except boost\python.hpp map( lambda creator: extmodule.remove_creator( creator ), includes ) for include_header in customization_data.includes: extmodule.adopt_include( code_creators.include_t( header=include_header ) ) def add_code( self, mb ): as_number_template = 'def( "as_number", &%(class_def)s::operator %(class_def)s::value_type, bp::default_call_policies() )' classes = mb.classes() classes.always_expose_using_scope = True #better error reporting from compiler classes = mb.classes(lambda decl: decl.alias != 'local_date_time' ) classes.redefine_operators = True #redefine all operators found in base classes classes = mb.classes(lambda decl: decl.name.startswith('constrained_value<') ) for cls in classes: cls.add_code( as_number_template % { 'class_def' : declarations.full_name( cls ) } ) classes = mb.classes(lambda decl: decl.alias in [ 'date_duration', 'time_duration' ] ) for operator in [ '>', '>=', '<=', '<', '+', '-' ]: classes.add_code( 'def( bp::self %s bp::self )' % operator ) ptime = mb.class_( lambda decl: decl.alias == 'ptime' ) for operator in [ '>', '>=', '<=', '<', '-' ]: ptime.add_code( 'def( bp::self %s bp::self )' % operator ) def beautify_code( self, mb ): extmodule = mb.code_creator position = extmodule.last_include_index() + 1 extmodule.adopt_creator( code_creators.namespace_using_t( 'boost' ) , position ) position += 1 extmodule.adopt_creator( code_creators.namespace_using_t( 'boost::date_time' ) , position ) position += 1 for full_ns_name, alias in customization_data.ns_aliases.items(): creator = code_creators.namespace_alias_t( alias=alias , full_namespace_name=full_ns_name ) extmodule.adopt_creator( creator, position ) position += 1 def customize_extmodule( self, mb ): extmodule = mb.code_creator #beautifying include code generation extmodule.license = customization_data.license extmodule.user_defined_directories.append( settings.boost_path ) extmodule.user_defined_directories.append( settings.working_dir ) extmodule.user_defined_directories.append( settings.generated_files_dir ) extmodule.license = customization_data.license extmodule.precompiled_header = 'boost/python.hpp' self.replace_include_directives( mb ) self.beautify_code( mb ) def write_files( self, mb ): mb.split_module( settings.generated_files_dir ) shutil.copyfile( os.path.join( settings.date_time_pypp_include, 'date_time_wrapper.hpp' ) , os.path.join( settings.generated_files_dir, 'date_time_wrapper.hpp' ) ) def create(self): start_time = time.clock() mb = self.create_module_builder() self.filter_declarations(mb) self.fix_free_template_functions( mb ) self.add_code( mb ) mb.build_code_creator( settings.module_name ) self.customize_extmodule( mb ) self.write_files( mb ) print 'time taken : ', time.clock() - start_time, ' seconds' def export(): exporter = exporter_t() exporter.create() if __name__ == '__main__': export() print 'done' --- NEW FILE: build_setup.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) import os import sys import shutil def create( source_dir, target_dir ): sys.path.append( source_dir ) environment = __import__( 'environment' ) files_dir = os.path.join( source_dir, 'unittests' ) files = ['date_time.py' , 'date_time_zonespec.csv' , 'LICENSE_1_0.txt' , 'local_time_tester.py' , 'posix_time_tester.py' , 'gregorian_tester.py' , 'test_all.py' ] if 'win32' == sys.platform: files.append( '_date_time_.pyd' ) else: files.append( '_date_time_.so' ) files = map( lambda fname: os.path.join( files_dir, fname ), files ) if 'win32' == sys.platform: files.append( os.path.join( environment.settings.boost_libs_path, 'boost_python.dll' ) ) files.append( os.path.join( environment.settings.boost_libs_path, 'boost_date_time-vc71-mt-1_33_1.dll' ) ) else: files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_python.so' ) ) files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_python.so.1.33.1' ) ) files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_date_time-gcc-1_33_1.so' ) ) files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_date_time-gcc-1_33_1.so.1.33.1' ) ) for f in files: shutil.copy( f, target_dir ) |
From: Roman <rom...@us...> - 2006-04-06 06:29:41
|
Update of /cvsroot/pygccxml/source/pyplusplus/examples/py_easybmp In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6271/pyplusplus/examples/py_easybmp Added Files: build_setup.py generate_code.py Log Message: --- NEW FILE: generate_code.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) import os from environment import settings from pyplusplus import code_creators from pyplusplus import module_builder license = \ """ // Copyright 2004 Roman Yakovenko. // 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) """ def export(): global license header_file = os.path.join( settings.easybmp_path, 'EasyBMP.h' ) #create configuration for GCC-XML parser #initialize module builder mb = module_builder.module_builder_t( [ header_file ] , gccxml_path=settings.gccxml_path , working_directory=settings.easybmp_path ) bmp_class = mb.class_( 'BMP' ) call_operator = bmp_class.operator( symbol='()', recursive=False ) call_operator.alias = 'GetRGBAPixel' call_operator.call_policies = module_builder.call_policies.return_internal_reference() #customizing code, before generation mb.build_code_creator( settings.module_name ) mb.code_creator.license = license mb.code_creator.user_defined_directories.append( settings.easybmp_path ) mb.code_creator.precompiled_header = 'boost/python.hpp' mb.code_creator.adopt_creator( code_creators.include_t( header=header_file ), 2 ) mb.write_module( os.path.join( settings.generated_files_dir, settings.module_name + '.cpp') ) if __name__ == '__main__': export() print 'done' --- NEW FILE: build_setup.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) import os import sys import shutil def create( source_dir, target_dir ): sys.path.append( source_dir ) environment = __import__( 'environment' ) files_dir = os.path.join( source_dir, 'unittests' ) files = ['grayscale.py', 'source.bmp', 'target.bmp', 'LICENSE_1_0.txt' ] if 'win32' == sys.platform: files.append( 'pyeasybmp.pyd' ) else: files.append( 'pyeasybmp.so' ) files = map( lambda fname: os.path.join( files_dir, fname ), files ) if 'win32' == sys.platform: files.append( os.path.join( environment.settings.boost_libs_path, 'boost_python.dll' ) ) else: files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_python.so' ) ) files.append( os.path.join( environment.settings.boost_libs_path, 'libboost_python.so.1.33.1' ) ) for f in files: shutil.copy( f, target_dir ) |
From: Roman <rom...@us...> - 2006-04-06 06:29:40
|
Update of /cvsroot/pygccxml/source/pyplusplus/examples/tutorials In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6271/pyplusplus/examples/tutorials Added Files: generate_code.py hello_world.py.cpp Log Message: --- NEW FILE: generate_code.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) import os from environment import settings from pyplusplus import module_builder mb = module_builder.module_builder_t( files=['hello_world.hpp'] , gccxml_path=settings.gccxml_path #path to gccxml executable , working_directory=settings.working_dir ) #setting working directory for gccxml #rename enum Color to color Color = mb.enum( 'color' ) Color.rename('Color') #Set call policies to animal::get_name_ptr animal = mb.class_( 'animal' ) get_name_ptr = animal.member_function( 'get_name_ptr', recursive=False ) get_name_ptr.call_policies = module_builder.call_policies.return_internal_reference() #next code has same effect get_name_ptr = mb.member_function( 'get_name_ptr' ) get_name_ptr.call_policies = module_builder.call_policies.return_internal_reference() #I want to exclude all classes with name starts with impl impl_classes = mb.classes( lambda decl: decl.name.startswith( 'impl' ) ) impl_classes.exclude() #I want to exclude all functions that returns pointer to int ptr_to_int = mb.free_functions( return_type='int *' ) ptr_to_int.exclude() #I can print declarations to see what is going on mb.print_declarations() #I can print single declarations mb.print_declarations( animal ) #Now it is the time to give a name to our module mb.build_code_creator( module_name='hw' ) #I don't want absolute includes within code mb.code_creator.user_defined_directories.append( settings.working_dir ) #And finally we can write code to the disk mb.write_module( os.path.join( settings.working_dir, 'hello_world.py.cpp' ) ) --- NEW FILE: hello_world.py.cpp --- // This file has been generated by pyplusplus. // std directories: [] // user defined directories: ['/home/roman/pygccxml_sources/source/pyplusplus/examples/tutorials'] #include "boost/python.hpp" #include "hello_world.hpp" namespace bp = boost::python; BOOST_PYTHON_MODULE(hw){ bp::enum_<color>("Color") .value("blue", blue) .value("green", green) .value("red", red) .export_values() ; bp::class_< animal >( "animal", bp::init< bp::optional< std::string const & > >(( bp::arg("name")="" )) ) .def( "get_name_ptr" , &animal::get_name_ptr , bp::return_internal_reference< 1, bp::default_call_policies >() ) .def( "name" , &animal::name , bp::return_value_policy< bp::copy_const_reference, bp::default_call_policies >() ); bp::implicitly_convertible< std::string const &, animal >(); } |
From: Roman <rom...@us...> - 2006-04-06 06:20:16
|
Update of /cvsroot/pygccxml/source/pyplusplus/docs/tutorials In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv434/pyplusplus/docs/tutorials Added Files: module_builder.rest www_configuration.py Log Message: adding missing files --- NEW FILE: module_builder.rest --- ==================== pyplusplus tutorials ==================== .. contents:: Table of contents **All written here is relevant to CVS version.** ------------------- What is pyplusplus? ------------------- .. include:: ./../definition.rest -------- Concepts -------- `pyplusplus`_ introduces few concepts: **code creator** ---------------- Class, that is responsible to create some specific code. For example, ``include_t`` code creator is responsible to create C++ include directive. **compound code creator** ------------------------- Code creator, that contains an ordered set of other code creators. For example, ``module_t`` is compaund code creator, because it keeps all code creators. **code creators tree** ---------------------- Good definition is needed, meanwhile I can make next anology of code creators with XML DOM 1) code creators - DOM nodes 2) code creators tree - XML DOM 3) module - DOM Document **module creator** ------------------ Factory, that is repososible to create all necessary code creators, for a given set of C++ declarations. **file writer(s)** ------------------ Classes, that are responsible for writing all code produced by ``module_t`` into file(s). -------- Overview -------- Code generation process using `pyplusplus`_ consists from few steps: 1. Read C++ declarations. 2. Create code creators tree. 3. Customize code creators. 4. Write code to files. Later, in this article I am going to explain every step. Before doing this, I would like to give you small advice: please `download`_ `pyplusplus`_ `GUI`_ and run it. There is one good reason for doing this: code generator wizard. `pyplusplus`_ GUI contains small and simple wizard that will generate `pyplusplus`_ code from your settings. You have to know nothing about API - just few clicks with you mouse and you will get the code. Enjoy. .. _`download`: ./download.html .. _`GUI`: ./examples/pyplusplus_demo.png To do: add reference to the code!!! ----------------------------- Step 1: Read C++ declarations ----------------------------- During this step C++ source files are parsed and all declarations are read. `pyplusplus`_ is not involved in this step at all. You should use `pygccxml`_. Fortunately it is very easy to setup\\use `pygccxml`_: :: import os from pygccxml import parser from pygccxml import declarations from pyplusplus import code_creators from pyplusplus import module_creator from pyplusplus import file_writers class settings: gccxml_path = '/home/roman/gccxml/bin' working_dir = '/tmp' #configurating parser parser_config = parser.config_t( gccxml_path=settings.gccxml_path, working_directory=settings.working_dir ) #reading all declarations decls_all = parser.parse( ['hello_world.hpp'], parser_config ) #filtering declarations decls = declarations.filtering.by_location( decls_all, [settings.working_dir] ) `pygccxml`_ does not parse C++ files, but use `GCC-XML`_ to do the job. So, the first thing that you should do is to setup `GCC-XML`_ binary location. The only way to do it is to create ``parser.config_t`` class instance. ``parser.config_t.__init__`` method takes few arguments: * `GCC-XML`_ binary location * working directory, this will help `GCC-XML`_ to locate included files * list of additional include directories * list of defined\\undefined symbols * ..., please see documentation of `pygccxml`_ for more information Now, when we created configuration for parser, we can actually read all declarations from source files. Function ``parse`` of module ``parser`` will do it. It will read all declarations that are found in your file and files included from the file. This means, that variable ``decls_all`` contains some declarations, that we do not want to export. So there is a need to apply some filter. In my example I remove all declarations that have been defined in files, outside of our working directory. We finished this step. The result of this step is that we have a set of declarations that we want to export. --------------------------------- Step 2: Create code creators tree --------------------------------- During this step `pyplusplus`_ will create one or more code creator for every C++ declaration, that should be exported. At the end of this step ``module_t`` class instances is created. Lets see some code: :: #creating code creators tree extmodule = module_creator.create( decls=decls, module_name="hello_world",recursive=False ) What is going on? First of all this is a first time we actualy use `pyplusplus`_. `pyplusplus`_ contains a package, named ``module_creator`` that contains functionality that create code creator(s) for every declaration. In this case I want to export all declarations from ``decls`` list. I also set exported module name to "hello_world". The 3rd parameter needs more explanation. ``decls`` argument could be interpreted as * list of all declaration to be exported * list of top level declarations. all declarations should be exported recursively. In order to clarify the use of ``decls`` argument, argument ``recursive`` is used. In my case ``decls`` variable holds a list of all declarations that should be exported, so I set ``recursive`` to be ``False``. Actually, we finished this step. ------------------------------- Step 3: Customize code creators ------------------------------- This step is optional. Inspite of being "optional" this step allows you to change code before it has been generated. You can create and add custom code creatpors. Or you can modify an exising one. Or even more you can delete code creators. There are few function that will help you to locate desired code creator by different criterias. In my case I only want to set user defined directories. Thus allowing `pyplusplus`_ to generate nice( shorter ) include directives: :: extmodule.user_defined_directories.append( parser_config.working_directory ) That's all for this step. --------------------------- Step 4: Write code to files --------------------------- :: file_writers.write_file( extmodule, 'bindings.cpp' ) I think that code above is self explained. I write ``extmodule`` into ``bindings.cpp`` file. It is also possible to write ``extmodule`` into multiple files: :: file_writers.write_multiple_files( extmodule, '.' ) The code above split extension module source to few files. This is very useful option. It saves compilation time. -------------- Congratulation -------------- Congratulation! You've done. You can find the whole listing of the program within CVS/pyplusplus/examples/tutorials. Enjoy. .. _`pyplusplus` : ./pyplusplus.html .. _`pygccxml` : ./../pygccxml/pygccxml.html .. _`boost.python`: http://www.boost.org/libs/python/doc/index.html .. _`SourceForge`: http://sourceforge.net/index.php .. _`Python`: http://www.python.org .. _`GCC-XML`: http://www.gccxml.org .. Local Variables: mode: indented-text indent-tabs-mode: nil sentence-end-double-space: t fill-column: 70 End: --- NEW FILE: www_configuration.py --- name = 'tutorials' main_html_file = 'module_builder.html' |
From: Roman <rom...@us...> - 2006-04-06 06:20:16
|
Update of /cvsroot/pygccxml/source In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv434 Modified Files: setup_pyplusplus.py Log Message: adding missing files Index: setup_pyplusplus.py =================================================================== RCS file: /cvsroot/pygccxml/source/setup_pyplusplus.py,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** setup_pyplusplus.py 6 Mar 2006 15:08:47 -0000 1.8 --- setup_pyplusplus.py 6 Apr 2006 06:20:06 -0000 1.9 *************** *** 21,24 **** , 'pyplusplus.decl_wrappers' , 'pyplusplus.module_builder' ! , 'pyplusplus.utils'] ) --- 21,25 ---- , 'pyplusplus.decl_wrappers' , 'pyplusplus.module_builder' ! , 'pyplusplus.utils' ! , 'pyplusplus._logging_'] ) |
From: Roman <rom...@us...> - 2006-04-06 06:20:16
|
Update of /cvsroot/pygccxml/source/pyplusplus/examples/custom_code_creator In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv434/pyplusplus/examples/custom_code_creator Added Files: generate_code.py properties.hpp Log Message: adding missing files --- NEW FILE: generate_code.py --- #! /usr/bin/python # Copyright 2004 Roman Yakovenko. # 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) """ This file contains example to custom code creator. My class point_t has private member variable 'x' and two accessors: get_x and set_x. I want to export those accessors as Python property. In order to do this I created new class property_creator_t. In __init__ it takes 3 arguments: reference to get function declaration reference to set function declaration reference to parent code creator ( we can safely omit this argument ) """ import os from environment import settings from pygccxml import declarations from pyplusplus import code_creators from pyplusplus import module_builder class property_creator_t( code_creators.code_creator_t ): def __init__( self, get_function, set_function, parent=None ): #get/set functions are references to relevant declarations code_creators.code_creator_t.__init__( self, parent ) self.__get_function = get_function self.__set_function = set_function def _create_impl(self): template = 'add_property( "%(name)s", &%(getter)s, &%(setter)s )' property_name = self.__get_function.name[4:] #get_ return template % dict( name=property_name , getter=declarations.full_name( self.__get_function ) , setter=declarations.full_name( self.__set_function ) ) #This is the most complex code in this example :-) def replace_functions( class_creator ): def is_relevant( code_creator ): if not isinstance( code_creator, code_creators.declaration_based_t ): #We are looking for code creator, that has to export some declaration return False if not isinstance( code_creator.declaration, module_builder.member_function_t ): #declaration should be member function return False decl = code_creator.declaration #member function name should start from "get" or "set" return decl.name.startswith( 'get' ) or decl.name.startswith( 'set' ) #accessors is a list of all relevant code creators found within the class code creator accessors = filter( is_relevant, class_creator.creators ) #accessors_db is a dictionary, that maps between name and get//set code creators accessors_db = {} # name : [get creator, set creator] #Filling accessors_db for creator in accessors: property_name = creator.declaration.name[3:] if not accessors_db.has_key( property_name ): accessors_db[ property_name ] = [None, None] accessors_db[ property_name ][ int(creator.declaration.name[0] == 's') ] = creator #Now, when we have all pairs of accessors, we can actually start replacing them #with instance of property_creator_t for get_creator, set_creator in accessors_db.values(): if not ( get_creator and set_creator ): continue #removing get/set code creators class_creator.remove_creator( get_creator ) class_creator.remove_creator( set_creator ) #instead of them we add an instance of property_creator_t class prop_creator = property_creator_t( get_creator.declaration, set_creator.declaration ) class_creator.adopt_creator( prop_creator ) if __name__ == '__main__': #1. creating module builder mb = module_builder.module_builder_t( files=['properties.hpp'] , gccxml_path=settings.gccxml_path , working_directory=settings.sources_path ) #2. creating module code creator mb.build_code_creator( module_name=settings.module_name ) mb.code_creator.user_defined_directories.append( settings.working_dir ) #3. replacing get/set code creators with property code creator classes = filter( lambda creator: isinstance( creator, code_creators.class_t ) , code_creators.make_flatten( mb.code_creator ) ) map( replace_functions, classes ) #4. writing module to disk mb.write_module( os.path.join( settings.generated_files_dir, settings.module_name + '.py.cpp') ) print 'done' --- NEW FILE: properties.hpp --- #ifndef __properties_h__ #define __properties_h__ namespace geometry{ struct point_t{ explicit point_t(int x=0, int y=0) : m_x(x), m_y(0) {} int get_x() const { return m_x; } void set_x(int x) { m_x = x; } int get_y() const { return m_y; } void set_y(int y) { m_y = y; } private: int m_x; int m_y; }; inline int extract_x( const point_t& pt ){ return pt.get_x(); } inline int extract_y( const point_t& pt ){ return pt.get_y(); } } #endif//__properties_h__ |
From: Roman <rom...@us...> - 2006-04-06 06:18:36
|
Update of /cvsroot/pygccxml/source/pyplusplus/docs/tutorials In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32009/tutorials Log Message: Directory /cvsroot/pygccxml/source/pyplusplus/docs/tutorials added to the repository |
Update of /cvsroot/pygccxml/source/pyplusplus/examples/tnfox In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28954/pyplusplus/examples/tnfox Modified Files: call_policies.py create_tnfox.py declarations_to_exclude.py environment.py files_to_exclude.py tnfox.vcproj Log Message: There are a lot of changes, sorry CVS did not worked for week or something like this Changes 1. Lots of code clean up 2. Adding and updating documentation 3. Adding new method on decl_wrapper - readme. This method will return list of msgs to the developer. For example if function takes by reference fundamental type it will say that this function could not be called from Python 4. Logging functionlity has been added to file writers too 5. Few bug fixes 6. For operator [] call policies is always set. Index: call_policies.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/call_policies.py,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** call_policies.py 30 Mar 2006 05:56:17 -0000 1.9 --- call_policies.py 6 Apr 2006 06:16:07 -0000 1.10 *************** *** 73,76 **** --- 73,77 ---- , "::FX::FXBitmap::getData" : return_internal_reference() , "::FX::FXBitmapView::getBitmap" : return_internal_reference() + , "::FX::FXCharset::clear" : return_self() , "::FX::FXColorSelector::acceptButton" : return_internal_reference() , "::FX::FXColorSelector::cancelButton" : return_internal_reference() *************** *** 90,93 **** --- 91,95 ---- , "::FX::FXDirSelector::acceptButton" : return_internal_reference() , "::FX::FXDirSelector::cancelButton" : return_internal_reference() + , "::FX::FXDockBar::findDockAtSide" : return_value_policy( reference_existing_object ) , "::FX::FXDockBar::findDockNear" : return_value_policy( reference_existing_object ) , "::FX::FXDockBar::getDryDock" : return_value_policy( reference_existing_object ) *************** *** 205,208 **** --- 207,211 ---- , "::FX::FXId::getApp" : return_value_policy( reference_existing_object ) , "::FX::FXId::getEventLoop" : return_value_policy( reference_existing_object ) + , "::FX::FXId::getVisual" : return_value_policy( reference_existing_object ) , "::FX::FXImageFrame::getImage" : return_internal_reference() , "::FX::FXImage::getData" : return_internal_reference() *************** *** 256,259 **** --- 259,264 ---- , "::FX::FXMDIChild::getIcon" : return_internal_reference() , "::FX::FXMDIChild::getMenu" : return_internal_reference() + , "::FX::FXMDIChild::getWindowIcon" : return_internal_reference() + , "::FX::FXMDIChild::getWindowMenu" : return_internal_reference() , "::FX::FXMDIClient::getActiveChild" : return_internal_reference() , "::FX::FXMenuButton::getMenu" : return_internal_reference() *************** *** 278,290 **** --- 283,301 ---- , "::FX::FXOptionMenu::getCurrent" : return_internal_reference() , "::FX::FXOptionMenu::getMenu" : return_internal_reference() + , "::FX::FXOptionMenu::getPopup" : return_internal_reference() , "::FX::FXPopup::getGrabOwner" : return_internal_reference() , "::FX::FXPopup::getNextActive" : return_internal_reference() , "::FX::FXPopup::getPrevActive" : return_internal_reference() , "::FX::FXProcess::instance" : return_value_policy( reference_existing_object ) + , "::FX::FXProcess::permissions" : return_internal_reference() , "::FX::FXProcess::threadPool" : return_value_policy( reference_existing_object ) , "::FX::FXProgressBar::getFont" : return_internal_reference() , "::FX::FXQuatd::adjust" : return_self() , "::FX::FXQuatf::adjust" : return_self() + #does not exist in sources + #, "::FX::FXRanged::clipTo" : return_self() , "::FX::FXRanged::include" : return_self() + #does not exist in sources + #, "::FX::FXRangef::clipTo" : return_self() , "::FX::FXRangef::include" : return_self() , "::FX::FXRealSpinner::getFont" : return_internal_reference() *************** *** 308,311 **** --- 319,323 ---- , "::FX::FXSpheref::include" : return_self() , "::FX::FXSpinner::getFont" : return_internal_reference() + , "::FX::FXSplashWindow::getFont" : return_internal_reference() , "::FX::FXSplashWindow::getIcon" : return_internal_reference() , "::FX::FXSplitter::findHSplit" : return_internal_reference() *************** *** 321,326 **** --- 333,341 ---- , "::FX::FXSQLDBCursor::statement" : return_value_policy( reference_existing_object ) , "::FX::FXSQLDBRegistry::processRegistry" : return_value_policy( reference_existing_object ) + , "::FX::FXSQLDBServer::addDatabase" : return_self() , "::FX::FXSQLDBStatement::bind" : return_self() , "::FX::FXSQLDBStatement::driver" : return_value_policy( reference_existing_object ) + , "::FX::FXSQLDB_ipc::setIsAsynchronous" : return_self() + , "::FX::FXSQLDB_ipc::setPrefetching" : return_self() , "::FX::FXSSLKey::asymmetricKey" : return_internal_reference() , "::FX::FXSSLKey::setAsymmetricKey" : return_self() *************** *** 354,357 **** --- 369,376 ---- , "::FX::FXTime::toUTC" : return_self() , "::FX::FXToggleButton::getAltIcon" : return_internal_reference() + , "::FX::FXToolBar::findDockAtSide" : return_value_policy( reference_existing_object ) + , "::FX::FXToolBar::findDockNear" : return_value_policy( reference_existing_object ) + , "::FX::FXToolBar::getDryDock" : return_value_policy( reference_existing_object ) + , "::FX::FXToolBar::getWetDock" : return_value_policy( reference_existing_object ) , "::FX::FXToolTip::getFont" : return_internal_reference() , "::FX::FXTopWindow::getIcon" : return_value_policy( reference_existing_object ) *************** *** 428,431 **** --- 447,451 ---- , "::FX::QDir::entryInfoList" : return_internal_reference() , "::FX::QGZipDevice::GZData" : return_value_policy( reference_existing_object ) + , "::FX::QIODevice::permissions" : return_internal_reference() , "::FX::QMemArray<unsigned char>::data" : return_internal_reference() , "::FX::QMemArray<unsigned char>::assign" : return_self() *************** *** 441,444 **** --- 461,465 ---- , "::FX::QPtrVector<FX::FXWindow>::getLast" : return_internal_reference() , "::FX::QPtrVector<FX::FXWindow>::first" : return_internal_reference() + , "::FX::QPtrVector<FX::FXWindow>::last" : return_internal_reference() , "::FX::QPtrVector<FX::FXWindow>::int_vector" : return_self() , "::FX::QPtrVector<FX::Generic::BoundFunctorV>::data" : return_internal_reference() *************** *** 465,467 **** --- 486,489 ---- , "::FX::FXObjectListOf<FX::FXHeaderItem>::list" : return_internal_reference() , "::FX::FXObjectListOf<FX::FXIconItem>::list" : return_internal_reference() + , "::FX::QBZip2Device::BZ2Data" : return_internal_reference() } Index: environment.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/environment.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** environment.py 5 Dec 2005 08:10:58 -0000 1.5 --- environment.py 6 Apr 2006 06:16:07 -0000 1.6 *************** *** 8,12 **** class settings: ! module_name='tnfox' boost_path = '' boost_libs_path = '' --- 8,12 ---- class settings: ! module_name='TnFOX' boost_path = '' boost_libs_path = '' *************** *** 27,31 **** , "FX_INCLUDE_ABSOLUTELY_EVERYTHING" , "FOXPYTHONDLL_EXPORTS" ! , "FX_NO_GLOBAL_NAMESPACE" ] if 'big'==sys.byteorder: defined_symbols.append("FOX_BIGENDIAN=1") --- 27,35 ---- , "FX_INCLUDE_ABSOLUTELY_EVERYTHING" , "FOXPYTHONDLL_EXPORTS" ! , "FX_NO_GLOBAL_NAMESPACE" ! , "FOXPYTHONDLL"] ! # For debugging purposes to get far smaller bindings, you can define FX_DISABLEGUI ! defined_symbols.append("FX_DISABLEGUI=1") ! if 'big'==sys.byteorder: defined_symbols.append("FOX_BIGENDIAN=1") Index: create_tnfox.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/create_tnfox.py,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** create_tnfox.py 30 Mar 2006 05:56:17 -0000 1.18 --- create_tnfox.py 6 Apr 2006 06:16:07 -0000 1.19 *************** *** 5,20 **** # http://www.boost.org/LICENSE_1_0.txt) ! import os import time from environment import settings - from pygccxml import parser from pygccxml import declarations from pyplusplus import code_creators - from pyplusplus import module_creator from pyplusplus import file_writers - from pyplusplus import utils as pypp_utils - from pyplusplus import decl_wrappers from pyplusplus import module_builder import aliases --- 5,18 ---- # http://www.boost.org/LICENSE_1_0.txt) ! import os, sys import time from environment import settings from pygccxml import declarations from pyplusplus import code_creators from pyplusplus import file_writers from pyplusplus import module_builder + from pyplusplus.module_builder import call_policies + import aliases *************** *** 29,44 **** fx_ns = mb.namespace( 'FX' ) fx_ns.include() ! fx_ns.decls( declarations_to_exclude.is_excluded ).exclude() ! fx_ns.decls( lambda decl: decl.name.startswith('FXIPCMsg') ).exclude() fx_ns.namespace( 'Pol' ).exclude() fx_ns.decls( files_to_exclude.is_excluded ).exclude() ! #find FXFunctorTarget constructor that takes 1 argument of some type ! fx_ns.constructors( name='FXFunctorTarget', arg_types=[None] ).exclude() ! fx_ns.class_( 'QValueList<FX::Pol::knowReferrers::ReferrerEntry>').exclude() ! fx_ns.class_( 'QPtrVector<FX::Generic::BoundFunctorV>').exclude() ! #Niall? wrapper for this function could not be compiled ! FXSQLDBStatement = fx_ns.class_( 'FXSQLDBStatement' ) ! FXSQLDBStatement.member_function( name='bind', arg_types=[None,None,None] ).exclude() ! for func in fx_ns.calldefs(): #I want to exclude all functions that returns pointer to pointer --- 27,39 ---- fx_ns = mb.namespace( 'FX' ) fx_ns.include() ! fx_ns.decls( declarations_to_exclude.is_excluded ).exclude() ! fx_ns.decls( lambda decl: decl.name.startswith('FXIPCMsgHolder') ).exclude() fx_ns.namespace( 'Pol' ).exclude() fx_ns.decls( files_to_exclude.is_excluded ).exclude() ! fx_ns.class_( 'QValueList<FX::Pol::knowReferrers::ReferrerEntry>').exclude() ! try: ! fx_ns.class_( 'QPtrVector<FX::Generic::BoundFunctorV>').exclude() ! except: pass ! for func in fx_ns.calldefs(): #I want to exclude all functions that returns pointer to pointer *************** *** 46,49 **** --- 41,46 ---- if declarations.is_pointer( func.return_type ): temp = declarations.remove_pointer( func.return_type ) + if declarations.is_void( temp ): + continue #export function that returns void* if declarations.is_fundamental( temp ) and not declarations.is_const(temp): func.exclude() *************** *** 53,60 **** func.exclude() ! #decls = fx_ns.decls( lambda decl: decl.alias in declarations_to_exclude.declarations_aliases ) ! #decls.exclude() ! def set_call_policies(mb): #first of all call policies defined within data base for fname, call_pol in call_policies.db.items(): --- 50,69 ---- func.exclude() ! QIODeviceS = fx_ns.class_( 'QIODeviceS' ) ! QIODeviceS.member_function( 'open', recursive=False ).exclude() ! QIODeviceS.member_function( 'truncate', recursive=False ).exclude() ! QIODeviceS.member_function( 'readBlockFrom', recursive=False ).exclude() ! QIODeviceS.member_function( 'writeBlockTo', recursive=False ).exclude() ! ! fx_ns.casting_operators().exclude() ! ! def set_call_policies(mb): + + #for func in mb.calldefs(): + # if "QMemArray" in func.name: + # print "HERE!", func.name, func.parent.name, [x.name for x in func.arguments] + #sys.exit(0) + #first of all call policies defined within data base for fname, call_pol in call_policies.db.items(): *************** *** 64,85 **** else: mb.calldefs( fname ).call_policies = call_pol ! except Exception, error: ! print '> error: %s, %s' %( fname, str( error ) ) ! copy_funcs = mb.calldefs( lambda decl: 'FXGL' in decl.parent.name and decl.name == 'copy' ) ! copy_funcs.call_policies = decl_wrappers.return_value_policy( decl_wrappers.manage_new_object ) ! take_funcs = mb.calldefs( lambda decl: 'QPtrVector<' in decl.parent.name \ ! and decl.name == 'take' \ ! and declarations.is_pointer( decl.return_type ) ) ! # Set reference_existing object only on the overload not returning a bool ! take_funcs.call_policies = decl_wrappers.return_value_policy( decl_wrappers.reference_existing_object ) ! mb.calldefs( 'manufacture' ).call_policies \ ! = decl_wrappers.return_value_policy( decl_wrappers.manage_new_object ) ! mb.calldefs( 'getMetaClass' ).call_policies \ ! = decl_wrappers.return_value_policy( decl_wrappers.reference_existing_object ) #third calculated ! return_by_value = decl_wrappers.return_value_policy( decl_wrappers.return_by_value ) ! return_internal_ref = decl_wrappers.return_internal_reference() const_t = declarations.const_t pointer_t = declarations.pointer_t --- 73,105 ---- else: mb.calldefs( fname ).call_policies = call_pol ! except: ! print "ERROR, skipping! was:",sys.exc_info()[0],sys.exc_info()[1] ! ! try: ! copy_funcs = mb.calldefs( lambda decl: 'FXGL' in decl.parent.name and decl.name == 'copy' ) ! copy_funcs.call_policies = call_policies.return_value_policy( call_policies.manage_new_object ) ! except: ! print "ERROR, skipping! was:",sys.exc_info()[0],sys.exc_info()[1] ! try: ! take_funcs = mb.calldefs( lambda decl: 'QPtrVector<' in decl.parent.name \ ! and decl.name == 'take' \ ! and declarations.is_pointer( decl.return_type ) ) ! # Set reference_existing object only on the overload not returning a bool ! take_funcs.call_policies = call_policies.return_value_policy( call_policies.reference_existing_object ) ! except: ! print "ERROR, skipping! was:",sys.exc_info()[0],sys.exc_info()[1] ! ! try: ! mb.calldefs( 'manufacture' ).call_policies \ ! = call_policies.return_value_policy( call_policies.manage_new_object ) ! mb.calldefs( 'getMetaClass' ).call_policies \ ! = call_policies.return_value_policy( call_policies.reference_existing_object ) ! except: ! print "ERROR, skipping! was:",sys.exc_info()[0],sys.exc_info()[1] #third calculated ! return_by_value = call_policies.return_value_policy( call_policies.return_by_value ) ! return_internal_ref = call_policies.return_internal_reference() const_t = declarations.const_t pointer_t = declarations.pointer_t *************** *** 97,103 **** #~ mb.calldefs( return_type=type_ ).call_policies = policy - #for name in 'FXVec4d', 'FXVec4f', 'FXVec3d', 'FXVec3f', 'QMemArray<unsigned char>': - # mb.casting_operators( name ).call_policies = return_internal_ref - return None --- 117,120 ---- *************** *** 128,140 **** extmodule.adopt_creator( code_creators.namespace_using_t('::FX'), position ) extmodule.user_defined_directories.append( settings.generated_files_dir ) - - def create_module(): - parser_config = parser.config_t( ) fx_xml = os.path.join( settings.xml_files, 'fx.xml' ) ! mb = module_builder.module_builder_t( [ parser.create_cached_source_fc( 'fx.h', fx_xml ) ] , gccxml_path=settings.gccxml_path , include_paths=[settings.boost_path, settings.tnfox_include_path] , define_symbols=settings.defined_symbols_gccxml ) print 'filtering declarations' filter_decls( mb ) --- 145,175 ---- extmodule.adopt_creator( code_creators.namespace_using_t('::FX'), position ) extmodule.user_defined_directories.append( settings.generated_files_dir ) + def add_error_codes( mb ): + error_codes_header = os.path.join( settings.tnfox_include_path, 'FXErrCodes.h' ) + #in future version of pyplusplus I will add new code creator + tmpl = '::boost::python::scope().attr("%(name)s") = %(value)s;' + body = mb.code_creator.body + for line in file( error_codes_header ): + line = line.rstrip( os.linesep ) + parts = line.split(' ') + if 3 != len(parts): + continue + if not parts[0].startswith( '#define' ): + continue + define_var = code_creators.custom_text_t( + tmpl % { 'name':parts[1] + , 'value':parts[2] } ) + + body.adopt_creator( define_var ) + + def create_module(): fx_xml = os.path.join( settings.xml_files, 'fx.xml' ) ! mb = module_builder.module_builder_t( [ module_builder.create_cached_source_fc( 'fx.h', fx_xml ) ] , gccxml_path=settings.gccxml_path , include_paths=[settings.boost_path, settings.tnfox_include_path] , define_symbols=settings.defined_symbols_gccxml ) + + mb.run_query_optimizer() print 'filtering declarations' filter_decls( mb ) *************** *** 151,154 **** --- 186,190 ---- print 'customizing module' customize_module( mb ) + add_error_codes( mb ) print 'customizing module - done' return mb *************** *** 157,160 **** --- 193,198 ---- print 'writing module to files' assert isinstance( mb, module_builder.module_builder_t ) + if not os.path.exists( settings.generated_files_dir ): + os.mkdir( settings.generated_files_dir ) start_time = time.clock() file_writers.write_file( os.path.join( settings.generated_files_dir, color_array.file_name ) Index: declarations_to_exclude.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/declarations_to_exclude.py,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** declarations_to_exclude.py 29 Mar 2006 04:26:58 -0000 1.10 --- declarations_to_exclude.py 6 Apr 2006 06:16:07 -0000 1.11 *************** *** 66,70 **** , "::FX::FXWindow::remColormapWindows" , "::FX::QHostAddress::ip6Addr" - , "::FX::QIODevice::readLine" , "::FX::QMemArray::begin" , "::FX::QMemArray::data" --- 66,69 ---- *************** *** 126,131 **** , "::FX::FXEventLoop" , "::FX::TnFXAppEventLoop::executeRetCode" - , "::FX::QIODevice" - , "::FX::QIODeviceS" ] --- 125,128 ---- *************** *** 164,166 **** def is_excluded( decl ): ! return declarations.full_name( decl ) in to_be_excluded or is_deprecated( decl ) \ No newline at end of file --- 161,163 ---- def is_excluded( decl ): ! return declarations.full_name( decl ) in to_be_excluded or is_deprecated( decl ) Index: files_to_exclude.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/files_to_exclude.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** files_to_exclude.py 29 Mar 2006 04:26:58 -0000 1.3 --- files_to_exclude.py 6 Apr 2006 06:16:07 -0000 1.4 *************** *** 14,17 **** --- 14,18 ---- , "FXErrCodes.h" , "FXFileStream.h" + , "FXFunctorTarget.h" , "FXGenericTools.h" , "FXHash.h" *************** *** 26,33 **** , "FXRollback.h" , "FXSecure.h" - , "FXStringDict.h" , "FXString.h" , "FXTextCodec.h" - , "FXURL.h" , "FXUTF16Codec.h" , "FXUTF32Codec.h" --- 27,32 ---- *************** *** 36,39 **** --- 35,39 ---- #Niall? , "QThread.h" + , "FXWinLinks.h" ] Index: tnfox.vcproj =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/tnfox/tnfox.vcproj,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** tnfox.vcproj 1 Feb 2006 07:31:43 -0000 1.7 --- tnfox.vcproj 6 Apr 2006 06:16:07 -0000 1.8 *************** *** 21,25 **** Optimization="0" AdditionalIncludeDirectories="C:\python\libs;D:\pygccxml_sources\source\pyplusplus\examples\tnfox\TnFOX\include;D:\boost_cvs;D:\pygccxml_sources\source\pyplusplus\examples\tnfox\TnFOX\Python" ! PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FXDISABLE_GLOBALALLOCATORREPLACEMENTS;FX_INCLUDE_ABSOLUTELY_EVERYTHING;FOXPYTHONDLL_EXPORTS;FOX_BIGENDIAN" MinimalRebuild="TRUE" BasicRuntimeChecks="3" --- 21,25 ---- Optimization="0" AdditionalIncludeDirectories="C:\python\libs;D:\pygccxml_sources\source\pyplusplus\examples\tnfox\TnFOX\include;D:\boost_cvs;D:\pygccxml_sources\source\pyplusplus\examples\tnfox\TnFOX\Python" ! PreprocessorDefinitions="WIN32;_DEBUG;_WINDOWS;_USRDLL;FXDISABLE_GLOBALALLOCATORREPLACEMENTS;FX_INCLUDE_ABSOLUTELY_EVERYTHING;FOXPYTHONDLL_EXPORTS;FOX_BIGENDIAN;FOXPYTHONDLL" MinimalRebuild="TRUE" [...3828 lines suppressed...] <File *************** *** 2025,2032 **** --- 2062,2077 ---- </File> <File + RelativePath=".\generated\TnFXAppEventLoop.pypp.cpp"> + </File> + <File RelativePath=".\generated\TnFXAppEventLoop.pypp.hpp"> </File> </Filter> <Filter + Name="Header Files" + Filter="h;hpp;hxx;hm;inl;inc;xsd" + UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"> + </Filter> + <Filter Name="Resource Files" Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx" |
From: Roman <rom...@us...> - 2006-04-06 06:16:57
|
Update of /cvsroot/pygccxml/source/pyplusplus/examples/py_date_time/include In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28954/pyplusplus/examples/py_date_time/include Modified Files: date_time.pypp.xml Log Message: There are a lot of changes, sorry CVS did not worked for week or something like this Changes 1. Lots of code clean up 2. Adding and updating documentation 3. Adding new method on decl_wrapper - readme. This method will return list of msgs to the developer. For example if function takes by reference fundamental type it will say that this function could not be called from Python 4. Logging functionlity has been added to file writers too 5. Few bug fixes 6. For operator [] call policies is always set. Index: date_time.pypp.xml =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/examples/py_date_time/include/date_time.pypp.xml,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** date_time.pypp.xml 29 Mar 2006 04:26:57 -0000 1.8 --- date_time.pypp.xml 6 Apr 2006 06:16:06 -0000 1.9 *************** *** 3,8 **** <Namespace id="_1" name="::" members="_3 _4 _5 _6 _7 _8 _9 _10 _11 _12 _13 _14 _15 _16 _17 _18 _19 _20 _21 _22 _23 _24 _25 _26 _27 _28 _29 _30 _31 _32 _33 _34 _35 _36 _37 _38 _39 _40 _41 _42 _43 _44 _45 _46 _47 _48 _49 _50 _51 _52 _53 _54 _55 _56 _57 _58 _59 _60 _61 _62 _63 _64 _65 _66 _67 _68 _70 _71 _72 _73 _74 _75 _77 _78 _79 _80 _81 _82 _83 _84 _85 _86 _87 _88 _89 _90 _91 _92 _93 _94 _95 _96 _97 _98 _99 _100 _101 _102 _103 _104 _105 _106 _107 _108 _109 _110 _111 _112 _113 _114 _115 _116 _117 _118 _119 _120 _121 _122 _123 _124 _125 _126 _127 _128 _129 _130 _131 _132 _133 _134 _135 _136 _137 _138 _139 _140 _141 _142 _143 _144 _145 _146 _147 _148 _149 _150 _151 _152 _153 _154 _155 _156 _157 _158 _159 _160 _161 _162 _163 _164 _165 _166 _167 _168 _169 _170 _171 _172 _173 _174 _175 _176 _177 _178 _179 _180 _181 _182 _183 _184 _185 _186 _187 _188 _189 _190 _191 _192 _193 _194 _195 _196 _197 _198 _199 _200 _201 _202 _203 _204 _205 _206 _207 _208 _209 _210 _211 _212 _213 _214 _215 _216 _217 _218 _219 _220 _221 _222 _223 _224 _225 _226 _227 _228 _229 _230 _231 _232 _233 _234 _235 _236 _237 _238 _239 _240 _241 _242 _243 _244 _245 _246 _247 _248 _249 _250 _251 _252 _253 _254 _255 _256 _257 _258 _259 _260 _261 _262 _263 _264 _265 _266 _267 _268 _269 _270 _271 _272 _273 _274 _275 _276 _277 _278 _279 _280 _281 _282 _283 _284 _285 _286 _287 _288 _289 _290 _291 _292 _293 _294 _295 _296 _297 _298 _299 _300 _301 _302 _303 _304 _305 _306 _307 _308 _309 _310 _311 _312 _313 _314 _315 _316 _317 _318 _319 _320 _321 _322 _323 _324 _325 _326 _327 _328 _329 _330 _331 _332 _333 _334 _335 _336 _337 _338 _339 _340 _341 _342 _343 _344 _345 _346 _347 _348 _349 _350 _351 _352 _353 _354 _355 _356 _357 _358 _359 _360 _361 _362 _363 _364 _365 _366 _367 _368 _369 _370 _371 _372 _373 _374 _375 _376 _377 _378 _379 _380 _381 _382 _383 _384 _385 _386 _387 _388 _389 _390 _391 _392 _393 _394 _395 _396 _397 _398 _399 _400 _401 _402 _403 _404 _405 _406 _407 _408 _409 _410 _411 _412 _413 _414 _415 _416 _417 _418 _419 _420 _421 _422 _423 _424 _425 _426 _427 _428 _429 _430 _431 _432 _433 _434 _435 _436 _437 _438 _439 _440 _441 _442 _443 _444 _445 _446 _447 _448 _449 _450 _451 _452 _453 _454 _455 _456 _457 _458 _459 _460 _461 _462 _463 _464 _465 _466 _467 _468 _469 _470 _471 _472 _473 _474 _475 _476 _477 _478 _479 _480 _481 _482 _483 _484 _485 _486 _487 _488 _489 _490 _491 _492 _493 _494 _495 _496 _497 _498 _499 _500 _501 _502 _503 _504 _505 _506 _507 _508 _509 _510 _511 _512 _513 _514 _515 _516 _517 _518 _519 _520 _521 _522 _523 _524 _525 _526 _527 _528 _529 _530 _531 _532 _533 _534 _535 _536 _537 _538 _539 _540 _541 _542 _543 _544 _545 _546 _547 _548 _549 _550 _551 _552 _553 _554 _555 _556 _557 _558 _559 _560 _561 _562 _563 _564 _565 _566 _567 _568 _569 _571 _572 _573 _574 _575 _576 _577 _578 _579 _580 _581 _582 _583 _584 _585 _586 _587 _588 _589 _590 _591 _592 _593 _594 _595 _596 _597 _598 _599 _600 _601 _602 _603 _604 _605 _606 _607 _608 _609 _610 _611 _612 _613 _614 _615 _616 _617 _618 _619 _620 _621 _622 _623 _625 _626 _627 _628 _629 _630 _631 _632 _633 _634 _635 _636 _637 _638 _639 _640 _642 _643 _644 _645 _646 _647 _648 _649 _650 _651 _652 _653 _654 _655 _656 _657 _658 _659 _660 _661 _662 _663 _664 _665 _666 _667 _668 _669 _670 _671 _672 _673 _674 _675 _676 _677 _678 _679 _680 _681 _682 _683 _684 _685 _686 _687 _688 _689 _690 _691 _692 _693 _694 _695 _696 _697 _698 _699 _700 _701 _702 _703 _704 _705 _706 _707 _708 _709 _710 _711 _712 _713 _714 _715 _716 _717 _718 _719 _720 _721 _722 _723 _724 _725 _726 _727 _728 _729 _730 _731 _732 _733 _734 _735 _736 _737 _738 _739 _740 _741 _742 _743 _744 _745 _746 _747 _748 _749 _750 _751 _752 _753 _754 _755 _756 _757 _758 _759 _760 _761 _762 _763 _764 _765 _766 _767 _768 _769 _770 _771 _772 _773 _774 _775 _776 _777 _778 _779 _780 _781 _782 _783 _784 _785 _786 _787 _788 _789 _790 _791 _792 _793 _794 _795 _796 _797 _798 _799 _800 _801 _802 _803 _804 _805 _806 _808 _809 _810 _811 _812 _813 _814 _815 _816 _817 _818 _820 _821 _823 _824 _825 _826 _827 _828 _829 _830 _831 _832 _833 _834 _835 _836 _837 _838 _839 _840 _841 _842 _843 _844 _845 _846 _847 _848 _849 _850 _851 _852 _853 _854 _855 _856 _857 _858 _859 _860 _861 _862 _863 _864 _865 _866 _867 _868 _869 _870 _871 _872 _873 _874 _875 _876 _877 _878 _879 _880 _881 _882 _883 _884 _885 _886 _887 _888 _889 _890 _891 _892 _893 _894 _895 _896 _897 _898 _899 _900 _901 _902 _903 _904 _905 _906 _907 _908 _909 _910 _911 _912 _913 _914 _915 _916 _917 _918 _919 _920 _921 _922 _923 _924 _925 _926 _927 _928 _929 _930 _931 _932 _933 _934 _935 _936 _937 _938 _939 _940 _941 _942 _943 _944 _945 _946 _947 _948 _949 _950 _951 _952 _953 _954 _955 _956 _957 _958 _959 _960 _961 _962 _963 _964 _965 _966 _967 _968 _969 _970 _971 _972 _973 _974 _975 _976 _977 _978 _979 _980 _981 _982 _983 _984 _985 _986 _987 _988 _989 _990 _991 _992 _993 _994 _995 _996 _997 _998 _999 _1000 _1001 _1002 _1003 _1004 _1005 _1006 _1007 _1008 _1009 _1010 _1011 _1012 _1013 _1014 _1015 _1016 _1017 _1018 _1019 _1020 _1021 _1022 _1023 _1024 _1025 _1026 _1027 _1028 _1029 _1030 _1031 _1032 _1033 _1034 _1035 _1036 _1037 _1038 _1039 _1040 _1041 _1042 _1043 _1044 _1045 _1046 _1047 _1048 _1049 _1050 _1051 _1052 _1053 _1054 _1055 _1056 _1057 _1058 _1059 _1060 _1061 _1062 _1063 _1064 _1065 _1066 _1067 _1068 _1069 _1070 _1071 _1072 _1073 _1074 _1075 _1076 _1077 _1078 _1079 _1080 _1082 _1084 _1086 _1087 _1088 _1089 _1090 _1091 _1092 _1093 _1094 _1095 _1096 _1097 _1098 _1099 _1100 _1101 _1102 _1103 _1104 _1105 _1106 _1107 _1108 _1109 _1110 _1111 _1112 _1113 _1114 _1115 _1116 _1118 _1117 _1120 _1122 _1124 _1126 _1127 _1128 _1129 _1130 _1131 _1132 _1133 _1134 _1135 _1136 _1137 _1138 _1140 _1141 _1142 _1143 _1145 _1146 _1148 _1149 _1151 _1152 _1154 _1156 _1158 _1160 _1162 _1164 _1166 _1168 _1170 _1171 _1172 _1173 _1174 _1175 _1176 _1081 _1083 _807 _1177 _1179 _1180 _1178 _1181 _1182 _1183 _1184 _1185 _1186 _1187 _1188 _1189 _1190 _1191 _1192 _1193 _1194 _1195 _1196 _1197 _1198 _1199 _1200 _1201 _1202 _1203 _1204 _1205 _1206 _1207 _1208 _1209 _1210 _1211 _1212 _1213 _1214 _1215 _1216 _1217 _1218 _1219 _1220 _1221 _1222 _1223 _1224 _1225 _1226 _1227 _1228 _1229 _1230 _1231 _1232 _1233 _1235 _1236 _1237 _1238 _1239 _1240 _1241 _1242 _1243 _1244 _1245 _1246 _1247 _1249 _1250 _1251 _1252 _1253 _1255 _1257 _1258 _1259 _1260 _1261 _1263 _1264 _1265 _1266 _1268 _1269 _1270 _1271 _1272 _1273 _1274 _1275 _1276 _1277 _1278 _1279 _1280 _1281 _1282 _1283 _1284 _1285 _1286 _1287 _1288 _1289 _1290 _1291 _1292 _1293 _1294 _1295 _1296 _1297 _1298 _1299 _1300 _1301 _1302 _1303 _1304 _1305 _1306 _1307 _1308 _1309 _1310 _1311 _1312 _1313 _1314 _1315 _1316 _1317 _1318 _1319 _1320 _1321 _1322 _1323 _1324 _1325 _1326 _1327 _1328 _1329 _1330 _1331 _1332 _1333 _1334 _1335 _1336 _1337 _1338 _1339 _1340 _1341 _1342 _1343 _1344 _1345 _1346 _1347 _1348 _1349 _1350 _1351 _1352 _1353 _1354 _1355 _1356 _1357 _1358 _1359 _1360 _1361 _1362 _1363 _1364 _1365 _1366 _1367 _1368 _1369 _1370 _1371 _1372 _1373 _1374 _1375 _1376 _1377 _1378 _1379 _1380 _1381 _1382 _1383 _1384 _1385 _1386 _1387 _1388 _1389 _1390 _1391 _1392 _1393 _1394 _1395 _1396 _1397 _1398 _1399 _1400 _1401 _1402 _1403 _1404 _1405 _1406 _1407 _1408 _1409 _1410 _1411 _1412 _1413 _1414 _1415 _1416 _1417 _1418 _1419 _1420 _1421 _1422 _1423 _1424 _1425 _1426 _1427 _1428 _1429 _1430 _1431 _1432 _1433 _1434 _1435 _1436 _1438 _1439 _1440 _1441 _1442 _1443 _1444 _1445 _1446 _1447 _1448 _1449 _1450 _1451 _1452 _1453 _1454 _1455 _1456 _1457 _1458 _1459 _1460 _1461 _1462 _1463 _1464 _1465 _1466 _1467 _1468 _1469 _1470 _1471 _1472 _1473 _1474 _1475 _1476 _1477 _1478 _1479 _1480 _1481 _1482 _1483 _1484 _1485 _1486 _1487 _1488 _1489 _1490 _1491 _1492 _1493 _1494 _1495 _1496 _1497 _1499 _1498 _1500 _1501 _819 _1502 _1503 _1504 _1505 _1507 _1506 _1509 _1510 _1511 _1512 _1513 _1514 _1515 _1516 _1517 _1518 _1520 _1521 _1522 _1523 _1524 _1525 _1526 _1527 _1528 _1530 _1529 _1531 _1532 _1533 _1534 _1535 _1536 _1537 _1538 _1539 _1540 _1541 _1542 _1543 _1544 _1545 _1546 _1547 _1548 _1549 _1550 _1551 _1552 _1553 _1554 _1555 _1556 _1557 _1558 _1559 _1560 _1561 _1562 _1563 _1564 _1565 _1567 _1568 _1569 _1570 _1571 _1572 _1573 _1574 _1575 _1576 _1578 _1579 _1580 _1581 _1582 _1583 _1584 _1585 _1586 _1587 _1588 _1589 _1590 _1591 _1592 _1593 _1594 _1595 _1596 _1597 _1598 _1599 _1566 _1600 _1601 _1602 _1603 _1604 _1605 _1606 _1607 _1608 _1609 _1610 _1611 _1612 _1613 _1614 _1615 _1616 _1617 _1618 _1619 _1620 _1621 _1622 _1623 _1624 _1625 _1626 _1627 _1628 _1629 _1630 _1631 _1632 _1633 _1634 _1635 _1636 _1637 _1638 _1639 _1640 _1641 _1642 _1643 _1644 _1645 _1646 _1647 _1648 _1649 _1650 _1651 _1652 _1653 _1654 _1655 _1656 _1657 _1658 _1659 _1660 _1661 _1662 _1663 _1664 _1665 _1666 _1667 _1668 _1669 _1670 _1671 _1672 _1673 _1674 _1675 _1676 _1677 _1678 _1679 _1680 _1681 _1682 _1683 _1684 _1685 _1686 _1687 _1688 _1689 _1690 _1691 _1692 _1693 _1694 _1695 _1696 _1697 _1698 _1699 _1700 _1701 _1702 _1703 _1704 _1705 _1706 _1707 _1708 _1709 _1710 _1711 _1712 _1713 _1714 _1715 _1716 _1717 _1718 _1719 _1720 _1721 _1722 _1723 _1724 _1725 _1726 _1727 _1728 _1729 _1730 _1731 _1732 _1733 _1734 _1735 _1736 _1737 _1738 _1739 _1740 _1741 _1742 _1743 _1744 _1745 _1746 _1747 " mangled="_Z2::"/> <Namespace id="_2" name="std" context="_1" members="_1752 _1753 _1758 _1759 _1770 _1771 _1776 _1777 _1782 _1783 _1785 _1786 _1787 _1788 _1789 _1790 _1791 _1792 _1793 _1794 _1800 _1801 _1802 _1803 _1804 _1805 _1806 _1807 _1808 _1809 _1810 _1811 _1812 _1813 _1814 _1817 _1818 _1819 _1820 _1821 _1822 _1823 _1824 _1825 _1826 _1827 _1828 _1839 _1840 _1841 _1842 _1843 _1844 _1845 _1846 _1847 _1848 _1849 _1850 _1851 _1852 _1853 _1854 _1855 _1856 _1857 _1858 _1862 _1863 _1864 _1865 _1866 _1867 _1868 _1869 _1870 _1871 _1872 _1873 _1874 _1875 _1876 _1877 _1878 _1879 _1880 _1881 _1882 _1883 _1884 _1885 _1886 _1887 _1888 _1889 _1890 _1891 _1892 _1893 _1894 _1895 _1896 _1920 _1930 _1931 _1932 _1933 _1934 _1935 _1936 _1937 _1938 _1939 _1940 _1941 _1942 _1943 _1944 _1945 _1946 _1947 _1948 _1949 _1950 _1951 _1952 _1953 _1954 _1955 _1956 _1957 _1958 _1959 _1960 _1961 _1962 _1963 _1964 _1965 _1966 _1967 _1968 _1969 _1970 _1971 _1972 _1973 _1974 _1975 _1976 _1977 _1978 _1979 _2001 _2002 _2037 _2039 _2041 _2040 _2042 _2043 _2044 _2045 _2046 _2047 _2052 _2053 _2054 _2154 _2156 _2157 _2158 _2215 _2216 _2217 _2218 _2219 _2220 _2222 _2223 _2224 _2225 _2226 _2227 _2228 _2229 _2230 _2231 _2232 _2233 _2234 _2235 _2236 _2238 _2240 _2242 _2244 _2246 _2248 _2250 _2252 _2254 _2256 _2258 _2260 _2262 _2264 _2266 _2268 _2270 _2272 _2274 _2276 _2278 _2280 _2282 _2284 _2286 _2288 _2289 _2290 _2291 _2292 _2293 _2294 _2295 _2296 _2297 _2298 _2299 _2300 _2301 _2302 _2303 _2305 _2306 _2307 _2308 _2309 _2310 _2311 _2312 _2313 _2314 _2315 _2316 _2317 _2318 _2320 _2322 _2323 _2356 _2357 _2358 _2359 _2360 _2361 _2362 _2363 _2364 _2365 " mangled="_Z3std"/> ! <Function id="_3" name="_GLOBAL__D__home_roman_pygccxml_sources_source_pyplusplus_examples_py_date_time_include_date_time.pypp.hppbHk4ab" returns="_1139" context="_1" location="f0:131" file="f0" line="131" endline="131"/> ! <Function id="_4" name="_GLOBAL__I__home_roman_pygccxml_sources_source_pyplusplus_examples_py_date_time_include_date_time.pypp.hppbHk4ab" returns="_1139" context="_1" location="f0:131" file="f0" line="131" endline="131"/> <Variable id="_5" name="_ZGVN5boost9date_time10date_facetINS_9gregorian4dateEcSt19ostreambuf_iteratorIcSt11char_traitsIcEEE2idE" type="_1256" context="_1" location="f1:372" file="f1" line="372" artificial="1"/> <Function id="_6" name="__static_initialization_and_destruction_0" returns="_1139" context="_1" mangled="_Z41__static_initialization_and_destruction_0ii" location="f0:131" file="f0" line="131" endline="77"> --- 3,8 ---- <Namespace id="_1" name="::" members="_3 _4 _5 _6 _7 _8 _9 _10 _11 _12 _13 _14 _15 _16 _17 _18 _19 _20 _21 _22 _23 _24 _25 _26 _27 _28 _29 _30 _31 _32 _33 _34 _35 _36 _37 _38 _39 _40 _41 _42 _43 _44 _45 _46 _47 _48 _49 _50 _51 _52 _53 _54 _55 _56 _57 _58 _59 _60 _61 _62 _63 _64 _65 _66 _67 _68 _70 _71 _72 _73 _74 _75 _77 _78 _79 _80 _81 _82 _83 _84 _85 _86 _87 _88 _89 _90 _91 _92 _93 _94 _95 _96 _97 _98 _99 _100 _101 _102 _103 _104 _105 _106 _107 _108 _109 _110 _111 _112 _113 _114 _115 _116 _117 _118 _119 _120 _121 _122 _123 _124 _125 _126 _127 _128 _129 _130 _131 _132 _133 _134 _135 _136 _137 _138 _139 _140 _141 _142 _143 _144 _145 _146 _147 _148 _149 _150 _151 _152 _153 _154 _155 _156 _157 _158 _159 _160 _161 _162 _163 _164 _165 _166 _167 _168 _169 _170 _171 _172 _173 _174 _175 _176 _177 _178 _179 _180 _181 _182 _183 _184 _185 _186 _187 _188 _189 _190 _191 _192 _193 _194 _195 _196 _197 _198 _199 _200 _201 _202 _203 _204 _205 _206 _207 _208 _209 _210 _211 _212 _213 _214 _215 _216 _217 _218 _219 _220 _221 _222 _223 _224 _225 _226 _227 _228 _229 _230 _231 _232 _233 _234 _235 _236 _237 _238 _239 _240 _241 _242 _243 _244 _245 _246 _247 _248 _249 _250 _251 _252 _253 _254 _255 _256 _257 _258 _259 _260 _261 _262 _263 _264 _265 _266 _267 _268 _269 _270 _271 _272 _273 _274 _275 _276 _277 _278 _279 _280 _281 _282 _283 _284 _285 _286 _287 _288 _289 _290 _291 _292 _293 _294 _295 _296 _297 _298 _299 _300 _301 _302 _303 _304 _305 _306 _307 _308 _309 _310 _311 _312 _313 _314 _315 _316 _317 _318 _319 _320 _321 _322 _323 _324 _325 _326 _327 _328 _329 _330 _331 _332 _333 _334 _335 _336 _337 _338 _339 _340 _341 _342 _343 _344 _345 _346 _347 _348 _349 _350 _351 _352 _353 _354 _355 _356 _357 _358 _359 _360 _361 _362 _363 _364 _365 _366 _367 _368 _369 _370 _371 _372 _373 _374 _375 _376 _377 _378 _379 _380 _381 _382 _383 _384 _385 _386 _387 _388 _389 _390 _391 _392 _393 _394 _395 _396 _397 _398 _399 _400 _401 _402 _403 _404 _405 _406 _407 _408 _409 _410 _411 _412 _413 _414 _415 _416 _417 _418 _419 _420 _421 _422 _423 _424 _425 _426 _427 _428 _429 _430 _431 _432 _433 _434 _435 _436 _437 _438 _439 _440 _441 _442 _443 _444 _445 _446 _447 _448 _449 _450 _451 _452 _453 _454 _455 _456 _457 _458 _459 _460 _461 _462 _463 _464 _465 _466 _467 _468 _469 _470 _471 _472 _473 _474 _475 _476 _477 _478 _479 _480 _481 _482 _483 _484 _485 _486 _487 _488 _489 _490 _491 _492 _493 _494 _495 _496 _497 _498 _499 _500 _501 _502 _503 _504 _505 _506 _507 _508 _509 _510 _511 _512 _513 _514 _515 _516 _517 _518 _519 _520 _521 _522 _523 _524 _525 _526 _527 _528 _529 _530 _531 _532 _533 _534 _535 _536 _537 _538 _539 _540 _541 _542 _543 _544 _545 _546 _547 _548 _549 _550 _551 _552 _553 _554 _555 _556 _557 _558 _559 _560 _561 _562 _563 _564 _565 _566 _567 _568 _569 _571 _572 _573 _574 _575 _576 _577 _578 _579 _580 _581 _582 _583 _584 _585 _586 _587 _588 _589 _590 _591 _592 _593 _594 _595 _596 _597 _598 _599 _600 _601 _602 _603 _604 _605 _606 _607 _608 _609 _610 _611 _612 _613 _614 _615 _616 _617 _618 _619 _620 _621 _622 _623 _625 _626 _627 _628 _629 _630 _631 _632 _633 _634 _635 _636 _637 _638 _639 _640 _642 _643 _644 _645 _646 _647 _648 _649 _650 _651 _652 _653 _654 _655 _656 _657 _658 _659 _660 _661 _662 _663 _664 _665 _666 _667 _668 _669 _670 _671 _672 _673 _674 _675 _676 _677 _678 _679 _680 _681 _682 _683 _684 _685 _686 _687 _688 _689 _690 _691 _692 _693 _694 _695 _696 _697 _698 _699 _700 _701 _702 _703 _704 _705 _706 _707 _708 _709 _710 _711 _712 _713 _714 _715 _716 _717 _718 _719 _720 _721 _722 _723 _724 _725 _726 _727 _728 _729 _730 _731 _732 _733 _734 _735 _736 _737 _738 _739 _740 _741 _742 _743 _744 _745 _746 _747 _748 _749 _750 _751 _752 _753 _754 _755 _756 _757 _758 _759 _760 _761 _762 _763 _764 _765 _766 _767 _768 _769 _770 _771 _772 _773 _774 _775 _776 _777 _778 _779 _780 _781 _782 _783 _784 _785 _786 _787 _788 _789 _790 _791 _792 _793 _794 _795 _796 _797 _798 _799 _800 _801 _802 _803 _804 _805 _806 _808 _809 _810 _811 _812 _813 _814 _815 _816 _817 _818 _820 _821 _823 _824 _825 _826 _827 _828 _829 _830 _831 _832 _833 _834 _835 _836 _837 _838 _839 _840 _841 _842 _843 _844 _845 _846 _847 _848 _849 _850 _851 _852 _853 _854 _855 _856 _857 _858 _859 _860 _861 _862 _863 _864 _865 _866 _867 _868 _869 _870 _871 _872 _873 _874 _875 _876 _877 _878 _879 _880 _881 _882 _883 _884 _885 _886 _887 _888 _889 _890 _891 _892 _893 _894 _895 _896 _897 _898 _899 _900 _901 _902 _903 _904 _905 _906 _907 _908 _909 _910 _911 _912 _913 _914 _915 _916 _917 _918 _919 _920 _921 _922 _923 _924 _925 _926 _927 _928 _929 _930 _931 _932 _933 _934 _935 _936 _937 _938 _939 _940 _941 _942 _943 _944 _945 _946 _947 _948 _949 _950 _951 _952 _953 _954 _955 _956 _957 _958 _959 _960 _961 _962 _963 _964 _965 _966 _967 _968 _969 _970 _971 _972 _973 _974 _975 _976 _977 _978 _979 _980 _981 _982 _983 _984 _985 _986 _987 _988 _989 _990 _991 _992 _993 _994 _995 _996 _997 _998 _999 _1000 _1001 _1002 _1003 _1004 _1005 _1006 _1007 _1008 _1009 _1010 _1011 _1012 _1013 _1014 _1015 _1016 _1017 _1018 _1019 _1020 _1021 _1022 _1023 _1024 _1025 _1026 _1027 _1028 _1029 _1030 _1031 _1032 _1033 _1034 _1035 _1036 _1037 _1038 _1039 _1040 _1041 _1042 _1043 _1044 _1045 _1046 _1047 _1048 _1049 _1050 _1051 _1052 _1053 _1054 _1055 _1056 _1057 _1058 _1059 _1060 _1061 _1062 _1063 _1064 _1065 _1066 _1067 _1068 _1069 _1070 _1071 _1072 _1073 _1074 _1075 _1076 _1077 _1078 _1079 _1080 _1082 _1084 _1086 _1087 _1088 _1089 _1090 _1091 _1092 _1093 _1094 _1095 _1096 _1097 _1098 _1099 _1100 _1101 _1102 _1103 _1104 _1105 _1106 _1107 _1108 _1109 _1110 _1111 _1112 _1113 _1114 _1115 _1116 _1118 _1117 _1120 _1122 _1124 _1126 _1127 _1128 _1129 _1130 _1131 _1132 _1133 _1134 _1135 _1136 _1137 _1138 _1140 _1141 _1142 _1143 _1145 _1146 _1148 _1149 _1151 _1152 _1154 _1156 _1158 _1160 _1162 _1164 _1166 _1168 _1170 _1171 _1172 _1173 _1174 _1175 _1176 _1081 _1083 _807 _1177 _1179 _1180 _1178 _1181 _1182 _1183 _1184 _1185 _1186 _1187 _1188 _1189 _1190 _1191 _1192 _1193 _1194 _1195 _1196 _1197 _1198 _1199 _1200 _1201 _1202 _1203 _1204 _1205 _1206 _1207 _1208 _1209 _1210 _1211 _1212 _1213 _1214 _1215 _1216 _1217 _1218 _1219 _1220 _1221 _1222 _1223 _1224 _1225 _1226 _1227 _1228 _1229 _1230 _1231 _1232 _1233 _1235 _1236 _1237 _1238 _1239 _1240 _1241 _1242 _1243 _1244 _1245 _1246 _1247 _1249 _1250 _1251 _1252 _1253 _1255 _1257 _1258 _1259 _1260 _1261 _1263 _1264 _1265 _1266 _1268 _1269 _1270 _1271 _1272 _1273 _1274 _1275 _1276 _1277 _1278 _1279 _1280 _1281 _1282 _1283 _1284 _1285 _1286 _1287 _1288 _1289 _1290 _1291 _1292 _1293 _1294 _1295 _1296 _1297 _1298 _1299 _1300 _1301 _1302 _1303 _1304 _1305 _1306 _1307 _1308 _1309 _1310 _1311 _1312 _1313 _1314 _1315 _1316 _1317 _1318 _1319 _1320 _1321 _1322 _1323 _1324 _1325 _1326 _1327 _1328 _1329 _1330 _1331 _1332 _1333 _1334 _1335 _1336 _1337 _1338 _1339 _1340 _1341 _1342 _1343 _1344 _1345 _1346 _1347 _1348 _1349 _1350 _1351 _1352 _1353 _1354 _1355 _1356 _1357 _1358 _1359 _1360 _1361 _1362 _1363 _1364 _1365 _1366 _1367 _1368 _1369 _1370 _1371 _1372 _1373 _1374 _1375 _1376 _1377 _1378 _1379 _1380 _1381 _1382 _1383 _1384 _1385 _1386 _1387 _1388 _1389 _1390 _1391 _1392 _1393 _1394 _1395 _1396 _1397 _1398 _1399 _1400 _1401 _1402 _1403 _1404 _1405 _1406 _1407 _1408 _1409 _1410 _1411 _1412 _1413 _1414 _1415 _1416 _1417 _1418 _1419 _1420 _1421 _1422 _1423 _1424 _1425 _1426 _1427 _1428 _1429 _1430 _1431 _1432 _1433 _1434 _1435 _1436 _1438 _1439 _1440 _1441 _1442 _1443 _1444 _1445 _1446 _1447 _1448 _1449 _1450 _1451 _1452 _1453 _1454 _1455 _1456 _1457 _1458 _1459 _1460 _1461 _1462 _1463 _1464 _1465 _1466 _1467 _1468 _1469 _1470 _1471 _1472 _1473 _1474 _1475 _1476 _1477 _1478 _1479 _1480 _1481 _1482 _1483 _1484 _1485 _1486 _1487 _1488 _1489 _1490 _1491 _1492 _1493 _1494 _1495 _1496 _1497 _1499 _1498 _1500 _1501 _819 _1502 _1503 _1504 _1505 _1507 _1506 _1509 _1510 _1511 _1512 _1513 _1514 _1515 _1516 _1517 _1518 _1520 _1521 _1522 _1523 _1524 _1525 _1526 _1527 _1528 _1530 _1529 _1531 _1532 _1533 _1534 _1535 _1536 _1537 _1538 _1539 _1540 _1541 _1542 _1543 _1544 _1545 _1546 _1547 _1548 _1549 _1550 _1551 _1552 _1553 _1554 _1555 _1556 _1557 _1558 _1559 _1560 _1561 _1562 _1563 _1564 _1565 _1567 _1568 _1569 _1570 _1571 _1572 _1573 _1574 _1575 _1576 _1578 _1579 _1580 _1581 _1582 _1583 _1584 _1585 _1586 _1587 _1588 _1589 _1590 _1591 _1592 _1593 _1594 _1595 _1596 _1597 _1598 _1599 _1566 _1600 _1601 _1602 _1603 _1604 _1605 _1606 _1607 _1608 _1609 _1610 _1611 _1612 _1613 _1614 _1615 _1616 _1617 _1618 _1619 _1620 _1621 _1622 _1623 _1624 _1625 _1626 _1627 _1628 _1629 _1630 _1631 _1632 _1633 _1634 _1635 _1636 _1637 _1638 _1639 _1640 _1641 _1642 _1643 _1644 _1645 _1646 _1647 _1648 _1649 _1650 _1651 _1652 _1653 _1654 _1655 _1656 _1657 _1658 _1659 _1660 _1661 _1662 _1663 _1664 _1665 _1666 _1667 _1668 _1669 _1670 _1671 _1672 _1673 _1674 _1675 _1676 _1677 _1678 _1679 _1680 _1681 _1682 _1683 _1684 _1685 _1686 _1687 _1688 _1689 _1690 _1691 _1692 _1693 _1694 _1695 _1696 _1697 _1698 _1699 _1700 _1701 _1702 _1703 _1704 _1705 _1706 _1707 _1708 _1709 _1710 _1711 _1712 _1713 _1714 _1715 _1716 _1717 _1718 _1719 _1720 _1721 _1722 _1723 _1724 _1725 _1726 _1727 _1728 _1729 _1730 _1731 _1732 _1733 _1734 _1735 _1736 _1737 _1738 _1739 _1740 _1741 _1742 _1743 _1744 _1745 _1746 _1747 " mangled="_Z2::"/> <Namespace id="_2" name="std" context="_1" members="_1752 _1753 _1758 _1759 _1770 _1771 _1776 _1777 _1782 _1783 _1785 _1786 _1787 _1788 _1789 _1790 _1791 _1792 _1793 _1794 _1800 _1801 _1802 _1803 _1804 _1805 _1806 _1807 _1808 _1809 _1810 _1811 _1812 _1813 _1814 _1817 _1818 _1819 _1820 _1821 _1822 _1823 _1824 _1825 _1826 _1827 _1828 _1839 _1840 _1841 _1842 _1843 _1844 _1845 _1846 _1847 _1848 _1849 _1850 _1851 _1852 _1853 _1854 _1855 _1856 _1857 _1858 _1862 _1863 _1864 _1865 _1866 _1867 _1868 _1869 _1870 _1871 _1872 _1873 _1874 _1875 _1876 _1877 _1878 _1879 _1880 _1881 _1882 _1883 _1884 _1885 _1886 _1887 _1888 _1889 _1890 _1891 _1892 _1893 _1894 _1895 _1896 _1920 _1930 _1931 _1932 _1933 _1934 _1935 _1936 _1937 _1938 _1939 _1940 _1941 _1942 _1943 _1944 _1945 _1946 _1947 _1948 _1949 _1950 _1951 _1952 _1953 _1954 _1955 _1956 _1957 _1958 _1959 _1960 _1961 _1962 _1963 _1964 _1965 _1966 _1967 _1968 _1969 _1970 _1971 _1972 _1973 _1974 _1975 _1976 _1977 _1978 _1979 _2001 _2002 _2037 _2039 _2041 _2040 _2042 _2043 _2044 _2045 _2046 _2047 _2052 _2053 _2054 _2154 _2156 _2157 _2158 _2215 _2216 _2217 _2218 _2219 _2220 _2222 _2223 _2224 _2225 _2226 _2227 _2228 _2229 _2230 _2231 _2232 _2233 _2234 _2235 _2236 _2238 _2240 _2242 _2244 _2246 _2248 _2250 _2252 _2254 _2256 _2258 _2260 _2262 _2264 _2266 _2268 _2270 _2272 _2274 _2276 _2278 _2280 _2282 _2284 _2286 _2288 _2289 _2290 _2291 _2292 _2293 _2294 _2295 _2296 _2297 _2298 _2299 _2300 _2301 _2302 _2303 _2305 _2306 _2307 _2308 _2309 _2310 _2311 _2312 _2313 _2314 _2315 _2316 _2317 _2318 _2320 _2322 _2323 _2356 _2357 _2358 _2359 _2360 _2361 _2362 _2363 _2364 _2365 " mangled="_Z3std"/> ! <Function id="_3" name="_GLOBAL__D__home_roman_pygccxml_sources_source_pyplusplus_examples_py_date_time_include_date_time.pypp.hppdoechd" returns="_1139" context="_1" location="f0:131" file="f0" line="131" endline="131"/> [...14492 lines suppressed...] <CvQualifiedType id="_3201c" type="_3201" const="1"/> <CvQualifiedType id="_3254c" type="_3254" const="1"/> ! <CvQualifiedType id="_9370c" type="_9370" const="1"/> ! <Class id="_9394" name="deque<char,std::allocator<char> >" context="_2" mangled="St5dequeIcSaIcEE" location="f81:638" file="f81" line="638"/> <CvQualifiedType id="_3198c" type="_3198" const="1"/> ! <PointerType id="_9952" type="_1173"/> ! <PointerType id="_9953" type="_3165"/> ! <PointerType id="_9954" type="_3130"/> ! <PointerType id="_9955" type="_2438"/> ! <Namespace id="_9956" name="__cxxabiv1" context="_1" mangled="_Z10__cxxabiv1"/> ! <ReferenceType id="_9957" type="_6393"/> ! <Unimplemented id="_9958" tree_code="188" tree_code_name="template_type_parm" node="0xcb59b60"/> ! <MethodType id="_9959" basetype="_9961" returns="_1139"> </MethodType> ! <MethodType id="_9960" basetype="_9962" returns="_1139"> </MethodType> ! <Struct id="_9961" name="FinderConcept<boost::algorithm::detail::first_finderF<const char*, boost::algorithm::is_equal>,__gnu_cxx::__normal_iterator<const char*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >" context="_2981" mangled="N5boost9algorithm13FinderConceptINS0_6detail13first_finderFIPKcNS0_8is_equalEEEN9__gnu_cxx17__normal_iteratorIS5_SsEEEE" location="f244:35" file="f244" line="35"/> ! <Struct id="_9962" name="FormatterConcept<boost::algorithm::detail::const_formatF<std::basic_string<char, std::char_traits<char>, std::allocator<char> > >,boost::algorithm::detail::first_finderF<const char*, boost::algorithm::is_equal>,__gnu_cxx::__normal_iterator<const char*, std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >" context="_2981" mangled="N5boost9algorithm16FormatterConceptINS0_6detail13const_formatFISsEENS2_13first_finderFIPKcNS0_8is_equalEEEN9__gnu_cxx17__normal_iteratorIS7_SsEEEE" location="f244:62" file="f244" line="62"/> <File id="f0" name="/home/roman/boost_cvs/boost/algorithm/string/sequence_traits.hpp"/> <File id="f1" name="/home/roman/boost_cvs/boost/date_time/date_facet.hpp"/> |
From: Roman <rom...@us...> - 2006-04-06 06:16:56
|
Update of /cvsroot/pygccxml/source/pyplusplus/module_builder In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28954/pyplusplus/module_builder Modified Files: builder.py Log Message: There are a lot of changes, sorry CVS did not worked for week or something like this Changes 1. Lots of code clean up 2. Adding and updating documentation 3. Adding new method on decl_wrapper - readme. This method will return list of msgs to the developer. For example if function takes by reference fundamental type it will say that this function could not be called from Python 4. Logging functionlity has been added to file writers too 5. Few bug fixes 6. For operator [] call policies is always set. Index: builder.py =================================================================== RCS file: /cvsroot/pygccxml/source/pyplusplus/module_builder/builder.py,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** builder.py 30 Mar 2006 05:56:17 -0000 1.7 --- builder.py 6 Apr 2006 06:16:08 -0000 1.8 *************** *** 5,8 **** --- 5,9 ---- import os + import time import types from sets import Set as set *************** *** 12,16 **** from pyplusplus import module_creator as mcreator_package from pyplusplus import file_writers ! class module_builder_t(object): --- 13,17 ---- from pyplusplus import module_creator as mcreator_package from pyplusplus import file_writers ! from pyplusplus import _logging_ class module_builder_t(object): *************** *** 36,39 **** --- 37,50 ---- , start_with_declarations=start_with_declarations , verbose=compilation_verbose) + + #may be in future I will add those directories to user_defined_directories + #to self.__code_creator. + self.__working_dir = os.path.abspath( working_directory ) + + self.__parsed_files = map( decls_package.filtering.normalize_path + , parser.project_reader_t.get_os_file_names( files ) ) + tmp = map( lambda file_: os.path.split( file_ )[0], self.__parsed_files ) + self.__parsed_dirs = filter( None, tmp ) + self.__global_ns = self.__parse_declarations( files , gccxml_config *************** *** 43,47 **** if optimize_queries: self.run_query_optimizer() ! def _get_global_ns( self ): return self.__global_ns --- 54,58 ---- if optimize_queries: self.run_query_optimizer() ! def _get_global_ns( self ): return self.__global_ns *************** *** 49,55 **** def run_query_optimizer(self): - map( lambda decl: decl.init_optimizer() - , filter( lambda decl: isinstance( decl, decls_package.scopedef_t ) - , decls_package.make_flatten( self.__global_ns ) ) ) self.__global_ns.init_optimizer() --- 60,63 ---- *************** *** 59,90 **** if None is compilation_mode: compilation_mode = parser.COMPILATION_MODE.FILE_BY_FILE reader = parser.project_reader_t( gccxml_config, cache, decl_wrappers.dwfactory_t() ) decls = reader.read_files( files, compilation_mode ) ! self.__apply_decls_defaults(decls, reader.get_os_file_names(files) ) return decls_package.matcher.get_single( decls_package.namespace_matcher_t( name='::' ) , decls ) ! def __apply_decls_defaults(self, decls, parsed_files): ! dnames = map( lambda fname: os.path.split( fname )[0], parsed_files ) ! locations = parsed_files + dnames ! relevant_decls = decls_package.filtering.by_location( decls, locations ) ! relevant_decls_ids = map( id, relevant_decls ) ! call_policies_resolver = mcreator_package.built_in_resolver_t() ! for decl in decls_package.make_flatten( decls ): ! if id( decl ) not in relevant_decls_ids: ! decl.ignore = True ! if isinstance( decl, decls_package.calldef_t ): ! decl.call_policies = call_policies_resolver( decl ) ! if isinstance( decl, decls_package.member_operator_t ) \ ! and decl.symbol == '()': ! decl.alias = '__call__' ! #if I remove the union I should remove also all variables that have the union type ! if isinstance( decl, decls_package.class_t ): ! if decl.class_type == decls_package.CLASS_TYPES.UNION: ! decl.exclude() ! def print_declarations(self): ! decl_wrappers.print_declarations( self.global_ns ) def build_code_creator( self --- 67,114 ---- if None is compilation_mode: compilation_mode = parser.COMPILATION_MODE.FILE_BY_FILE + start_time = time.clock() + _logging_.logger.debug( 'parsing files - started' ) reader = parser.project_reader_t( gccxml_config, cache, decl_wrappers.dwfactory_t() ) decls = reader.read_files( files, compilation_mode ) ! _logging_.logger.debug( 'parsing files - done( %f seconds )' % ( time.clock() - start_time ) ) ! _logging_.logger.debug( 'settings declarations defaults- started' ) ! start_time = time.clock() ! self.__apply_decls_defaults(decls) ! _logging_.logger.debug( 'settings declarations defaults - done( %f seconds )' ! % ( time.clock() - start_time ) ) return decls_package.matcher.get_single( decls_package.namespace_matcher_t( name='::' ) , decls ) ! def __filter_by_location( self, flatten_decls ): ! for decl in flatten_decls: ! if not decl.location: ! continue ! fpath = decls_package.filtering.normalize_path( decl.location.file_name ) ! if decls_package.filtering.contains_parent_dir( fpath, self.__parsed_dirs ): ! continue ! if fpath in self.__parsed_files: ! continue ! found = False ! for pfile in self.__parsed_files: ! if fpath.endswith( pfile ): ! found = True ! break ! if not found: ! decl.exclude() ! def __apply_decls_defaults(self, decls): ! flatten_decls = decls_package.make_flatten( decls ) ! self.__filter_by_location( flatten_decls ) ! call_policies_resolver = mcreator_package.built_in_resolver_t() ! calldefs = filter( lambda decl: isinstance( decl, decls_package.calldef_t ) ! , flatten_decls ) ! map( lambda calldef: calldef.set_call_policies( call_policies_resolver( calldef ) ) ! , calldefs ) ! ! def print_declarations(self, decl=None): ! if None is decl: ! decl = self.global_ns ! decl_wrappers.print_declarations( decl ) def build_code_creator( self *************** *** 103,106 **** --- 127,135 ---- , target_configuration ) self.__code_creator = creator.create() + #I think I should ask users, what they expect + #self.__code_creator.user_defined_directories.append( self.__working_dir ) + #map( self.__code_creator.user_defined_directories.append + # , self.__parsed_dirs ) + return self.__code_creator *************** *** 154,157 **** --- 183,187 ---- return self.global_ns.variable( name=name , function=function + , type=type , header_dir=header_dir , header_file=header_file *************** *** 161,164 **** --- 191,195 ---- return self.global_ns.variables( name=name , function=function + , type=type , header_dir=header_dir , header_file=header_file *************** *** 198,202 **** , symbol=symbol , function=function ! , decl_type=declarations.operator_t , return_type=return_type , arg_types=arg_types --- 229,233 ---- , symbol=symbol , function=function ! , decl_type=decl_type , return_type=return_type , arg_types=arg_types *************** *** 204,207 **** --- 235,239 ---- , header_file=header_file , recursive=recursive ) + def member_function( self, name=None, function=None, return_type=None, arg_types=None, header_dir=None, header_file=None, recursive=None ): return self.global_ns.member_function( name=name *************** *** 284,288 **** , header_file=header_file , recursive=recursive) ! def enumerations( self, name=None, function=None, header_dir=None, header_file=None, recursive=None ): return self.global_ns.enumerations( name=name --- 316,321 ---- , header_file=header_file , recursive=recursive) ! enum = enumeration ! def enumerations( self, name=None, function=None, header_dir=None, header_file=None, recursive=None ): return self.global_ns.enumerations( name=name *************** *** 292,296 **** , recursive=recursive) ! def namespace( self, name=None, function=None, recursive=None ): return self.global_ns.namespace( name=name --- 325,330 ---- , recursive=recursive) ! enums = enumerations ! def namespace( self, name=None, function=None, recursive=None ): return self.global_ns.namespace( name=name |