-
Notifications
You must be signed in to change notification settings - Fork 10
/
DIGlobalVariableExpression.cs
33 lines (28 loc) · 1.45 KB
/
DIGlobalVariableExpression.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
// -----------------------------------------------------------------------
// <copyright file="DIGlobalVariableExpression.cs" company="Ubiquity.NET Contributors">
// Copyright (c) Ubiquity.NET Contributors. All rights reserved.
// </copyright>
// -----------------------------------------------------------------------
using Ubiquity.NET.Llvm.Interop;
using static Ubiquity.NET.Llvm.Interop.NativeMethods;
namespace Ubiquity.NET.Llvm.DebugInfo
{
/// <summary>Debug Global variable expression</summary>
/// <remarks>This node binds a <see cref="DIGlobalVariable"/> and a <see cref="DIExpression"/></remarks>
/// <seealso href="xref:llvm_langref#diglobalvariable">LLVM DIGlobalVariable</seealso>
/// <seealso href="xref:llvm_langref#diexpression">LLVM DIExpression</seealso>
public class DIGlobalVariableExpression
: MDNode
{
/// <summary>Gets the <see cref="DIGlobalVariable"/> for this node</summary>
public DIGlobalVariable Variable
=> FromHandle<DIGlobalVariable>( LLVMDIGlobalVariableExpressionGetVariable( MetadataHandle ).ThrowIfInvalid( ) )!;
/// <summary>Gets the <see cref="DIExpression"/> for this node</summary>
public DIExpression Expression
=> FromHandle<DIExpression>( LLVMDIGlobalVariableExpressionGetExpression( MetadataHandle ).ThrowIfInvalid( ) )!;
internal DIGlobalVariableExpression( LLVMMetadataRef handle )
: base( handle )
{
}
}
}