* Skip generated wrappers when trying to step.
* Changing to use System.Diagnostics.DebuggerNonUserCode
public const string JSImportAttribute = "System.Runtime.InteropServices.JavaScript.JSImportAttribute";
public const string JSExportAttribute = "System.Runtime.InteropServices.JavaScript.JSExportAttribute";
public const string JavaScriptMarshal = "System.Runtime.InteropServices.JavaScript.JavaScriptMarshal";
+ public const string DebuggerNonUserCodeAttribute = "System.Diagnostics.DebuggerNonUserCode";
public const string JSFunctionSignatureGlobal = "global::System.Runtime.InteropServices.JavaScript.JSFunctionBinding";
public const string JSMarshalerArgumentGlobal = "global::System.Runtime.InteropServices.JavaScript.JSMarshalerArgument";
MemberDeclarationSyntax wrappperMethod = MethodDeclaration(PredefinedType(Token(SyntaxKind.VoidKeyword)), Identifier(wrapperName))
.WithModifiers(TokenList(new[] { Token(SyntaxKind.InternalKeyword), Token(SyntaxKind.StaticKeyword), Token(SyntaxKind.UnsafeKeyword) }))
+ .WithAttributeLists(SingletonList(AttributeList(SingletonSeparatedList(
+ Attribute(IdentifierName(Constants.DebuggerNonUserCodeAttribute))))))
.WithParameterList(ParameterList(SingletonSeparatedList(
Parameter(Identifier("__arguments_buffer")).WithType(PointerType(ParseTypeName(Constants.JSMarshalerArgumentGlobal))))))
.WithBody(wrapperStatements);
// Create stub function
MethodDeclarationSyntax stubMethod = MethodDeclaration(stub.SignatureContext.StubReturnType, userDeclaredMethod.Identifier)
.AddAttributeLists(stub.SignatureContext.AdditionalAttributes.ToArray())
+ .WithAttributeLists(SingletonList(AttributeList(SingletonSeparatedList(
+ Attribute(IdentifierName(Constants.DebuggerNonUserCodeAttribute))))))
.WithModifiers(StripTriviaFromModifiers(userDeclaredMethod.Modifiers))
.WithParameterList(ParameterList(SeparatedList(stub.SignatureContext.StubParameters)))
.WithBody(stubCode);