Skip to content

extractRubyControlFlow

reference
1 min readUpdated

Kind: Function

Source: atloria-monorepo/libs/parser-core/src/parsers/backend/ruby-control-flow.ts

Read the guards and handlers out of Ruby source, or out of one method of it.

startLine/endLine are inclusive 1-based file lines, so an action can be read on its own while the reported line numbers stay the file's.

Signature

ts
function extractRubyControlFlow(source: string, startLine, endLine): ControlFlow

Parameters

NameType
sourcestring
startLineany
endLineany

Returns: ControlFlow

Was this page helpful?

Download as PDF