Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
SequencePoint.cs
Go to the documentation of this file.
1
using
System.Diagnostics
;
2
using
System.Diagnostics.CodeAnalysis
;
3
using
System.Reflection.Internal
;
4
5
namespace
System.Reflection.Metadata
;
6
7
[DebuggerDisplay(
"{GetDebuggerDisplay(),nq}"
)]
8
public
readonly
struct
SequencePoint
:
IEquatable
<SequencePoint>
9
{
10
public
const
int
HiddenLine
= 16707566;
11
12
public
DocumentHandle
Document
{
get
; }
13
14
public
int
Offset
{
get
; }
15
16
public
int
StartLine
{
get
; }
17
18
public
int
EndLine
{
get
; }
19
20
public
int
StartColumn
{
get
; }
21
22
public
int
EndColumn
{
get
; }
23
24
public
bool
IsHidden
=>
StartLine
== 16707566;
25
26
internal
SequencePoint
(
DocumentHandle
document,
int
offset
)
27
{
28
Document
= document;
29
Offset
=
offset
;
30
StartLine
= 16707566;
31
StartColumn
= 0;
32
EndLine
= 16707566;
33
EndColumn
= 0;
34
}
35
36
internal
SequencePoint
(
DocumentHandle
document,
int
offset
,
int
startLine, ushort startColumn,
int
endLine, ushort endColumn)
37
{
38
Document
= document;
39
Offset
=
offset
;
40
StartLine
= startLine;
41
StartColumn
= startColumn;
42
EndLine
= endLine;
43
EndColumn
= endColumn;
44
}
45
46
public
override
int
GetHashCode
()
47
{
48
return
Hash
.
Combine
(
Document
.RowId,
Hash
.
Combine
(
Offset
,
Hash
.
Combine
(
StartLine
,
Hash
.
Combine
(
StartColumn
,
Hash
.
Combine
(
EndLine
,
EndColumn
)))));
49
}
50
51
public
override
bool
Equals
([NotNullWhen(
true
)]
object
?
obj
)
52
{
53
if
(
obj
is
SequencePoint
other
)
54
{
55
return
Equals
(
other
);
56
}
57
return
false
;
58
}
59
60
public
bool
Equals
(
SequencePoint
other
)
61
{
62
if
(
Document
==
other
.
Document
&&
Offset
==
other
.Offset &&
StartLine
==
other
.StartLine &&
StartColumn
==
other
.StartColumn &&
EndLine
==
other
.EndLine)
63
{
64
return
EndColumn
==
other
.EndColumn;
65
}
66
return
false
;
67
}
68
69
private
string
GetDebuggerDisplay
()
70
{
71
if
(!
IsHidden
)
72
{
73
return
$
"{Offset}: ({StartLine}, {StartColumn}) - ({EndLine}, {EndColumn})"
;
74
}
75
return
"<hidden>"
;
76
}
77
}
System.Reflection.Internal.Hash.Combine
static int Combine(int newKey, int currentKey)
Definition
Hash.cs:11
System.Reflection.Internal.Hash
Definition
Hash.cs:6
System.IEquatable
Definition
IEquatable.cs:4
System.Diagnostics.CodeAnalysis
Definition
AllowNullAttribute.cs:1
System.Diagnostics
Definition
AggregationManager.cs:6
System.Reflection.Internal
Definition
AbstractMemoryBlock.cs:4
System.Reflection.Metadata
Definition
AssemblyExtensions.cs:4
System.ExceptionArgument.other
@ other
System.ExceptionArgument.offset
@ offset
System.ExceptionArgument.obj
@ obj
System.Reflection.Metadata.DocumentHandle
Definition
DocumentHandle.cs:4
System.Reflection.Metadata.Document.Document
Document(MetadataReader reader, DocumentHandle handle)
Definition
Document.cs:19
System.Reflection.Metadata.Document
Definition
Document.cs:4
System.Reflection.Metadata.SequencePoint.EndColumn
int EndColumn
Definition
SequencePoint.cs:22
System.Reflection.Metadata.SequencePoint.IsHidden
bool IsHidden
Definition
SequencePoint.cs:24
System.Reflection.Metadata.SequencePoint.SequencePoint
SequencePoint(DocumentHandle document, int offset, int startLine, ushort startColumn, int endLine, ushort endColumn)
Definition
SequencePoint.cs:36
System.Reflection.Metadata.SequencePoint.StartColumn
int StartColumn
Definition
SequencePoint.cs:20
System.Reflection.Metadata.SequencePoint.SequencePoint
SequencePoint(DocumentHandle document, int offset)
Definition
SequencePoint.cs:26
System.Reflection.Metadata.SequencePoint.GetHashCode
override int GetHashCode()
Definition
SequencePoint.cs:46
System.Reflection.Metadata.SequencePoint.EndLine
int EndLine
Definition
SequencePoint.cs:18
System.Reflection.Metadata.SequencePoint.Equals
override bool Equals([NotNullWhen(true)] object? obj)
Definition
SequencePoint.cs:51
System.Reflection.Metadata.SequencePoint.StartLine
int StartLine
Definition
SequencePoint.cs:16
System.Reflection.Metadata.SequencePoint.Offset
int Offset
Definition
SequencePoint.cs:14
System.Reflection.Metadata.SequencePoint.GetDebuggerDisplay
string GetDebuggerDisplay()
Definition
SequencePoint.cs:69
System.Reflection.Metadata.SequencePoint.HiddenLine
const int HiddenLine
Definition
SequencePoint.cs:10
System.Reflection.Metadata.SequencePoint.Equals
bool Equals(SequencePoint other)
Definition
SequencePoint.cs:60
System.Reflection.Metadata.SequencePoint
Definition
SequencePoint.cs:9
source
System.Reflection.Metadata
System.Reflection.Metadata
SequencePoint.cs
Generated by
1.10.0