def interactive_expressions():
    try:
        index = 1
        while True:
            try:
                code = raw_input('%d fora-> ' % index)

                while balance_pos(code) != len(code):
                    code += "\n" + raw_input('%d -----> ' % index)

                yield (code, index)
                index = index + 1
            except UnbalancedException, e:
                print "Error: unbalanced delimiter."
            except __HOLE__:
                #not an error - just a reset indication
                index = index + 1
                print "\n\n\t[Interrupted]\n"

    except EOFError:
        # Not an error; just the end of input.
        print# make sure following output starts on a new line
        return

#TODO BUG brax: fora command-line should leave objects as FORA objects in the repl environment
#
#Otherwise, we get python objects mixed in, which is weird. This is different
#than what we want to happen when we're accessing FORA from python itself.
dataset/ETHPy150Open ufora/ufora/ufora/FORA/python/fora_interpreter.py/interactive_expressions