107 references to Position
Microsoft.CodeAnalysis.CSharp (107)
Parser\Blender.cs (1)
69
_newPosition = lexer.TextWindow.
Position
;
Parser\Blender.Reader.cs (1)
165
if (_lexer.TextWindow.
Position
!= _newPosition)
Parser\DirectiveParser.cs (1)
36
var hashPosition = lexer.TextWindow.
Position
;
Parser\LanguageParser.cs (1)
220
return CreateForGlobalFailure(lexer.TextWindow.
Position
, createEmptyNodeFunc(this));
Parser\Lexer.cs (33)
306
this.LexSyntaxTrivia(isFollowingToken: TextWindow.
Position
> 0, isTrailing: false, triviaList: ref _leadingTriviaCache);
325
this.LexSyntaxTrivia(isFollowingToken: TextWindow.
Position
> 0, isTrailing: false, triviaList: ref _leadingTriviaCache);
445
int startingPosition = TextWindow.
Position
;
464
var atDotPosition = this.TextWindow.
Position
;
637
this.AddError(TextWindow.
Position
+ 1, width: 1, ErrorCode.ERR_ExpectedVerbatimLiteral);
807
int start = TextWindow.
Position
;
813
return start < TextWindow.
Position
;
862
int start = TextWindow.
Position
;
1040
this.AddError(MakeError(start, TextWindow.
Position
- start, ErrorCode.ERR_InvalidNumber));
1065
info.DecimalValue = this.GetValueDecimal(valueText, start, TextWindow.
Position
);
1443
int start = TextWindow.
Position
;
1451
var atCount = TextWindow.
Position
- start;
1658
int start = TextWindow.
Position
;
1677
int beforeConsumed = TextWindow.
Position
;
1712
if (!isEscaped && (TextWindow.
Position
== beforeConsumed + 1) &&
1974
this.AddError(TextWindow.
Position
, width: 1, ErrorCode.ERR_UnexpectedCharacter, '@');
2005
var savePosition = TextWindow.
Position
;
2011
var text = TextWindow.Text.GetSubText(TextSpan.FromBounds(savePosition, TextWindow.
Position
));
2085
var position = TextWindow.
Position
;
2119
this.AddError(TextWindow.
Position
, s_conflictMarkerLength,
2443
int lastLineStart = TextWindow.
Position
;
2463
if (lastLineStart < TextWindow.
Position
&& !allWhitespace)
2473
lastLineStart = TextWindow.
Position
;
2722
var pos = TextWindow.
Position
;
3313
int start = TextWindow.
Position
;
3337
info.Text = TextWindow.GetText(start, TextWindow.
Position
- start, intern: true);
3611
int beforeConsumed = TextWindow.
Position
;
3687
Debug.Assert(TextWindow.
Position
> beforeConsumed, "First character or entity has been consumed.");
3910
int pos = TextWindow.
Position
;
4369
var start = TextWindow.
Position
;
4597
int position = TextWindow.
Position
;
4636
int start = TextWindow.
Position
;
4843
TextWindow.
Position
- start,
Parser\Lexer_RawStringLiteral.cs (16)
19
var start = TextWindow.
Position
;
23
return TextWindow.
Position
- start;
91
var valueLength = TextWindow.
Position
- afterStartDelimiter;
137
this.AddError(TextWindow.
Position
, width: TextWindow.GetNewLineWidth(), ErrorCode.ERR_UnterminatedRawString);
142
this.AddError(TextWindow.
Position
, width: 0, ErrorCode.ERR_UnterminatedRawString);
153
var beforeEndDelimiter = TextWindow.
Position
;
166
position: TextWindow.
Position
- excessQuoteCount,
196
var afterStartDelimiter = TextWindow.
Position
;
211
position: TextWindow.
Position
- startingQuoteCount,
222
var tokenEnd = TextWindow.
Position
;
269
position: TextWindow.
Position
- excessQuoteCount,
285
this.AddError(TextWindow.
Position
, width: 0, ErrorCode.ERR_UnterminatedRawString);
299
position: TextWindow.
Position
- currentQuoteCount,
329
var lineStartPosition = TextWindow.
Position
;
352
width: TextWindow.
Position
- lineStartPosition,
360
width: TextWindow.
Position
- lineStartPosition,
Parser\Lexer_StringLiteral.cs (47)
131
var start = TextWindow.
Position
;
157
this.AddError(start, TextWindow.
Position
- start, info.Code, info.Arguments);
185
this.AddError(start, TextWindow.
Position
- start, ErrorCode.ERR_IllegalEscape);
197
var start = TextWindow.
Position
;
203
if (TextWindow.
Position
- start >= 2)
205
this.AddError(start, width: TextWindow.
Position
- start, ErrorCode.ERR_IllegalAtSequence);
381
var start = _lexer.TextWindow.
Position
;
383
Debug.Assert(_lexer.TextWindow.
Position
!= start);
385
openQuoteRange = start.._lexer.TextWindow.
Position
;
391
closeQuoteRange = _lexer.TextWindow.
Position
.._lexer.TextWindow.
Position
;
415
var start = window.
Position
;
464
TrySetError(_lexer.MakeError(start, window.
Position
- start, ErrorCode.ERR_StringMustStartWithQuoteCharacter));
475
TrySetError(_lexer.MakeError(start, window.
Position
- start, ErrorCode.ERR_IllegalAtSequence));
481
TrySetError(_lexer.MakeError(window.
Position
- startingQuoteCount, startingQuoteCount, ErrorCode.ERR_NotEnoughQuotesForRawString));
486
var afterQuotePosition = window.
Position
;
510
var closeQuotePosition = _lexer.TextWindow.
Position
;
524
closeQuoteRange = closeQuotePosition.._lexer.TextWindow.
Position
;
538
IsAtEnd(allowNewline: true) ? _lexer.TextWindow.
Position
- 1 : _lexer.TextWindow.
Position
,
561
IsAtEnd(allowNewline: true) ? _lexer.TextWindow.
Position
- 1 : _lexer.TextWindow.
Position
,
579
position: _lexer.TextWindow.
Position
- excessQuoteCount,
596
_lexer.TextWindow.
Position
- 1, width: 1, ErrorCode.ERR_UnterminatedRawString));
607
position: _lexer.TextWindow.
Position
- closeQuoteCount,
626
position: _lexer.TextWindow.
Position
- excessQuoteCount,
678
var escapeStart = _lexer.TextWindow.
Position
;
682
TrySetError(_lexer.MakeError(escapeStart, _lexer.TextWindow.
Position
- escapeStart, ErrorCode.ERR_EscapedCurly, ch));
705
var beforeQuotesPosition = _lexer.TextWindow.
Position
;
713
_lexer.TextWindow.
Position
- closeQuoteCount, closeQuoteCount, ErrorCode.ERR_RawStringMustContainContent));
728
var startPosition = _lexer.TextWindow.
Position
;
783
var beforeQuotePosition = _lexer.TextWindow.
Position
;
803
var pos = _lexer.TextWindow.
Position
;
829
position: _lexer.TextWindow.
Position
- closeBraceCount,
857
int openBracePosition = _lexer.TextWindow.
Position
;
860
int closeBracePosition = _lexer.TextWindow.
Position
;
873
new Range(closeBracePosition, _lexer.TextWindow.
Position
)));
886
var beforeOpenBracesPosition = _lexer.TextWindow.
Position
;
894
var afterOpenBracePosition = _lexer.TextWindow.
Position
;
908
var beforeCloseBracePosition = _lexer.TextWindow.
Position
;
937
beforeCloseBracePosition.._lexer.TextWindow.
Position
));
961
var pos = _lexer.TextWindow.
Position
;
982
_lexer.TextWindow.
Position
, 1, ErrorCode.ERR_UnexpectedCharacter, ch));
1022
TrySetError(_lexer.MakeError(_lexer.TextWindow.
Position
, 1, ErrorCode.ERR_SyntaxError, endingChar.ToString()));
1040
colonRange = new Range(_lexer.TextWindow.
Position
, _lexer.TextWindow.
Position
+ 1);
1054
TrySetError(_lexer.MakeError(_lexer.TextWindow.
Position
, 1, ErrorCode.ERR_SyntaxError, endingChar.ToString()));
Parser\SlidingTextWindow.cs (3)
201
if (this.
Position
>= _textEnd)
253
return _offset >= _characterWindowCount &&
Position
>= _textEnd;
358
int position = this.
Position
;
Syntax\SyntaxTokenParser.cs (4)
54
var startingPosition = _lexer.TextWindow.
Position
;
68
var startingPosition = _lexer.TextWindow.
Position
;
83
var startingPosition = _lexer.TextWindow.
Position
;
96
if (position < _lexer.TextWindow.
Position
)