Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
language:namespaces [2020/05/01 16:48]
rajit [Importing namespaces]
language:namespaces [2020/05/01 16:49]
rajit [Importing namespaces]
Line 123: Line 123:
 It assumes that the file ''_all_.act'' in the directory It assumes that the file ''_all_.act'' in the directory
 ''processor/lib'' contains all the definitions corresponding to the ''processor/lib'' contains all the definitions corresponding to the
-''processor::lib'' namespace.+''processor::lib'' namespace. More generally, an import statement 
 + 
 +<code> 
 +import foo; 
 +</code> 
 + 
 +would do the following: 
 +  * Look for ''foo/_all_.act'' using the search paths specified earlier; 
 +  * If unsuccessful, then look for ''foo.act'' 
 +  * If unsuccessful, report an error 
 + 
 +After the import, the specified namespace is checked to see if it exists. If not, an error will be reported. 
  
 ===== Opening namespaces ===== ===== Opening namespaces =====