internal void AddJump(BlockEndOpcode jumpTo) { bool flag = base.IsReachableFromConditional(); if (flag) { base.prev.DelinkFromConditional(this); } if (this.jump == null) { this.jump = jumpTo; } else { BranchOpcode jump; if (this.jump.ID == OpcodeID.Branch) { jump = (BranchOpcode)this.jump; } else { BlockEndOpcode opcode = (BlockEndOpcode)this.jump; jump = new BranchOpcode(); jump.Branches.Add(opcode); this.jump = jump; } jump.Branches.Add(jumpTo); } jumpTo.LinkJump(this); if (flag && (this.jump != null)) { base.prev.LinkToConditional(this); } }
internal void AddJump(BlockEndOpcode jumpTo) { bool flag = base.IsReachableFromConditional(); if (flag) { base.prev.DelinkFromConditional(this); } if (this.jump == null) { this.jump = jumpTo; } else { BranchOpcode jump; if (this.jump.ID == OpcodeID.Branch) { jump = (BranchOpcode) this.jump; } else { BlockEndOpcode opcode = (BlockEndOpcode) this.jump; jump = new BranchOpcode(); jump.Branches.Add(opcode); this.jump = jump; } jump.Branches.Add(jumpTo); } jumpTo.LinkJump(this); if (flag && (this.jump != null)) { base.prev.LinkToConditional(this); } }
internal void AddJump(BlockEndOpcode jumpTo) { bool conditional = this.IsReachableFromConditional(); if (conditional) { this.prev.DelinkFromConditional(this); } if (null == this.jump) { this.jump = jumpTo; } else { BranchOpcode jumpBranch; if (this.jump.ID == OpcodeID.Branch) { // already a branch jumpBranch = (BranchOpcode)this.jump; } else { BlockEndOpcode currentJump = (BlockEndOpcode)this.jump; jumpBranch = new BranchOpcode(); jumpBranch.Branches.Add(currentJump); this.jump = jumpBranch; } jumpBranch.Branches.Add(jumpTo); } jumpTo.LinkJump(this); if (conditional && null != this.jump) { this.prev.LinkToConditional(this); } }