@markw65/monkeyc-optimizer 1.1.22 → 1.1.23
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/README.md +4 -0
- package/build/api.cjs +33 -33
- package/build/{chunk-563GVBVT.cjs → chunk-27ZJJM2Y.cjs} +5 -5
- package/build/optimizer.cjs +17 -17
- package/build/sdk-util.cjs +14 -14
- package/build/src/readprg/bytecode.d.ts +1 -1
- package/build/worker-thread.cjs +3 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -824,3 +824,7 @@ Bug Fixes
|
|
|
824
824
|
- Handle more bytecodes in interp
|
|
825
825
|
- If an array is initialized to its default value, drop the initializers
|
|
826
826
|
- Add an option to [remove argc bytecodes](https://github.com/markw65/monkeyc-optimizer/wiki/Post-Build-Optimizer#remove-argc)
|
|
827
|
+
|
|
828
|
+
### 1.1.23
|
|
829
|
+
|
|
830
|
+
No functional change, just fixes a typo that broke the typescript exports.
|
package/build/api.cjs
CHANGED
|
@@ -18,42 +18,42 @@ 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
|
-
collectNamespaces: () =>
|
|
23
|
-
createDocumentationMap: () =>
|
|
24
|
-
diagnostic: () =>
|
|
25
|
-
diagnosticHelper: () =>
|
|
26
|
-
findNamesInScope: () =>
|
|
27
|
-
findUsingForNode: () =>
|
|
28
|
-
formatAst: () =>
|
|
29
|
-
formatAstLongLines: () =>
|
|
30
|
-
getApiFunctionInfo: () =>
|
|
31
|
-
getApiMapping: () =>
|
|
32
|
-
getSuperClasses: () =>
|
|
33
|
-
hasProperty: () =>
|
|
34
|
-
isClassVariable: () =>
|
|
35
|
-
isLocal: () =>
|
|
36
|
-
isLookupCandidate: () =>
|
|
37
|
-
isStateNode: () =>
|
|
38
|
-
lookupByFullName: () =>
|
|
39
|
-
lookupNext: () =>
|
|
40
|
-
lookupResultContains: () =>
|
|
41
|
-
lookupWithType: () =>
|
|
42
|
-
makeToyboxLink: () =>
|
|
43
|
-
mapVarDeclsByType: () =>
|
|
44
|
-
markInvokeClassMethod: () =>
|
|
45
|
-
parseSdkVersion: () =>
|
|
46
|
-
sameLookupResult: () =>
|
|
47
|
-
traverseAst: () =>
|
|
48
|
-
variableDeclarationName: () =>
|
|
49
|
-
visitReferences: () =>
|
|
50
|
-
visit_resources: () =>
|
|
51
|
-
visitorNode: () =>
|
|
21
|
+
checkCompilerVersion: () => import_chunk_27ZJJM2Y.checkCompilerVersion,
|
|
22
|
+
collectNamespaces: () => import_chunk_27ZJJM2Y.collectNamespaces,
|
|
23
|
+
createDocumentationMap: () => import_chunk_27ZJJM2Y.createDocumentationMap,
|
|
24
|
+
diagnostic: () => import_chunk_27ZJJM2Y.diagnostic,
|
|
25
|
+
diagnosticHelper: () => import_chunk_27ZJJM2Y.diagnosticHelper,
|
|
26
|
+
findNamesInScope: () => import_chunk_27ZJJM2Y.findNamesInScope,
|
|
27
|
+
findUsingForNode: () => import_chunk_27ZJJM2Y.findUsingForNode,
|
|
28
|
+
formatAst: () => import_chunk_27ZJJM2Y.formatAst,
|
|
29
|
+
formatAstLongLines: () => import_chunk_27ZJJM2Y.formatAstLongLines,
|
|
30
|
+
getApiFunctionInfo: () => import_chunk_27ZJJM2Y.getApiFunctionInfo,
|
|
31
|
+
getApiMapping: () => import_chunk_27ZJJM2Y.getApiMapping,
|
|
32
|
+
getSuperClasses: () => import_chunk_27ZJJM2Y.getSuperClasses,
|
|
33
|
+
hasProperty: () => import_chunk_27ZJJM2Y.hasProperty,
|
|
34
|
+
isClassVariable: () => import_chunk_27ZJJM2Y.isClassVariable,
|
|
35
|
+
isLocal: () => import_chunk_27ZJJM2Y.isLocal,
|
|
36
|
+
isLookupCandidate: () => import_chunk_27ZJJM2Y.isLookupCandidate,
|
|
37
|
+
isStateNode: () => import_chunk_27ZJJM2Y.isStateNode,
|
|
38
|
+
lookupByFullName: () => import_chunk_27ZJJM2Y.lookupByFullName,
|
|
39
|
+
lookupNext: () => import_chunk_27ZJJM2Y.lookupNext,
|
|
40
|
+
lookupResultContains: () => import_chunk_27ZJJM2Y.lookupResultContains,
|
|
41
|
+
lookupWithType: () => import_chunk_27ZJJM2Y.lookupWithType,
|
|
42
|
+
makeToyboxLink: () => import_chunk_27ZJJM2Y.makeToyboxLink,
|
|
43
|
+
mapVarDeclsByType: () => import_chunk_27ZJJM2Y.mapVarDeclsByType,
|
|
44
|
+
markInvokeClassMethod: () => import_chunk_27ZJJM2Y.markInvokeClassMethod,
|
|
45
|
+
parseSdkVersion: () => import_chunk_27ZJJM2Y.parseSdkVersion,
|
|
46
|
+
sameLookupResult: () => import_chunk_27ZJJM2Y.sameLookupResult,
|
|
47
|
+
traverseAst: () => import_chunk_27ZJJM2Y.traverseAst,
|
|
48
|
+
variableDeclarationName: () => import_chunk_27ZJJM2Y.variableDeclarationName,
|
|
49
|
+
visitReferences: () => import_chunk_27ZJJM2Y.visitReferences,
|
|
50
|
+
visit_resources: () => import_chunk_27ZJJM2Y.visit_resources,
|
|
51
|
+
visitorNode: () => import_chunk_27ZJJM2Y.visitorNode
|
|
52
52
|
});
|
|
53
53
|
module.exports = __toCommonJS(api_exports);
|
|
54
|
-
var
|
|
54
|
+
var import_chunk_27ZJJM2Y = require("./chunk-27ZJJM2Y.cjs");
|
|
55
55
|
var import_chunk_HHQDDCTP = require("./chunk-HHQDDCTP.cjs");
|
|
56
|
-
(0,
|
|
56
|
+
(0, import_chunk_27ZJJM2Y.init_api)();
|
|
57
57
|
// Annotate the CommonJS export names for ESM import in node:
|
|
58
58
|
0 && (module.exports = {
|
|
59
59
|
checkCompilerVersion,
|
|
@@ -26,8 +26,8 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
26
26
|
mod
|
|
27
27
|
));
|
|
28
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
var
|
|
30
|
-
__export(
|
|
29
|
+
var chunk_27ZJJM2Y_exports = {};
|
|
30
|
+
__export(chunk_27ZJJM2Y_exports, {
|
|
31
31
|
EnumTagsConst: () => EnumTagsConst,
|
|
32
32
|
LastTypeTag: () => LastTypeTag,
|
|
33
33
|
ObjectLikeTagsConst: () => ObjectLikeTagsConst,
|
|
@@ -125,7 +125,7 @@ __export(chunk_563GVBVT_exports, {
|
|
|
125
125
|
visitorNode: () => visitorNode,
|
|
126
126
|
xml_util_exports: () => xml_util_exports
|
|
127
127
|
});
|
|
128
|
-
module.exports = __toCommonJS(
|
|
128
|
+
module.exports = __toCommonJS(chunk_27ZJJM2Y_exports);
|
|
129
129
|
var import_chunk_HHQDDCTP = require("./chunk-HHQDDCTP.cjs");
|
|
130
130
|
var import_prettier_plugin_monkeyc = require("@markw65/prettier-plugin-monkeyc");
|
|
131
131
|
var import_node_assert = __toESM(require("node:assert"));
|
|
@@ -28914,7 +28914,7 @@ async function generateOneConfig(buildConfig, manifestXML, dependencyFiles, conf
|
|
|
28914
28914
|
const opt_time = await (0, import_chunk_HHQDDCTP.first_modified)(
|
|
28915
28915
|
Object.values(fnMap).map((v) => v.output)
|
|
28916
28916
|
);
|
|
28917
|
-
if (source_time < opt_time &&
|
|
28917
|
+
if (source_time < opt_time && 1680120250138 < opt_time) {
|
|
28918
28918
|
return { hasTests, diagnostics: prevDiagnostics };
|
|
28919
28919
|
}
|
|
28920
28920
|
}
|
|
@@ -28946,7 +28946,7 @@ async function generateOneConfig(buildConfig, manifestXML, dependencyFiles, conf
|
|
|
28946
28946
|
JSON.stringify({
|
|
28947
28947
|
hasTests: hasTests2,
|
|
28948
28948
|
diagnostics,
|
|
28949
|
-
optimizerVersion: "1.1.
|
|
28949
|
+
optimizerVersion: "1.1.23",
|
|
28950
28950
|
...Object.fromEntries(
|
|
28951
28951
|
configOptionsToCheck.map((option) => [option, config[option]])
|
|
28952
28952
|
)
|
package/build/optimizer.cjs
CHANGED
|
@@ -18,27 +18,27 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
var optimizer_exports = {};
|
|
20
20
|
__export(optimizer_exports, {
|
|
21
|
-
StateNodeAttributes: () =>
|
|
22
|
-
buildOptimizedProject: () =>
|
|
21
|
+
StateNodeAttributes: () => import_chunk_27ZJJM2Y.StateNodeAttributes,
|
|
22
|
+
buildOptimizedProject: () => import_chunk_27ZJJM2Y.buildOptimizedProject,
|
|
23
23
|
copyRecursiveAsNeeded: () => import_chunk_HHQDDCTP.copyRecursiveAsNeeded,
|
|
24
|
-
defaultConfig: () =>
|
|
25
|
-
display: () =>
|
|
26
|
-
generateApiMirTests: () =>
|
|
27
|
-
generateOneConfig: () =>
|
|
28
|
-
generateOptimizedProject: () =>
|
|
29
|
-
getConfig: () =>
|
|
30
|
-
getProjectAnalysis: () =>
|
|
31
|
-
get_jungle: () =>
|
|
32
|
-
isErrorWithLocation: () =>
|
|
33
|
-
launchSimulator: () =>
|
|
34
|
-
manifestProducts: () =>
|
|
35
|
-
mctree: () =>
|
|
36
|
-
simulateProgram: () =>
|
|
24
|
+
defaultConfig: () => import_chunk_27ZJJM2Y.defaultConfig,
|
|
25
|
+
display: () => import_chunk_27ZJJM2Y.display,
|
|
26
|
+
generateApiMirTests: () => import_chunk_27ZJJM2Y.generateApiMirTests,
|
|
27
|
+
generateOneConfig: () => import_chunk_27ZJJM2Y.generateOneConfig,
|
|
28
|
+
generateOptimizedProject: () => import_chunk_27ZJJM2Y.generateOptimizedProject,
|
|
29
|
+
getConfig: () => import_chunk_27ZJJM2Y.getConfig,
|
|
30
|
+
getProjectAnalysis: () => import_chunk_27ZJJM2Y.getProjectAnalysis,
|
|
31
|
+
get_jungle: () => import_chunk_27ZJJM2Y.get_jungle,
|
|
32
|
+
isErrorWithLocation: () => import_chunk_27ZJJM2Y.isErrorWithLocation,
|
|
33
|
+
launchSimulator: () => import_chunk_27ZJJM2Y.launchSimulator,
|
|
34
|
+
manifestProducts: () => import_chunk_27ZJJM2Y.manifestProducts,
|
|
35
|
+
mctree: () => import_chunk_27ZJJM2Y.mctree,
|
|
36
|
+
simulateProgram: () => import_chunk_27ZJJM2Y.simulateProgram
|
|
37
37
|
});
|
|
38
38
|
module.exports = __toCommonJS(optimizer_exports);
|
|
39
|
-
var
|
|
39
|
+
var import_chunk_27ZJJM2Y = require("./chunk-27ZJJM2Y.cjs");
|
|
40
40
|
var import_chunk_HHQDDCTP = require("./chunk-HHQDDCTP.cjs");
|
|
41
|
-
(0,
|
|
41
|
+
(0, import_chunk_27ZJJM2Y.init_optimizer)();
|
|
42
42
|
// Annotate the CommonJS export names for ESM import in node:
|
|
43
43
|
0 && (module.exports = {
|
|
44
44
|
StateNodeAttributes,
|
package/build/sdk-util.cjs
CHANGED
|
@@ -18,23 +18,23 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
var sdk_util_exports = {};
|
|
20
20
|
__export(sdk_util_exports, {
|
|
21
|
-
SectionKinds: () =>
|
|
22
|
-
appSupport: () =>
|
|
23
|
-
connectiq: () =>
|
|
24
|
-
getDeviceInfo: () =>
|
|
25
|
-
getFunctionDocumentation: () =>
|
|
26
|
-
getLanguages: () =>
|
|
27
|
-
getSdkPath: () =>
|
|
28
|
-
isWin: () =>
|
|
29
|
-
optimizeProgram: () =>
|
|
30
|
-
readPrg: () =>
|
|
31
|
-
readPrgWithOffsets: () =>
|
|
32
|
-
xmlUtil: () =>
|
|
21
|
+
SectionKinds: () => import_chunk_27ZJJM2Y.SectionKinds,
|
|
22
|
+
appSupport: () => import_chunk_27ZJJM2Y.appSupport,
|
|
23
|
+
connectiq: () => import_chunk_27ZJJM2Y.connectiq,
|
|
24
|
+
getDeviceInfo: () => import_chunk_27ZJJM2Y.getDeviceInfo,
|
|
25
|
+
getFunctionDocumentation: () => import_chunk_27ZJJM2Y.getFunctionDocumentation,
|
|
26
|
+
getLanguages: () => import_chunk_27ZJJM2Y.getLanguages,
|
|
27
|
+
getSdkPath: () => import_chunk_27ZJJM2Y.getSdkPath,
|
|
28
|
+
isWin: () => import_chunk_27ZJJM2Y.isWin,
|
|
29
|
+
optimizeProgram: () => import_chunk_27ZJJM2Y.optimizeProgram,
|
|
30
|
+
readPrg: () => import_chunk_27ZJJM2Y.readPrg,
|
|
31
|
+
readPrgWithOffsets: () => import_chunk_27ZJJM2Y.readPrgWithOffsets,
|
|
32
|
+
xmlUtil: () => import_chunk_27ZJJM2Y.xml_util_exports
|
|
33
33
|
});
|
|
34
34
|
module.exports = __toCommonJS(sdk_util_exports);
|
|
35
|
-
var
|
|
35
|
+
var import_chunk_27ZJJM2Y = require("./chunk-27ZJJM2Y.cjs");
|
|
36
36
|
var import_chunk_HHQDDCTP = require("./chunk-HHQDDCTP.cjs");
|
|
37
|
-
(0,
|
|
37
|
+
(0, import_chunk_27ZJJM2Y.init_sdk_util)();
|
|
38
38
|
// Annotate the CommonJS export names for ESM import in node:
|
|
39
39
|
0 && (module.exports = {
|
|
40
40
|
SectionKinds,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import * as crypto from "node:crypto";
|
|
3
|
-
import { BuildConfig } from "
|
|
3
|
+
import { BuildConfig } from "../optimizer-types";
|
|
4
4
|
import { xmlUtil } from "../sdk-util";
|
|
5
5
|
import { ExceptionEntry, ExceptionsMap } from "./exceptions";
|
|
6
6
|
import { Header } from "./header";
|
package/build/worker-thread.cjs
CHANGED
|
@@ -21,15 +21,15 @@ __export(worker_thread_exports, {
|
|
|
21
21
|
default: () => worker_thread_default
|
|
22
22
|
});
|
|
23
23
|
module.exports = __toCommonJS(worker_thread_exports);
|
|
24
|
-
var
|
|
24
|
+
var import_chunk_27ZJJM2Y = require("./chunk-27ZJJM2Y.cjs");
|
|
25
25
|
var import_chunk_HHQDDCTP = require("./chunk-HHQDDCTP.cjs");
|
|
26
26
|
var import_node_worker_threads = require("node:worker_threads");
|
|
27
27
|
var require_worker_thread = (0, import_chunk_HHQDDCTP.__commonJS)({
|
|
28
28
|
"src/worker-thread.ts"() {
|
|
29
|
-
(0,
|
|
29
|
+
(0, import_chunk_27ZJJM2Y.init_worker_task)();
|
|
30
30
|
if (import_node_worker_threads.parentPort) {
|
|
31
31
|
import_node_worker_threads.parentPort.on("message", async (task) => {
|
|
32
|
-
return import_node_worker_threads.parentPort.postMessage(await (0,
|
|
32
|
+
return import_node_worker_threads.parentPort.postMessage(await (0, import_chunk_27ZJJM2Y.performTask)(task));
|
|
33
33
|
});
|
|
34
34
|
}
|
|
35
35
|
}
|
package/package.json
CHANGED