本文整理汇总了C#中Boo.Lang.Compiler.Ast.ExpressionStatement.get_Expression方法的典型用法代码示例。如果您正苦于以下问题:C# ExpressionStatement.get_Expression方法的具体用法?C# ExpressionStatement.get_Expression怎么用?C# ExpressionStatement.get_Expression使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Boo.Lang.Compiler.Ast.ExpressionStatement
的用法示例。
在下文中一共展示了ExpressionStatement.get_Expression方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnExpressionStatement
public override void OnExpressionStatement(ExpressionStatement node)
{
base.OnExpressionStatement(node);
base.EnsureDocumentInitialized(node);
Expression expression = node.get_Expression();
SourceLocation self = base.doc.TokenSourceLocationFollowing(BooExtensions.AsLexicalInfo(expression.get_EndSourceLocation(), null), ";");
if (self != null)
{
node.set_EndSourceLocation(BooExtensions.OffsetedBy(self, 0, -2));
}
}
示例2: OnExpressionStatement
public override void OnExpressionStatement(ExpressionStatement node)
{
this._found = false;
this.Visit(node.get_Expression());
if (this._found)
{
Node node2 = node.get_ParentNode();
BooCodeBuilder builder = this._context.get_CodeBuilder();
Block block = new Block(node.get_LexicalInfo());
block.Add(node);
block.Add(builder.CreateMethodInvocation(this._parent._UnityRuntimeServices_Update, builder.CreateReference(this._iteratorVariable), builder.CreateReference(this._loopVariable)));
node2.Replace(node, block);
}
}