Regular expression code implementation review between Tcl vs Python

K_Lee Google_Post at
Tue Nov 11 16:58:14 CET 2003

I documented the regex internal implementation code for both Tcl and Python.

As much as I like Tcl, I like Python's code much more.  
Tcl's Stub interface to the external commands is confusing to 
outsider.   I still don't get why the stub interface is needed.

One aspect I don't understanding about python is that the Python
language itself is object oriented and all the internal is implement
as C object.   Why not C++ object?

         Regular Expression
             initregex - regexmodule.c:646
             regex_global_methods - regexmodule.c:635
                 regex_compile - regexmodule.c:410
                 regex_symcomp - regexmodule.c:637
                 regex_match - regexmodule.c:638
                 regex_search - regexmodule.c:639
             re_compile_initialize - regexpr.c:448
             re_compile_pattern - regexpr.h:83

         Regular Expression
             TclRegexp - tclRegexp.h:35
             Tcl_RegExpCompile - tclRegexp.c:141
                 CompileRegexp - tclRegexp.c:147
             Tcl_RegExpExec - tclRegexp.c:173
                 RegExpExecUniChar - tclRegexp.c:213
                     RegExpExecUniChar - tclRegexp.c:291

More information about the Python-list mailing list