Commit 6fe12ad6 authored by Luke Sandberg's avatar Luke Sandberg

fix return value handling

parent d5978f96
......@@ -824,9 +824,6 @@ trait FunctionLike {
false
}
fn span(&self) -> Span;
fn is_expr_arrow_fn(&self) -> bool {
false
}
}
impl FunctionLike for Function {
......@@ -839,9 +836,6 @@ impl FunctionLike for Function {
fn span(&self) -> Span {
self.span
}
fn is_expr_arrow_fn(&self) -> bool {
false
}
}
impl FunctionLike for ArrowExpr {
fn is_async(&self) -> bool {
......@@ -853,9 +847,6 @@ impl FunctionLike for ArrowExpr {
fn span(&self) -> Span {
self.span
}
fn is_expr_arrow_fn(&self) -> bool {
matches!(*self.body, BlockStmtOrExpr::Expr(_))
}
}
impl FunctionLike for Constructor {
......@@ -958,18 +949,10 @@ mod analyzer_state {
let fn_id = function.span().lo.0;
let prev_fn_id = self.state.cur_fn_id.replace(fn_id);
let prev_return_values = self.state.cur_fn_return_values.replace(vec![]);
let prev_early_return_stack = take(&mut self.early_return_stack);
visitor(self);
let mut return_values = self.state.cur_fn_return_values.take().unwrap();
// If we do not always end with a `return` and the function is not an arrow function
// with a single expression then there is an implicit `undefined` return value
if !self.end_early_return_block() && !function.is_expr_arrow_fn() {
// If the block doesn't end in a return there is an implicit `undefined` return
return_values.push(JsValue::Constant(ConstantValue::Undefined))
}
let return_values = self.state.cur_fn_return_values.take().unwrap();
self.early_return_stack = prev_early_return_stack;
self.state.cur_fn_id = prev_fn_id;
self.state.cur_fn_return_values = prev_return_values;
JsValue::function(
......@@ -977,7 +960,15 @@ mod analyzer_state {
function.is_async(),
function.is_generator(),
match return_values.len() {
0 => JsValue::Constant(ConstantValue::Undefined),
0 => {
// This doesn't really seem possible
debug_assert!(
false,
"Function with no return values and early return handling didn't \
detect it"
);
JsValue::Constant(ConstantValue::Undefined)
}
1 => return_values.into_iter().next().unwrap(),
_ => JsValue::alternatives(return_values),
},
......@@ -1120,7 +1111,11 @@ impl Analyzer<'_> {
{
let mut ast_path = ast_path
.with_guard(AstParentNodeRef::FnExpr(fn_expr, FnExprField::Function));
self.handle_iife_function(function, &mut ast_path, &n.args);
// We don't handle the value of the function here, though we could to better
// model the value of this 'call'
self.enter_fn(&**function, |this| {
this.handle_iife_function(function, &mut ast_path, &n.args);
});
}
true
......@@ -1130,7 +1125,11 @@ impl Analyzer<'_> {
let mut ast_path =
ast_path.with_guard(AstParentNodeRef::Expr(expr, ExprField::Arrow));
let args = &n.args;
self.handle_iife_arrow(arrow_expr, args, &mut ast_path);
// We don't handle the value of the function here, though we could to better
// model the value of this 'call'
self.enter_fn(arrow_expr, |this| {
this.handle_iife_arrow(arrow_expr, args, &mut ast_path);
});
true
}
_ => false,
......@@ -1701,10 +1700,13 @@ impl VisitAstPath for Analyzer<'_> {
) {
let fn_value = self.enter_fn(&*decl.function, |this| {
decl.visit_children_with_ast_path(this, ast_path);
// Take all effects produced by the function and move them to hoisted effects since
// function declarations are hoisted.
this.hoisted_effects.append(&mut this.effects);
});
// Take all effects produced by the function and move them to hoisted effects since
// function declarations are hoisted.
// This accounts for the fact that even with `if (false) { function f() {} }` `f` is
// hoisted out of the condition. so we still need to process effects for it.
// TODO(lukesandberg): shouldn't this just be the effects associated with the function.
self.hoisted_effects.append(&mut self.effects);
self.add_value(decl.ident.to_id(), fn_value);
}
......@@ -2441,7 +2443,9 @@ impl VisitAstPath for Analyzer<'_> {
let mut effects = take(&mut self.effects);
let hoisted_effects = take(&mut self.hoisted_effects);
n.visit_children_with_ast_path(self, ast_path);
self.end_early_return_block();
if !self.end_early_return_block() {
self.add_return_value(JsValue::Constant(ConstantValue::Undefined));
}
self.effects.append(&mut self.hoisted_effects);
effects.append(&mut self.effects);
self.hoisted_effects = hoisted_effects;
......
*anonymous function 170* = (...) => ([file] | undefined)
*anonymous function 170* = (...) => [file]
*anonymous function 254* = (...) => (FreeVar(require)["resolve"](file) | undefined)
*anonymous function 254* = (...) => FreeVar(require)["resolve"](file)
*anonymous function 88* = (...) => (file | undefined)
*anonymous function 88* = (...) => file
a = ["../lib/a.js", "../lib/b.js"]
......@@ -20,4 +20,4 @@ file#5 = arguments[0]
file#6 = arguments[0]
func = (...) => (FreeVar(require)["resolve"](file) | undefined)
func = (...) => FreeVar(require)["resolve"](file)
......@@ -2,88 +2,61 @@
(
"*anonymous function 170*",
Function(
5,
3,
170,
Alternatives {
total_nodes: 4,
values: [
Array {
total_nodes: 2,
items: [
Variable(
(
"file",
#4,
),
),
],
mutable: true,
},
Constant(
Undefined,
Array {
total_nodes: 2,
items: [
Variable(
(
"file",
#4,
),
),
],
logical_property: None,
mutable: true,
},
),
),
(
"*anonymous function 254*",
Function(
7,
5,
254,
Alternatives {
total_nodes: 6,
values: [
MemberCall(
4,
FreeVar(
"require",
),
Constant(
Str(
Atom(
"resolve",
),
),
MemberCall(
4,
FreeVar(
"require",
),
Constant(
Str(
Atom(
"resolve",
),
[
Variable(
(
"file",
#5,
),
),
],
),
Constant(
Undefined,
),
[
Variable(
(
"file",
#5,
),
),
],
logical_property: None,
},
),
),
),
(
"*anonymous function 88*",
Function(
4,
2,
88,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"file",
#3,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"file",
#3,
),
),
),
),
(
......@@ -263,38 +236,29 @@
(
"func",
Function(
7,
5,
308,
Alternatives {
total_nodes: 6,
values: [
MemberCall(
4,
FreeVar(
"require",
),
Constant(
Str(
Atom(
"resolve",
),
),
MemberCall(
4,
FreeVar(
"require",
),
Constant(
Str(
Atom(
"resolve",
),
[
Variable(
(
"file",
#6,
),
),
],
),
Constant(
Undefined,
),
[
Variable(
(
"file",
#6,
),
),
],
logical_property: None,
},
),
),
),
]
0 -> 2 member call = ["../lib/a.js", "../lib/b.js"]["map"]((...) => (file | undefined))
0 -> 2 member call = ["../lib/a.js", "../lib/b.js"]["map"]((...) => file)
2 -> 3 unreachable = ???*0*
- *0* unreachable
⚠️ This value might have side effects
0 -> 5 member call = ["../lib/a.js", "../lib/b.js"]["map"]((...) => ([file] | undefined))
0 -> 5 member call = ["../lib/a.js", "../lib/b.js"]["map"]((...) => [file])
5 -> 6 unreachable = ???*0*
- *0* unreachable
⚠️ This value might have side effects
0 -> 8 member call = ["../lib/a.js", "../lib/b.js"]["map"](
(...) => (FreeVar(require)["resolve"](file) | undefined)
)
0 -> 8 member call = ["../lib/a.js", "../lib/b.js"]["map"]((...) => FreeVar(require)["resolve"](file))
8 -> 10 free var = FreeVar(require)
......
*anonymous function 170* = (...) => ([file] | undefined)
*anonymous function 170* = (...) => [file]
*anonymous function 254* = (...) => (FreeVar(require)["resolve"](file) | undefined)
*anonymous function 254* = (...) => FreeVar(require)["resolve"](file)
*anonymous function 88* = (...) => (file | undefined)
*anonymous function 88* = (...) => file
a = ["../lib/a.js", "../lib/b.js"]
b = [("../lib/a.js" | undefined), ("../lib/b.js" | undefined)]
b = ["../lib/a.js", "../lib/b.js"]
c = [(["../lib/a.js"] | undefined), (["../lib/b.js"] | undefined)]
c = [["../lib/a.js"], ["../lib/b.js"]]
d = [
("\"../lib/a.js\"/resolved/lib/index.js" | undefined),
("\"../lib/b.js\"/resolved/lib/index.js" | undefined)
]
d = ["\"../lib/a.js\"/resolved/lib/index.js", "\"../lib/b.js\"/resolved/lib/index.js"]
file#3 = ???*0*
- *0* arguments[0]
......@@ -31,4 +28,4 @@ file#6 = ???*0*
- *0* arguments[0]
⚠️ function calls are not analysed yet
func = (...) => (FreeVar(require)["resolve"](file) | undefined)
func = (...) => FreeVar(require)["resolve"](file)
*anonymous function 116* = (...) => (3 | undefined)
*anonymous function 116* = (...) => 3
*anonymous function 339* = (...) => (3 | undefined)
*anonymous function 339* = (...) => 3
*arrow function 11* = (...) => 1
......@@ -8,15 +8,15 @@
*arrow function 236* = (...) => 2
*arrow function 259* = (...) => (1 | undefined)
*arrow function 259* = (...) => 1
*arrow function 299* = (...) => (2 | undefined)
*arrow function 299* = (...) => 2
*arrow function 30* = (...) => 2
*arrow function 50* = (...) => (1 | undefined)
*arrow function 50* = (...) => 1
*arrow function 83* = (...) => (2 | undefined)
*arrow function 83* = (...) => 2
a = *arrow function 11*
......@@ -28,7 +28,7 @@ d = *arrow function 83*
e#2 = *anonymous function 116*
e#6 = (...) => (4 | undefined)
e#6 = (...) => 4
f = e
......@@ -42,7 +42,7 @@ xc = *arrow function 259*
xd = *arrow function 299*
xe#12 = (...) => (4 | undefined)
xe#12 = (...) => 4
xe#8 = *anonymous function 339*
......
......@@ -2,47 +2,29 @@
(
"*anonymous function 116*",
Function(
4,
2,
116,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
3.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
3.0,
),
],
logical_property: None,
},
),
),
),
),
(
"*anonymous function 339*",
Function(
4,
2,
339,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
3.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
3.0,
),
],
logical_property: None,
},
),
),
),
),
(
......@@ -90,47 +72,29 @@
(
"*arrow function 259*",
Function(
4,
2,
259,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
1.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
1.0,
),
],
logical_property: None,
},
),
),
),
),
(
"*arrow function 299*",
Function(
4,
2,
299,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
2.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
2.0,
),
],
logical_property: None,
},
),
),
),
),
(
......@@ -150,47 +114,29 @@
(
"*arrow function 50*",
Function(
4,
2,
50,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
1.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
1.0,
),
],
logical_property: None,
},
),
),
),
),
(
"*arrow function 83*",
Function(
4,
2,
83,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
2.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
2.0,
),
],
logical_property: None,
},
),
),
),
),
(
......@@ -241,24 +187,15 @@
(
"e#6",
Function(
4,
2,
155,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
4.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
4.0,
),
],
logical_property: None,
},
),
),
),
),
(
......@@ -319,24 +256,15 @@
(
"xe#12",
Function(
4,
2,
385,
Alternatives {
total_nodes: 3,
values: [
Constant(
Num(
ConstantNumber(
4.0,
),
),
),
Constant(
Undefined,
Constant(
Num(
ConstantNumber(
4.0,
),
],
logical_property: None,
},
),
),
),
),
(
......
*anonymous function 116* = (...) => (3 | undefined)
*anonymous function 116* = (...) => 3
*anonymous function 339* = (...) => (3 | undefined)
*anonymous function 339* = (...) => 3
*arrow function 11* = (...) => 1
......@@ -8,29 +8,29 @@
*arrow function 236* = (...) => 2
*arrow function 259* = (...) => (1 | undefined)
*arrow function 259* = (...) => 1
*arrow function 299* = (...) => (2 | undefined)
*arrow function 299* = (...) => 2
*arrow function 30* = (...) => 2
*arrow function 50* = (...) => (1 | undefined)
*arrow function 50* = (...) => 1
*arrow function 83* = (...) => (2 | undefined)
*arrow function 83* = (...) => 2
a = (...) => 1
b = (...) => 2
c = (...) => (1 | undefined)
c = (...) => 1
d = (...) => (2 | undefined)
d = (...) => 2
e#2 = (...) => (3 | undefined)
e#2 = (...) => 3
e#6 = (...) => (4 | undefined)
e#6 = (...) => 4
f = (...) => (4 | undefined)
f = (...) => 4
x = (...) => undefined
......@@ -38,12 +38,12 @@ xa = (...) => 1
xb = (...) => 2
xc = (...) => (1 | undefined)
xc = (...) => 1
xd = (...) => (2 | undefined)
xd = (...) => 2
xe#12 = (...) => (4 | undefined)
xe#12 = (...) => 4
xe#8 = (...) => (3 | undefined)
xe#8 = (...) => 3
xf = (...) => (4 | undefined)
xf = (...) => 4
computeAsyncValue = (...) => Promise<("async result" | undefined)>
computeAsyncValue = (...) => Promise<"async result">
ensureAsyncProcessStarted = (...) => (lasyInitAsyncProcess | undefined)
ensureAsyncProcessStarted = (...) => lasyInitAsyncProcess
getLasyInitAsyncValue = (...) => (lasyInitAsyncValue | undefined)
getLasyInitAsyncValue = (...) => lasyInitAsyncValue
initLasyInitAsyncProcess = (...) => Promise<undefined>
......
......@@ -2,71 +2,44 @@
(
"computeAsyncValue",
Function(
5,
3,
222,
Promise(
4,
Alternatives {
total_nodes: 3,
values: [
Constant(
Str(
Atom(
"async result",
),
),
),
Constant(
Undefined,
2,
Constant(
Str(
Atom(
"async result",
),
],
logical_property: None,
},
),
),
),
),
),
(
"ensureAsyncProcessStarted",
Function(
4,
2,
606,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"lasyInitAsyncProcess",
#2,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"lasyInitAsyncProcess",
#2,
),
),
),
),
(
"getLasyInitAsyncValue",
Function(
4,
2,
294,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"lasyInitAsyncValue",
#2,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"lasyInitAsyncValue",
#2,
),
),
),
),
(
......
......@@ -2,9 +2,9 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 2 conditional = !((null | Promise<("async result" | undefined)>))
0 -> 2 conditional = !((null | Promise<"async result">))
2 -> 3 call = (...) => Promise<("async result" | undefined)>()
2 -> 3 call = (...) => Promise<"async result">()
0 -> 4 unreachable = ???*0*
- *0* unreachable
......
computeAsyncValue = (...) => Promise<("async result" | undefined)>
computeAsyncValue = (...) => Promise<"async result">
ensureAsyncProcessStarted = (...) => (lasyInitAsyncProcess | undefined)
ensureAsyncProcessStarted = (...) => lasyInitAsyncProcess
getLasyInitAsyncValue = (...) => (lasyInitAsyncValue | undefined)
getLasyInitAsyncValue = (...) => lasyInitAsyncValue
initLasyInitAsyncProcess = (...) => Promise<undefined>
lasyInitAsyncProcess = (null | Promise<undefined>)
lasyInitAsyncValue = (null | Promise<("async result" | undefined)>)
lasyInitAsyncValue = (null | Promise<"async result">)
*arrow function 105* = (...) => (value2 | undefined)
*arrow function 105* = (...) => value2
Fun = (...) => (value | undefined)
Fun = (...) => value
Fun2 = *arrow function 105*
......
......@@ -2,45 +2,27 @@
(
"*arrow function 105*",
Function(
4,
2,
105,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"value2",
#4,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"value2",
#4,
),
),
),
),
(
"Fun",
Function(
4,
2,
39,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"value",
#3,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"value",
#3,
),
),
),
),
(
......
*arrow function 105* = (...) => (value2 | undefined)
*arrow function 105* = (...) => value2
Fun = (...) => (value | undefined)
Fun = (...) => value
Fun2 = (...) => (value2 | undefined)
Fun2 = (...) => value2
value = (???*0* | module<./module.js, {}>["named"])
- *0* ???*1*["value"]
......
......@@ -14,9 +14,9 @@ g = (...) => undefined
h = (...) => undefined
i = (...) => (FreeVar(i1)() | FreeVar(i2)() | undefined)
i = (...) => (FreeVar(i1)() | FreeVar(i2)())
j#2 = (...) => (FreeVar(i1)() | FreeVar(i2)() | undefined)
j#2 = (...) => (FreeVar(i1)() | FreeVar(i2)())
j#25 = arguments[0]
......
......@@ -82,10 +82,10 @@
(
"i",
Function(
7,
6,
606,
Alternatives {
total_nodes: 6,
total_nodes: 5,
values: [
Call(
2,
......@@ -101,9 +101,6 @@
),
[],
),
Constant(
Undefined,
),
],
logical_property: None,
},
......@@ -112,10 +109,10 @@
(
"j#2",
Function(
7,
6,
673,
Alternatives {
total_nodes: 6,
total_nodes: 5,
values: [
Call(
2,
......@@ -131,9 +128,6 @@
),
[],
),
Constant(
Undefined,
),
],
logical_property: None,
},
......
......@@ -14,9 +14,9 @@ g = (...) => undefined
h = (...) => undefined
i = (...) => (FreeVar(i1)() | FreeVar(i2)() | undefined)
i = (...) => (FreeVar(i1)() | FreeVar(i2)())
j#2 = (...) => (FreeVar(i1)() | FreeVar(i2)() | undefined)
j#2 = (...) => (FreeVar(i1)() | FreeVar(i2)())
j#25 = ???*0*
- *0* arguments[0]
......
......@@ -6,7 +6,7 @@ e = ???*0*
- *0* e
⚠️ pattern without value
generateBinPath = (...) => (binPath | undefined)
generateBinPath = (...) => binPath
knownWindowsPackages = {
"win32 arm64 LE": "esbuild-windows-arm64",
......@@ -24,7 +24,7 @@ pkg#3 = (???*0* | knownWindowsPackages[FreeVar(platformKey)])
pkg#4 = pkgAndSubpathForCurrentPlatform()["pkg"]
pkgAndSubpathForCurrentPlatform = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)
pkgAndSubpathForCurrentPlatform = (...) => {"pkg": pkg, "subpath": subpath}
subpath#3 = (???*0* | "esbuild.exe")
- *0* subpath
......
......@@ -77,23 +77,14 @@
(
"generateBinPath",
Function(
4,
2,
387,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"binPath",
#4,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"binPath",
#4,
),
),
),
),
(
......@@ -248,52 +239,43 @@
(
"pkgAndSubpathForCurrentPlatform",
Function(
8,
6,
217,
Alternatives {
total_nodes: 7,
values: [
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"pkg",
),
),
),
Variable(
(
"pkg",
#3,
),
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"pkg",
),
),
KeyValue(
Constant(
Str(
Atom(
"subpath",
),
),
),
Variable(
(
"subpath",
#3,
),
),
Variable(
(
"pkg",
#3,
),
),
),
KeyValue(
Constant(
Str(
Atom(
"subpath",
),
),
],
mutable: true,
},
Constant(
Undefined,
),
Variable(
(
"subpath",
#3,
),
),
),
],
logical_property: None,
mutable: true,
},
),
),
......
0 -> 1 call = (...) => (binPath | undefined)()
0 -> 1 call = (...) => binPath()
0 -> 2 free var = FreeVar(require)
......@@ -16,20 +16,12 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 9 call = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)()
0 -> 9 call = (...) => {"pkg": pkg, "subpath": subpath}()
0 -> 11 free var = FreeVar(require)
0 -> 12 member call = require*0*["resolve"](
`${(
| ???*1*
| "esbuild-windows-arm64"
| "esbuild-windows-32"
| "esbuild-windows-64"
| ???*2*
| ???*4*
| undefined["pkg"]
)}/${(???*5* | "esbuild.exe" | ???*6* | undefined["subpath"])}`
`${(???*1* | "esbuild-windows-arm64" | "esbuild-windows-32" | "esbuild-windows-64" | ???*2* | ???*4*)}/${(???*5* | "esbuild.exe" | ???*6*)}`
)
- *0* require: The require method from CommonJS
- *1* pkg
......
......@@ -2,15 +2,7 @@ binPath = (???*0* | ???*1*)
- *0* binPath
⚠️ pattern without value
- *1* require.resolve*2*(
`${(
| ???*3*
| "esbuild-windows-arm64"
| "esbuild-windows-32"
| "esbuild-windows-64"
| ???*4*
| ???*6*
| undefined["pkg"]
)}/${(???*7* | "esbuild.exe" | ???*8* | undefined["subpath"])}`
`${(???*3* | "esbuild-windows-arm64" | "esbuild-windows-32" | "esbuild-windows-64" | ???*4* | ???*6*)}/${(???*7* | "esbuild.exe" | ???*8*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
......@@ -34,7 +26,7 @@ e = ???*0*
- *0* e
⚠️ pattern without value
generateBinPath = (...) => (binPath | undefined)
generateBinPath = (...) => binPath
knownWindowsPackages = {
"win32 arm64 LE": "esbuild-windows-arm64",
......@@ -58,15 +50,7 @@ pkg#3 = (???*0* | "esbuild-windows-arm64" | "esbuild-windows-32" | "esbuild-wind
⚠️ unknown global
⚠️ This value might have side effects
pkg#4 = (
| ???*0*
| "esbuild-windows-arm64"
| "esbuild-windows-32"
| "esbuild-windows-64"
| ???*1*
| ???*3*
| undefined["pkg"]
)
pkg#4 = (???*0* | "esbuild-windows-arm64" | "esbuild-windows-32" | "esbuild-windows-64" | ???*1* | ???*3*)
- *0* pkg
⚠️ pattern without value
- *1* {}[???*2*]
......@@ -78,31 +62,23 @@ pkg#4 = (
- *3* unknown mutation
⚠️ This value might have side effects
pkgAndSubpathForCurrentPlatform = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)
pkgAndSubpathForCurrentPlatform = (...) => {"pkg": pkg, "subpath": subpath}
subpath#3 = (???*0* | "esbuild.exe")
- *0* subpath
⚠️ pattern without value
subpath#4 = (???*0* | "esbuild.exe" | ???*1* | undefined["subpath"])
subpath#4 = (???*0* | "esbuild.exe" | ???*1*)
- *0* subpath
⚠️ pattern without value
- *1* unknown mutation
⚠️ This value might have side effects
x = (???*0* | ???*1* | undefined)
x = (???*0* | ???*1*)
- *0* binPath
⚠️ pattern without value
- *1* require.resolve*2*(
`${(
| ???*3*
| "esbuild-windows-arm64"
| "esbuild-windows-32"
| "esbuild-windows-64"
| ???*4*
| ???*6*
| undefined["pkg"]
)}/${(???*7* | "esbuild.exe" | ???*8* | undefined["subpath"])}`
`${(???*3* | "esbuild-windows-arm64" | "esbuild-windows-32" | "esbuild-windows-64" | ???*4* | ???*6*)}/${(???*7* | "esbuild.exe" | ???*8*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
......
......@@ -6,7 +6,6 @@
]
]
| [generateBinPath(), []]
| undefined
)
args = esbuildCommandAndArgs()[1]
......@@ -35,7 +34,7 @@ esbuildCommandAndArgs = *arrow function 2666*
esbuildLibDir = path["dirname"](FreeVar(require)["resolve"]("esbuild"))
generateBinPath = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath | undefined)
generateBinPath = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath)
isYarnPnP = (false | true)
......@@ -75,7 +74,7 @@ pkg#3 = (???*0* | knownWindowsPackages[platformKey] | knownUnixlikePackages[plat
pkg#7 = pkgAndSubpathForCurrentPlatform()["pkg"]
pkgAndSubpathForCurrentPlatform = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)
pkgAndSubpathForCurrentPlatform = (...) => {"pkg": pkg, "subpath": subpath}
platformKey = `${FreeVar(process)["platform"]} ${os["arch"]()} ${os["endianness"]()}`
......
......@@ -2,10 +2,10 @@
(
"*arrow function 2666*",
Function(
17,
16,
2666,
Alternatives {
total_nodes: 16,
total_nodes: 15,
values: [
Array {
total_nodes: 10,
......@@ -89,9 +89,6 @@
],
mutable: true,
},
Constant(
Undefined,
),
],
logical_property: None,
},
......@@ -384,10 +381,10 @@
(
"generateBinPath",
Function(
6,
5,
1409,
Alternatives {
total_nodes: 5,
total_nodes: 4,
values: [
FreeVar(
"ESBUILD_BINARY_PATH",
......@@ -404,9 +401,6 @@
#7,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
......@@ -864,52 +858,43 @@
(
"pkgAndSubpathForCurrentPlatform",
Function(
8,
6,
911,
Alternatives {
total_nodes: 7,
values: [
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"pkg",
),
),
),
Variable(
(
"pkg",
#3,
),
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"pkg",
),
),
KeyValue(
Constant(
Str(
Atom(
"subpath",
),
),
),
Variable(
(
"subpath",
#3,
),
),
Variable(
(
"pkg",
#3,
),
),
),
KeyValue(
Constant(
Str(
Atom(
"subpath",
),
),
],
mutable: true,
},
Constant(
Undefined,
),
Variable(
(
"subpath",
#3,
),
),
),
],
logical_property: None,
mutable: true,
},
),
),
......
......@@ -51,7 +51,7 @@
- *0* unreachable
⚠️ This value might have side effects
12 -> 17 call = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath | undefined)()
12 -> 17 call = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath)()
12 -> 18 unreachable = ???*0*
- *0* unreachable
......@@ -65,10 +65,9 @@
]
]
| [generateBinPath(), []]
| undefined
)()
0 -> 21 member call = (["bin/esbuild"] | ???*0* | [] | undefined[1])["concat"]("--service=0.14.12", "--ping")
0 -> 21 member call = (["bin/esbuild"] | ???*0* | [])["concat"]("--service=0.14.12", "--ping")
- *0* unknown mutation
⚠️ This value might have side effects
......@@ -119,12 +118,12 @@
- *0* unreachable
⚠️ This value might have side effects
40 -> 43 call = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)()
40 -> 43 call = (...) => {"pkg": pkg, "subpath": subpath}()
40 -> 45 free var = FreeVar(require)
40 -> 46 member call = require*0*["resolve"](
`${(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])}/${(???*3* | "esbuild.exe" | "bin/esbuild" | ???*4* | undefined["subpath"])}`
`${(???*1* | undefined | ???*2* | "esbuild-linux-64")}/${(???*3* | "esbuild.exe" | "bin/esbuild" | ???*4*)}`
)
- *0* require: The require method from CommonJS
- *1* pkg
......@@ -139,8 +138,8 @@
40 -> 47 free var = FreeVar(downloadedBinPath)
40 -> 48 call = ???*0*(
(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"]),
(???*3* | "esbuild.exe" | "bin/esbuild" | ???*4* | undefined["subpath"])
(???*1* | undefined | ???*2* | "esbuild-linux-64"),
(???*3* | "esbuild.exe" | "bin/esbuild" | ???*4*)
)
- *0* FreeVar(downloadedBinPath)
⚠️ unknown global
......@@ -163,7 +162,7 @@
- *1* binPath
⚠️ pattern without value
- *2* require.resolve*3*(
`${(???*4* | undefined | ???*5* | "esbuild-linux-64" | undefined["pkg"])}/${(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7* | undefined["subpath"])}`
`${(???*4* | undefined | ???*5* | "esbuild-linux-64")}/${(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
......@@ -193,9 +192,7 @@
52 -> 54 free var = FreeVar(require)
52 -> 55 member call = require*0*["resolve"](
(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])
)
52 -> 55 member call = require*0*["resolve"]((???*1* | undefined | ???*2* | "esbuild-linux-64"))
- *0* require: The require method from CommonJS
- *1* pkg
⚠️ pattern without value
......@@ -205,7 +202,7 @@
52 -> 56 free var = FreeVar(Error)
52 -> 57 call = new ???*0*(
`The package "${(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])}" could not be found, and is needed by esbuild.
`The package "${(???*1* | undefined | ???*2* | "esbuild-linux-64")}" could not be found, and is needed by esbuild.
If you are installing esbuild with npm, make sure that you don't specify the
"--no-optional" flag. The "optionalDependencies" package.json feature is used
......@@ -234,9 +231,7 @@ by esbuild to install the correct binary executable for your current platform.`
60 -> 65 member call = path*0*["dirname"]("\"esbuild\"/resolved/lib/index.js")
- *0* path: The Node.js path module: https://nodejs.org/api/path.html
60 -> 68 member call = path*0*["basename"](
(???*1* | "esbuild.exe" | "bin/esbuild" | ???*2* | undefined["subpath"])
)
60 -> 68 member call = path*0*["basename"]((???*1* | "esbuild.exe" | "bin/esbuild" | ???*2*))
- *0* path: The Node.js path module: https://nodejs.org/api/path.html
- *1* subpath
⚠️ pattern without value
......@@ -245,16 +240,14 @@ by esbuild to install the correct binary executable for your current platform.`
60 -> 69 member call = path*0*["join"](
"\"esbuild\"/resolved/lib",
`pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])}-${???*3*}`
`pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64")}-${???*3*}`
)
- *0* path: The Node.js path module: https://nodejs.org/api/path.html
- *1* pkg
⚠️ pattern without value
- *2* unknown mutation
⚠️ This value might have side effects
- *3* ???*4*(
(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7* | undefined["subpath"])
)
- *3* ???*4*((???*6* | "esbuild.exe" | "bin/esbuild" | ???*7*))
⚠️ unknown callee
⚠️ This value might have side effects
- *4* path*5*["basename"]
......@@ -269,7 +262,7 @@ by esbuild to install the correct binary executable for your current platform.`
60 -> 71 free var = FreeVar(fs)
60 -> 72 member call = ???*0*["existsSync"](
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])}-${???*3*}`
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64")}-${???*3*}`
)
- *0* FreeVar(fs)
⚠️ unknown global
......@@ -278,9 +271,7 @@ by esbuild to install the correct binary executable for your current platform.`
⚠️ pattern without value
- *2* unknown mutation
⚠️ This value might have side effects
- *3* ???*4*(
(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7* | undefined["subpath"])
)
- *3* ???*4*((???*6* | "esbuild.exe" | "bin/esbuild" | ???*7*))
⚠️ unknown callee
⚠️ This value might have side effects
- *4* path*5*["basename"]
......@@ -304,7 +295,7 @@ by esbuild to install the correct binary executable for your current platform.`
73 -> 76 member call = ???*0*["copyFileSync"](
(???*1* | ???*2* | ???*8*),
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*10* | undefined | ???*11* | "esbuild-linux-64" | undefined["pkg"])}-${???*12*}`
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*10* | undefined | ???*11* | "esbuild-linux-64")}-${???*12*}`
)
- *0* FreeVar(fs)
⚠️ unknown global
......@@ -312,7 +303,7 @@ by esbuild to install the correct binary executable for your current platform.`
- *1* binPath
⚠️ pattern without value
- *2* require.resolve*3*(
`${(???*4* | undefined | ???*5* | "esbuild-linux-64" | undefined["pkg"])}/${(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7* | undefined["subpath"])}`
`${(???*4* | undefined | ???*5* | "esbuild-linux-64")}/${(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
......@@ -336,7 +327,7 @@ by esbuild to install the correct binary executable for your current platform.`
- *11* unknown mutation
⚠️ This value might have side effects
- *12* ???*13*(
(???*15* | "esbuild.exe" | "bin/esbuild" | ???*16* | undefined["subpath"])
(???*15* | "esbuild.exe" | "bin/esbuild" | ???*16*)
)
⚠️ unknown callee
⚠️ This value might have side effects
......@@ -352,7 +343,7 @@ by esbuild to install the correct binary executable for your current platform.`
73 -> 78 free var = FreeVar(fs)
73 -> 79 member call = ???*0*["chmodSync"](
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64" | undefined["pkg"])}-${???*3*}`,
`"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*1* | undefined | ???*2* | "esbuild-linux-64")}-${???*3*}`,
493
)
- *0* FreeVar(fs)
......@@ -362,9 +353,7 @@ by esbuild to install the correct binary executable for your current platform.`
⚠️ pattern without value
- *2* unknown mutation
⚠️ This value might have side effects
- *3* ???*4*(
(???*6* | "esbuild.exe" | "bin/esbuild" | ???*7* | undefined["subpath"])
)
- *3* ???*4*((???*6* | "esbuild.exe" | "bin/esbuild" | ???*7*))
⚠️ unknown callee
⚠️ This value might have side effects
- *4* path*5*["basename"]
......
......@@ -6,10 +6,9 @@
]
]
| [generateBinPath(), []]
| undefined
)
args = (["bin/esbuild"] | ???*0* | [] | undefined[1])
args = (["bin/esbuild"] | ???*0* | [])
- *0* unknown mutation
⚠️ This value might have side effects
......@@ -17,7 +16,7 @@ binPath = (???*0* | ???*1* | ???*7*)
- *0* binPath
⚠️ pattern without value
- *1* require.resolve*2*(
`${(???*3* | undefined | ???*4* | "esbuild-linux-64" | undefined["pkg"])}/${(???*5* | "esbuild.exe" | "bin/esbuild" | ???*6* | undefined["subpath"])}`
`${(???*3* | undefined | ???*4* | "esbuild-linux-64")}/${(???*5* | "esbuild.exe" | "bin/esbuild" | ???*6*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
......@@ -37,14 +36,12 @@ binPath = (???*0* | ???*1* | ???*7*)
⚠️ unknown global
⚠️ This value might have side effects
binTargetPath = `"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*0* | undefined | ???*1* | "esbuild-linux-64" | undefined["pkg"])}-${???*2*}`
binTargetPath = `"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*0* | undefined | ???*1* | "esbuild-linux-64")}-${???*2*}`
- *0* pkg
⚠️ pattern without value
- *1* unknown mutation
⚠️ This value might have side effects
- *2* ???*3*(
(???*5* | "esbuild.exe" | "bin/esbuild" | ???*6* | undefined["subpath"])
)
- *2* ???*3*((???*5* | "esbuild.exe" | "bin/esbuild" | ???*6*))
⚠️ unknown callee
⚠️ This value might have side effects
- *3* path*4*["basename"]
......@@ -56,8 +53,56 @@ binTargetPath = `"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*0* | undefined
- *6* unknown mutation
⚠️ This value might have side effects
command = ???*0*
- *0* max number of linking steps reached
command = (
| "node"
| ???*0*
| ???*1*
| `"esbuild"/resolved/lib${("/" | "")}pnpapi-${(???*2* | undefined | ???*3* | "esbuild-linux-64")}-${???*4*}`
| ???*9*
| ???*10*
| ???*16*
)
- *0* unknown mutation
⚠️ This value might have side effects
- *1* FreeVar(ESBUILD_BINARY_PATH)
⚠️ unknown global
⚠️ This value might have side effects
- *2* pkg
⚠️ pattern without value
- *3* unknown mutation
⚠️ This value might have side effects
- *4* ???*5*((???*7* | "esbuild.exe" | "bin/esbuild" | ???*8*))
⚠️ unknown callee
⚠️ This value might have side effects
- *5* path*6*["basename"]
⚠️ unsupported property on Node.js path module
⚠️ This value might have side effects
- *6* path: The Node.js path module: https://nodejs.org/api/path.html
- *7* subpath
⚠️ pattern without value
- *8* unknown mutation
⚠️ This value might have side effects
- *9* binPath
⚠️ pattern without value
- *10* require.resolve*11*(
`${(???*12* | undefined | ???*13* | "esbuild-linux-64")}/${(???*14* | "esbuild.exe" | "bin/esbuild" | ???*15*)}`
)
⚠️ require.resolve non constant
⚠️ This value might have side effects
- *11* require.resolve: The require.resolve method from CommonJS
- *12* pkg
⚠️ pattern without value
- *13* unknown mutation
⚠️ This value might have side effects
- *14* subpath
⚠️ pattern without value
- *15* unknown mutation
⚠️ This value might have side effects
- *16* ???*17*(pkg, subpath)
⚠️ unknown callee
⚠️ This value might have side effects
- *17* FreeVar(downloadedBinPath)
⚠️ unknown global
⚠️ This value might have side effects
e#10 = ???*0*
......@@ -76,12 +121,11 @@ esbuildCommandAndArgs = (...) => (
]
]
| [generateBinPath(), []]
| undefined
)
esbuildLibDir = "\"esbuild\"/resolved/lib"
generateBinPath = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath | undefined)
generateBinPath = (...) => (FreeVar(ESBUILD_BINARY_PATH) | binTargetPath | binPath)
isYarnPnP = (false | true)
......@@ -124,13 +168,13 @@ pkg#3 = (???*0* | undefined | ???*1* | "esbuild-linux-64")
- *1* unknown mutation
⚠️ This value might have side effects
pkg#7 = (???*0* | undefined | ???*1* | "esbuild-linux-64" | undefined["pkg"])
pkg#7 = (???*0* | undefined | ???*1* | "esbuild-linux-64")
- *0* pkg
⚠️ pattern without value
- *1* unknown mutation
⚠️ This value might have side effects
pkgAndSubpathForCurrentPlatform = (...) => ({"pkg": pkg, "subpath": subpath} | undefined)
pkgAndSubpathForCurrentPlatform = (...) => {"pkg": pkg, "subpath": subpath}
platformKey = "linux x64 LE"
......@@ -138,12 +182,15 @@ subpath#3 = (???*0* | "esbuild.exe" | "bin/esbuild")
- *0* subpath
⚠️ pattern without value
subpath#7 = (???*0* | "esbuild.exe" | "bin/esbuild" | ???*1* | undefined["subpath"])
subpath#7 = (???*0* | "esbuild.exe" | "bin/esbuild" | ???*1*)
- *0* subpath
⚠️ pattern without value
- *1* unknown mutation
⚠️ This value might have side effects
x = ???*0*
- *0* max number of linking steps reached
x = (["bin/esbuild", "--service=0.14.12", "--ping"] | ???*0* | ["--service=0.14.12", "--ping"])
- *0* ???*1*["concat"]("--service=0.14.12", "--ping")
⚠️ unknown callee object
⚠️ This value might have side effects
- *1* unknown mutation
⚠️ This value might have side effects
......@@ -2,7 +2,7 @@ a = arguments[0]
b = arguments[1]
c = (...) => ([`${a}${x}`, a] | undefined)
c = (...) => [`${a}${x}`, a]
d = c("1", "2")
......
......@@ -16,45 +16,36 @@
(
"c",
Function(
8,
6,
1,
Alternatives {
total_nodes: 7,
values: [
Array {
total_nodes: 5,
items: [
Concat(
3,
[
Variable(
(
"a",
#3,
),
),
Variable(
(
"x",
#3,
),
),
],
),
Array {
total_nodes: 5,
items: [
Concat(
3,
[
Variable(
(
"a",
#3,
),
),
Variable(
(
"x",
#3,
),
),
],
mutable: true,
},
Constant(
Undefined,
),
Variable(
(
"a",
#3,
),
),
],
logical_property: None,
mutable: true,
},
),
),
......
0 -> 1 call = (...) => ([`${a}${x}`, a] | undefined)("1", "2")
0 -> 1 call = (...) => [`${a}${x}`, a]("1", "2")
0 -> 2 unreachable = ???*0*
- *0* unreachable
......
......@@ -6,15 +6,15 @@ b = ???*0*
- *0* arguments[1]
⚠️ function calls are not analysed yet
c = (...) => ([`${a}${x}`, a] | undefined)
c = (...) => [`${a}${x}`, a]
d = (["12", "1"] | undefined)
d = ["12", "1"]
e = ("12" | ???*0* | undefined[0])
e = ("12" | ???*0*)
- *0* unknown mutation
⚠️ This value might have side effects
f = ("1" | ???*0* | undefined[1])
f = ("1" | ???*0*)
- *0* unknown mutation
⚠️ This value might have side effects
......
......@@ -2,7 +2,7 @@ a = arguments[0]
b = arguments[1]
c = (...) => ([`${a}${b}`, a] | undefined)
c = (...) => [`${a}${b}`, a]
d = c("1", "2")
......
......@@ -16,45 +16,36 @@
(
"c",
Function(
8,
6,
1,
Alternatives {
total_nodes: 7,
values: [
Array {
total_nodes: 5,
items: [
Concat(
3,
[
Variable(
(
"a",
#3,
),
),
Variable(
(
"b",
#3,
),
),
],
),
Array {
total_nodes: 5,
items: [
Concat(
3,
[
Variable(
(
"a",
#3,
),
),
Variable(
(
"b",
#3,
),
),
],
mutable: true,
},
Constant(
Undefined,
),
Variable(
(
"a",
#3,
),
),
],
logical_property: None,
mutable: true,
},
),
),
......
0 -> 1 call = (...) => ([`${a}${b}`, a] | undefined)("1", "2")
0 -> 1 call = (...) => [`${a}${b}`, a]("1", "2")
0 -> 2 unreachable = ???*0*
- *0* unreachable
......
......@@ -6,14 +6,14 @@ b = ???*0*
- *0* arguments[1]
⚠️ function calls are not analysed yet
c = (...) => ([`${a}${b}`, a] | undefined)
c = (...) => [`${a}${b}`, a]
d = (["12", "1"] | undefined)
d = ["12", "1"]
e = ("12" | ???*0* | undefined[0])
e = ("12" | ???*0*)
- *0* unknown mutation
⚠️ This value might have side effects
f = ("1" | ???*0* | undefined[1])
f = ("1" | ???*0*)
- *0* unknown mutation
⚠️ This value might have side effects
_ = (...) => (parent | undefined)
_ = (...) => parent
i = (0 | ???*0*)
- *0* updated with update expression
......
......@@ -2,23 +2,14 @@
(
"_",
Function(
4,
2,
17,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"parent",
#4,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"parent",
#4,
),
),
),
),
(
......
......@@ -24,7 +24,7 @@
- *0* arguments[1]
⚠️ function calls are not analysed yet
0 -> 14 call = (...) => (parent | undefined)(???*0*, (???*2* ? ???*3* : (???*10* | undefined)), (???*15* | {}){truthy})
0 -> 14 call = (...) => parent(???*0*, (???*2* ? ???*3* : (???*10* | undefined)), (???*15* | {}){truthy})
- *0* ???*1*[key]
⚠️ unknown object
- *1* arguments[0]
......@@ -68,4 +68,4 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 16 call = (...) => (parent | undefined)({"wrapper": {"data": {"key": {}}}}, "", {})
0 -> 16 call = (...) => parent({"wrapper": {"data": {"key": {}}}}, "", {})
_ = (...) => (parent | undefined)
_ = (...) => parent
i = (0 | ???*0*)
- *0* updated with update expression
......
......@@ -8,12 +8,9 @@ HelloWorld = ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
Home = (...) => (
| module<https://esm.sh/preact/jsx-runtime, {}>["jsx"](
"button",
{"onClick": *arrow function 362*, "children": "Click me"}
)
| undefined
Home = (...) => module<https://esm.sh/preact/jsx-runtime, {}>["jsx"](
"button",
{"onClick": *arrow function 362*, "children": "Click me"}
)
cb = arguments[0]
......
......@@ -61,84 +61,75 @@
(
"Home",
Function(
13,
11,
227,
Alternatives {
total_nodes: 12,
values: [
Call(
10,
Member(
3,
Module(
ModuleValue {
module: "https://esm.sh/preact/jsx-runtime",
annotations: ImportAnnotations {
map: {},
},
},
Call(
10,
Member(
3,
Module(
ModuleValue {
module: "https://esm.sh/preact/jsx-runtime",
annotations: ImportAnnotations {
map: {},
},
},
),
Constant(
Str(
Atom(
"jsx",
),
Constant(
Str(
Atom(
"jsx",
),
),
),
),
),
[
Constant(
Str(
Atom(
"button",
),
),
[
Constant(
Str(
Atom(
"button",
),
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"onClick",
),
),
),
Variable(
(
"*arrow function 362*",
#0,
),
),
),
Object {
total_nodes: 5,
parts: [
KeyValue(
Constant(
Str(
Atom(
"onClick",
),
),
),
Variable(
(
"*arrow function 362*",
#0,
),
KeyValue(
Constant(
Str(
Atom(
"children",
),
),
KeyValue(
Constant(
Str(
Atom(
"children",
),
),
),
Constant(
Str(
Atom(
"Click me",
),
),
),
Constant(
Str(
Atom(
"Click me",
),
),
],
mutable: true,
},
),
),
],
),
Constant(
Undefined,
),
mutable: true,
},
],
logical_property: None,
},
),
),
),
(
......
......@@ -8,12 +8,9 @@ HelloWorld = ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
Home = (...) => (
| module<https://esm.sh/preact/jsx-runtime, {}>["jsx"](
"button",
{"onClick": *arrow function 362*, "children": "Click me"}
)
| undefined
Home = (...) => module<https://esm.sh/preact/jsx-runtime, {}>["jsx"](
"button",
{"onClick": *arrow function 362*, "children": "Click me"}
)
cb = ???*0*
......
runGetClassesOrUseCache = (...) => ("value a" | "value b" | undefined)
runGetClassesOrUseCache = (...) => ("value a" | "value b")
......@@ -2,10 +2,10 @@
(
"runGetClassesOrUseCache",
Function(
5,
4,
52,
Alternatives {
total_nodes: 4,
total_nodes: 3,
values: [
Constant(
Str(
......@@ -21,9 +21,6 @@
),
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
......
runGetClassesOrUseCache = (...) => ("value a" | "value b" | undefined)
runGetClassesOrUseCache = (...) => ("value a" | "value b")
*arrow function 19* = (...) => false
run = (...) => ("should not run" | "should run" | undefined)
run = (...) => ("should not run" | "should run")
shouldRun = *arrow function 19*
......
......@@ -12,10 +12,10 @@
(
"run",
Function(
5,
4,
48,
Alternatives {
total_nodes: 4,
total_nodes: 3,
values: [
Constant(
Str(
......@@ -31,9 +31,6 @@
),
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
......
*arrow function 19* = (...) => false
run = (...) => ("should not run" | "should run" | undefined)
run = (...) => ("should not run" | "should run")
shouldRun = (...) => false
......
......@@ -74,18 +74,15 @@ i = (???*0* | 0 | (i + 16))
len = arguments[1]
md5cmn = (...) => (
| FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)
| undefined
md5cmn = (...) => FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)
md5ff = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ff = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -115,7 +112,7 @@ t#5 = arguments[5]
t#6 = arguments[6]
wordsToMd5 = (...) => ([a, b, c, d] | undefined)
wordsToMd5 = (...) => [a, b, c, d]
x#3 = arguments[0]
......
......@@ -2,7 +2,7 @@
0 -> 3 free var = FreeVar(md5)
0 -> 8 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, ???*7*)
0 -> 8 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -20,7 +20,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 10 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
0 -> 10 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -38,7 +38,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 12 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, 606105819)
0 -> 12 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, 606105819)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -54,7 +54,7 @@
- *6* arguments[0]
⚠️ function calls are not analysed yet
0 -> 14 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
0 -> 14 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -72,7 +72,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 16 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, ???*7*)
0 -> 16 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -90,7 +90,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 18 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, 1200080426)
0 -> 18 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, 1200080426)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -106,7 +106,7 @@
- *6* arguments[0]
⚠️ function calls are not analysed yet
0 -> 20 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
0 -> 20 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -124,7 +124,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 22 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
0 -> 22 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -142,7 +142,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 24 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, 1770035416)
0 -> 24 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, 1770035416)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -158,7 +158,7 @@
- *6* arguments[0]
⚠️ function calls are not analysed yet
0 -> 26 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
0 -> 26 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -176,7 +176,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 28 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
0 -> 28 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -194,7 +194,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 30 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
0 -> 30 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -212,7 +212,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 32 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, 1804603682)
0 -> 32 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 7, 1804603682)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -228,7 +228,7 @@
- *6* arguments[0]
⚠️ function calls are not analysed yet
0 -> 34 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
0 -> 34 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 12, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -246,7 +246,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 36 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
0 -> 36 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 17, ???*7*)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -264,7 +264,7 @@
- *7* unsupported expression
⚠️ This value might have side effects
0 -> 38 call = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, 1236535329)
0 -> 38 call = (...) => md5cmn(???*0*, a, b, x, s, t)(???*1*, ???*2*, ???*3*, ???*4*, ???*5*, 22, 1236535329)
- *0* unsupported expression
⚠️ This value might have side effects
- *1* max number of linking steps reached
......@@ -362,15 +362,12 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 51 call = (...) => (
| FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)
| undefined
0 -> 51 call = (...) => FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)(???*0*, ???*1*, ???*2*, ???*3*, ???*4*, ???*5*)
- *0* unsupported expression
⚠️ This value might have side effects
......
......@@ -48,18 +48,15 @@ len = ???*0*
- *0* arguments[1]
⚠️ function calls are not analysed yet
md5cmn = (...) => (
| FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)
| undefined
md5cmn = (...) => FreeVar(safeAdd)(
FreeVar(bitRotateLeft)(
FreeVar(safeAdd)(FreeVar(safeAdd)(a, q), FreeVar(safeAdd)(x, t)),
s
),
b
)
md5ff = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ff = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -99,7 +96,7 @@ t#6 = ???*0*
- *0* arguments[6]
⚠️ function calls are not analysed yet
wordsToMd5 = (...) => ([a, b, c, d] | undefined)
wordsToMd5 = (...) => [a, b, c, d]
x#3 = ???*0*
- *0* arguments[0]
......
......@@ -106,13 +106,13 @@ b#7 = (
- *12* unsupported expression
⚠️ This value might have side effects
bitRotateLeft = (...) => (???*0* | undefined)
bitRotateLeft = (...) => ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
bytes = (arguments[0] | new FreeVar(Array)(msg["length"]))
bytesToWords = (...) => (output | undefined)
bytesToWords = (...) => output
c#15 = arguments[2]
......@@ -272,36 +272,30 @@ lsw = (???*0* + ???*1*)
- *1* unsupported expression
⚠️ This value might have side effects
md5 = (...) => (
| md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), ???*0*))
| undefined
)
md5 = (...) => md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), ???*0*))
- *0* unsupported expression
⚠️ This value might have side effects
md5ToHexEncodedArray = (...) => (output | undefined)
md5ToHexEncodedArray = (...) => output
md5cmn = (...) => (
| safeAdd(
bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s),
b
)
| undefined
md5cmn = (...) => safeAdd(
bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s),
b
)
md5ff = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ff = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5gg = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5gg = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5hh = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5hh = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5ii = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ii = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -352,7 +346,7 @@ s#17 = arguments[5]
s#18 = arguments[5]
safeAdd = (...) => (???*0* | undefined)
safeAdd = (...) => ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -366,7 +360,7 @@ t#17 = arguments[6]
t#18 = arguments[6]
wordsToMd5 = (...) => ([a, b, c, d] | undefined)
wordsToMd5 = (...) => [a, b, c, d]
x#12 = arguments[0]
......
......@@ -46,7 +46,7 @@ b#7 = ???*0*
- *0* max number of linking steps reached
⚠️ This value might have side effects
bitRotateLeft = (...) => (???*0* | undefined)
bitRotateLeft = (...) => ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -66,7 +66,7 @@ bytes = (???*0* | new ???*1*((???*2* | undefined["length"])))
⚠️ unknown global
⚠️ This value might have side effects
bytesToWords = (...) => (output | undefined)
bytesToWords = (...) => output
c#15 = ???*0*
- *0* arguments[2]
......@@ -181,36 +181,30 @@ lsw = (???*0* + ???*1*)
- *1* unsupported expression
⚠️ This value might have side effects
md5 = (...) => (
| md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), ???*0*))
| undefined
)
md5 = (...) => md5ToHexEncodedArray(wordsToMd5(bytesToWords(bytes), ???*0*))
- *0* unsupported expression
⚠️ This value might have side effects
md5ToHexEncodedArray = (...) => (output | undefined)
md5ToHexEncodedArray = (...) => output
md5cmn = (...) => (
| safeAdd(
bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s),
b
)
| undefined
md5cmn = (...) => safeAdd(
bitRotateLeft(safeAdd(safeAdd(a, q), safeAdd(x, t)), s),
b
)
md5ff = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ff = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5gg = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5gg = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5hh = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5hh = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
md5ii = (...) => (md5cmn(???*0*, a, b, x, s, t) | undefined)
md5ii = (...) => md5cmn(???*0*, a, b, x, s, t)
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -278,7 +272,7 @@ s#18 = ???*0*
- *0* arguments[5]
⚠️ function calls are not analysed yet
safeAdd = (...) => (???*0* | undefined)
safeAdd = (...) => ???*0*
- *0* unsupported expression
⚠️ This value might have side effects
......@@ -302,7 +296,7 @@ t#18 = ???*0*
- *0* arguments[6]
⚠️ function calls are not analysed yet
wordsToMd5 = (...) => ([a, b, c, d] | undefined)
wordsToMd5 = (...) => [a, b, c, d]
x#12 = ???*0*
- *0* arguments[0]
......
*anonymous function 181* = (...) => (crypt["endian"]([a, b, c, d]) | undefined)
*anonymous function 181* = (...) => crypt["endian"]([a, b, c, d])
*anonymous function 5013* = (...) => ((???*0* + b) | undefined)
*anonymous function 5013* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5163* = (...) => ((???*0* + b) | undefined)
*anonymous function 5163* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5313* = (...) => ((???*0* + b) | undefined)
*anonymous function 5313* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5454* = (...) => ((???*0* + b) | undefined)
*anonymous function 5454* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5685* = (...) => (
| ((options && options["asBytes"]) ? digestbytes : ((options && options["asString"]) ? bin["bytesToString"](digestbytes) : crypt["bytesToHex"](digestbytes)))
| undefined
)
*anonymous function 5685* = (...) => ((options && options["asBytes"]) ? digestbytes : ((options && options["asString"]) ? bin["bytesToString"](digestbytes) : crypt["bytesToHex"](digestbytes)))
FF = md5["_ff"]
......
*anonymous function 181* = (...) => (crypt["endian"]([a, b, c, d]) | undefined)
*anonymous function 181* = (...) => crypt["endian"]([a, b, c, d])
*anonymous function 5013* = (...) => ((???*0* + b) | undefined)
*anonymous function 5013* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5163* = (...) => ((???*0* + b) | undefined)
*anonymous function 5163* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5313* = (...) => ((???*0* + b) | undefined)
*anonymous function 5313* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5454* = (...) => ((???*0* + b) | undefined)
*anonymous function 5454* = (...) => (???*0* + b)
- *0* unsupported expression
⚠️ This value might have side effects
*anonymous function 5685* = (...) => (
| ((options && options["asBytes"]) ? digestbytes : ((options && options["asString"]) ? bin["bytesToString"](digestbytes) : crypt["bytesToHex"](digestbytes)))
| undefined
)
*anonymous function 5685* = (...) => ((options && options["asBytes"]) ? digestbytes : ((options && options["asString"]) ? bin["bytesToString"](digestbytes) : crypt["bytesToHex"](digestbytes)))
FF = (...) => (crypt["endian"]([a, b, c, d]) | undefined)["_ff"]
FF = (...) => crypt["endian"]([a, b, c, d])["_ff"]
GG = (...) => (crypt["endian"]([a, b, c, d]) | undefined)["_gg"]
GG = (...) => crypt["endian"]([a, b, c, d])["_gg"]
HH = (...) => (crypt["endian"]([a, b, c, d]) | undefined)["_hh"]
HH = (...) => crypt["endian"]([a, b, c, d])["_hh"]
II = (...) => (crypt["endian"]([a, b, c, d]) | undefined)["_ii"]
II = (...) => crypt["endian"]([a, b, c, d])["_ii"]
a#10 = ???*0*
- *0* arguments[0]
......@@ -165,7 +162,7 @@ m = module<crypt, {}>["bytesToWords"]((???*0* | ???*1* | ???*3*))
⚠️ unknown global
⚠️ This value might have side effects
md5 = (...) => (crypt["endian"]([a, b, c, d]) | undefined)
md5 = (...) => crypt["endian"]([a, b, c, d])
message#11 = ???*0*
- *0* arguments[0]
......
......@@ -8,11 +8,11 @@ b#10 = arguments[0]
b#5 = arguments[0]
inner = (...) => ((a + b) | undefined)
inner = (...) => (a + b)
outer = (...) => (inner("b") | undefined)
outer = (...) => inner("b")
r = (...) => (a | (r((a + 1)) + 1) | undefined)
r = (...) => (a | (r((a + 1)) + 1))
v1 = x(1)(2)
......@@ -20,6 +20,6 @@ v2 = r(2)
v3 = outer("a")
x = (...) => (y | undefined)
x = (...) => y
y = (...) => ((a + b) | undefined)
y = (...) => (a + b)
......@@ -37,77 +37,59 @@
(
"inner",
Function(
6,
4,
219,
Alternatives {
total_nodes: 5,
values: [
Add(
3,
[
Variable(
(
"a",
#9,
),
),
Variable(
(
"b",
#10,
),
),
],
Add(
3,
[
Variable(
(
"a",
#9,
),
),
Constant(
Undefined,
Variable(
(
"b",
#10,
),
),
],
logical_property: None,
},
),
),
),
(
"outer",
Function(
6,
4,
197,
Alternatives {
total_nodes: 5,
values: [
Call(
3,
Variable(
(
"inner",
#9,
),
),
[
Constant(
Str(
Atom(
"b",
),
),
),
],
Call(
3,
Variable(
(
"inner",
#9,
),
),
[
Constant(
Undefined,
Str(
Atom(
"b",
),
),
),
],
logical_property: None,
},
),
),
),
(
"r",
Function(
11,
10,
87,
Alternatives {
total_nodes: 10,
total_nodes: 9,
values: [
Variable(
(
......@@ -156,9 +138,6 @@
),
],
),
Constant(
Undefined,
),
],
logical_property: None,
},
......@@ -242,56 +221,38 @@
(
"x",
Function(
4,
2,
1,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"y",
#4,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"y",
#4,
),
),
),
),
(
"y",
Function(
6,
4,
26,
Alternatives {
total_nodes: 5,
values: [
Add(
3,
[
Variable(
(
"a",
#3,
),
),
Variable(
(
"b",
#5,
),
),
],
Add(
3,
[
Variable(
(
"a",
#3,
),
),
Constant(
Undefined,
Variable(
(
"b",
#5,
),
),
],
logical_property: None,
},
),
),
),
]
0 -> 1 call = (...) => (inner("b") | undefined)("a")
0 -> 1 call = (...) => inner("b")("a")
0 -> 2 unreachable = ???*0*
- *0* unreachable
......@@ -8,9 +8,9 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 4 call = (...) => (y | undefined)(1)
0 -> 4 call = (...) => y(1)
0 -> 5 call = ((...) => ((a + b) | undefined) | undefined)(2)
0 -> 5 call = (...) => (a + b)(2)
0 -> 6 conditional = (???*0* === 0)
- *0* unsupported expression
......@@ -20,7 +20,7 @@
- *0* unreachable
⚠️ This value might have side effects
6 -> 8 call = (...) => (a | (r((a + 1)) + 1) | undefined)((???*0* + 1))
6 -> 8 call = (...) => (a | (r((a + 1)) + 1))((???*0* + 1))
- *0* arguments[0]
⚠️ function calls are not analysed yet
......@@ -32,9 +32,9 @@
- *0* unreachable
⚠️ This value might have side effects
0 -> 11 call = (...) => (a | (r((a + 1)) + 1) | undefined)(2)
0 -> 11 call = (...) => (a | (r((a + 1)) + 1))(2)
0 -> 12 call = (...) => ((a + b) | undefined)("b")
0 -> 12 call = (...) => (a + b)("b")
0 -> 13 unreachable = ???*0*
- *0* unreachable
......
......@@ -18,23 +18,23 @@ b#5 = ???*0*
- *0* arguments[0]
⚠️ function calls are not analysed yet
inner = (...) => ((a + b) | undefined)
inner = (...) => (a + b)
outer = (...) => (inner("b") | undefined)
outer = (...) => inner("b")
r = (...) => (a | (r((a + 1)) + 1) | undefined)
r = (...) => (a | (r((a + 1)) + 1))
v1 = ???*0*
- *0* ((...) => ((a + b) | undefined) | undefined)(2)
⚠️ non-function callee
v1 = (???*0* + 2)
- *0* arguments[0]
⚠️ function calls are not analysed yet
v2 = (2 | (???*0* + 1) | undefined)
- *0* (...) => (a | (r((a + 1)) + 1) | undefined)(3)
v2 = (2 | (???*0* + 1))
- *0* (...) => (a | (r((a + 1)) + 1))(3)
⚠️ recursive function call
⚠️ This value might have side effects
v3 = (`ab` | undefined)
v3 = `ab`
x = (...) => (y | undefined)
x = (...) => y
y = (...) => ((a + b) | undefined)
y = (...) => (a + b)
......@@ -12,7 +12,7 @@ clientComponentLoadTimes = (0 | (clientComponentLoadTimes + ???*0*))
- *0* unsupported expression
⚠️ This value might have side effects
getClientComponentLoaderMetrics = (...) => (metrics | undefined)
getClientComponentLoaderMetrics = (...) => metrics
metrics = ((clientComponentLoadTimes === 0) ? undefined : {
"clientComponentLoadTimes": clientComponentLoadTimes
......@@ -24,4 +24,4 @@ options = ???*0*
startTime = FreeVar(performance)["now"]()
wrapClientComponentLoader = (...) => ({"loadChunk": *arrow function 173*} | undefined)
wrapClientComponentLoader = (...) => {"loadChunk": *arrow function 173*}
......@@ -77,23 +77,14 @@
(
"getClientComponentLoaderMetrics",
Function(
4,
2,
415,
Alternatives {
total_nodes: 3,
values: [
Variable(
(
"metrics",
#7,
),
),
Constant(
Undefined,
),
],
logical_property: None,
},
Variable(
(
"metrics",
#7,
),
),
),
),
(
......@@ -178,37 +169,28 @@
(
"wrapClientComponentLoader",
Function(
6,
4,
95,
Alternatives {
total_nodes: 5,
values: [
Object {
total_nodes: 3,
parts: [
KeyValue(
Constant(
Str(
Atom(
"loadChunk",
),
),
),
Variable(
(
"*arrow function 173*",
#0,
),
Object {
total_nodes: 3,
parts: [
KeyValue(
Constant(
Str(
Atom(
"loadChunk",
),
),
],
mutable: true,
},
Constant(
Undefined,
),
Variable(
(
"*arrow function 173*",
#0,
),
),
),
],
logical_property: None,
mutable: true,
},
),
),
......
......@@ -2,7 +2,7 @@ a = context["resolve"]("./a")
context = FreeVar(require)["context"]("./test", false, /\.test\.js$/)
importAll = (...) => (r["keys"]()["map"](r) | undefined)
importAll = (...) => r["keys"]()["map"](r)
items = importAll(context)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment