mirror of
https://github.com/abhigyanpatwari/GitNexus.git
synced 2026-10-09 03:17:54 +00:00
fix: remove unused import, fix any type in Java scanner, update stale comment
- Remove unused extractCalleeName import from jvm.ts - Fix (c: any) → (c: SyntaxNode) in Java scanner - Update stale CONSTRUCTOR_BINDING_SCANNERS reference in ruby.ts comment
This commit is contained in:
parent
4a99c7fe9a
commit
6f416410f9
2 changed files with 4 additions and 3 deletions
|
|
@ -1,6 +1,6 @@
|
|||
import type { SyntaxNode } from '../utils.js';
|
||||
import type { LanguageTypeConfig, ParameterExtractor, TypeBindingExtractor, InitializerExtractor, ClassNameLookup, ConstructorBindingScanner } from './types.js';
|
||||
import { extractSimpleTypeName, extractVarName, extractCalleeName, findChildByType } from './shared.js';
|
||||
import { extractSimpleTypeName, extractVarName, findChildByType } from './shared.js';
|
||||
|
||||
// ── Java ──────────────────────────────────────────────────────────────────
|
||||
|
||||
|
|
@ -73,7 +73,7 @@ const scanJavaConstructorBinding: ConstructorBindingScanner = (node) => {
|
|||
const typeNode = node.childForFieldName('type');
|
||||
if (!typeNode) return undefined;
|
||||
if (typeNode.text !== 'var') return undefined;
|
||||
const declarator = node.namedChildren.find((c: any) => c.type === 'variable_declarator');
|
||||
const declarator = node.namedChildren.find((c: SyntaxNode) => c.type === 'variable_declarator');
|
||||
if (!declarator) return undefined;
|
||||
const nameNode = declarator.childForFieldName('name');
|
||||
const value = declarator.childForFieldName('value');
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
import type { LanguageTypeConfig, ParameterExtractor, TypeBindingExtractor, InitializerExtractor, ClassNameLookup } from './types.js';
|
||||
import { extractRubyConstructorAssignment } from './shared.js';
|
||||
import { SyntaxNode } from '../utils.js';
|
||||
|
||||
/**
|
||||
* Ruby type extractor — YARD annotation parsing.
|
||||
|
|
@ -19,7 +20,7 @@ import { extractRubyConstructorAssignment } from './shared.js';
|
|||
*
|
||||
* Resolution tiers:
|
||||
* - Tier 0: YARD @param annotations (extractDeclaration pre-populates env)
|
||||
* - Tier 1: Constructor inference via `user = User.new` (handled by CONSTRUCTOR_BINDING_SCANNERS in type-env.ts)
|
||||
* - Tier 1: Constructor inference via `user = User.new` (handled by scanConstructorBinding in typeConfig)
|
||||
*/
|
||||
|
||||
/** Regex to extract @param annotations: `@param name [Type]` */
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue