X-Git-Url: http://git.hcoop.net/jackhill/mal.git/blobdiff_plain/6a0851036753ed412d857d7817bc560379b8f6f2..02936b429afad9ac856bc02657718f63958d62be:/plsql/step9_try.sql

diff --git a/plsql/step9_try.sql b/plsql/step9_try.sql
index ed68f2ef..942bc38a 100644
--- a/plsql/step9_try.sql
+++ b/plsql/step9_try.sql
@@ -20,7 +20,7 @@ FUNCTION MAIN(args varchar DEFAULT '()') RETURN integer IS
     E         env_pkg.env_entry_table;  -- mal env memory pool
     repl_env  integer;
     x         integer;
-    line      varchar2(4000);
+    line      CLOB;
     core_ns   core_ns_type;
     cidx      integer;
     argv      mal_seq_items_type;
@@ -423,18 +423,18 @@ BEGIN
 
     WHILE true LOOP
         BEGIN
-            line := stream_readline('user> ', 0);
-            IF line IS NULL THEN CONTINUE; END IF;
+            line := io.readline('user> ', 0);
+            IF line = EMPTY_CLOB() THEN CONTINUE; END IF;
             IF line IS NOT NULL THEN
-                stream_writeline(REP(line));
+                io.writeline(REP(line));
             END IF;
 
             EXCEPTION WHEN OTHERS THEN
                 IF SQLCODE = -20001 THEN  -- io streams closed
                     RETURN 0;
                 END IF;
-                stream_writeline('Error: ' || SQLERRM);
-                stream_writeline(dbms_utility.format_error_backtrace);
+                io.writeline('Error: ' || SQLERRM);
+                io.writeline(dbms_utility.format_error_backtrace);
         END;
     END LOOP;
 END;
