12345678910111213141516171819202122232425 |
- def otherwise=true:
- proc xxtoy(chan in, out, value x, y)=
- var c:
- seq
- c:= not EOF
- while c<>EOF
- seq
- in ? c
- if
- c=x
- seq
- in ? c
- if
- c=x
- out ! y
- otherwise
- out ! x; c
- otherwise
- out ! c
- :
- chan link:
- par
- xxtoy(input, link, 'a', 'b')
- xxtoy(link, output, 'b', 'c')
|