From 57e0ac7e95a55ede7408a36dc7524649bbc8e4c2 Mon Sep 17 00:00:00 2001 From: Rob Hoelz Date: Wed, 4 Sep 2013 11:41:42 +0200 Subject: Add another example of function call without parens Function calls using a table literal as its sole parameter may also omit parentheses --- lua.html.markdown | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lua.html.markdown b/lua.html.markdown index 35d68e9b..9f9fd77b 100644 --- a/lua.html.markdown +++ b/lua.html.markdown @@ -136,6 +136,10 @@ local g; g = function (x) return math.sin(x) end -- Calls with one string param don't need parens: print 'hello' -- Works fine. +-- Calls with one table param don't need parens +-- either (more on tables below): +print {} -- Works fine too. + ---------------------------------------------------- -- 3. Tables. -- cgit v1.2.3