Topic: string transformation languages

topics > computer science > programming > Group: types of programming languages


access by pattern matching
evaluate operator
pattern matching
reduction languages
reduction machines
scripting language
string operations
structure transformation languages
symbolic manipulation of formulas
theorem proving systems
transformation of programs


During string transformation, strings are processed by rewrite rules. When a rule matches a sub-string, the sub-string is replaced by the rule's right-hand side. String components can be rearranged or values inserted. This process may or may not be repeated. Some languages such as COMIT and SNOBOL allow local string transformations controlled by program statements. Macro languages expand text by paraphrase extension and rescan for new macro calls. Other languages such as TRAC are organized totally around string transformation. In TRAC, the idle loop is #(ps,#(rs a)) which reads a string into 'a', evaluates it, then prints the "value". The printed value is also a string.

Advantages -- Direct manipulation of user readable data; practical implementation of reduction machines. (cbb 5/80)

Subtopic: programming by string rewrite up

Quote: use GAWK for AI because any logic merely defines how strings can be transformed into other strings; GAWK is designed for string transformation [»louiRP8_1996]
Quote: program refinements can be formalized by transformation rules with a source pattern, target pattern, and enabling condition [»smitDR11_1985]
Quote: TRAC converts active strings to inactive ones; ##(...) has an inactive result and #(...) an active result [»mooeCN8_1965, OK]
QuoteRef: sammJE_1969 ;;453 example #(ds, n, ##(c1,n)#(da)) calls n into working area, deletes all forms (da) then defines form n as original without segment gaps.
QuoteRef: sammJE_1969 ;;422 program of rewrite rules executed if pattern found: label pattern-specifier = pattern replacement // routing goto (null field by *)
QuoteRef: wessBD_1965 ;; takes string of characters, replaces with another and see if do again.

Subtopic: pattern replacement up

Quote: perform string transformations by pattern replacement of leftmost, shortest match; includes variable parts [»ledgHF9_1971, OK]
QuoteRef: sammJE_1969 ;;426 left side refers to substring to be replaced and constitutes not mentioned are deleted.
QuoteRef: sammJE_1969 ;;426 replacement string built by sequence arguments (e.g. 1 for first pattern constitute)
QuoteRef: bobrDG9_1974 ;;158 macro value substituted into pattern before matching
QuoteRef: chriC8_1966 ;;570 string transformations as unique match to replacement, pattern of literals and certain classes e.g., all
QuoteRef: farbDJ1_1964 ;;23 replace by search string expression = string (if true the pattern match is replaced by the string)
QuoteRef: sammJE_1969 ;;432 change all B to C by *$+b=1+c//*Q23 1 2 / (repeats till fails) *$0=//*A23 1*
QuoteRef: solnN_1971 ;;280 Leavenworth, R.M. '66: macro's which do pattern match with literals and classes then replace pattern based on matching string

Subtopic: alternate patterns up

QuoteRef: solnN_1971 ;;281 Leavenworth RM '66: macros with alternate patterns can be tested in replacement pattern using label keyed alternatives
Quote: evaluation in Icon seeks for successful results in the presence of alternative values [»grisRE4_1979]

Subtopic: pattern replacement with context up

Quote: instead of parameters, a macro can use its left and right context; arbitrary modifications (search outward from call) [»granCA12_1971, OK]

Related Topics up

Group: grammar   (8 topics, 181 quotes)
Group: patterns   (8 topics, 179 quotes)

Topic: access by pattern matching (18 items)
Topic: evaluate operator (7 items)
Topic: macros (22 items)
Topic: pattern matching (42 items)
Topic: reduction languages (17 items)
Topic: reduction machines (14 items)
Topic: scripting language (27 items)
Topic: strings (13 items)
Topic: string operations (20 items)
Topic: structure transformation languages (7 items)
Topic: symbolic manipulation of formulas (12 items)
Topic: theorem proving systems (20 items)
Topic: transformation of programs
(27 items)

Updated barberCB 2/05
Copyright © 2002-2008 by C. Bradford Barber. All rights reserved.
Thesa is a trademark of C. Bradford Barber.