Show
Ignore:
Timestamp:
06/18/09 20:21:35 (5 months ago)
Author:
EricAllen
Message:

Added API linker and associated hooks (work in progress).
Added some testing of cache cleaning.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/ProjectFortress/src/com/sun/fortress/compiler/StaticChecker.java

    r3865 r3876  
    4545import com.sun.fortress.nodes.Type; 
    4646import com.sun.fortress.repository.FortressRepository; 
     47import com.sun.fortress.scala_src.linker.ApiLinker; 
     48import com.sun.fortress.scala_src.linker.CompoundApiChecker; 
    4749import com.sun.fortress.scala_src.typechecker.CoercionTest; 
    4850import com.sun.fortress.scala_src.typechecker.ExportChecker; 
     
    290292                                             GlobalEnvironment env, 
    291293                                             FortressRepository repository) { 
     294 
     295        // Check if this is a compound API, and, if so, link it into a single API. 
     296        List<StaticError> errors = new CompoundApiChecker(env, repository).check(api); 
     297        if (! errors.isEmpty()) {  
     298            return new TypeCheckerResult(api.ast(), errors); 
     299        } 
     300        api = new ApiLinker(env, repository).link(api); 
     301 
    292302        // Check type hierarchy to ensure acyclicity. 
    293         List<StaticError> errors = new TypeHierarchyChecker(api, env, repository).checkHierarchy(); 
     303        errors = new TypeHierarchyChecker(api, env, repository).checkHierarchy(); 
    294304        if (! errors.isEmpty()) { 
    295305            return new TypeCheckerResult(api.ast(), errors);