We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b1a1f8c + c290043 commit 2b87dd8Copy full SHA for 2b87dd8
app/Contexts/Binary.php
@@ -0,0 +1,11 @@
1
+<?php
2
+
3
+namespace App\Contexts;
4
5
+class Binary extends AbstractContext
6
+{
7
+ public function type(): string
8
+ {
9
+ return 'binary';
10
+ }
11
+}
app/Parsers/BinaryExpressionParser.php
@@ -0,0 +1,25 @@
+namespace App\Parsers;
+use App\Contexts\AbstractContext;
+use App\Contexts\Binary;
+use Microsoft\PhpParser\Node\Expression\BinaryExpression;
+class BinaryExpressionParser extends AbstractParser
+ /**
12
+ * @var Binary
13
+ */
14
+ protected AbstractContext $context;
15
16
+ public function parse(BinaryExpression $node)
17
18
+ return $this->context;
19
20
21
+ public function initNewContext(): ?AbstractContext
22
23
+ return new Binary;
24
25
0 commit comments