Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FuncInfo ¶
type FuncInfo struct { HasDefer bool // Flattened map tracks which AST nodes within function body must be // translated into re-enterant blocks. // // Function body needs to be "flattened" if an option to jump an arbitrary // position in the code is required. Typical examples are a "goto" operator or // resuming goroutine execution after a blocking call. Flattened map[ast.Node]bool // Blocking map tracks which AST nodes lead to potentially blocking calls. // // Blocking calls require special handling on JS side to avoid blocking the // event loop and freezing the page. Blocking map[ast.Node]bool // GotoLabel keeps track of labels referenced by a goto operator. // // JS doesn't support "goto" natively and it needs to be emulated with a // switch/case statement. This is distinct from labeled loop statements, which // have native JS syntax and don't require special handling. GotoLabel map[*types.Label]bool // contains filtered or unexported fields }
Click to show internal directories.
Click to hide internal directories.