diff core/src/luan/cmd_line.luan @ 201:27abb3746917

minir git-svn-id: https://luan-java.googlecode.com/svn/trunk@202 21e917c8-12df-6dd8-5cb6-c86387c605b9
author fschmidt@gmail.com <fschmidt@gmail.com@21e917c8-12df-6dd8-5cb6-c86387c605b9>
date Thu, 03 Jul 2014 22:42:44 +0000
parents cf939124461a
children 705d14f4d8ee
line wrap: on
line diff
--- a/core/src/luan/cmd_line.luan	Thu Jul 03 22:22:16 2014 +0000
+++ b/core/src/luan/cmd_line.luan	Thu Jul 03 22:42:44 2014 +0000
@@ -65,8 +65,12 @@
 	for j,v in ipairs(args) do
 		_G.arg[j-i] = v
 	end
-	local main_file = load_file(file)
-	main_file( Table.unpack(_G.arg) )
+	try
+		local main_file = load_file(file)
+		main_file( Table.unpack(_G.arg) )
+	catch e do
+		print(e)
+	end
 end
 if interactive then
 	Debug.debug("> ")