Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: fix build #1504

Merged
merged 2 commits into from
Feb 11, 2024
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
2 changes: 1 addition & 1 deletion packages/scripts/deps.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export * as path from "https://deno.land/[email protected]/path/mod.ts";
export * as tsMorph from "https://deno.land/x/[email protected].0/mod.ts";
export * as tsMorph from "https://deno.land/x/[email protected].1/mod.ts";
15 changes: 7 additions & 8 deletions packages/scripts/utils/Memoize.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
/** Decorator for memoizing the result of a method or get accessor. */
export function Memoize(target: any, propertyName: string, descriptor: TypedPropertyDescriptor<any>) {
if (descriptor.value != null)
descriptor.value = getNewFunction(descriptor.value);
else if (descriptor.get != null)
descriptor.get = getNewFunction(descriptor.get);
else
throw new Error("Only put a Memoize decorator on a method or get accessor.");
/** Decorator for memoizing the result of a method. */
export function Memoize(target: (...args: any[]) => void) {
if (target instanceof Function) {
return getNewFunction(target);
} else {
throw new Error("Not implemented.");
}
}

const weakMap = new WeakMap<object, Map<string, unknown>>();
Expand Down
1 change: 0 additions & 1 deletion packages/ts-morph/scripts/generation/main.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { tsMorph } from "../deps.ts";
import { InspectorFactory } from "../inspectors/mod.ts";
import { createDeclarationFile } from "./createDeclarationFile.ts";
import { createForEachStructureChild } from "./createForEachStructureChild.ts";
Expand Down
Loading