nevin1@ihlpf.ATT.COM (00704A-Liber) (12/30/87)
HELP!! How does one transmit results of expressions to co-expressions? I know that the example in the Icon book section 13.4.2 no longer works (I think I read about that in the Version 6 docs) and I tried the example given in technical report TR 87-6 (Programming in Icon; Part II -- Programming with Co-Expressions), but when I try to execute it I get run-time error 214 -- recursive co-expression activation. I could probably use a global variable but somehow that doesn't seem elegant. Please e-mail me any sample programs or explanations and I will summarize and post to the net. I am using Version 6.3 under MS-DOS with the LMM/FR executable; I have also tried it under Unix (Icon version 6.0) with the same error message. BTW, does anyone know what's coming up in Version 7?? :-) Here is a copy of the program found in TR 87-6 pp 10-11: global words, lines, writer procedure main() words := create word() lines := create reader() writer := create output() @writer end procedure word() static letters initial letters := &lcase || &ucase while line := @lines do line ? while tab(upto(letters)) do tab(many(&lcase)) @ writer end procedure reader() while read() @ words end procedure output() while write(@words) @&main end Thanks (in advance)!! -- _ __ NEVIN J. LIBER ..!ihnp4!ihlpf!nevin1 (312) 510-6194 ' ) ) "The secret compartment of my ring I fill / / _ , __o ____ with an Underdog super-energy pill." / (_</_\/ <__/ / <_ These are solely MY opinions, not AT&T's, blah blah blah