Redet Reference Manual: Limits
Author: Bill Poser

## Limitations

There are a number of things that Redet cannot do. Some of these are probably temporary; others are deeper and will be difficult or impossible to achieve.

In its present form, Redet is line-oriented. It matches patterns against single lines of data and performs substitutions on single lines. It is therefore not useful for searches and replacements in which larger chunks are needed and cannot be used to explore properties involving matching over more than one line, such as whether a construct matches newline characters. Similarly, Redet cannot distinguish between the beginning of a string and the beginning of a file, or between the end of a string and the end of a file.

Redet is oriented toward declarative specification of patterns and substitutions, where the user specifies a pattern to match and possibly also a substituion to perform but does not provide any explicit instructions as to how to perform the match or substitution. Some pattern matchers are procedural or combine procedural and declarative elements. An example of the latter is Perl, which allows arbitrary Perl code to be intermixed with regular expressions. Redet only deals with declarative pattern matching and substitution.

Redet does not always support (by feature-testing and a palette entry) every feature of every engine. This may be because I don't know about the feature or have overlooked it. It may be because I don't understand the feature well, or because I have not yet figured out how to test it. If you would like to see a missing feature supported, feel free to contact me about it.

Some characters have special meaning to Tcl, the language in which Redet is written, to the language used actually to execute the expression, or to an intermediate program, such as a shell, through which the regular expression passes during execution. In some cases expressions may be passed to the engine in more than one way. As a result, issues arise having to do with quotation, that is, with preventing characters from being interpreted until we want them to be.

If you are using Redet as a search or replace tool, this should not concern you. If you are using Redet to prepare expressions for use elsewhere, it is possible that you will need to quote them differently if you pass them to the engine in a different way than I do. If, for example, I am embedding the expression directly in the source text of a program but you pass expressions via the command line or read them from a file, you may have to quote them differently.

Next
Back to Table of Contents