Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/baseTranspiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import { IFileImport, IFileExport, TranspilationError, IMethodType, IParameterType } from './types.js';
import { unCamelCase } from "./utils.js";
import { Logger } from "./logger.js";
import { timingSafeEqual } from 'crypto';

Check warning on line 5 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'timingSafeEqual' is defined but never used
class BaseTranspiler {

NUM_LINES_BETWEEN_CLASS_MEMBERS = 1;
Expand Down Expand Up @@ -186,6 +186,7 @@
defaultPropertyAccess = 'public';

currentClassName = "";
className = "undefined";

uncamelcaseIdentifiers;
asyncTranspiling;
Expand Down Expand Up @@ -342,7 +343,7 @@

let method = undefined;

let parentClass = (ts as any).getAllSuperTypeNodes(node.parent)[0];

Check warning on line 346 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

Unexpected any. Specify a different type

while (parentClass !== undefined) {
const parentClassType = global.checker.getTypeAtLocation(parentClass);
Expand All @@ -359,13 +360,13 @@
if (ts.isMethodDeclaration(elem)) {

const name = elem.name.getText().trim();
if ((node as any).name.escapedText === name) {

Check warning on line 363 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

Unexpected any. Specify a different type
method = elem;
}
}
});

parentClass = (ts as any).getAllSuperTypeNodes(parentClassDecl)[0] ?? undefined;

Check warning on line 369 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

Unexpected any. Specify a different type
}


Expand All @@ -378,7 +379,7 @@
return this.DEFAULT_IDENTATION.repeat(parseInt(num));
}

getBlockOpen(identation){

Check warning on line 382 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'identation' is defined but never used
return this.SPACE_BEFORE_BLOCK_OPENING + this.BLOCK_OPENING_TOKEN + "\n";
}

Expand Down Expand Up @@ -443,11 +444,11 @@
return this.getIden(identation) + `${left} instanceof ${right}`;
}

getCustomOperatorIfAny(left, right, operator) {

Check warning on line 447 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'operator' is defined but never used

Check warning on line 447 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'right' is defined but never used

Check warning on line 447 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'left' is defined but never used
return undefined;
}

printCustomBinaryExpressionIfAny(node, identation) {

Check warning on line 451 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'identation' is defined but never used

Check warning on line 451 in src/baseTranspiler.ts

View workflow job for this annotation

GitHub Actions / build (18.x)

'node' is defined but never used
return undefined; // stub to override
}

Expand Down
1 change: 0 additions & 1 deletion src/goTranspiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ export class GoTranspiler extends BaseTranspiler {
binaryExpressionsWrappers;
wrapThisCalls: boolean;
wrapCallMethods: string[] = [];
className: string;
classNameMap: { [key: string]: string };
DEFAULT_RETURN_TYPE = 'any';

Expand Down
1 change: 0 additions & 1 deletion src/rustTranspiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ const parserConfig = {
export class RustTranspiler extends BaseTranspiler {

binaryExpressionsWrappers;
className: string;
methodSignatures: Record<string, { requiredCount: number }>;
forLoopCounter: number;

Expand Down
Loading