@effect/language-service 0.81.0 → 0.83.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
 
3
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Pipeable.js
3
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Pipeable.js
4
4
  var pipeArguments = (self, args3) => {
5
5
  switch (args3.length) {
6
6
  case 0:
@@ -44,7 +44,7 @@ var Class = /* @__PURE__ */ (function() {
44
44
  return PipeableBase;
45
45
  })();
46
46
 
47
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Function.js
47
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Function.js
48
48
  var dual = function(arity, body) {
49
49
  if (typeof arity === "function") {
50
50
  return function() {
@@ -92,7 +92,7 @@ function pipe(a, ...args3) {
92
92
  return pipeArguments(a, args3);
93
93
  }
94
94
 
95
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Equivalence.js
95
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Equivalence.js
96
96
  var make = (isEquivalent) => (self, that) => self === that || isEquivalent(self, that);
97
97
  function Array2(item) {
98
98
  return make((self, that) => {
@@ -104,7 +104,7 @@ function Array2(item) {
104
104
  });
105
105
  }
106
106
 
107
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/internal/equal.js
107
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/internal/equal.js
108
108
  var getAllObjectKeys = (obj) => {
109
109
  const keys2 = new Set(Reflect.ownKeys(obj));
110
110
  if (obj.constructor === Object) return keys2;
@@ -127,7 +127,7 @@ var getAllObjectKeys = (obj) => {
127
127
  };
128
128
  var byReferenceInstances = /* @__PURE__ */ new WeakSet();
129
129
 
130
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Predicate.js
130
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Predicate.js
131
131
  function isString(input) {
132
132
  return typeof input === "string";
133
133
  }
@@ -148,7 +148,7 @@ function isObjectKeyword(input) {
148
148
  }
149
149
  var hasProperty = /* @__PURE__ */ dual(2, (self, property) => isObjectKeyword(self) && property in self);
150
150
 
151
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Hash.js
151
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Hash.js
152
152
  var symbol = "~effect/interfaces/Hash";
153
153
  var hash = (self) => {
154
154
  switch (typeof self) {
@@ -267,7 +267,7 @@ function withVisitedTracking(obj, fn2) {
267
267
  return result;
268
268
  }
269
269
 
270
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Equal.js
270
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Equal.js
271
271
  var symbol2 = "~effect/interfaces/Equal";
272
272
  function equals() {
273
273
  if (arguments.length === 1) {
@@ -429,7 +429,7 @@ var compareSets = /* @__PURE__ */ makeCompareSet(compareBoth);
429
429
  var isEqual = (u) => hasProperty(u, symbol2);
430
430
  var asEquivalence = () => equals;
431
431
 
432
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Redactable.js
432
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Redactable.js
433
433
  var symbolRedactable = /* @__PURE__ */ Symbol.for("~effect/Inspectable/redactable");
434
434
  var isRedactable = (u) => hasProperty(u, symbolRedactable);
435
435
  function redact(u) {
@@ -448,7 +448,7 @@ var emptyServiceMap = {
448
448
  }
449
449
  };
450
450
 
451
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Formatter.js
451
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Formatter.js
452
452
  function format(input, options) {
453
453
  const space = options?.space ?? 0;
454
454
  const seen = /* @__PURE__ */ new WeakSet();
@@ -527,7 +527,7 @@ function safeToString(input) {
527
527
  }
528
528
  }
529
529
 
530
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Inspectable.js
530
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Inspectable.js
531
531
  var NodeInspectSymbol = /* @__PURE__ */ Symbol.for("nodejs.util.inspect.custom");
532
532
  var toJson = (input) => {
533
533
  try {
@@ -571,30 +571,7 @@ var Class2 = class {
571
571
  }
572
572
  };
573
573
 
574
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Utils.js
575
- var GenKindTypeId = "~effect/Utils/GenKind";
576
- var GenKindImpl = class {
577
- value;
578
- constructor(value) {
579
- this.value = value;
580
- }
581
- get _F() {
582
- return identity;
583
- }
584
- get _R() {
585
- return (_) => _;
586
- }
587
- get _O() {
588
- return (_) => _;
589
- }
590
- get _E() {
591
- return (_) => _;
592
- }
593
- [GenKindTypeId] = GenKindTypeId;
594
- [Symbol.iterator]() {
595
- return new SingleShotGen(this);
596
- }
597
- };
574
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Utils.js
598
575
  var SingleShotGen = class _SingleShotGen {
599
576
  called = false;
600
577
  self;
@@ -620,7 +597,7 @@ var SingleShotGen = class _SingleShotGen {
620
597
  return new _SingleShotGen(this.self);
621
598
  }
622
599
  };
623
- var InternalTypeId = "~effect/Effect/internal";
600
+ var InternalTypeId = "~effect/Utils/internal";
624
601
  var standard = {
625
602
  [InternalTypeId]: (body) => {
626
603
  return body();
@@ -636,10 +613,8 @@ var forced = {
636
613
  };
637
614
  var isNotOptimizedAway = /* @__PURE__ */ standard[InternalTypeId](() => new Error().stack)?.includes(InternalTypeId) === true;
638
615
  var internalCall = isNotOptimizedAway ? standard[InternalTypeId] : forced[InternalTypeId];
639
- var genConstructor = function* () {
640
- }.constructor;
641
616
 
642
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/internal/core.js
617
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/internal/core.js
643
618
  var EffectTypeId = `~effect/Effect`;
644
619
  var ExitTypeId = `~effect/Exit`;
645
620
  var effectVariance = {
@@ -986,7 +961,7 @@ var DoneVoid = {
986
961
  value: void 0
987
962
  };
988
963
 
989
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/internal/option.js
964
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/internal/option.js
990
965
  var TypeId = "~effect/data/Option";
991
966
  var CommonProto = {
992
967
  [TypeId]: {
@@ -1018,10 +993,16 @@ var SomeProto = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(Comm
1018
993
  return exitSucceed(this.value);
1019
994
  }
1020
995
  });
996
+ Object.defineProperty(SomeProto, "valueOrUndefined", {
997
+ get() {
998
+ return this.value;
999
+ }
1000
+ });
1021
1001
  var NoneHash = /* @__PURE__ */ hash("None");
1022
1002
  var NoneProto = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(CommonProto), {
1023
1003
  _tag: "None",
1024
1004
  _op: "None",
1005
+ valueOrUndefined: void 0,
1025
1006
  [symbol2](that) {
1026
1007
  return isOption(that) && isNone(that);
1027
1008
  },
@@ -1051,7 +1032,7 @@ var some = (value) => {
1051
1032
  return a;
1052
1033
  };
1053
1034
 
1054
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/internal/result.js
1035
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/internal/result.js
1055
1036
  var TypeId2 = "~effect/data/Result";
1056
1037
  var CommonProto2 = {
1057
1038
  [TypeId2]: {
@@ -1122,7 +1103,7 @@ var succeed = (success) => {
1122
1103
  return a;
1123
1104
  };
1124
1105
 
1125
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Result.js
1106
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Result.js
1126
1107
  var succeed2 = succeed;
1127
1108
  var fail2 = fail;
1128
1109
  var isFailure2 = isFailure;
@@ -1130,10 +1111,10 @@ var isSuccess2 = isSuccess;
1130
1111
  var map = /* @__PURE__ */ dual(2, (self, f) => isSuccess2(self) ? succeed2(f(self.success)) : fail2(self.failure));
1131
1112
  var getOrElse = /* @__PURE__ */ dual(2, (self, onFailure) => isFailure2(self) ? onFailure(self.failure) : self.success);
1132
1113
 
1133
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/internal/array.js
1114
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/internal/array.js
1134
1115
  var isArrayNonEmpty = (self) => self.length > 0;
1135
1116
 
1136
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Order.js
1117
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Order.js
1137
1118
  function make2(compare) {
1138
1119
  return (self, that) => self === that ? 0 : compare(self, that);
1139
1120
  }
@@ -1156,7 +1137,7 @@ var combine2 = /* @__PURE__ */ dual(2, (self, that) => make2((a1, a2) => {
1156
1137
  }));
1157
1138
  var mapInput = /* @__PURE__ */ dual(2, (self, f) => make2((b1, b2) => self(f(b1), f(b2))));
1158
1139
 
1159
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Option.js
1140
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Option.js
1160
1141
  var none2 = () => none;
1161
1142
  var some2 = some;
1162
1143
  var isNone2 = isNone;
@@ -1167,7 +1148,7 @@ var fromNullishOr = (a) => a == null ? none2() : some2(a);
1167
1148
  var getOrUndefined = /* @__PURE__ */ getOrElse2(constUndefined);
1168
1149
  var map2 = /* @__PURE__ */ dual(2, (self, f) => isNone2(self) ? none2() : some2(f(self.value)));
1169
1150
 
1170
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Record.js
1151
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Record.js
1171
1152
  var map3 = /* @__PURE__ */ dual(2, (self, f) => {
1172
1153
  const out = {
1173
1154
  ...self
@@ -1179,7 +1160,7 @@ var map3 = /* @__PURE__ */ dual(2, (self, f) => {
1179
1160
  });
1180
1161
  var keys = (self) => Object.keys(self);
1181
1162
 
1182
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Array.js
1163
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Array.js
1183
1164
  var Array3 = globalThis.Array;
1184
1165
  var fromIterable = (collection) => Array3.isArray(collection) ? collection : Array3.from(collection);
1185
1166
  var append = /* @__PURE__ */ dual(2, (self, last) => [...self, last]);
@@ -1270,7 +1251,7 @@ var dedupeWith = /* @__PURE__ */ dual(2, (self, isEquivalent) => {
1270
1251
  var dedupe = (self) => dedupeWith(self, asEquivalence());
1271
1252
  var join = /* @__PURE__ */ dual(2, (self, sep) => fromIterable(self).join(sep));
1272
1253
 
1273
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Data.js
1254
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Data.js
1274
1255
  var Class3 = class extends Class {
1275
1256
  constructor(props) {
1276
1257
  super();
@@ -1281,7 +1262,7 @@ var Class3 = class extends Class {
1281
1262
  };
1282
1263
  var TaggedError2 = TaggedError;
1283
1264
 
1284
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Encoding.js
1265
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Encoding.js
1285
1266
  var EncodingErrorTypeId = "~effect/encoding/EncodingError";
1286
1267
  var EncodingError = class extends (/* @__PURE__ */ TaggedError2("EncodingError")) {
1287
1268
  /**
@@ -1317,7 +1298,7 @@ var base64EncodeUint8Array = (bytes) => {
1317
1298
  var base64abc = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "+", "/"];
1318
1299
  var base64UrlEncodeUint8Array = (data) => base64EncodeUint8Array(data).replace(/=/g, "").replace(/\+/g, "-").replace(/\//g, "_");
1319
1300
 
1320
- // ../../node_modules/.pnpm/effect@4.0.0-beta.27/node_modules/effect/dist/Graph.js
1301
+ // ../../node_modules/.pnpm/effect@4.0.0-beta.37/node_modules/effect/dist/Graph.js
1321
1302
  var TypeId3 = "~effect/collections/Graph";
1322
1303
  var Edge = class extends Class3 {
1323
1304
  };
@@ -1389,7 +1370,7 @@ var GraphError = class extends (/* @__PURE__ */ TaggedError2("GraphError")) {
1389
1370
  var missingNode = (node) => new GraphError({
1390
1371
  message: `Node ${node} does not exist`
1391
1372
  });
1392
- var isGraph = (u) => typeof u === "object" && u !== null && TypeId3 in u;
1373
+ var isGraph = (u) => hasProperty(u, TypeId3);
1393
1374
  var directed = (mutate2) => {
1394
1375
  const graph = Object.create(ProtoGraph);
1395
1376
  graph.type = "directed";
@@ -1399,7 +1380,7 @@ var directed = (mutate2) => {
1399
1380
  graph.reverseAdjacency = /* @__PURE__ */ new Map();
1400
1381
  graph.nextNodeIndex = 0;
1401
1382
  graph.nextEdgeIndex = 0;
1402
- graph.acyclic = true;
1383
+ graph.acyclic = some2(true);
1403
1384
  graph.mutable = false;
1404
1385
  if (mutate2) {
1405
1386
  const mutable = beginMutation(graph);
@@ -1476,16 +1457,16 @@ var reverse = (mutable) => {
1476
1457
  targetEdges.push(edgeIndex);
1477
1458
  mutable.reverseAdjacency.set(edgeData.target, targetEdges);
1478
1459
  }
1479
- mutable.acyclic = void 0;
1460
+ mutable.acyclic = none2();
1480
1461
  };
1481
1462
  var invalidateCycleFlagOnRemoval = (mutable) => {
1482
- if (mutable.acyclic === false) {
1483
- mutable.acyclic = void 0;
1463
+ if (mutable.acyclic._tag === "Some" && mutable.acyclic.value === false) {
1464
+ mutable.acyclic = none2();
1484
1465
  }
1485
1466
  };
1486
1467
  var invalidateCycleFlagOnAddition = (mutable) => {
1487
- if (mutable.acyclic === true) {
1488
- mutable.acyclic = void 0;
1468
+ if (mutable.acyclic._tag === "Some" && mutable.acyclic.value === true) {
1469
+ mutable.acyclic = none2();
1489
1470
  }
1490
1471
  };
1491
1472
  var addEdge = (mutable, source, target, data) => {
@@ -7429,6 +7410,7 @@ var classSelfMismatch = createDiagnostic({
7429
7410
  if (ts.isClassDeclaration(node) && node.name && node.heritageClauses) {
7430
7411
  const result = yield* pipe(
7431
7412
  typeParser.extendsEffectService(node),
7413
+ orElse2(() => typeParser.extendsServiceMapService(node)),
7432
7414
  orElse2(() => typeParser.extendsContextTag(node)),
7433
7415
  orElse2(() => typeParser.extendsEffectTag(node)),
7434
7416
  orElse2(() => typeParser.extendsSchemaClass(node)),
@@ -7738,6 +7720,89 @@ var effectFnIife = createDiagnostic({
7738
7720
  })
7739
7721
  });
7740
7722
 
7723
+ // src/diagnostics/effectFnImplicitAny.ts
7724
+ var getParameterName = (typescript, name) => {
7725
+ if (typescript.isIdentifier(name)) {
7726
+ return typescript.idText(name);
7727
+ }
7728
+ return "parameter";
7729
+ };
7730
+ var hasOuterContextualFunctionType = (typescript, typeChecker, node) => {
7731
+ const contextualType = typeChecker.getContextualType(node);
7732
+ if (!contextualType) {
7733
+ return false;
7734
+ }
7735
+ return typeChecker.getSignaturesOfType(contextualType, typescript.SignatureKind.Call).length > 0;
7736
+ };
7737
+ var effectFnImplicitAny = createDiagnostic({
7738
+ name: "effectFnImplicitAny",
7739
+ code: 54,
7740
+ description: "Mirrors noImplicitAny for unannotated Effect.fn and Effect.fnUntraced callback parameters when no outer contextual function type exists",
7741
+ group: "correctness",
7742
+ severity: "error",
7743
+ fixable: false,
7744
+ supportedEffect: ["v3", "v4"],
7745
+ apply: fn("effectFnImplicitAny.apply")(function* (sourceFile, report) {
7746
+ const ts = yield* service(TypeScriptApi);
7747
+ const program = yield* service(TypeScriptProgram);
7748
+ const typeChecker = yield* service(TypeCheckerApi);
7749
+ const typeParser = yield* service(TypeParser);
7750
+ const noImplicitAny = program.getCompilerOptions().noImplicitAny ?? program.getCompilerOptions().strict ?? false;
7751
+ if (!noImplicitAny) {
7752
+ return;
7753
+ }
7754
+ const nodeToVisit = [sourceFile];
7755
+ const appendNodeToVisit = (node) => {
7756
+ nodeToVisit.push(node);
7757
+ return void 0;
7758
+ };
7759
+ while (nodeToVisit.length > 0) {
7760
+ const node = nodeToVisit.pop();
7761
+ ts.forEachChild(node, appendNodeToVisit);
7762
+ const parsed = yield* pipe(
7763
+ typeParser.effectFn(node),
7764
+ map5((result) => ({
7765
+ call: result.node,
7766
+ fn: result.regularFunction
7767
+ })),
7768
+ orElse2(
7769
+ () => pipe(
7770
+ typeParser.effectFnGen(node),
7771
+ map5((result) => ({
7772
+ call: result.node,
7773
+ fn: result.generatorFunction
7774
+ }))
7775
+ )
7776
+ ),
7777
+ orElse2(
7778
+ () => pipe(
7779
+ typeParser.effectFnUntracedGen(node),
7780
+ map5((result) => ({
7781
+ call: result.node,
7782
+ fn: result.generatorFunction
7783
+ }))
7784
+ )
7785
+ ),
7786
+ orUndefined
7787
+ );
7788
+ if (!parsed || hasOuterContextualFunctionType(ts, typeChecker, parsed.call)) {
7789
+ continue;
7790
+ }
7791
+ for (const parameter of parsed.fn.parameters) {
7792
+ if (parameter.type || parameter.initializer) {
7793
+ continue;
7794
+ }
7795
+ const parameterName = getParameterName(ts, parameter.name);
7796
+ report({
7797
+ location: parameter.name,
7798
+ messageText: `Parameter '${parameterName}' implicitly has an 'any' type in Effect.fn/Effect.fnUntraced. Add an explicit type annotation or provide a contextual function type.`,
7799
+ fixes: []
7800
+ });
7801
+ }
7802
+ }
7803
+ })
7804
+ });
7805
+
7741
7806
  // src/diagnostics/effectFnOpportunity.ts
7742
7807
  var effectFnOpportunity = createDiagnostic({
7743
7808
  name: "effectFnOpportunity",
@@ -9272,6 +9337,24 @@ var leakingRequirements = createDiagnostic({
9272
9337
  const typeCheckerUtils = yield* service(TypeCheckerUtils);
9273
9338
  const typeParser = yield* service(TypeParser);
9274
9339
  const tsUtils = yield* service(TypeScriptUtils);
9340
+ const isExpectedLeakingServiceSuppressed = (leakedServiceName, startNode) => {
9341
+ const sourceFile2 = tsUtils.getSourceFileOfNode(startNode);
9342
+ if (!sourceFile2) return false;
9343
+ return !!ts.findAncestor(startNode, (current) => {
9344
+ const ranges = ts.getLeadingCommentRanges(sourceFile2.text, current.pos) ?? [];
9345
+ const isSuppressed = ranges.some((range) => {
9346
+ const commentText = sourceFile2.text.slice(range.pos, range.end);
9347
+ return commentText.split("\n").filter((line) => line.includes("@effect-expect-leaking")).some((line) => {
9348
+ const markerIndex = line.indexOf("@effect-expect-leaking");
9349
+ return markerIndex !== -1 && line.slice(markerIndex + "@effect-expect-leaking".length).includes(leakedServiceName);
9350
+ });
9351
+ });
9352
+ if (isSuppressed) {
9353
+ return true;
9354
+ }
9355
+ return ts.isClassDeclaration(current) || ts.isVariableStatement(current) || ts.isExpressionStatement(current) || ts.isStatement(current) ? "quit" : false;
9356
+ });
9357
+ };
9275
9358
  const parseLeakedRequirements = cachedBy(
9276
9359
  fn("leakingServices.checkServiceLeaking")(
9277
9360
  function* (service2, atLocation) {
@@ -9353,8 +9436,12 @@ var leakingRequirements = createDiagnostic({
9353
9436
  (_, service2) => service2
9354
9437
  );
9355
9438
  function reportLeakingRequirements(node, requirements) {
9356
- if (requirements.length === 0) return;
9357
- const requirementsStr = requirements.map((_) => typeChecker.typeToString(_)).join(" | ");
9439
+ const filteredRequirements = requirements.filter(
9440
+ (requirement) => !isExpectedLeakingServiceSuppressed(typeChecker.typeToString(requirement), node)
9441
+ );
9442
+ if (filteredRequirements.length === 0) return;
9443
+ const requirementsStr = filteredRequirements.map((_) => typeChecker.typeToString(_)).join(" | ");
9444
+ const firstStr = typeChecker.typeToString(filteredRequirements[0]);
9358
9445
  report({
9359
9446
  location: node,
9360
9447
  messageText: `Methods of this Service require \`${requirementsStr}\` from every caller.
@@ -9363,7 +9450,7 @@ This leaks implementation details into the service's public type \u2014 callers
9363
9450
 
9364
9451
  Resolve these dependencies at Layer creation and provide them to each method, so the service's type reflects its purpose, not its implementation.
9365
9452
 
9366
- To suppress this diagnostic for specific dependency types that are intentionally passed through (e.g., HttpServerRequest), add \`@effect-leakable-service\` JSDoc to their interface declarations (e.g., the \`${typeChecker.typeToString(requirements[0])}\` interface), not to this service.
9453
+ To suppress this diagnostic for specific dependency types that are intentionally passed through (e.g., HttpServerRequest), add \`@effect-leakable-service\` JSDoc to their interface declarations (e.g., the \`${firstStr}\` interface), or to this service by adding a \`@effect-expect-leaking ${firstStr}\` JSDoc.
9367
9454
 
9368
9455
  More info and examples at https://effect.website/docs/requirements-management/layers/#avoiding-requirement-leakage`,
9369
9456
  fixes: []
@@ -12615,6 +12702,7 @@ var diagnostics = [
12615
12702
  catchUnfailableEffect,
12616
12703
  classSelfMismatch,
12617
12704
  duplicatePackage,
12705
+ effectFnImplicitAny,
12618
12706
  effectGenUsesAdapter,
12619
12707
  missingEffectContext,
12620
12708
  missingEffectError,