DocAda(tm) is a productivity tool of KSCE
|
|
|
|
About DocAda Light:
Preface / Preliminary
/ Help
/ TOC
/ Copyright
DocAda Online at the Ada Home:
Complete RM95
/ Updates
/ News
A context_clause is used to specify the library_items whose names are needed within a compilation unit.
Syntax
context_clause ::= {context_item} context_item ::= with_clause | use_clause with_clause ::= with library_unit_name {, library_unit_name};
Name Resolution Rules
The scope of a with_clause that appears on a library_unit_declaration or library_unit_renaming_declaration consists of the entire declarative region of the declaration, which includes all children and subunits. The scope of a with_clause that appears on a body consists of the body, which includes all subunits.
A library_item is mentioned in a with_clause if it is denoted by a library_unit_name or a prefix in the with_clause.
Outside its own declarative region, the declaration or renaming of a library unit can be visible only within the scope of a with_clause that mentions it. The visibility of the declaration or renaming of a library unit otherwise follows from its placement in the environment.
Legality Rules
If a with_clause of a given compilation_unit mentions a private child of some library unit, then the given compilation_unit shall be either the declaration of a private descendant of that library unit or the body or subunit of a (public or private) descendant of that library unit.
About DocAda Light:
Preface / Preliminary
/ Help
/ TOC
/ Copyright
DocAda Online at the Ada Home:
Complete RM95
/ Updates
/ News
|
|
|
|