code-gauge 3.1.0 → 4.1.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.
Files changed (63) hide show
  1. package/README.md +16 -15
  2. package/dist/crossFileDuplication.cjs +1 -1
  3. package/dist/crossFileDuplication.cjs.map +1 -1
  4. package/dist/crossFileDuplication.js +1 -1
  5. package/dist/crossFileDuplication.js.map +1 -1
  6. package/dist/diffCommand.cjs +1 -1
  7. package/dist/diffCommand.cjs.map +1 -1
  8. package/dist/diffCommand.js +1 -1
  9. package/dist/diffCommand.js.map +1 -1
  10. package/dist/duplication.cjs +1 -1
  11. package/dist/duplication.cjs.map +1 -1
  12. package/dist/duplication.d.ts +14 -28
  13. package/dist/duplication.js +1 -1
  14. package/dist/duplication.js.map +1 -1
  15. package/dist/index.cjs +1 -1
  16. package/dist/index.d.ts +0 -1
  17. package/dist/index.js +1 -1
  18. package/dist/languages.cjs +1 -1
  19. package/dist/languages.cjs.map +1 -1
  20. package/dist/languages.d.ts +5 -0
  21. package/dist/languages.js +1 -1
  22. package/dist/languages.js.map +1 -1
  23. package/dist/metrics.cjs +1 -1
  24. package/dist/metrics.cjs.map +1 -1
  25. package/dist/metrics.d.ts +14 -12
  26. package/dist/metrics.js +1 -1
  27. package/dist/metrics.js.map +1 -1
  28. package/dist/nativeMetrics.cjs +3 -1
  29. package/dist/nativeMetrics.cjs.map +1 -1
  30. package/dist/nativeMetrics.d.ts +24 -9
  31. package/dist/nativeMetrics.js +3 -1
  32. package/dist/nativeMetrics.js.map +1 -1
  33. package/dist/scan.cjs +1 -1
  34. package/dist/scan.cjs.map +1 -1
  35. package/dist/scan.js +1 -1
  36. package/dist/scan.js.map +1 -1
  37. package/dist/types.d.ts +5 -13
  38. package/native/Cargo.lock +523 -0
  39. package/native/Cargo.toml +45 -0
  40. package/native/build.rs +3 -0
  41. package/native/src/complexity.rs +627 -0
  42. package/native/src/dep_degree.rs +253 -0
  43. package/native/src/duplication.rs +2007 -0
  44. package/native/src/functions.rs +345 -0
  45. package/native/src/languages.rs +647 -0
  46. package/native/src/lib.rs +101 -0
  47. package/native/src/measure.rs +590 -0
  48. package/native/src/ncss.rs +263 -0
  49. package/native/src/types.rs +135 -0
  50. package/native/src/util.rs +139 -0
  51. package/package.json +17 -19
  52. package/scripts/buildNative.mjs +25 -0
  53. package/scripts/installNative.mjs +96 -0
  54. package/dist/depDegree.cjs +0 -2
  55. package/dist/depDegree.cjs.map +0 -1
  56. package/dist/depDegree.d.ts +0 -12
  57. package/dist/depDegree.js +0 -2
  58. package/dist/depDegree.js.map +0 -1
  59. package/dist/ncss.cjs +0 -2
  60. package/dist/ncss.cjs.map +0 -1
  61. package/dist/ncss.d.ts +0 -17
  62. package/dist/ncss.js +0 -2
  63. package/dist/ncss.js.map +0 -1
@@ -0,0 +1,523 @@
1
+ # This file is automatically @generated by Cargo.
2
+ # It is not intended for manual editing.
3
+ version = 4
4
+
5
+ [[package]]
6
+ name = "aho-corasick"
7
+ version = "1.1.4"
8
+ source = "registry+https://github.com/rust-lang/crates.io-index"
9
+ checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301"
10
+ dependencies = [
11
+ "memchr",
12
+ ]
13
+
14
+ [[package]]
15
+ name = "bitflags"
16
+ version = "2.13.1"
17
+ source = "registry+https://github.com/rust-lang/crates.io-index"
18
+ checksum = "b588b76d00fde79687d7646a9b5bdf3cc0f655e0bbd080335a95d7e96f3587da"
19
+
20
+ [[package]]
21
+ name = "cc"
22
+ version = "1.0.106"
23
+ source = "registry+https://github.com/rust-lang/crates.io-index"
24
+ checksum = "066fce287b1d4eafef758e89e09d724a24808a9196fe9756b8ca90e86d0719a2"
25
+
26
+ [[package]]
27
+ name = "cfg-if"
28
+ version = "1.0.4"
29
+ source = "registry+https://github.com/rust-lang/crates.io-index"
30
+ checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801"
31
+
32
+ [[package]]
33
+ name = "code-gauge-native"
34
+ version = "0.0.0"
35
+ dependencies = [
36
+ "indexmap",
37
+ "napi",
38
+ "napi-build",
39
+ "napi-derive",
40
+ "regex",
41
+ "serde",
42
+ "serde_json",
43
+ "tree-sitter",
44
+ "tree-sitter-c",
45
+ "tree-sitter-cpp",
46
+ "tree-sitter-go",
47
+ "tree-sitter-java",
48
+ "tree-sitter-javascript",
49
+ "tree-sitter-python",
50
+ "tree-sitter-ruby",
51
+ "tree-sitter-rust",
52
+ "tree-sitter-typescript",
53
+ ]
54
+
55
+ [[package]]
56
+ name = "convert_case"
57
+ version = "0.11.0"
58
+ source = "registry+https://github.com/rust-lang/crates.io-index"
59
+ checksum = "affbf0190ed2caf063e3def54ff444b449371d55c58e513a95ab98eca50adb49"
60
+ dependencies = [
61
+ "unicode-segmentation",
62
+ ]
63
+
64
+ [[package]]
65
+ name = "ctor"
66
+ version = "1.0.9"
67
+ source = "registry+https://github.com/rust-lang/crates.io-index"
68
+ checksum = "a394189d59f9befacce833f337f7b1eca5e9a91221bcdd4d28e0114d96e597b3"
69
+
70
+ [[package]]
71
+ name = "equivalent"
72
+ version = "1.0.2"
73
+ source = "registry+https://github.com/rust-lang/crates.io-index"
74
+ checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"
75
+
76
+ [[package]]
77
+ name = "futures"
78
+ version = "0.3.33"
79
+ source = "registry+https://github.com/rust-lang/crates.io-index"
80
+ checksum = "a88cf1f829d945f548cf8fec32c61b1f202b6d93b45848602fc02af4b12ad218"
81
+ dependencies = [
82
+ "futures-channel",
83
+ "futures-core",
84
+ "futures-executor",
85
+ "futures-io",
86
+ "futures-sink",
87
+ "futures-task",
88
+ "futures-util",
89
+ ]
90
+
91
+ [[package]]
92
+ name = "futures-channel"
93
+ version = "0.3.33"
94
+ source = "registry+https://github.com/rust-lang/crates.io-index"
95
+ checksum = "262590f4fe6afeb0bc83be1daa64e52657fe185690a958af7f3ad0e92085c5ae"
96
+ dependencies = [
97
+ "futures-core",
98
+ "futures-sink",
99
+ ]
100
+
101
+ [[package]]
102
+ name = "futures-core"
103
+ version = "0.3.33"
104
+ source = "registry+https://github.com/rust-lang/crates.io-index"
105
+ checksum = "2cd50c473c80f6d7c3670a752354b8e569b1a7cbfdc0419ec88e5edad85e0dc7"
106
+
107
+ [[package]]
108
+ name = "futures-executor"
109
+ version = "0.3.33"
110
+ source = "registry+https://github.com/rust-lang/crates.io-index"
111
+ checksum = "6754879cc9f2c66f88c6e5c35344bb0bdb0708b0352b1201815667c7eabc7458"
112
+ dependencies = [
113
+ "futures-core",
114
+ "futures-task",
115
+ "futures-util",
116
+ ]
117
+
118
+ [[package]]
119
+ name = "futures-io"
120
+ version = "0.3.33"
121
+ source = "registry+https://github.com/rust-lang/crates.io-index"
122
+ checksum = "4577ecaa3c4f96589d473f679a71b596316f6641bc350038b962a5daf0085d7a"
123
+
124
+ [[package]]
125
+ name = "futures-macro"
126
+ version = "0.3.33"
127
+ source = "registry+https://github.com/rust-lang/crates.io-index"
128
+ checksum = "2d6d3cde68c518367be28956066ddfef33813991b77a55005a69dae04bf3b10b"
129
+ dependencies = [
130
+ "proc-macro2",
131
+ "quote",
132
+ "syn 2.0.119",
133
+ ]
134
+
135
+ [[package]]
136
+ name = "futures-sink"
137
+ version = "0.3.33"
138
+ source = "registry+https://github.com/rust-lang/crates.io-index"
139
+ checksum = "e34418ac499d6305c2fb5ad0ed2f6ac998c5f8ca209b4510f7f94242c647e307"
140
+
141
+ [[package]]
142
+ name = "futures-task"
143
+ version = "0.3.33"
144
+ source = "registry+https://github.com/rust-lang/crates.io-index"
145
+ checksum = "b231ed28831efb4a61a08580c4bc233ec56bc009f4cd8f52da2c3cb97df0c109"
146
+
147
+ [[package]]
148
+ name = "futures-util"
149
+ version = "0.3.33"
150
+ source = "registry+https://github.com/rust-lang/crates.io-index"
151
+ checksum = "a77a90a256fce34da66415271e30f94ee91c57b04b8a2c042d9cf3220179deaa"
152
+ dependencies = [
153
+ "futures-channel",
154
+ "futures-core",
155
+ "futures-io",
156
+ "futures-macro",
157
+ "futures-sink",
158
+ "futures-task",
159
+ "memchr",
160
+ "pin-project-lite",
161
+ "slab",
162
+ ]
163
+
164
+ [[package]]
165
+ name = "hashbrown"
166
+ version = "0.17.1"
167
+ source = "registry+https://github.com/rust-lang/crates.io-index"
168
+ checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a"
169
+
170
+ [[package]]
171
+ name = "indexmap"
172
+ version = "2.14.0"
173
+ source = "registry+https://github.com/rust-lang/crates.io-index"
174
+ checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"
175
+ dependencies = [
176
+ "equivalent",
177
+ "hashbrown",
178
+ ]
179
+
180
+ [[package]]
181
+ name = "itoa"
182
+ version = "1.0.18"
183
+ source = "registry+https://github.com/rust-lang/crates.io-index"
184
+ checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"
185
+
186
+ [[package]]
187
+ name = "libloading"
188
+ version = "0.9.0"
189
+ source = "registry+https://github.com/rust-lang/crates.io-index"
190
+ checksum = "754ca22de805bb5744484a5b151a9e1a8e837d5dc232c2d7d8c2e3492edc8b60"
191
+ dependencies = [
192
+ "cfg-if",
193
+ "windows-link",
194
+ ]
195
+
196
+ [[package]]
197
+ name = "memchr"
198
+ version = "2.8.3"
199
+ source = "registry+https://github.com/rust-lang/crates.io-index"
200
+ checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"
201
+
202
+ [[package]]
203
+ name = "napi"
204
+ version = "3.10.5"
205
+ source = "registry+https://github.com/rust-lang/crates.io-index"
206
+ checksum = "6826e5ddc15589b2d68c8ad5321c18e85d40488e93e32962f362e572669bccf6"
207
+ dependencies = [
208
+ "bitflags",
209
+ "ctor",
210
+ "futures",
211
+ "napi-build",
212
+ "napi-sys",
213
+ "nohash-hasher",
214
+ "rustc-hash",
215
+ ]
216
+
217
+ [[package]]
218
+ name = "napi-build"
219
+ version = "2.3.2"
220
+ source = "registry+https://github.com/rust-lang/crates.io-index"
221
+ checksum = "c9c366d2c8c60b86fa632df75f745509b52f9128f91a6bad4c796e44abb505e1"
222
+
223
+ [[package]]
224
+ name = "napi-derive"
225
+ version = "3.5.10"
226
+ source = "registry+https://github.com/rust-lang/crates.io-index"
227
+ checksum = "b0fe526e81c105d3640516fcde83909dd1afe757c0d7a15af58830b5bc0fb9a1"
228
+ dependencies = [
229
+ "convert_case",
230
+ "ctor",
231
+ "napi-derive-backend",
232
+ "proc-macro2",
233
+ "quote",
234
+ "syn 2.0.119",
235
+ ]
236
+
237
+ [[package]]
238
+ name = "napi-derive-backend"
239
+ version = "5.1.2"
240
+ source = "registry+https://github.com/rust-lang/crates.io-index"
241
+ checksum = "514281397bcddd9ea9a876c7a21a57bff2374237a000ca9a64ea0211ec1993e2"
242
+ dependencies = [
243
+ "convert_case",
244
+ "proc-macro2",
245
+ "quote",
246
+ "semver",
247
+ "syn 2.0.119",
248
+ ]
249
+
250
+ [[package]]
251
+ name = "napi-sys"
252
+ version = "3.2.3"
253
+ source = "registry+https://github.com/rust-lang/crates.io-index"
254
+ checksum = "73e43cf2eb0bd1bf95a43c07c076ebd2da5d1e015a71c3d201faeffffcc0ecac"
255
+ dependencies = [
256
+ "libloading",
257
+ ]
258
+
259
+ [[package]]
260
+ name = "nohash-hasher"
261
+ version = "0.2.0"
262
+ source = "registry+https://github.com/rust-lang/crates.io-index"
263
+ checksum = "2bf50223579dc7cdcfb3bfcacf7069ff68243f8c363f62ffa99cf000a6b9c451"
264
+
265
+ [[package]]
266
+ name = "pin-project-lite"
267
+ version = "0.2.17"
268
+ source = "registry+https://github.com/rust-lang/crates.io-index"
269
+ checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"
270
+
271
+ [[package]]
272
+ name = "proc-macro2"
273
+ version = "1.0.107"
274
+ source = "registry+https://github.com/rust-lang/crates.io-index"
275
+ checksum = "985e7ec9bb745e6ce6535b544d84d6cd6f7ad8bd711c398938ae983b91a766d9"
276
+ dependencies = [
277
+ "unicode-ident",
278
+ ]
279
+
280
+ [[package]]
281
+ name = "quote"
282
+ version = "1.0.47"
283
+ source = "registry+https://github.com/rust-lang/crates.io-index"
284
+ checksum = "1fbf4db142a473a8d80c26bbf18454ed458bf8d26c8219c331daecfdbd079001"
285
+ dependencies = [
286
+ "proc-macro2",
287
+ ]
288
+
289
+ [[package]]
290
+ name = "regex"
291
+ version = "1.13.1"
292
+ source = "registry+https://github.com/rust-lang/crates.io-index"
293
+ checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d"
294
+ dependencies = [
295
+ "aho-corasick",
296
+ "memchr",
297
+ "regex-automata",
298
+ "regex-syntax",
299
+ ]
300
+
301
+ [[package]]
302
+ name = "regex-automata"
303
+ version = "0.4.16"
304
+ source = "registry+https://github.com/rust-lang/crates.io-index"
305
+ checksum = "8fcfdb36bda0c880c5931cdc7a2bcdc8ba4556847b9d912bca70bc94708711ad"
306
+ dependencies = [
307
+ "aho-corasick",
308
+ "memchr",
309
+ "regex-syntax",
310
+ ]
311
+
312
+ [[package]]
313
+ name = "regex-syntax"
314
+ version = "0.8.11"
315
+ source = "registry+https://github.com/rust-lang/crates.io-index"
316
+ checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"
317
+
318
+ [[package]]
319
+ name = "rustc-hash"
320
+ version = "2.1.3"
321
+ source = "registry+https://github.com/rust-lang/crates.io-index"
322
+ checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"
323
+
324
+ [[package]]
325
+ name = "semver"
326
+ version = "1.0.28"
327
+ source = "registry+https://github.com/rust-lang/crates.io-index"
328
+ checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"
329
+
330
+ [[package]]
331
+ name = "serde"
332
+ version = "1.0.229"
333
+ source = "registry+https://github.com/rust-lang/crates.io-index"
334
+ checksum = "4148590afebada386688f18773da617792bf2ef03ffc1e4cbd2b1d45b023e0ba"
335
+ dependencies = [
336
+ "serde_core",
337
+ "serde_derive",
338
+ ]
339
+
340
+ [[package]]
341
+ name = "serde_core"
342
+ version = "1.0.229"
343
+ source = "registry+https://github.com/rust-lang/crates.io-index"
344
+ checksum = "67dca2c9c51e58a4791a4b1ed58308b39c64224d349a935ab5039aa360942a48"
345
+ dependencies = [
346
+ "serde_derive",
347
+ ]
348
+
349
+ [[package]]
350
+ name = "serde_derive"
351
+ version = "1.0.229"
352
+ source = "registry+https://github.com/rust-lang/crates.io-index"
353
+ checksum = "e7a5d71263a5a7d47b41f6b3f06ba276f10cc18b0931f1799f710578e2309348"
354
+ dependencies = [
355
+ "proc-macro2",
356
+ "quote",
357
+ "syn 3.0.0",
358
+ ]
359
+
360
+ [[package]]
361
+ name = "serde_json"
362
+ version = "1.0.150"
363
+ source = "registry+https://github.com/rust-lang/crates.io-index"
364
+ checksum = "e8014e44b4736ed0538adeecded0fce2a272f22dc9578a7eb6b2d9993c74cfb9"
365
+ dependencies = [
366
+ "itoa",
367
+ "memchr",
368
+ "serde",
369
+ "serde_core",
370
+ "zmij",
371
+ ]
372
+
373
+ [[package]]
374
+ name = "slab"
375
+ version = "0.4.12"
376
+ source = "registry+https://github.com/rust-lang/crates.io-index"
377
+ checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"
378
+
379
+ [[package]]
380
+ name = "syn"
381
+ version = "2.0.119"
382
+ source = "registry+https://github.com/rust-lang/crates.io-index"
383
+ checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297"
384
+ dependencies = [
385
+ "proc-macro2",
386
+ "quote",
387
+ "unicode-ident",
388
+ ]
389
+
390
+ [[package]]
391
+ name = "syn"
392
+ version = "3.0.0"
393
+ source = "registry+https://github.com/rust-lang/crates.io-index"
394
+ checksum = "f2fac314a64dc9a36e61a9eb4261a5e9bbfbc922b27e518af97bc32b926cf967"
395
+ dependencies = [
396
+ "proc-macro2",
397
+ "quote",
398
+ "unicode-ident",
399
+ ]
400
+
401
+ [[package]]
402
+ name = "tree-sitter"
403
+ version = "0.22.6"
404
+ source = "registry+https://github.com/rust-lang/crates.io-index"
405
+ checksum = "df7cc499ceadd4dcdf7ec6d4cbc34ece92c3fa07821e287aedecd4416c516dca"
406
+ dependencies = [
407
+ "cc",
408
+ "regex",
409
+ ]
410
+
411
+ [[package]]
412
+ name = "tree-sitter-c"
413
+ version = "0.21.4"
414
+ source = "registry+https://github.com/rust-lang/crates.io-index"
415
+ checksum = "f956d5351d62652864a4ff3ae861747e7a1940dc96c9998ae400ac0d3ce30427"
416
+ dependencies = [
417
+ "cc",
418
+ "tree-sitter",
419
+ ]
420
+
421
+ [[package]]
422
+ name = "tree-sitter-cpp"
423
+ version = "0.22.3"
424
+ source = "registry+https://github.com/rust-lang/crates.io-index"
425
+ checksum = "1d509a22a992790d38f2c291961ff8a1ff016c437c7ec6befc9220b8eec8918c"
426
+ dependencies = [
427
+ "cc",
428
+ "tree-sitter",
429
+ ]
430
+
431
+ [[package]]
432
+ name = "tree-sitter-go"
433
+ version = "0.21.2"
434
+ source = "registry+https://github.com/rust-lang/crates.io-index"
435
+ checksum = "b8d702a98d3c7e70e466456e58ff2b1ac550bf1e29b97e5770676d2fdabec00d"
436
+ dependencies = [
437
+ "cc",
438
+ "tree-sitter",
439
+ ]
440
+
441
+ [[package]]
442
+ name = "tree-sitter-java"
443
+ version = "0.21.0"
444
+ source = "registry+https://github.com/rust-lang/crates.io-index"
445
+ checksum = "33bc21adf831a773c075d9d00107ab43965e6a6ea7607b47fd9ec6f3db4b481b"
446
+ dependencies = [
447
+ "cc",
448
+ "tree-sitter",
449
+ ]
450
+
451
+ [[package]]
452
+ name = "tree-sitter-javascript"
453
+ version = "0.21.4"
454
+ source = "registry+https://github.com/rust-lang/crates.io-index"
455
+ checksum = "8710a71bc6779e33811a8067bdda3ed08bed1733296ff915e44faf60f8c533d7"
456
+ dependencies = [
457
+ "cc",
458
+ "tree-sitter",
459
+ ]
460
+
461
+ [[package]]
462
+ name = "tree-sitter-python"
463
+ version = "0.21.0"
464
+ source = "registry+https://github.com/rust-lang/crates.io-index"
465
+ checksum = "b4066c6cf678f962f8c2c4561f205945c84834cce73d981e71392624fdc390a9"
466
+ dependencies = [
467
+ "cc",
468
+ "tree-sitter",
469
+ ]
470
+
471
+ [[package]]
472
+ name = "tree-sitter-ruby"
473
+ version = "0.21.0"
474
+ source = "registry+https://github.com/rust-lang/crates.io-index"
475
+ checksum = "c0031f687c0772f2dad7b77104c43428611099a1804c81244ada21560f41f0b1"
476
+ dependencies = [
477
+ "cc",
478
+ "tree-sitter",
479
+ ]
480
+
481
+ [[package]]
482
+ name = "tree-sitter-rust"
483
+ version = "0.21.2"
484
+ source = "registry+https://github.com/rust-lang/crates.io-index"
485
+ checksum = "277690f420bf90741dea984f3da038ace46c4fe6047cba57a66822226cde1c93"
486
+ dependencies = [
487
+ "cc",
488
+ "tree-sitter",
489
+ ]
490
+
491
+ [[package]]
492
+ name = "tree-sitter-typescript"
493
+ version = "0.21.2"
494
+ source = "registry+https://github.com/rust-lang/crates.io-index"
495
+ checksum = "ecb35d98a688378e56c18c9c159824fd16f730ccbea19aacf4f206e5d5438ed9"
496
+ dependencies = [
497
+ "cc",
498
+ "tree-sitter",
499
+ ]
500
+
501
+ [[package]]
502
+ name = "unicode-ident"
503
+ version = "1.0.24"
504
+ source = "registry+https://github.com/rust-lang/crates.io-index"
505
+ checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
506
+
507
+ [[package]]
508
+ name = "unicode-segmentation"
509
+ version = "1.13.3"
510
+ source = "registry+https://github.com/rust-lang/crates.io-index"
511
+ checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"
512
+
513
+ [[package]]
514
+ name = "windows-link"
515
+ version = "0.2.1"
516
+ source = "registry+https://github.com/rust-lang/crates.io-index"
517
+ checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"
518
+
519
+ [[package]]
520
+ name = "zmij"
521
+ version = "1.0.23"
522
+ source = "registry+https://github.com/rust-lang/crates.io-index"
523
+ checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"
@@ -0,0 +1,45 @@
1
+ [package]
2
+ name = "code-gauge-native"
3
+ version = "0.0.0"
4
+ edition = "2021"
5
+ license = "Apache-2.0"
6
+ publish = false
7
+
8
+ [lib]
9
+ crate-type = ["cdylib"]
10
+
11
+ [dependencies]
12
+ napi = { version = "3", default-features = false }
13
+ napi-derive = "3"
14
+ serde = { version = "1", features = ["derive"] }
15
+ serde_json = "1"
16
+ indexmap = "2"
17
+ regex = "1"
18
+
19
+ # Grammar crates are pinned exactly: every metric (and the golden-based test suite) is calibrated
20
+ # against these grammar versions, so upgrades are deliberate, test-verified changes. The versions
21
+ # match the npm grammar packages the former node-tree-sitter backend used, keeping historical
22
+ # outputs stable. Core 0.22.6 parses identically to node-tree-sitter 0.21.1's vendored core
23
+ # (0.21.0 does not: it lacks several parser fixes and can abort on malformed input); its one
24
+ # behavioral difference — extra (error-recovery) children no longer inherit fields in
25
+ # ts_node_field_name_for_child — is compensated in util::find_children_by_field_name.
26
+ tree-sitter = "=0.22.6"
27
+ tree-sitter-c = "=0.21.4"
28
+ tree-sitter-cpp = "=0.22.3"
29
+ tree-sitter-go = "=0.21.2"
30
+ tree-sitter-java = "=0.21.0"
31
+ tree-sitter-javascript = "=0.21.4"
32
+ tree-sitter-python = "=0.21.0"
33
+ tree-sitter-ruby = "=0.21.0"
34
+ # 0.21.0 breaks MSVC (its build script passes the GCC-only -Wno-unused-parameter
35
+ # unconditionally; cl.exe fails with D8021); 0.21.2 gates the flag and the golden-based test
36
+ # suite verifies its grammar changes leave every measured metric unchanged.
37
+ tree-sitter-rust = "=0.21.2"
38
+ tree-sitter-typescript = "=0.21.2"
39
+
40
+ [build-dependencies]
41
+ napi-build = "2"
42
+
43
+ [profile.release]
44
+ lto = true
45
+ codegen-units = 1
@@ -0,0 +1,3 @@
1
+ fn main() {
2
+ napi_build::setup();
3
+ }