Skip to content

Commit cc8dcf0

Browse files
committed
Fix operand getter method
1 parent f34f167 commit cc8dcf0

File tree

202 files changed

+808
-202
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

202 files changed

+808
-202
lines changed

src/Kernel/Mnemonics/_aaload.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ final class _aaload extends AbstractOperationCode implements OperationCodeInterf
1111
public function getOperands(): ?Operands
1212
{
1313
parent::getOperands();
14-
return $this->operands ?? new Operands();
14+
if ($this->operands !== null) {
15+
return $this->operands;
16+
}
17+
return $this->operands = new Operands();
1518
}
1619

1720
/**

src/Kernel/Mnemonics/_aastore.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ final class _aastore extends AbstractOperationCode implements OperationCodeInter
1111
public function getOperands(): ?Operands
1212
{
1313
parent::getOperands();
14-
return $this->operands ?? new Operands();
14+
if ($this->operands !== null) {
15+
return $this->operands;
16+
}
17+
return $this->operands = new Operands();
1518
}
1619

1720
/**

src/Kernel/Mnemonics/_aconst_null.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aconst_null extends AbstractOperationCode implements OperationCodeI
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_aload.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aload extends AbstractOperationCode implements OperationCodeInterfa
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_aload_0.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aload_0 extends AbstractOperationCode implements OperationCodeInter
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_aload_1.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aload_1 extends AbstractOperationCode implements OperationCodeInter
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_aload_2.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aload_2 extends AbstractOperationCode implements OperationCodeInter
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_aload_3.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _aload_3 extends AbstractOperationCode implements OperationCodeInter
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
/**

src/Kernel/Mnemonics/_anewarray.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ final class _anewarray extends AbstractOperationCode implements OperationCodeInt
1111
public function getOperands(): ?Operands
1212
{
1313
parent::getOperands();
14-
return $this->operands ?? new Operands();
14+
if ($this->operands !== null) {
15+
return $this->operands;
16+
}
17+
return $this->operands = new Operands();
1518
}
1619

1720
/**

src/Kernel/Mnemonics/_areturn.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,10 @@ final class _areturn extends AbstractOperationCode implements OperationCodeInter
99
public function getOperands(): ?Operands
1010
{
1111
parent::getOperands();
12-
return $this->operands ?? new Operands();
12+
if ($this->operands !== null) {
13+
return $this->operands;
14+
}
15+
return $this->operands = new Operands();
1316
}
1417

1518
public function execute(): void

0 commit comments

Comments
 (0)