Content deleted Content added
No edit summary |
No edit summary |
||
Line 6:
TXL is most commonly used in software analysis and reengineering tasks such as [[reengineering (software)|design recovery]], and in rapid prototyping of new [[programming languages]] and dialects.
===Examples===
====Factorial====
define program
[number]
end define
function main
replace [program]
p [number]
by
p [fact][fact0]
end function
function fact
replace [number]
n [number]
construct nMinusOne [number]
n [- 1]
where
n [> 1]
construct factMinusOne [number]
nMinusOne [fact]
by
n [* factMinusOne]
end function
function fact0
replace [number]
0
by
1
end function
== References ==
|