@@ -7,6 +7,7 @@ const ReferenceTrackerREAD: unique symbol = eslintUtils.ReferenceTracker.READ;
7
7
const ReferenceTrackerCALL : unique symbol = eslintUtils . ReferenceTracker . CALL ;
8
8
const ReferenceTrackerCONSTRUCT : unique symbol =
9
9
eslintUtils . ReferenceTracker . CONSTRUCT ;
10
+ const ReferenceTrackerESM : unique symbol = eslintUtils . ReferenceTracker . ESM ;
10
11
11
12
interface ReferenceTracker {
12
13
/**
@@ -59,19 +60,22 @@ interface ReferenceTrackerStatic {
59
60
readonly READ : typeof ReferenceTrackerREAD ;
60
61
readonly CALL : typeof ReferenceTrackerCALL ;
61
62
readonly CONSTRUCT : typeof ReferenceTrackerCONSTRUCT ;
63
+ readonly ESM : typeof ReferenceTrackerESM ;
62
64
}
63
65
64
66
namespace ReferenceTracker {
65
67
export type READ = ReferenceTrackerStatic [ 'READ' ] ;
66
68
export type CALL = ReferenceTrackerStatic [ 'CALL' ] ;
67
69
export type CONSTRUCT = ReferenceTrackerStatic [ 'CONSTRUCT' ] ;
70
+ export type ESM = ReferenceTrackerStatic [ 'ESM' ] ;
68
71
export type ReferenceType = READ | CALL | CONSTRUCT ;
69
72
// eslint-disable-next-line @typescript-eslint/no-explicit-any
70
73
export type TraceMap < T = any > = Record < string , TraceMapElement < T > > ;
71
74
export interface TraceMapElement < T > {
72
75
[ ReferenceTrackerREAD ] ?: T ;
73
76
[ ReferenceTrackerCALL ] ?: T ;
74
77
[ ReferenceTrackerCONSTRUCT ] ?: T ;
78
+ [ ReferenceTrackerESM ] ?: true ;
75
79
[ key : string ] : TraceMapElement < T > ;
76
80
}
77
81
// eslint-disable-next-line @typescript-eslint/no-explicit-any
0 commit comments