public override Expression ResolveImport( IImportResolver resolver, IPlatform platform, AddressContext ctx) { return(resolver.ResolveImport(ModuleName, ImportName, platform)); }
public override Expression ResolveImport(IImportResolver importResolver, IPlatform platform, AddressContext ctx) { var imp = importResolver.ResolveImport(ModuleName, Ordinal, platform); if (imp != null) { return(imp); } ctx.Warn("Unable to resolve imported reference {0}.", this); return(null); }
public override Expression ResolveImport( IImportResolver resolver, IPlatform platform, AddressContext ctx) { var global = resolver.ResolveImport(ModuleName, ImportName, platform); if (global != null) { return(global); } var t = platform.DataTypeFromImportName(ImportName); //$REVIEW: the way imported symbols are resolved as // globals or functions needs a revisit. if (t != null && !(t.Item2 is FunctionType)) { return(new Identifier(t.Item1, t.Item2, new MemoryStorage())); } else { return(null); } }