PostSharp 4.3 / / Post­Sharp Documentation / API Reference / Post­Sharp Namespace / Post Class / Post Methods / Post.​Get­Value(T) Method
Post.GetValue<T> Method
When used to retrieve the value of a field, forces the compiler to retrieve a copy of the field value instead of an address to this field. This allows to call instance methods of value-type fields without loading the field address.

Namespace: PostSharp
Assembly: PostSharp (in PostSharp.dll) Version: 4.3.48.0 (4.3.48.0)
Syntax
C#
public static T GetValue<T>(
	T value
)
where T : struct, new()

Parameters

value
Type: T
Value.

Type Parameters

T
Type of the value to retrieve (this type parameter can generally be omitted).

Return Value

Type: T
value, exactly.
See Also