[Contents]
[Prev] [Next] [Limbo Basics] [Limbo Programming] [Language Definition]

Type Equality and Compatibility

In an assignment and in passing an actual argument to a function, the types of the target and the expression being assigned or passed must be equal (with noted exceptions, such as assignment of nil to a reference type). When a function is defined, its type must be equal to the type of a function with the same name if one is in scope. Type equality is determined as follows.

		A: adt { x: ref B };

		B: adt { x: ref A };


 the types A and B are equal.



[Contents]
[Prev] [Next] [Limbo Basics] [Limbo Programming] [Language Definition]

Copyright © 1998, Lucent Technologies, Inc. All rights reserved.