Difference between revisions of "Source code: cat.pal"
From PROSE Programming Language - Wiki
(Created page with '<pre> % % Reads data from stdin and writes to stdout % ._init func/def [main], &[.main] local/rtn .main error/jmp &[.trap], ![.prose.error.sys.AttributeEmpty] reg/load P0, ![.pr…') |
(Update for 0.7.0) |
||
Line 9: | Line 9: | ||
.main | .main | ||
error/jmp &[.trap], ![.prose.error.sys.AttributeEmpty] | error/jmp &[.trap], ![.prose.error.sys.AttributeEmpty] | ||
− | reg/load P0, ![.prose.io] | + | reg/load P0, ![.prose.sys.io] |
attr/load P1, [psStreamIn], P2, [psStreamOut] | attr/load P1, [psStreamIn], P2, [psStreamOut] | ||
Latest revision as of 11:29, 23 December 2010
% % Reads data from stdin and writes to stdout % ._init func/def [main], &[.main] local/rtn .main error/jmp &[.trap], ![.prose.error.sys.AttributeEmpty] reg/load P0, ![.prose.sys.io] attr/load P1, [psStreamIn], P2, [psStreamOut] .loop attr/direct P0, P2, P0, P1 local/jmp &[.loop] .trap error/clr func/rtn