diff --git a/src/_premake_init.lua b/src/_premake_init.lua index a9d6e657..ea7cc468 100644 --- a/src/_premake_init.lua +++ b/src/_premake_init.lua @@ -483,6 +483,18 @@ } } + api.register { + name = "inlining", + scope = "config", + kind = "string", + allowed = { + "Default", + "Disabled", + "Explicit", + "Auto" + } + } + api.register { name = "callingconvention", scope = "config", diff --git a/src/actions/vstudio/vs2010_vcxproj.lua b/src/actions/vstudio/vs2010_vcxproj.lua index cb7d6cd4..bb71d83f 100644 --- a/src/actions/vstudio/vs2010_vcxproj.lua +++ b/src/actions/vstudio/vs2010_vcxproj.lua @@ -318,6 +318,7 @@ m.bufferSecurityCheck, m.treatWChar_tAsBuiltInType, m.floatingPointModel, + m.inlineFunctionExpansion, m.enableEnhancedInstructionSet, m.multiProcessorCompilation, m.additionalCompileOptions, @@ -1159,6 +1160,17 @@ end end + function m.inlineFunctionExpansion(cfg) + if cfg.inlining then + local types = { + Default = "Default", + Disabled = "Disabled", + Explicit = "OnlyExplicitInline", + Auto = "AnySuitable", + } + p.w('%s', types[cfg.inlining]) + end + end function m.forceIncludes(cfg, condition) if #cfg.forceincludes > 0 then