Support for CSDialect
This commit is contained in:
parent
fec912ddac
commit
e152b8ba85
@ -197,6 +197,30 @@
|
||||
]]
|
||||
end
|
||||
|
||||
|
||||
--
|
||||
-- Lang version tests
|
||||
--
|
||||
|
||||
function suite.OnCSVersion()
|
||||
csversion "6"
|
||||
prepare()
|
||||
test.capture [[
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProductVersion>8.0.50727</ProductVersion>
|
||||
<SchemaVersion>2.0</SchemaVersion>
|
||||
<ProjectGuid>{AE61726D-187C-E440-BD07-2556188A6565}</ProjectGuid>
|
||||
<OutputType>Exe</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>MyProject</RootNamespace>
|
||||
<AssemblyName>MyProject</AssemblyName>
|
||||
<LangVersion>6</LangVersion>
|
||||
</PropertyGroup>
|
||||
]]
|
||||
end
|
||||
|
||||
|
||||
--
|
||||
-- Make sure the root namespace can be overridden.
|
||||
|
@ -44,7 +44,8 @@
|
||||
dotnetbase.targetFrameworkProfile,
|
||||
dotnetbase.fileAlignment,
|
||||
dotnetbase.bindingRedirects,
|
||||
dotnetbase.projectTypeGuids
|
||||
dotnetbase.projectTypeGuids,
|
||||
dotnetbase.csversion
|
||||
}
|
||||
end
|
||||
|
||||
|
@ -687,7 +687,6 @@
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
function dotnetbase.targetFrameworkVersion(cfg)
|
||||
local action = p.action.current()
|
||||
local framework = cfg.dotnetframework or action.vstudio.targetFramework
|
||||
@ -696,6 +695,11 @@
|
||||
end
|
||||
end
|
||||
|
||||
function dotnetbase.csversion(cfg)
|
||||
if cfg.csversion then
|
||||
_p(2,'<LangVersion>%s</LangVersion>', cfg.csversion)
|
||||
end
|
||||
end
|
||||
|
||||
function dotnetbase.targetFrameworkProfile(cfg)
|
||||
if _ACTION == "vs2010" then
|
||||
|
@ -590,6 +590,12 @@
|
||||
kind = "string",
|
||||
}
|
||||
|
||||
api.register {
|
||||
name = "csversion",
|
||||
scope = "config",
|
||||
kind = "string",
|
||||
}
|
||||
|
||||
api.register {
|
||||
name = "gccprefix",
|
||||
scope = "config",
|
||||
|
Loading…
Reference in New Issue
Block a user