Marshaling MDA 

The Marshaling managed debugging assistant (MDA) is activated when the CLR sets up marshaling information for a method parameter or a field of a structure. This MDA does not work for JIT-compiled assemblies.

Effect on the Runtime

This MDA has no effect on the CLR.

Output

The MDA displays the type of the parameter or field in the managed and unmanaged contexts, and the structure or method containing the type. The following is an example of the output for a field:

Marshaling from 'Char' to 'ANSI char'
name="assembly!Namespace.Class::myChar

Configuration

The MDA configuration allows you to filter the reported marshaling information based on the involved field or method names. The following example shows the use of the methodFilter, fieldFilter, and match elements to specify filters. Setting the name attribute to * will match everything.

<mdaConfig>
  <assistants>
    <marshaling>
      <methodFilter>
        <match name="Method1"/>
        <match name="Method2"/>
      </methodFilter>
      <fieldFilter>
        <match name="Field1"/>
        <match name="Field2"/>
       </fieldFilter>
    </marshaling>
  </assistants>
</mdaConfig>

See Also

Reference

MarshalAsAttribute

Concepts

Diagnosing Errors with Managed Debugging Assistants
Interop Marshaling Overview

Other Resources

Interoperability