-
Notifications
You must be signed in to change notification settings - Fork 106
Cann't open .fs files in MonoDevelop 2.4.2 #18
Comments
This is because you have the Mono-released F# compiler in Mono 2.10 You have to adjust the explicit reference to this DLL in ./src/Services/FSharpCompiler.fs, replace the public key tokens on these lines: ./src/Services/FSharpCompiler.fs: static let asm = Assembly.Load("FSharp.Compiler, Version=2.0.0.0, Culture=neutral, PublicKeyToken=a19089b1c74d0809") ./src/Services/FSharpCompiler.fs: static let asm = Assembly.Load("FSharp.Compiler.Server.Shared, Version=2.0.0.0, Culture=neutral, PublicKeyToken=a19089b1c74d0809") Am working on getting this fix added to the release |
Look as fixed. Now when I try to open .fs files I get another exception: System.TypeLoadException: Could not load type 'System.Collections.IStructuralEquatable' from assembly 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. What about bug with System.Lazy when I try to do any doings with projects? System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.TypeLoadException: Could not load type 'System.Lazy |
Looks like another issue with Mono 2.10. Can you use Mono 2.8? |
btw what did you change those lines in ./src/Services/FSharpCompiler.fs to? |
I change PublicKeyToken=a19089b1c74d0809 into b03f5f7f11d50a3a |
Very old issue, closing this out |
When I try to open .fs files from F# projects I get exception.
ERROR [2011-05-12 12:28:21Z]: System.TypeInitializationException: An exception was thrown by the type initializer for FSharp.MonoDevelop.LanguageService ---> System.TypeInitializationException: An exception was thrown by the type initializer for <StartupCode$FSharpBinding>.$LanguageService ---> System.TypeInitializationException: An exception was thrown by the type initializer for FSharpCompiler ---> System.TypeInitializationException: An exception was thrown by the type initializer for <StartupCode$FSharpBinding>.$FSharpCompiler ---> System.IO.FileNotFoundException: Could not load file or assembly 'FSharp.Compiler, Version=2.0.0.0, Culture=neutral, PublicKeyToken=a19089b1c74d0809' or one of its dependencies. The system cannot find the file specified.
File name: 'FSharp.Compiler, Version=2.0.0.0, Culture=neutral, PublicKeyToken=a19089b1c74d0809'
at System.AppDomain.Load (System.String assemblyString, System.Security.Policy.Evidence assemblySecurity, Boolean refonly) [0x00000] in :0
at System.AppDomain.Load (System.String assemblyString) [0x00000] in :0
at (wrapper remoting-invoke-with-check) System.AppDomain:Load (string)
at System.Reflection.Assembly.Load (System.String assemblyString) [0x00000] in :0
at <StartupCode$FSharpBinding>.$FSharpCompiler..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at Microsoft.FSharp.Compiler.Reflection+FSharpCompiler..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at Microsoft.FSharp.Compiler.SourceCodeServices+InteractiveChecker.Create (Microsoft.FSharp.Core.FSharpFunc`2 dirty) [0x00000] in :0
at FSharp.MonoDevelop.LanguageService..ctor () [0x00000] in :0
at <StartupCode$FSharpBinding>.$LanguageService..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at FSharp.MonoDevelop.LanguageService..cctor () [0x00000] in :0
--- End of inner exception stack trace ---
at FSharp.MonoDevelop.FSharpParser.Parse (MonoDevelop.Projects.Dom.Parser.ProjectDom dom, System.String fileName, System.String fileContent) [0x00000] in :0
at MonoDevelop.Projects.Dom.Parser.ProjectDomService.DoParseFile (MonoDevelop.Projects.Dom.Parser.ProjectDom dom, System.String fileName, System.String fileContent) [0x00000] in :0
at MonoDevelop.Projects.Dom.Parser.ProjectDomService.ParseFile (MonoDevelop.Projects.Dom.Parser.ProjectDom dom, System.String fileName, MonoDevelop.Projects.Dom.Parser.ContentDelegate getContent) [0x00000] in :0
at MonoDevelop.Projects.Dom.Parser.ProjectDomService.ParseFile (MonoDevelop.Projects.Dom.Parser.ProjectDom dom, System.String fileName) [0x00000] in :0
at MonoDevelop.Projects.Dom.Parser.ProjectDomService.GetParsedDocument (MonoDevelop.Projects.Dom.Parser.ProjectDom dom, System.String fileName) [0x00000] in :0
at MonoDevelop.SourceEditor.SourceEditorView.Load (System.String fileName, System.String encoding) [0x00000] in :0
at MonoDevelop.SourceEditor.SourceEditorView.Load (System.String fileName) [0x00000] in :0
at MonoDevelop.Ide.Gui.LoadFileWrapper.Invoke (System.String fileName) [0x00000] in :0
but FSharp.Compiler exist:
/usr/lib/mono/2.0/FSharp.Compiler.dll -> ../gac/FSharp.Compiler/2.0.0.0__b03f5f7f11d50a3a/FSharp.Compiler.dll
/usr/lib/mono/4.0/FSharp.Compiler.dll -> ../gac/FSharp.Compiler/4.0.0.0__b03f5f7f11d50a3a/FSharp.Compiler.dll
The text was updated successfully, but these errors were encountered: