Type Binding
When is a Variable associated with a data type?
Categories of Type Binding
- Static Binding: Type of variable determined from
type specification
- Application: Used in Compiled Languages
- Advantage:
- Reliable: Type compatibility is checked
- Efficient: Type compatibility is checked before run-time
- Dynamic Binding: Type of variable inferred from the first assignment
- Advantage:
- Flexibile: Programs can be written to be type-polymorphic
- Disadvantage:
- Application: Used in Interpreted Languages
- Type binding time hidden by interpretation time