Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
Signed-off-by: Jade Abraham <[email protected]>
jabraham17 committed Nov 18, 2024
1 parent 369ff61 commit 82766bf
Showing 2 changed files with 9 additions and 3 deletions.
4 changes: 3 additions & 1 deletion tools/chapel-py/src/chapel/__init__.py
Original file line number Diff line number Diff line change
@@ -139,7 +139,9 @@ def get_docstring(node: AstNode, sibling_map: SiblingMap) -> Optional[str]:
return None


def parse_attribute(attr: Attribute, attribute: typing.Tuple[str, typing.Sequence[str]]):
def parse_attribute(
attr: Attribute, attribute: typing.Tuple[str, typing.Sequence[str]]
):
"""
Given an Attribute AST node, and a description of the attribute in
the form (name, formal_names), return a mapping of formal names to their
8 changes: 6 additions & 2 deletions tools/chapel-py/src/chapel/replace/__init__.py
Original file line number Diff line number Diff line change
@@ -100,7 +100,9 @@ def node_indent(self, node: chapel.AstNode) -> int:
return range_start - self.lines[self.lines_back[range_start]]


def rename_formals(rc: ReplacementContext, fn: chapel.Function, renames: typing.Dict[str, str]):
def rename_formals(
rc: ReplacementContext, fn: chapel.Function, renames: typing.Dict[str, str]
):
"""
Helper iterator to be used in finder functions. Given a function
and a map of ('original formal name' -> 'new formal name'), yields
@@ -118,7 +120,9 @@ def name_replacer(name):
yield (child, name_replacer(name))


def rename_named_actuals(rc: ReplacementContext, call: chapel.Call, renames: typing.Dict[str, str]):
def rename_named_actuals(
rc: ReplacementContext, call: chapel.Call, renames: typing.Dict[str, str]
):
"""
Helper iterator to be used in finder functions. Given a function call expression,
and a map of ('original name' -> 'new name'), yields

0 comments on commit 82766bf

Please sign in to comment.