xsharp.eu • ILSpy (7.2.1): System.NotSupportedException: Invalid value for FieldDirection
Page 1 of 1

ILSpy (7.2.1): System.NotSupportedException: Invalid value for FieldDirection

Posted: Thu Nov 24, 2022 9:11 am
by HansjoergP
The following code results to an exception in ILSpy using the X# Addin. The problem is the "in" in the parameter declaration ot TestMethod3

Code: Select all

public partial class TestPartial
        public method TestMethod3(col in usual) as logic
            return true
		public method TestMethod2() as logic
            return self:TestMethod3(1)
end class

Code: Select all

System.NotSupportedException: Invalid value for FieldDirection
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.VisitDirectionExpression(DirectionExpression directionExpression)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.WriteCommaSeparatedList(IEnumerable`1 list)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.WriteCommaSeparatedListInParenthesis(IEnumerable`1 list, Boolean spaceWithin)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.VisitInvocationExpression(InvocationExpression invocationExpression)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.VisitReturnStatement(ReturnStatement returnStatement)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.WriteBlock(BlockStatement blockStatement, BraceStyle style)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.WriteMethodBody(BlockStatement body, BraceStyle style)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.VisitMethodDeclaration(MethodDeclaration methodDeclaration)
   bei ILSpy.XSharpLanguage.XSharpOutputVisitor.VisitSyntaxTree(SyntaxTree syntaxTree)
   bei ILSpy.XSharpLanguage.XSharpLanguage.WriteCode(ITextOutput output, DecompilerSettings settings, SyntaxTree syntaxTree, IDecompilerTypeSystem typeSystem)
   bei ILSpy.XSharpLanguage.XSharpLanguage.DecompileMethod(IMethod methoddef, ITextOutput output, DecompilationOptions options)
   bei ICSharpCode.ILSpy.TextView.DecompilerTextView.DecompileNodes(DecompilationContext context, ITextOutput textOutput)
   bei ICSharpCode.ILSpy.TextView.DecompilerTextView.<>c__DisplayClass51_0.<DecompileAsync>b__0()

ILSpy (7.2.1): System.NotSupportedException: Invalid value for FieldDirection

Posted: Thu Nov 24, 2022 12:05 pm
by robert
Hansjoerg,
There is an update here:

https://www.xsharp.eu/itm-downloads/dow ... Plugin.zip

Robert

ILSpy (7.2.1): System.NotSupportedException: Invalid value for FieldDirection

Posted: Thu Nov 24, 2022 12:20 pm
by HansjoergP
Thanks!