Create a new PreExecutionNode
node.
Create a new RegularExpressionNode
node.
Create a new RequiredParameterNode
node.
Create a new RestParameterNode
node.
Retrieve the value of one of the RegularExpressionFlags
flags.
Marshal
dumps exit locations to the given filename.
Usage:
If --yjit-exit-locations
is passed, a file named “yjit_exit_locations.dump” will automatically be generated.
If you want to collect traces manually, call dump_exit_locations
directly.
Note that calling this in a script will generate stats after the dump is created, so the stats data may include exits from the dump itself.
In a script call:
at_exit do RubyVM::YJIT.dump_exit_locations("my_file.dump") end
Then run the file with the following options:
ruby --yjit --yjit-trace-exits test.rb
Once the code is done running, use Stackprof to read the dump file. See Stackprof documentation for options.
Compile a InterpolatedRegularExpressionNode
node
Dispatch enter and leave events for InterpolatedRegularExpressionNode
nodes and continue walking the tree.
Inspect a InterpolatedRegularExpressionNode
node.
Copy a InterpolatedRegularExpressionNode
node
Create a new ConstantPathOperatorWriteNode
node.
Sets the minimum and maximum supported protocol versions. See min_version=
and max_version=
.
-> { _1 + _2 } ^^^^^^^^^^^^^^
Iterates over strongly connected component in the subgraph reachable from node.
Return value is unspecified.
each_strongly_connected_component_from
doesn’t call tsort_each_node
.
class G include TSort def initialize(g) @g = g end def tsort_each_child(n, &b) @g[n].each(&b) end def tsort_each_node(&b) @g.each_key(&b) end end graph = G.new({1=>[2, 3], 2=>[4], 3=>[2, 4], 4=>[]}) graph.each_strongly_connected_component_from(2) {|scc| p scc } #=> [4] # [2] graph = G.new({1=>[2], 2=>[3, 4], 3=>[2], 4=>[]}) graph.each_strongly_connected_component_from(2) {|scc| p scc } #=> [4] # [2, 3]
Iterates over strongly connected components in a graph. The graph is represented by node and each_child.
node is the first node. each_child should have call
method which takes a node argument and yields for each child node.
Return value is unspecified.
TSort.each_strongly_connected_component_from is a class method and it doesn’t need a class to represent a graph which includes TSort
.
graph = {1=>[2], 2=>[3, 4], 3=>[2], 4=>[]} each_child = lambda {|n, &b| graph[n].each(&b) } TSort.each_strongly_connected_component_from(1, each_child) {|scc| p scc } #=> [4] # [2, 3] # [1]
def foo(bar = 1); end
^^^^^^^
Perform hostname verification following RFC 6125.
This method MUST be called after calling connect
to ensure that the hostname of a remote peer has been verified.
Fetch the start character offset of the value.
Parses a source buffer and returns the AST and the source code comments.
Oldest version we support downgrading to. This is the version that originally ships with the oldest supported patch version of ruby.
The required_ruby_version
constraint for this specification
A fallback is included because when generated, some marshalled specs have it set to nil
.