Skip to content

Commit

Permalink
Extract FastStringArray into separate package
Browse files Browse the repository at this point in the history
  • Loading branch information
jridgewell committed Apr 23, 2022
1 parent e2103a9 commit 5285f27
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 93 deletions.
14 changes: 14 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Expand Up @@ -57,6 +57,7 @@
"typescript": "4.5.5"
},
"dependencies": {
"@jridgewell/set-array": "^1.0.0",
"@jridgewell/trace-mapping": "^0.3.0"
}
}
38 changes: 0 additions & 38 deletions src/fast-string-array.ts

This file was deleted.

6 changes: 3 additions & 3 deletions src/source-map-tree.ts
@@ -1,4 +1,4 @@
import { FastStringArray, put } from './fast-string-array';
import { SetArray, put } from '@jridgewell/set-array';
import { presortedDecodedMap, traceSegment, decodedMappings } from '@jridgewell/trace-mapping';

import type { TraceMap } from '@jridgewell/trace-mapping';
Expand Down Expand Up @@ -62,8 +62,8 @@ export function OriginalSource(source: string, content: string | null): Original
*/
export function traceMappings(tree: Sources): TraceMap {
const mappings: SourceMapSegment[][] = [];
const names = FastStringArray();
const sources = FastStringArray();
const names = new SetArray();
const sources = new SetArray();
const sourcesContent: (string | null)[] = [];
const { sources: rootSources, map } = tree;
const rootNames = map.names;
Expand Down
52 changes: 0 additions & 52 deletions test/unit/fast-array-string.ts

This file was deleted.

0 comments on commit 5285f27

Please sign in to comment.