Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
lwm1986
roslyn
提交
641e07aa
R
roslyn
项目概览
lwm1986
/
roslyn
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
roslyn
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
641e07aa
编写于
10月 09, 2017
作者:
A
Ashley Hauck
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Clarify that it's a native invocation, not necessarily native executable
上级
8c49d85e
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
13 addition
and
12 deletion
+13
-12
src/Compilers/Core/MSBuildTask/DotnetHost.cs
src/Compilers/Core/MSBuildTask/DotnetHost.cs
+9
-8
src/Compilers/Core/MSBuildTask/InteractiveCompiler.cs
src/Compilers/Core/MSBuildTask/InteractiveCompiler.cs
+2
-2
src/Compilers/Core/MSBuildTask/ManagedCompiler.cs
src/Compilers/Core/MSBuildTask/ManagedCompiler.cs
+2
-2
未找到文件。
src/Compilers/Core/MSBuildTask/DotnetHost.cs
浏览文件 @
641e07aa
...
...
@@ -12,23 +12,24 @@ internal sealed class DotnetHost
/// <summary>
/// True if this tool is a managed executable, and will be invoked with `dotnet`.
/// False if this executable is being invoked directly.
/// False if this executable is being invoked directly
/// (it may still be a managed executable, but will be invoked directly).
/// </summary>
public
bool
IsManaged
Tool
{
get
;
}
public
bool
IsManaged
Invocation
{
get
;
}
private
DotnetHost
(
string
pathToToolOpt
,
string
commandLineArgs
,
bool
isManaged
Tool
)
private
DotnetHost
(
string
pathToToolOpt
,
string
commandLineArgs
,
bool
isManaged
Invocation
)
{
PathToToolOpt
=
pathToToolOpt
;
CommandLineArgs
=
commandLineArgs
;
IsManaged
Tool
=
isManagedTool
;
IsManaged
Invocation
=
isManagedInvocation
;
}
public
static
DotnetHost
CreateNative
ToolInvocation
(
string
pathToTool
,
string
commandLineArgs
)
public
static
DotnetHost
CreateNative
InvocationTool
(
string
pathToTool
,
string
commandLineArgs
)
{
return
new
DotnetHost
(
pathToTool
,
commandLineArgs
,
isManaged
Tool
:
false
);
return
new
DotnetHost
(
pathToTool
,
commandLineArgs
,
isManaged
Invocation
:
false
);
}
public
static
DotnetHost
CreateManaged
ToolInvocation
(
string
toolName
,
string
commandLineArgs
)
public
static
DotnetHost
CreateManaged
InvocationTool
(
string
toolName
,
string
commandLineArgs
)
{
var
pathToToolOpt
=
Utilities
.
GenerateFullPathToTool
(
toolName
);
// Desktop executes tool directly, only prepend if we're on CLI
...
...
@@ -38,7 +39,7 @@ public static DotnetHost CreateManagedToolInvocation(string toolName, string com
pathToToolOpt
=
pathToDotnet
;
}
return
new
DotnetHost
(
pathToToolOpt
,
commandLineArgs
,
isManaged
Tool
:
true
);
return
new
DotnetHost
(
pathToToolOpt
,
commandLineArgs
,
isManaged
Invocation
:
true
);
}
private
static
bool
IsCliHost
(
out
string
pathToDotnet
)
...
...
src/Compilers/Core/MSBuildTask/InteractiveCompiler.cs
浏览文件 @
641e07aa
...
...
@@ -196,13 +196,13 @@ private DotnetHost DotnetHostInfo
// explicitly overriden - so use it as a native invocation.
if
(
string
.
IsNullOrEmpty
(
ToolPath
)
||
ToolExe
==
ToolName
)
{
_dotnetHostInfo
=
DotnetHost
.
CreateManaged
ToolInvocation
(
ToolName
,
commandLine
);
_dotnetHostInfo
=
DotnetHost
.
CreateManaged
InvocationTool
(
ToolName
,
commandLine
);
}
else
{
// Explicitly provided ToolPath or ToolExe, don't try to
// figure anything out
_dotnetHostInfo
=
DotnetHost
.
CreateNative
ToolInvocation
(
Path
.
Combine
(
ToolPath
,
ToolExe
),
commandLine
);
_dotnetHostInfo
=
DotnetHost
.
CreateNative
InvocationTool
(
Path
.
Combine
(
ToolPath
,
ToolExe
),
commandLine
);
}
}
return
_dotnetHostInfo
;
...
...
src/Compilers/Core/MSBuildTask/ManagedCompiler.cs
浏览文件 @
641e07aa
...
...
@@ -425,13 +425,13 @@ private DotnetHost DotnetHostInfo
// explicitly overriden - so use it as a native invocation.
if
(
string
.
IsNullOrEmpty
(
ToolPath
)
||
ToolExe
==
ToolName
)
{
_dotnetHostInfo
=
DotnetHost
.
CreateManaged
ToolInvocation
(
ToolName
,
commandLine
);
_dotnetHostInfo
=
DotnetHost
.
CreateManaged
InvocationTool
(
ToolName
,
commandLine
);
}
else
{
// Explicitly provided ToolPath or ToolExe, don't try to
// figure anything out
_dotnetHostInfo
=
DotnetHost
.
CreateNative
ToolInvocation
(
Path
.
Combine
(
ToolPath
,
ToolExe
),
commandLine
);
_dotnetHostInfo
=
DotnetHost
.
CreateNative
InvocationTool
(
Path
.
Combine
(
ToolPath
,
ToolExe
),
commandLine
);
}
}
return
_dotnetHostInfo
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录