Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
lwm1986
roslyn
提交
ff0a3861
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,发现更多精彩内容 >>
未验证
提交
ff0a3861
编写于
8月 20, 2019
作者:
R
Rikki Gibson
提交者:
GitHub
8月 20, 2019
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #38008 from alrz/fix-typo
Fix typo
上级
0ed2256a
3988ed2b
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
28 addition
and
172 deletion
+28
-172
src/Compilers/CSharp/Portable/Parser/LanguageParser.cs
src/Compilers/CSharp/Portable/Parser/LanguageParser.cs
+28
-172
未找到文件。
src/Compilers/CSharp/Portable/Parser/LanguageParser.cs
浏览文件 @
ff0a3861
...
...
@@ -67,7 +67,7 @@ internal enum TerminatorState
IsEndOfFixedStatement
=
1
<<
10
,
IsEndOfTryBlock
=
1
<<
11
,
IsEndOfCatchClause
=
1
<<
12
,
IsEndOfilterClause
=
1
<<
13
,
IsEndOf
F
ilterClause
=
1
<<
13
,
IsEndOfCatchBlock
=
1
<<
14
,
IsEndOfDoWhileExpression
=
1
<<
15
,
IsEndOfForStatementArgument
=
1
<<
16
,
...
...
@@ -90,176 +90,32 @@ private bool IsTerminator()
for
(
int
i
=
1
;
i
<=
LastTerminatorState
;
i
<<=
1
)
{
TerminatorState
isolated
=
_termState
&
(
TerminatorState
)
i
;
if
(
isolated
!=
0
)
{
switch
(
isolated
)
{
case
TerminatorState
.
IsNamespaceMemberStartOrStop
:
if
(
this
.
IsNamespaceMemberStartOrStop
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsAttributeDeclarationTerminator
:
if
(
this
.
IsAttributeDeclarationTerminator
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsPossibleAggregateClauseStartOrStop
:
if
(
this
.
IsPossibleAggregateClauseStartOrStop
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsPossibleMemberStartOrStop
:
if
(
this
.
IsPossibleMemberStartOrStop
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfReturnType
:
if
(
this
.
IsEndOfReturnType
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfParameterList
:
if
(
this
.
IsEndOfParameterList
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfFieldDeclaration
:
if
(
this
.
IsEndOfFieldDeclaration
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsPossibleEndOfVariableDeclaration
:
if
(
this
.
IsPossibleEndOfVariableDeclaration
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfTypeArgumentList
:
if
(
this
.
IsEndOfTypeArgumentList
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsPossibleStatementStartOrStop
:
if
(
this
.
IsPossibleStatementStartOrStop
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfFixedStatement
:
if
(
this
.
IsEndOfFixedStatement
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfTryBlock
:
if
(
this
.
IsEndOfTryBlock
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfCatchClause
:
if
(
this
.
IsEndOfCatchClause
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfilterClause
:
if
(
this
.
IsEndOfFilterClause
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfCatchBlock
:
if
(
this
.
IsEndOfCatchBlock
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfDoWhileExpression
:
if
(
this
.
IsEndOfDoWhileExpression
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfForStatementArgument
:
if
(
this
.
IsEndOfForStatementArgument
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfDeclarationClause
:
if
(
this
.
IsEndOfDeclarationClause
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfArgumentList
:
if
(
this
.
IsEndOfArgumentList
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsSwitchSectionStart
:
if
(
this
.
IsPossibleSwitchSection
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfTypeParameterList
:
if
(
this
.
IsEndOfTypeParameterList
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfMethodSignature
:
if
(
this
.
IsEndOfMethodSignature
())
{
return
true
;
}
break
;
case
TerminatorState
.
IsEndOfNameInExplicitInterface
:
if
(
this
.
IsEndOfNameInExplicitInterface
())
{
return
true
;
}
break
;
}
switch
(
_termState
&
(
TerminatorState
)
i
)
{
case
TerminatorState
.
IsNamespaceMemberStartOrStop
when
this
.
IsNamespaceMemberStartOrStop
():
case
TerminatorState
.
IsAttributeDeclarationTerminator
when
this
.
IsAttributeDeclarationTerminator
():
case
TerminatorState
.
IsPossibleAggregateClauseStartOrStop
when
this
.
IsPossibleAggregateClauseStartOrStop
():
case
TerminatorState
.
IsPossibleMemberStartOrStop
when
this
.
IsPossibleMemberStartOrStop
():
case
TerminatorState
.
IsEndOfReturnType
when
this
.
IsEndOfReturnType
():
case
TerminatorState
.
IsEndOfParameterList
when
this
.
IsEndOfParameterList
():
case
TerminatorState
.
IsEndOfFieldDeclaration
when
this
.
IsEndOfFieldDeclaration
():
case
TerminatorState
.
IsPossibleEndOfVariableDeclaration
when
this
.
IsPossibleEndOfVariableDeclaration
():
case
TerminatorState
.
IsEndOfTypeArgumentList
when
this
.
IsEndOfTypeArgumentList
():
case
TerminatorState
.
IsPossibleStatementStartOrStop
when
this
.
IsPossibleStatementStartOrStop
():
case
TerminatorState
.
IsEndOfFixedStatement
when
this
.
IsEndOfFixedStatement
():
case
TerminatorState
.
IsEndOfTryBlock
when
this
.
IsEndOfTryBlock
():
case
TerminatorState
.
IsEndOfCatchClause
when
this
.
IsEndOfCatchClause
():
case
TerminatorState
.
IsEndOfFilterClause
when
this
.
IsEndOfFilterClause
():
case
TerminatorState
.
IsEndOfCatchBlock
when
this
.
IsEndOfCatchBlock
():
case
TerminatorState
.
IsEndOfDoWhileExpression
when
this
.
IsEndOfDoWhileExpression
():
case
TerminatorState
.
IsEndOfForStatementArgument
when
this
.
IsEndOfForStatementArgument
():
case
TerminatorState
.
IsEndOfDeclarationClause
when
this
.
IsEndOfDeclarationClause
():
case
TerminatorState
.
IsEndOfArgumentList
when
this
.
IsEndOfArgumentList
():
case
TerminatorState
.
IsSwitchSectionStart
when
this
.
IsPossibleSwitchSection
():
case
TerminatorState
.
IsEndOfTypeParameterList
when
this
.
IsEndOfTypeParameterList
():
case
TerminatorState
.
IsEndOfMethodSignature
when
this
.
IsEndOfMethodSignature
():
case
TerminatorState
.
IsEndOfNameInExplicitInterface
when
this
.
IsEndOfNameInExplicitInterface
():
return
true
;
}
}
...
...
@@ -7514,7 +7370,7 @@ private CatchClauseSyntax ParseCatchClause()
whenKeyword
=
AddTrailingSkippedSyntax
(
whenKeyword
,
EatToken
());
}
whenKeyword
=
CheckFeatureAvailability
(
whenKeyword
,
MessageID
.
IDS_FeatureExceptionFilter
);
_termState
|=
TerminatorState
.
IsEndOfilterClause
;
_termState
|=
TerminatorState
.
IsEndOf
F
ilterClause
;
var
openParen
=
this
.
EatToken
(
SyntaxKind
.
OpenParenToken
);
var
filterExpression
=
this
.
ParseExpressionCore
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录