# Exercise: Processing File Lines
#
# `file.for-each-line+` processes a file line by line with a quotation.
#
# Stack effect: ( path quot -- )
#
# The quotation receives: ( line status -- continue? )
#   - line: the current line (String)
#   - status: 1 if valid line, 0 at EOF
#   - return: 1 to continue, 0 to stop
#
# Example:
#   "data.txt" [
#       [   # status was true
#           io.write-line   # print the line
#           true            # continue
#       ] [
#           drop false      # stop at EOF
#       ] if
#   ] file.for-each-line+
#
# Your task: Understand line-by-line file processing
# When done, delete the marker line below.

# I AM NOT DONE

: line-processor-takes ( -- String )
    # The quotation for file.for-each-line+ receives what two values?
    # Return "line-and-status"
    ""
;

: test-lines ( -- )
    line-processor-takes
    # Do not edit below this line
    "line-and-status" string.equal? test.assert
;
