@junoscript/juno 0.0.0-stage → 0.1.2

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.
Files changed (59) hide show
  1. package/Modules/async.ts +81 -0
  2. package/Modules/juno-node-fs.ts +105 -0
  3. package/Modules/juno-test.jn +156 -0
  4. package/dist/CLI/build-juno.d.ts +5 -0
  5. package/dist/CLI/build-juno.js +58 -0
  6. package/dist/CLI/generate-juno-types.d.ts +1 -0
  7. package/dist/CLI/generate-juno-types.js +54 -0
  8. package/dist/CLI/junode.d.ts +2 -0
  9. package/dist/CLI/junode.js +58 -0
  10. package/dist/Lexer/lexer.d.ts +42 -0
  11. package/dist/Lexer/lexer.js +300 -0
  12. package/dist/Lexer/parser.d.ts +403 -0
  13. package/dist/Lexer/parser.js +1930 -0
  14. package/dist/Modules/async.d.ts +33 -0
  15. package/dist/Modules/async.js +76 -0
  16. package/dist/Modules/bytes.d.ts +15 -0
  17. package/dist/Modules/bytes.js +35 -0
  18. package/dist/Modules/index.d.ts +201 -0
  19. package/dist/Modules/index.js +35 -0
  20. package/dist/Modules/juno-node-fs.d.ts +52 -0
  21. package/dist/Modules/juno-node-fs.js +129 -0
  22. package/dist/Modules/juno-node.d.ts +74 -0
  23. package/dist/Modules/juno-node.js +56 -0
  24. package/dist/Modules/juno-test.d.ts +141 -0
  25. package/dist/Modules/juno-test.js +134 -0
  26. package/dist/Modules/juno-types.d.ts +35 -0
  27. package/dist/Modules/juno-types.js +2 -0
  28. package/dist/Modules/juno.d.ts +24 -0
  29. package/dist/Modules/juno.js +84 -0
  30. package/dist/Modules/types.d.ts +61 -0
  31. package/dist/Modules/types.js +95 -0
  32. package/dist/Runtime/interpreter.d.ts +64 -0
  33. package/dist/Runtime/interpreter.js +2630 -0
  34. package/dist/Runtime/resolve-import.d.ts +2 -0
  35. package/dist/Runtime/resolve-import.js +30 -0
  36. package/dist/vscode-junoscript/src/language.d.ts +86 -0
  37. package/dist/vscode-junoscript/src/language.js +4481 -0
  38. package/package.json +20 -4
  39. package/types/array.jn +158 -0
  40. package/types/boolean.jn +18 -0
  41. package/types/error.jn +28 -0
  42. package/types/error.ts +9 -0
  43. package/types/index.jn +11 -0
  44. package/types/iterable.jn +211 -0
  45. package/types/map.jn +44 -0
  46. package/types/map.ts +132 -0
  47. package/types/number.ts +52 -0
  48. package/types/object.jn +94 -0
  49. package/types/object.ts +49 -0
  50. package/types/queue.jn +46 -0
  51. package/types/random.jn +25 -0
  52. package/types/random.ts +1 -0
  53. package/types/range.jn +27 -0
  54. package/types/set.jn +139 -0
  55. package/types/set.ts +209 -0
  56. package/types/string.jn +33 -0
  57. package/types/string.ts +1 -0
  58. package/types/tuple.jn +11 -0
  59. package/README.md +0 -3
@@ -0,0 +1,64 @@
1
+ export declare class Interpreter {
2
+ private readonly globals;
3
+ private currentDirectory;
4
+ private currentFile?;
5
+ private readonly sourceFiles;
6
+ private readonly errorTraces;
7
+ private readonly callStack;
8
+ constructor();
9
+ run(source: string, filePath?: string): void;
10
+ runModule(source: string, filePath: string): Record<string, unknown>;
11
+ private executeStatements;
12
+ private execute;
13
+ private registerTypeDeclarations;
14
+ private loadLocalModule;
15
+ private evaluateSpread;
16
+ private addExpressionFrame;
17
+ private evaluate;
18
+ private evaluateExpression;
19
+ private callFunction;
20
+ private callFunctionAsync;
21
+ private executeStatementsAsync;
22
+ private executeAsync;
23
+ private evaluateAsync;
24
+ private evaluateExpressionAsync;
25
+ private resolveAwaitList;
26
+ private resolveAwaitExpressions;
27
+ private patternBindings;
28
+ private patternTypeNode;
29
+ private matchesPattern;
30
+ private captureStackTrace;
31
+ private toNativeValue;
32
+ private callRuntimeConstructor;
33
+ private toNativeExport;
34
+ private adaptNativeValue;
35
+ private declare;
36
+ private childEnvironment;
37
+ private adaptModule;
38
+ private adaptConsole;
39
+ private toJunoString;
40
+ private defaultToString;
41
+ private installDefaultHas;
42
+ private installCallableMethods;
43
+ private writeTarget;
44
+ private applyCompoundOperator;
45
+ private requireCondition;
46
+ private toBoolean;
47
+ private lookup;
48
+ private typeOf;
49
+ private indexedType;
50
+ private nonNullableType;
51
+ private inferValueType;
52
+ private inferRuntimeValueType;
53
+ private resolveAliasType;
54
+ private instantiateAlias;
55
+ private isCallableType;
56
+ private instantiateUtilityType;
57
+ private literalKeys;
58
+ private matchesTypeNode;
59
+ private applyTypeDefaults;
60
+ private findTypeMember;
61
+ private readMember;
62
+ }
63
+ export declare function runFile(file: string): void;
64
+ export declare function runBuiltModule(source: string, file: string): Record<string, unknown>;