tcl

Topics related to tcl:

Getting started with tcl

Tcl is a cross platform language with full unicode support.

Flexibility: redefine or enhance existing commands or write new commands.

Event driven programming: Event driven I/O and variable tracing.

Library Interface: It is very easy to integrate existing C libraries into Tcl and provide a Tcl interface to the C library. These interface "stubs" are not tied to any particular version of Tcl and will continue to work even after upgrading Tcl.

Tcl Interface: Tcl provides a complete API so you use the Tcl interpreter from within your C/Python/Ruby/Java/R program.

Expressions

Another benefit from using braced expression strings is that the byte compiler usually can generate more efficient code (5 - 10x faster) from them.

Procedure arguments

Variables

Dictionaries

Tcl Language Constructs

Control Structures

Regular Expressions

This topic is not intended to discuss regular expressions themselves. There are many resources on the internet explaining regular expressions and tools to help build regular expressions.

This topic will try to cover the common switches and methods of using regular expressions in Tcl and some of the differences between Tcl and other regular expression engines.

Regular expressions are generally slow. The first question you should ask is "Do I really need a regular expression?". Only match what you want. If you don't need the other data, don't match it.

For the purposes of these regular expression examples, the -expanded switch will be used in order to be able to comment and explain the regular expression.

Pathnames and filenames