class

Mint::ReferencesTracker

Inherits Reference < Object

This class tracks links between nodes which gets populated during type checking.

A link is stored as a tuple {node, parent} where node depends on the parent. Eventually this forms a graph, which from we can decide what bundles to construct. To do that we track back each node to it's root node(s) through the links.

Async components and deferred code got their on bundles and any other code which is referenced from multiple sources will get their own bundle.

Instance methods

add(node, parent)
Source
bundle?(nodes : Nodes)
Source
bundle?(node : Ast::Node)
Source
calculate

This method calculates bundles from the links.

Source
replace(node, other)
Source
roots(node : Ast::Node) : Nodes

This method recursively determines the roots of the node.

Source

Nested types