Mercurial Hosting > luan
diff http/src/luan/modules/http/Shell_mod.luan @ 554:18504c41b0be
move debug() to Io and remove Debug module;
Io.print() now doesn't print newline if there is nothing to be printed;
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Thu, 18 Jun 2015 03:30:18 -0600 |
parents | 342964519194 |
children | 2f39468680be |
line wrap: on
line diff
--- a/http/src/luan/modules/http/Shell_mod.luan Thu Jun 18 03:14:07 2015 -0600 +++ b/http/src/luan/modules/http/Shell_mod.luan Thu Jun 18 03:30:18 2015 -0600 @@ -1,10 +1,10 @@ local Luan = require "luan:Luan" -local ipairs = Luan.ipairs -local load = Luan.load -local try = Luan.try +local error = Luan.error +local ipairs = Luan.ipairs or error() +local load = Luan.load or error() +local try = Luan.try or error() local Io = require "luan:Io" -local print = Io.print -local Debug = require "luan:Debug" +local print = Io.print or error() local Http = require "luan:http/Http" local Html = require "luan:Html" @@ -29,7 +29,7 @@ try { function() local line = load(cmd,"<web_shell>",M.env,true) - Debug.print_if_something( line() ) + print( line() ) end; catch = function(e) Io.print_to(Io.stderr,e)