{% for decorator in function.decorators -%}
{{ '@' -}}{{ decorator -}}{{ '\n' -}}
{% endfor -%}
{% if function.is_async -%}{{ 'async ' -}}{% endif -%}{{ 'def ' -}}{{ function.name -}}{{ '(' -}}
{% if function.type_ignore -%}{{ '  # type: ignore' -}}{% endif -%}
{{ '\n' -}}
{% filter indent(4, True) -%}
    {% for argument in function.arguments -%}
        {% include "common/argument.py.jinja2" with context -%}
        {{ ",\n" if not loop.last else "\n" -}}
    {% endfor -%}
{% endfilter -%}
{{ ') -> ' -}}{{ function.return_type.render() -}}{{ ':\n' -}}
{% filter indent(4, True) -%}
    {% if (not render_docstrings or not function.docstring) and not function.body -%}
        {{ 'pass' -}}
    {% endif -%}
    {% if function.docstring and render_docstrings -%}
        {{ '"""\n' -}}
        {{ function.docstring -}}
        {{ '\n' -}}
        {{ '"""\n' -}}
    {% endif -%}
    {% if function.body -%}
        {{ function.body -}}
        {{ '\n' -}}
    {% endif -%}
{% endfilter -%}
