From: John L. <jr...@us...> - 2007-02-07 18:39:47
|
Update of /cvsroot/wxlua/wxLua/bindings In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv4861/wxLua/bindings Modified Files: genwxbind.lua Log Message: Use s_wxluaargArray_None for arg array in bindings if there are no args instead of creating a new empty array for each function, { 0 }. Index: genwxbind.lua =================================================================== RCS file: /cvsroot/wxlua/wxLua/bindings/genwxbind.lua,v retrieving revision 1.95 retrieving revision 1.96 diff -C2 -d -r1.95 -r1.96 *** genwxbind.lua 7 Feb 2007 01:45:02 -0000 1.95 --- genwxbind.lua 7 Feb 2007 18:39:07 -0000 1.96 *************** *** 3448,3451 **** --- 3448,3454 ---- local overload_argListName = "s_wxluatagArray_".. funcName overload_argList = overload_argList.."0 }" + if overload_argList == "{ 0 }" then + overload_argListName = "s_wxluaargArray_None" + end -- add function map only once for the base function name overload *************** *** 4347,4351 **** for i, functionBinding in pairs_sort(functionBindingList) do if functionBinding.Method then ! if functionBinding.ArgArrayName then table.insert(fileData, "static wxLuaArgTag "..functionBinding.ArgArrayName.."[] = "..functionBinding.ArgArray..";\n") end --- 4350,4354 ---- for i, functionBinding in pairs_sort(functionBindingList) do if functionBinding.Method then ! if functionBinding.ArgArrayName and (functionBinding.ArgArrayName ~= "s_wxluaargArray_None") then table.insert(fileData, "static wxLuaArgTag "..functionBinding.ArgArrayName.."[] = "..functionBinding.ArgArray..";\n") end *************** *** 4442,4448 **** for i = 1, #BindTableList do - if BindTableList[i].Method then ! if BindTableList[i].ArgArrayName then table.insert(fileData, "static wxLuaArgTag "..BindTableList[i].ArgArrayName.."[] = "..BindTableList[i].ArgArray..";\n") end --- 4445,4450 ---- for i = 1, #BindTableList do if BindTableList[i].Method then ! if BindTableList[i].ArgArrayName and (BindTableList[i].ArgArrayName ~= "s_wxluaargArray_None") then table.insert(fileData, "static wxLuaArgTag "..BindTableList[i].ArgArrayName.."[] = "..BindTableList[i].ArgArray..";\n") end |