Input loop: Difference between revisions

Content added Content deleted
No edit summary
Line 1,917: Line 1,917:
=={{header|x86 Assembly}}==
=={{header|x86 Assembly}}==


64 bit (Linux): Compiled with <code>gcc -nostdlib</code>. Memory maps the file and outputs one line at a time. Try <code>./a.out file</code>, <code>./a.out < file</code>, or <code>./a.out <<< "Heredoc"</code>. It's a little like cat, but less functional.
'''GAS, 64 bit (Linux)''': Compiled with <code>gcc -nostdlib</code>. Memory maps the file and outputs one line at a time. Try <code>./a.out file</code>, <code>./a.out < file</code>, or <code>./a.out <<< "Heredoc"</code>. It's a little like cat, but less functional.
<lang x86>#define SYS_WRITE $1
<lang x86>#define SYS_WRITE $1
#define SYS_OPEN $2
#define SYS_OPEN $2