C# 클래스 Jurassic.Compiler.OptimizationInfo

Represents information about one or more code generation optimizations.
파일 보기 프로젝트 열기: paulbartrum/jurassic 1 사용 예제들

공개 메소드들

메소드 설명
EmitLongJump ( ILGenerator generator, ILLabel targetLabel ) : void

Emits code to branch between statements, even if code generation is within a finally block (where unconditional branches are not allowed).

GetBreakTarget ( string labelName = null ) : ILLabel

Returns the break target for the statement with the given label, if one is provided, or the top-most break target otherwise.

GetContinueTarget ( string labelName = null ) : ILLabel

Returns the continue target for the statement with the given label, if one is provided, or the top-most continue target otherwise.

GetRegExpVariable ( ILGenerator generator, Jurassic.Compiler.RegularExpressionLiteral literal ) : ILLocalVariable

Retrieves a variable that can be used to store a shared instance of a regular expression.

MarkSequencePoint ( ILGenerator generator, Jurassic.Compiler.SourceCodeSpan span ) : void

Emits a sequence point, and sets the SourceSpan property.

OptimizationInfo ( ScriptEngine engine ) : System

Creates a new OptimizationInfo instance.

PopBreakOrContinueInfo ( ) : void

Removes the top-most break or continue information from the stack.

PushBreakOrContinueInfo ( IList labelNames, ILLabel breakTarget, ILLabel continueTarget, bool labelledOnly ) : void

Pushes information about break or continue targets to a stack.

비공개 메소드들

메소드 설명
GetBreakOrContinueLabelDepth ( ILLabel label ) : int

Searches for the given label in the break/continue stack.

메소드 상세

EmitLongJump() 공개 메소드

Emits code to branch between statements, even if code generation is within a finally block (where unconditional branches are not allowed).
public EmitLongJump ( ILGenerator generator, ILLabel targetLabel ) : void
generator ILGenerator The generator to output the CIL to.
targetLabel ILLabel The label to jump to.
리턴 void

GetBreakTarget() 공개 메소드

Returns the break target for the statement with the given label, if one is provided, or the top-most break target otherwise.
public GetBreakTarget ( string labelName = null ) : ILLabel
labelName string The label associated with the break target. Can be /// null.
리턴 ILLabel

GetContinueTarget() 공개 메소드

Returns the continue target for the statement with the given label, if one is provided, or the top-most continue target otherwise.
public GetContinueTarget ( string labelName = null ) : ILLabel
labelName string The label associated with the continue target. Can be /// null.
리턴 ILLabel

GetRegExpVariable() 공개 메소드

Retrieves a variable that can be used to store a shared instance of a regular expression.
public GetRegExpVariable ( ILGenerator generator, Jurassic.Compiler.RegularExpressionLiteral literal ) : ILLocalVariable
generator ILGenerator The IL generator used to create the variable.
literal Jurassic.Compiler.RegularExpressionLiteral The regular expression literal.
리턴 ILLocalVariable

MarkSequencePoint() 공개 메소드

Emits a sequence point, and sets the SourceSpan property.
public MarkSequencePoint ( ILGenerator generator, Jurassic.Compiler.SourceCodeSpan span ) : void
generator ILGenerator The IL generator used to emit the sequence point.
span Jurassic.Compiler.SourceCodeSpan The source code span.
리턴 void

OptimizationInfo() 공개 메소드

Creates a new OptimizationInfo instance.
public OptimizationInfo ( ScriptEngine engine ) : System
engine ScriptEngine The associated script engine.
리턴 System

PopBreakOrContinueInfo() 공개 메소드

Removes the top-most break or continue information from the stack.
public PopBreakOrContinueInfo ( ) : void
리턴 void

PushBreakOrContinueInfo() 공개 메소드

Pushes information about break or continue targets to a stack.
public PushBreakOrContinueInfo ( IList labelNames, ILLabel breakTarget, ILLabel continueTarget, bool labelledOnly ) : void
labelNames IList The label names associated with the break or continue target. /// Can be null.
breakTarget ILLabel The IL label to jump to if a break statement is encountered.
continueTarget ILLabel The IL label to jump to if a continue statement is /// encountered. Can be null.
labelledOnly bool true if break or continue statements without a label /// should ignore this entry; false otherwise.
리턴 void