@markw65/monkeyc-optimizer 1.1.89 → 1.1.90
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.
- package/CHANGELOG.md +5 -0
- package/build/api.cjs +44 -44
- package/build/cftinfo.cjs +7 -9
- package/build/{chunk-7CG7CM26.cjs → chunk-BOVSYC7N.cjs} +1572 -2023
- package/build/{chunk-X7QCZR3F.cjs → chunk-KHQPCXSJ.cjs} +449 -517
- package/build/{chunk-JDC43A3I.cjs → chunk-UBAYZSM3.cjs} +15 -25
- package/build/{chunk-ABYVSU2C.cjs → chunk-VS2QQHAK.cjs} +5 -6
- package/build/optimizer.cjs +22 -22
- package/build/sdk-util.cjs +17 -17
- package/build/src/type-flow/inference-type.d.ts +2 -0
- package/build/src/type-flow/interp.d.ts +1 -1
- package/build/src/type-flow/types.d.ts +3 -1
- package/build/util.cjs +27 -27
- package/build/worker-thread.cjs +7 -7
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to the "monkeyc-optimizer" package will be documented in this file.
|
|
4
4
|
|
|
5
|
+
### 1.1.90
|
|
6
|
+
|
|
7
|
+
- Fix a bug that could result in infinite recursion when computing the union or intersection of two types involving typedefs
|
|
8
|
+
- Fix a bug where the inferred type of `[ null ]` was tuple containing `Object?`.
|
|
9
|
+
|
|
5
10
|
### 1.1.89
|
|
6
11
|
|
|
7
12
|
- Fix error determining whether or not to generate a SHA256 signature, so that things start working with sdk-8.2.2 again
|
package/build/api.cjs
CHANGED
|
@@ -18,52 +18,52 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
var api_exports = {};
|
|
20
20
|
__export(api_exports, {
|
|
21
|
-
checkCompilerVersion: () =>
|
|
22
|
-
clearDiagnostics: () =>
|
|
23
|
-
collectNamespaces: () =>
|
|
24
|
-
createDocumentationMap: () =>
|
|
25
|
-
declKey: () =>
|
|
26
|
-
diagnostic: () =>
|
|
27
|
-
diagnosticHelper: () =>
|
|
28
|
-
findNamesInScope: () =>
|
|
29
|
-
findUsingForNode: () =>
|
|
30
|
-
formatAst: () =>
|
|
31
|
-
formatAstLongLines: () =>
|
|
32
|
-
formatScopedName: () =>
|
|
33
|
-
getApiFunctionInfo: () =>
|
|
34
|
-
getApiMapping: () =>
|
|
35
|
-
getSuperClasses: () =>
|
|
36
|
-
handleImportUsing: () =>
|
|
37
|
-
hasProperty: () =>
|
|
38
|
-
isClassVariable: () =>
|
|
39
|
-
isLocal: () =>
|
|
40
|
-
isLookupCandidate: () =>
|
|
41
|
-
isStateNode: () =>
|
|
42
|
-
lookupByFullName: () =>
|
|
43
|
-
lookupNext: () =>
|
|
44
|
-
lookupResultContains: () =>
|
|
45
|
-
lookupWithType: () =>
|
|
46
|
-
makeToyboxLink: () =>
|
|
47
|
-
mapVarDeclsByType: () =>
|
|
48
|
-
markInvokeClassMethod: () =>
|
|
49
|
-
parseSdkVersion: () =>
|
|
50
|
-
popRootNode: () =>
|
|
51
|
-
pushRootNode: () =>
|
|
52
|
-
resolveDiagnostics: () =>
|
|
53
|
-
resolveDiagnosticsMap: () =>
|
|
54
|
-
sameLookupResult: () =>
|
|
55
|
-
traverseAst: () =>
|
|
56
|
-
variableDeclarationName: () =>
|
|
57
|
-
visitReferences: () =>
|
|
58
|
-
visit_resources: () =>
|
|
59
|
-
visitorNode: () =>
|
|
21
|
+
checkCompilerVersion: () => import_chunk_BOVSYC7N.checkCompilerVersion,
|
|
22
|
+
clearDiagnostics: () => import_chunk_BOVSYC7N.clearDiagnostics,
|
|
23
|
+
collectNamespaces: () => import_chunk_BOVSYC7N.collectNamespaces,
|
|
24
|
+
createDocumentationMap: () => import_chunk_BOVSYC7N.createDocumentationMap,
|
|
25
|
+
declKey: () => import_chunk_BOVSYC7N.declKey,
|
|
26
|
+
diagnostic: () => import_chunk_BOVSYC7N.diagnostic,
|
|
27
|
+
diagnosticHelper: () => import_chunk_BOVSYC7N.diagnosticHelper,
|
|
28
|
+
findNamesInScope: () => import_chunk_BOVSYC7N.findNamesInScope,
|
|
29
|
+
findUsingForNode: () => import_chunk_BOVSYC7N.findUsingForNode,
|
|
30
|
+
formatAst: () => import_chunk_BOVSYC7N.formatAst,
|
|
31
|
+
formatAstLongLines: () => import_chunk_BOVSYC7N.formatAstLongLines,
|
|
32
|
+
formatScopedName: () => import_chunk_BOVSYC7N.formatScopedName,
|
|
33
|
+
getApiFunctionInfo: () => import_chunk_BOVSYC7N.getApiFunctionInfo,
|
|
34
|
+
getApiMapping: () => import_chunk_BOVSYC7N.getApiMapping,
|
|
35
|
+
getSuperClasses: () => import_chunk_BOVSYC7N.getSuperClasses,
|
|
36
|
+
handleImportUsing: () => import_chunk_BOVSYC7N.handleImportUsing,
|
|
37
|
+
hasProperty: () => import_chunk_UBAYZSM3.hasProperty,
|
|
38
|
+
isClassVariable: () => import_chunk_BOVSYC7N.isClassVariable,
|
|
39
|
+
isLocal: () => import_chunk_BOVSYC7N.isLocal,
|
|
40
|
+
isLookupCandidate: () => import_chunk_BOVSYC7N.isLookupCandidate,
|
|
41
|
+
isStateNode: () => import_chunk_BOVSYC7N.isStateNode,
|
|
42
|
+
lookupByFullName: () => import_chunk_BOVSYC7N.lookupByFullName,
|
|
43
|
+
lookupNext: () => import_chunk_BOVSYC7N.lookupNext,
|
|
44
|
+
lookupResultContains: () => import_chunk_BOVSYC7N.lookupResultContains,
|
|
45
|
+
lookupWithType: () => import_chunk_BOVSYC7N.lookupWithType,
|
|
46
|
+
makeToyboxLink: () => import_chunk_BOVSYC7N.makeToyboxLink,
|
|
47
|
+
mapVarDeclsByType: () => import_chunk_BOVSYC7N.mapVarDeclsByType,
|
|
48
|
+
markInvokeClassMethod: () => import_chunk_BOVSYC7N.markInvokeClassMethod,
|
|
49
|
+
parseSdkVersion: () => import_chunk_BOVSYC7N.parseSdkVersion,
|
|
50
|
+
popRootNode: () => import_chunk_BOVSYC7N.popRootNode,
|
|
51
|
+
pushRootNode: () => import_chunk_BOVSYC7N.pushRootNode,
|
|
52
|
+
resolveDiagnostics: () => import_chunk_BOVSYC7N.resolveDiagnostics,
|
|
53
|
+
resolveDiagnosticsMap: () => import_chunk_BOVSYC7N.resolveDiagnosticsMap,
|
|
54
|
+
sameLookupResult: () => import_chunk_BOVSYC7N.sameLookupResult,
|
|
55
|
+
traverseAst: () => import_chunk_UBAYZSM3.traverseAst,
|
|
56
|
+
variableDeclarationName: () => import_chunk_BOVSYC7N.variableDeclarationName,
|
|
57
|
+
visitReferences: () => import_chunk_BOVSYC7N.visitReferences,
|
|
58
|
+
visit_resources: () => import_chunk_BOVSYC7N.visit_resources,
|
|
59
|
+
visitorNode: () => import_chunk_BOVSYC7N.visitorNode
|
|
60
60
|
});
|
|
61
61
|
module.exports = __toCommonJS(api_exports);
|
|
62
|
-
var
|
|
63
|
-
var
|
|
64
|
-
var
|
|
65
|
-
var
|
|
66
|
-
(0,
|
|
62
|
+
var import_chunk_BOVSYC7N = require("./chunk-BOVSYC7N.cjs");
|
|
63
|
+
var import_chunk_KHQPCXSJ = require("./chunk-KHQPCXSJ.cjs");
|
|
64
|
+
var import_chunk_UBAYZSM3 = require("./chunk-UBAYZSM3.cjs");
|
|
65
|
+
var import_chunk_VS2QQHAK = require("./chunk-VS2QQHAK.cjs");
|
|
66
|
+
(0, import_chunk_BOVSYC7N.init_api)();
|
|
67
67
|
// Annotate the CommonJS export names for ESM import in node:
|
|
68
68
|
0 && (module.exports = {
|
|
69
69
|
checkCompilerVersion,
|
package/build/cftinfo.cjs
CHANGED
|
@@ -33,13 +33,13 @@ __export(cftinfo_exports, {
|
|
|
33
33
|
getDeviceFontInfo: () => getDeviceFontInfo
|
|
34
34
|
});
|
|
35
35
|
module.exports = __toCommonJS(cftinfo_exports);
|
|
36
|
-
var
|
|
37
|
-
var
|
|
36
|
+
var import_chunk_UBAYZSM3 = require("./chunk-UBAYZSM3.cjs");
|
|
37
|
+
var import_chunk_VS2QQHAK = require("./chunk-VS2QQHAK.cjs");
|
|
38
38
|
var import_node_assert = __toESM(require("node:assert"));
|
|
39
39
|
var fs = __toESM(require("node:fs/promises"));
|
|
40
40
|
var path = __toESM(require("node:path"));
|
|
41
41
|
var zlib = __toESM(require("node:zlib"));
|
|
42
|
-
(0,
|
|
42
|
+
(0, import_chunk_UBAYZSM3.init_ast)();
|
|
43
43
|
async function getCFTFontInfoFromBuffer(name, data, options) {
|
|
44
44
|
const view = new DataView(data.buffer, data.byteOffset, data.byteLength);
|
|
45
45
|
const glyphFlags = view.getUint8(3);
|
|
@@ -131,8 +131,8 @@ function getDeviceFontInfo(dirname) {
|
|
|
131
131
|
const langMap = {};
|
|
132
132
|
partNumbers.map(
|
|
133
133
|
(part) => part.languages.map((lang) => {
|
|
134
|
-
(0, import_node_assert.default)((0,
|
|
135
|
-
if ((0,
|
|
134
|
+
(0, import_node_assert.default)((0, import_chunk_UBAYZSM3.hasProperty)(fontSets, lang.fontSet));
|
|
135
|
+
if ((0, import_chunk_UBAYZSM3.hasProperty)(langMap, lang.code)) {
|
|
136
136
|
(0, import_node_assert.default)(langMap[lang.code] === lang.fontSet);
|
|
137
137
|
} else {
|
|
138
138
|
langMap[lang.code] = lang.fontSet;
|
|
@@ -194,8 +194,7 @@ function getGlyphAscentDescent(glyphData, glyphOffset, width, height, ascent, al
|
|
|
194
194
|
do {
|
|
195
195
|
const offset = row * byteWidth;
|
|
196
196
|
for (let i = 0; i < bytesToCount; i++) {
|
|
197
|
-
if (glyph.getUint8(offset + i))
|
|
198
|
-
return ascent - row;
|
|
197
|
+
if (glyph.getUint8(offset + i)) return ascent - row;
|
|
199
198
|
}
|
|
200
199
|
} while (++row < ascent);
|
|
201
200
|
return 0;
|
|
@@ -205,8 +204,7 @@ function getGlyphAscentDescent(glyphData, glyphOffset, width, height, ascent, al
|
|
|
205
204
|
while (row-- > ascent) {
|
|
206
205
|
const offset = row * byteWidth;
|
|
207
206
|
for (let i = 0; i < bytesToCount; i++) {
|
|
208
|
-
if (glyph.getUint8(offset + i))
|
|
209
|
-
return row - ascent;
|
|
207
|
+
if (glyph.getUint8(offset + i)) return row - ascent;
|
|
210
208
|
}
|
|
211
209
|
}
|
|
212
210
|
return 0;
|