% This is MAKEPROG.CF.STDOUT as of 02 May 89 %-------------------------------------------------------- % (c) 1988,1989 by J.Schrod. % % Changefile to map terminal output to standard output % assumes terminal output to be unbuffered % @x S 2 program MAKEPROG(@!doc_file,@!change_file,@!prog_file); @y program MAKEPROG(@!output,@!doc_file,@!change_file,@!prog_file); @z @x S 20 is assumed to consist of characters of type |text_char|: @^system dependencies@> @d print(#)==write(term_out,#) {`|print|' means write on the terminal} @d print_ln(#)==write_ln(term_out,#) {`|print|' and then start new line} @d new_line==write_ln(term_out) {start new line} @d print_nl(#)== {print information starting on a new line} begin new_line; print(#); end @= @!term_out:text_file; {the terminal as an output file} @y is assumed to consist of characters of type |text_char|: @^system dependencies@> @d term_out == output {the output file is normaly the terminal} @# @d print(#)==write(term_out,#) {`|print|' means write on the terminal} @d print_ln(#)==write_ln(term_out,#) {`|print|' and then start new line} @d new_line==write_ln(term_out) {start new line} @d print_nl(#)== {print information starting on a new line} begin new_line; print(#); end @z @x S 21 rewrite(term_out,'TTY:'); {send |term_out| output to the terminal} @y do_nothing; {|output| is opened automatically} @z @x S 22 @d update_terminal == break(term_out) {empty the terminal output buffer} @y @d update_terminal == do_nothing {output to |output| is unbuffered} @z