diff --git a/xml/System.Runtime.CompilerServices/FixedAddressValueTypeAttribute.xml b/xml/System.Runtime.CompilerServices/FixedAddressValueTypeAttribute.xml index c4b182f9f21..e6ababa04d4 100644 --- a/xml/System.Runtime.CompilerServices/FixedAddressValueTypeAttribute.xml +++ b/xml/System.Runtime.CompilerServices/FixedAddressValueTypeAttribute.xml @@ -54,11 +54,11 @@ attribute to mark static value types as pinned upon creation. + Use the attribute to mark static value type fields as pinned upon creation. This attribute does not apply to primitive value type and enum fields. This attribute is used by the Microsoft Visual C++ compiler. - Static value type fields are created as boxed objects. This means that their address can change as garbage collection is performed. When you apply this attribute to a static value type, its address remains constant during its lifetime. + The storage for static value type fields might be allocated on the GC heap. This means that their address can change as garbage collection is performed. When you apply this attribute to a static value type field, its address remains constant during its lifetime. ## Examples The following example illustrates the use of the attribute to pin a static field in memory. It defines an `Age` structure and initializes two classes that have static fields of type `Age`. The second class applies to pin the field's address. A number of memory allocations are made before and after these two objects are instantiated and the garbage collector is invoked. The output from the example shows that although the address of the first `Age` field has changed after garbage collection, the address of the field to which is applied has not.