@@ -245,9 +245,7 @@ export class XtabProvider implements IStatelessNextEditProvider {
245
245
246
246
const areaAroundEditWindowLinesRange = this . computeAreaAroundEditWindowLinesRange ( currentFileContentLines , cursorLineIdx ) ;
247
247
248
- const maxMergeConflictLines = this . configService . getExperimentBasedConfig ( ConfigKey . Internal . InlineEditsXtabMaxMergeConflictLines , this . expService ) ;
249
-
250
- const editWindowLinesRange = this . computeEditWindowLinesRange ( currentFileContentLines , cursorLineIdx , request , maxMergeConflictLines , retryState ) ;
248
+ const editWindowLinesRange = this . computeEditWindowLinesRange ( currentFileContentLines , cursorLineIdx , request , retryState ) ;
251
249
252
250
const cursorOriginalLinesOffset = Math . max ( 0 , cursorLineIdx - editWindowLinesRange . start ) ;
253
251
const editWindowLastLineLength = activeDocument . documentAfterEdits . getTransformer ( ) . getLineLength ( editWindowLinesRange . endExclusive ) ;
@@ -786,7 +784,7 @@ export class XtabProvider implements IStatelessNextEditProvider {
786
784
return new OffsetRange ( areaAroundStart , areaAroundEndExcl ) ;
787
785
}
788
786
789
- private computeEditWindowLinesRange ( currentDocLines : string [ ] , cursorLine : number , request : StatelessNextEditRequest , maxMergeConflictLines : number | undefined , retryState : RetryState ) : OffsetRange {
787
+ private computeEditWindowLinesRange ( currentDocLines : string [ ] , cursorLine : number , request : StatelessNextEditRequest , retryState : RetryState ) : OffsetRange {
790
788
let nLinesAbove : number ;
791
789
{
792
790
const useVaryingLinesAbove = this . configService . getExperimentBasedConfig ( ConfigKey . Internal . InlineEditsXtabProviderUseVaryingLinesAbove , this . expService ) ;
@@ -833,6 +831,7 @@ export class XtabProvider implements IStatelessNextEditProvider {
833
831
let codeToEditStart = Math . max ( 0 , cursorLine - nLinesAbove ) ;
834
832
let codeToEditEndExcl = Math . min ( currentDocLines . length , cursorLine + nLinesBelow + 1 ) ;
835
833
834
+ const maxMergeConflictLines = this . configService . getExperimentBasedConfig ( ConfigKey . Internal . InlineEditsXtabMaxMergeConflictLines , this . expService ) ;
836
835
if ( maxMergeConflictLines ) {
837
836
const tentativeEditWindow = new OffsetRange ( codeToEditStart , codeToEditEndExcl ) ;
838
837
const mergeConflictRange = findMergeConflictMarkersRange ( currentDocLines , tentativeEditWindow , maxMergeConflictLines ) ;
0 commit comments