@@ -361,9 +361,9 @@ namespace ts {
361
361
function getWatchFactoryWith < X , Y = undefined > ( watchLogLevel : WatchLogLevel , log : ( s : string ) => void , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ,
362
362
watchFile : ( host : WatchFileHost , file : string , callback : FileWatcherCallback , watchPriority : PollingInterval ) => FileWatcher ,
363
363
watchDirectory : ( host : WatchDirectoryHost , directory : string , callback : DirectoryWatcherCallback , flags : WatchDirectoryFlags ) => FileWatcher ) : WatchFactory < X , Y > {
364
- const createFileWatcher : CreateFileWatcher < WatchFileHost , PollingInterval , FileWatcherEventKind , undefined , X , Y > = getCreateFileWatcher ( watchLogLevel , watchFile ) ;
364
+ const createFileWatcher : CreateFileWatcher < WatchFileHost , PollingInterval , FileWatcherEventKind , never , X , Y > = getCreateFileWatcher ( watchLogLevel , watchFile ) ;
365
365
const createFilePathWatcher : CreateFileWatcher < WatchFileHost , PollingInterval , FileWatcherEventKind , Path , X , Y > = watchLogLevel === WatchLogLevel . None ? watchFilePath : createFileWatcher ;
366
- const createDirectoryWatcher : CreateFileWatcher < WatchDirectoryHost , WatchDirectoryFlags , undefined , undefined , X , Y > = getCreateFileWatcher ( watchLogLevel , watchDirectory ) ;
366
+ const createDirectoryWatcher : CreateFileWatcher < WatchDirectoryHost , WatchDirectoryFlags , undefined , never , X , Y > = getCreateFileWatcher ( watchLogLevel , watchDirectory ) ;
367
367
return {
368
368
watchFile : ( host , file , callback , pollingInterval , detailInfo1 , detailInfo2 ) =>
369
369
createFileWatcher ( host , file , callback , pollingInterval , /*passThrough*/ undefined , detailInfo1 , detailInfo2 , watchFile , log , "FileWatcher" , getDetailWatchInfo ) ,
@@ -402,7 +402,7 @@ namespace ts {
402
402
}
403
403
}
404
404
405
- function createFileWatcherWithLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , undefined > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
405
+ function createFileWatcherWithLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , V > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
406
406
log ( `${ watchCaption } :: Added:: ${ getWatchInfo ( file , flags , detailInfo1 , detailInfo2 , getDetailWatchInfo ) } ` ) ;
407
407
const watcher = createFileWatcherWithTriggerLogging ( host , file , cb , flags , passThrough , detailInfo1 , detailInfo2 , addWatch , log , watchCaption , getDetailWatchInfo ) ;
408
408
return {
@@ -413,7 +413,7 @@ namespace ts {
413
413
} ;
414
414
}
415
415
416
- function createDirectoryWatcherWithLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , undefined > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
416
+ function createDirectoryWatcherWithLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , V > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
417
417
const watchInfo = `${ watchCaption } :: Added:: ${ getWatchInfo ( file , flags , detailInfo1 , detailInfo2 , getDetailWatchInfo ) } ` ;
418
418
log ( watchInfo ) ;
419
419
const start = timestamp ( ) ;
@@ -432,7 +432,7 @@ namespace ts {
432
432
} ;
433
433
}
434
434
435
- function createFileWatcherWithTriggerLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , undefined > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
435
+ function createFileWatcherWithTriggerLogging < H , T , U , V , X , Y > ( host : H , file : string , cb : WatchCallback < U , V > , flags : T , passThrough : V | undefined , detailInfo1 : X | undefined , detailInfo2 : Y | undefined , addWatch : AddWatch < H , T , U , V > , log : ( s : string ) => void , watchCaption : string , getDetailWatchInfo : GetDetailWatchInfo < X , Y > | undefined ) : FileWatcher {
436
436
return addWatch ( host , file , ( fileName , cbOptional ) => {
437
437
const triggerredInfo = `${ watchCaption } :: Triggered with ${ fileName } ${ cbOptional !== undefined ? cbOptional : "" } :: ${ getWatchInfo ( file , flags , detailInfo1 , detailInfo2 , getDetailWatchInfo ) } ` ;
438
438
log ( triggerredInfo ) ;
0 commit comments