« Return to Thread: Most trivial example - failure

Re: SWIG documentation - compilers, modules and other mysteries.

by wsfulton :: Rate this Message:

Reply to Author | View in Thread

Smith Jack (Ext. - UGIS - UniCredit Group) wrote:

>  
> This wikipedia article helped me to understand SWIG's use of the term
> "module".
>
> http://en.wikipedia.org/wiki/Modularity_(programming)
>
> May I suggest that this term be clearly defined early in the SWIG
> documentation so that those of us who have never developed using COBOL,
> RPG, PL/1, Ada, D, F, Fortran, Haskell, Pascal,ML, Modula-2, Erlang,
> Perl, Python or Ruby (which apparently are familiar with the term as is
> used) - a set which includes the worlds most popular programming
> languages (Visual)Basic, C, C++, C# and Java - can at least start to
> understand the SWIG documentation.
>
> I'm still not certain what equivalent concept exists in those latter
> languages, but I suspect that for C++, C# and Java the word 'class' is
> an almost exact replacement.
>
> As a reasonably seasoned C/C++/C# developer reading the SWIG
> documentation is very difficult, since there are frequent misuse of
> terms such as compile and module.
>
> Examples:
>
> "In a nutshell, SWIG is a compiler that takes C declarations and creates
> the wrappers ...", here the use of the word 'compiler' is extremely
> confusing and at odds with the classic definition of that word - see:
> Paragraph 2 http://en.wikipedia.org/wiki/Compiler .  I would say that
> SWIG is essentially an enhanced pre-processor (in the C/C++ use of that
> term), not a compiler, since it does not output object files.
>
> "Most operating systems and scripting languages now support dynamic
> loading of modules."  I know of no 'major' operating system which allows
> the dynamic loading of 'modules' (especially considering that the SWIG
> usage of module is not an executable image, but essentially a 'class'
> definition), but I know several operating systems which allow the
> dynamic loading of shared object files (aka Dynamic Link Library) which
> may contain any number of compiled 'modules'.
>
> It is these types of inconsistancies which, for me anyway, have made
> understanding SWIG extremely challenging.
>
> I hope I don't sound like I'm being pedantic, or merely ranting. SWIG is
> clearly a very powerful and useful too, and I have little choice but to
> use it for the project I am on now.  I hope my comments are accepted in
> the spirit they are intended, to help others like myself who are new to
> SWIG learn it more efficiently.

SWIG is an open source project and all the contributions, including the
documentation have been given by volunteers. Although the nearly 700
pages of documentation is of a much higher volume and quality compared
to most open source projects, it is far from being perfect and is
lacking severely in some areas. Many of your comments in previous
threads have been valid, but some indicate that you simply have not hd
the patience to read the documentation that is there. I havn't had time
to reply to all your comments, but have attempted to improve the docs on
modules with your comments in mind. You can view the recent commits
http://swig.svn.sourceforge.net/viewvc/swig/trunk/Doc/Manual/?view=log

and can even view the latest version online from
http://swig.svn.sourceforge.net/viewvc/swig/trunk/Doc/Manual/

starting here:
http://swig.svn.sourceforge.net/viewvc/swig/trunk/Doc/Manual/Contents.html

Given you are going through the docs with a fine tooth comb, please
submit a patch onto SourceForge with any corrections you feel are
necessary. Contributions from SWIG users such as yourself are the only
way it is going to get better.

Thanks
William

------------------------------------------------------------------------------
Crystal Reports - New Free Runtime and 30 Day Trial
Check out the new simplified licensing option that enables unlimited
royalty-free distribution of the report engine for externally facing
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Swig-user mailing list
Swig-user@...
https://lists.sourceforge.net/lists/listinfo/swig-user

 « Return to Thread: Most trivial example - failure