Content deleted Content added
No edit summary |
No edit summary |
||
Line 19:
'''occam''' is a [[concurrent programming language]] that builds on the [[communicating sequential processes]] (CSP) process algebra,<ref name="oc21refman">{{cite book | last=INMOS | authorlink=INMOS | url=http://www.wotug.org/occam/documentation/oc21refman.pdf|title=occam 2.1 Reference Manual|publisher=SGS-Thomson Microelectronics Ltd|format=PDF|date=1995-05-12}} INMOS document 72 occ 45 03</ref> and shares many of its features. It is named after [[William of Ockham]] of [[Occam's Razor]] fame.
occam is an [[
==Overview==
In the following examples indentation and formatting are critical for parsing the code: expressions are terminated by the end of the line, lists of expressions need to be on the same level of indentation. This feature, named the [[off-side rule]], is also found in other languages such as [[Haskell (programming language)|Haskell]] and [[Python (programming language)|Python]].
Communication between processes work through named ''[[Channel (programming)|channels]]''. One process outputs data to a channel via '''"!"''' while another one inputs data with '''"?"'''. Input and output can not proceed until the other end is ready to accept or offer data. (In the "not proceeding" case it is often said that the process "[[
keyboard ? c
Line 62:
==Language revisions==
===occam 1===
'''occam 1'''<ref name="oc1refman">{{cite book | last=INMOS | authorlink=INMOS |title=occam Programming Manual|publisher=Prentice-Hall|year=1984|isbn=0-13-629296-8}}</ref> (released 1983) was a preliminary version of the language which borrowed from [[David May (computer scientist)|David May]]'s work on EPL and Tony Hoare's CSP. This supported only the VAR data type, which was an integral type corresponding to the native word length of the target architecture, and arrays of only one dimension.
===occam 2===
'''occam 2'''<ref name="oc2refman">{{cite book | last=Ericsson-Zenith |title=occam 2 Reference Manual|publisher=Prentice-Hall|year=1988|isbn=0-13-629312-3}}</ref> is an extension produced by INMOS Ltd in 1987 that adds [[floating-point]] support, functions, multi-dimensional arrays and more data types such as varying sizes of integers (INT16, INT32) and bytes.
Line 72 ⟶ 70:
===occam 2.1===
'''occam 2.1'''<ref name="oc21refman"/> was the last of the series of occam language developments contributed by INMOS. Defined in 1994, it was influenced by an earlier proposal for an '''occam 3''' language (also referred to as "occam91" during its early development) created by [[Geoff Barrett]] at INMOS in the early 1990s. A revised Reference Manual describing occam 3 was distributed for community comment,<ref name="occam3">{{cite paper|author=[[Geoff Barrett]] and Steven Ericsson-Zenith|title=occam 3 Reference Manual|url=http://www.wotug.org/occam/documentation/oc3refman.pdf|date=1992-03-31|publisher=[[INMOS]]|
format=PDF|
Line 78 ⟶ 75:
occam 2.1 introduced several new features to occam 2, including:
▲* Named data types (DATA TYPE x IS y)
*
▲* Packed Records
▲* Relaxation of some of the type conversion rules
▲* New operators (e.g. BYTESIN)
▲* Channel retyping and channel arrays
▲* Ability to return fixed-length array from function.
For a full list of the changes see Appendix P of the [http://www.wotug.org/occam/documentation/oc21refman.pdf INMOS occam 2.1 Reference Manual].
Line 91 ⟶ 87:
===occam-π===
'''[[occam-π]]'''<ref name="kroc">{{cite web|url=http://www.cs.kent.ac.uk/projects/ofa/kroc/|title=occam-pi: blending the best of CSP and the pi-calculus|author=Fred Barnes and Peter Welch|date=2006-01-14|accessdate=2006-11-24}}</ref> is the common name for the occam variant implemented by later versions of [[KRoC]], the Kent Retargetable occam Compiler. The addition of the symbol "[[Pi (letter)|π]]" (pi) to the occam name is an allusion to the fact that KRoC occam includes several ideas inspired by the [[pi-calculus]]. It contains a significant number of extensions to the occam 2.1 compiler, for example:
*Nested protocols
*Run-time process creation
Line 101 ⟶ 96:
==See also==
*
*
*
*
==
{{
==
*
*
*
*
*
*
==External links==
===General information===
* Information, compilers, editors and utilities at the [http://www.wotug.org/occam/ WoTUG occam pages].
|