Skip to content

Commit e20f3f9

Browse files
committed
try catch in progress
1 parent 9392085 commit e20f3f9

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

CodingSeb.ExpressionEvaluator/ExpressionEvaluator.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -831,7 +831,7 @@ void ExecuteIfList()
831831
|| (blockKeywordsWithoutParenthesesBeginningMatch = blockKeywordsWithoutParenthesesBeginningRegex.Match(script.Substring(i))).Success))
832832
{
833833
i += blockKeywordsBeginingMatch.Success ? blockKeywordsBeginingMatch.Length : blockKeywordsWithoutParenthesesBeginningMatch.Length;
834-
string keyword = blockKeywordsBeginingMatch.Success ? blockKeywordsBeginingMatch.Groups["keyword"].Value.Replace(" ", "") : (blockKeywordsWithoutParenthesesBeginningMatch?.Groups["keyword"].Value ?? string.Empty);
834+
string keyword = blockKeywordsBeginingMatch.Success ? blockKeywordsBeginingMatch.Groups["keyword"].Value.Replace(" ", "").Replace("\t", "") : (blockKeywordsWithoutParenthesesBeginningMatch?.Groups["keyword"].Value ?? string.Empty);
835835
List<string> keywordAttributes = blockKeywordsBeginingMatch.Success ? GetExpressionsBetweenParenthis(script, ref i, true, ";") : null;
836836

837837
if (blockKeywordsBeginingMatch.Success)
@@ -909,6 +909,10 @@ void ExecuteIfList()
909909
{
910910
ifElseStatementsList.Add(new List<string>() { keywordAttributes[0], subScript });
911911
ifBlockEvaluatedState = IfBlockEvaluatedState.If;
912+
}
913+
else if(keyword.Equals("try"))
914+
{
915+
912916
}
913917
else if (keyword.Equals("do"))
914918
{

0 commit comments

Comments
 (0)