cpp2ffi:better function return detection

This commit is contained in:
sonoro1234
2019-11-21 13:11:19 +01:00
parent c09dc063b0
commit e7c5c6b9a1

View File

@@ -342,7 +342,7 @@ local function parseFunction(self,stname,lineorig,namespace)
--skip template
if line:match("template") then return end
local ret = line:match("([^%(%)]+[%*%s])%s?~?[_%w]+%b()")
local ret = line:match("([^%(%):,]+[%*%s])%s?~?[_%w]+%b()")
--local funcname, args = line:match("(~?[_%w]+)%s*(%b())")
local funcname, args, extraconst = line:match("(~?[_%w]+)%s*(%b())(.*)")
extraconst = extraconst:match("const")