[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Reliability", "CA2001:AvoidCallingProblematicMethods", MessageId = "System.Reflection.Assembly.LoadFrom")] // TODO private Dictionary <string, CompiledFile> /*!*/ LoadCompiledCode() { Debug.Assert(_context.RubyOptions.LoadFromDisk); Dictionary <string, CompiledFile> result = new Dictionary <string, CompiledFile>(); Utils.Log("LOADING", "LOADER"); ScriptCode[] codes = ScriptCode.LoadFromAssembly(_context.DomainManager, Assembly.Load(Path.GetFileName(_context.RubyOptions.MainFile)) ); for (int i = 0; i < codes.Length; i++) { string path = codes[i].SourceUnit.Path; string fullPath = Platform.GetFullPath(path); result[fullPath] = new CompiledFile(codes[i]); } return(result); }