<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def iter_definitions(definitions, operations):
 """ Generate definitions to be converted to swagger schema. """

    # general error schema per errors.py
    for error_schema_class in [ErrorSchema, ErrorContextSchema, SubErrorSchema]:
        yield error_schema_class()

    # add all request and response schemas
    for operation, obj, rule, func in operations:
        yield get_request_schema(func)
        yield get_response_schema(func)