## Abstract

A notation based on pipes in the unix™ operating system is proposed for combining functions in a linear order. Examples suggest that semantic rules using pipes (i.e. the notation) are easy to read and understand, even for readers with little knowledge of semantics. The readability is a consequence of the operational intuition associated with pipes. The operational view is that each function is handed a sequence of values. Generally the sequence is treated as a stack; a function pops zero or more arguments off the stack, pushes zero or more results onto the stack, and passes the stack to the next function. The new idea is that a function may skip over some number of values before picking up its arguments. This approach is suited to expressing the composition of operations on machine states in a programming language. Pipes mesh smoothly with other metalanguage concepts, e.g., lambda abstraction. The bulk of the paper explores mathematical properties of pipes. In order for pipes to fit into lambda expressions, the arguments of the constructed function has to be well defined. Operationally speaking, we have to keep track of the elements in the stack. Pipes allow continuation semantics to be written with direct operators: instead of the operator having to worry about its continuation, the second function in a pipe is essentially a continuation of the first. A connection is established between functions connected by pipes and more traditional continuation semantics. This connection is made possible by a combinator do that constructs continuation versions of direct operators, e.g., continuation style operators from the literature for arithmetic, assigning to an identifier, and determining the value of an identifier, can be constructed from their direct counterparts using do. An example of the translation of a pipe based semantic rule for let expressions into a continuation based semantic rule is given.

Original language | English (US) |
---|---|

Title of host publication | Automata, Languages and Programming - 9th Colloquium |

Editors | Mogens Nielsen, Erik Meineche Schmidt |

Publisher | Springer-Verlag |

Pages | 429-441 |

Number of pages | 13 |

ISBN (Print) | 9783540115762 |

DOIs | |

State | Published - 1982 |

Externally published | Yes |

Event | 9th International Colloquium on Automata, Languages and Programming, ICALP 1982 - Aarhus, Denmark Duration: Jul 12 1982 → Jul 16 1982 |

### Publication series

Name | Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics) |
---|---|

Volume | 140 LNCS |

ISSN (Print) | 0302-9743 |

ISSN (Electronic) | 1611-3349 |

### Other

Other | 9th International Colloquium on Automata, Languages and Programming, ICALP 1982 |
---|---|

Country/Territory | Denmark |

City | Aarhus |

Period | 7/12/82 → 7/16/82 |

## ASJC Scopus subject areas

- Theoretical Computer Science
- Computer Science(all)