1Adding statement to Class Method containing Nop
2-----
3<?php
4class Foo {
5    public function __construct()
6    {
7        // I'm just a comment
8    }
9}
10-----
11$stmts[0]->stmts[0]->stmts[] = new Stmt\Expression(new Node\Expr\Variable('foo'));
12-----
13<?php
14class Foo {
15    public function __construct()
16    {
17        // I'm just a comment
18        $foo;
19    }
20}
21-----
22<?php
23class Foo {
24    public function __construct()
25    {
26        /* I'm just a comment */
27    }
28}
29-----
30$stmts[0]->stmts[0]->stmts[] = new Stmt\Expression(new Node\Expr\Variable('foo'));
31-----
32<?php
33class Foo {
34    public function __construct()
35    {
36        /* I'm just a comment */
37        $foo;
38    }
39}
40-----
41<?php
42class Foo {
43    public function __construct()
44    {
45        /* I'm just a comment */
46    }
47}
48-----
49$stmts[0]->stmts[0]->stmts[0]->setAttribute('comments', [new Comment("/* I'm a new comment */")]);
50-----
51<?php
52class Foo {
53    public function __construct()
54    {
55        /* I'm a new comment */
56
57    }
58}
59-----
60<?php
61class Foo {
62    public function __construct()
63    {
64        // I'm just a comment
65    }
66}
67-----
68$stmts[0]->stmts[0]->stmts[0]->setAttribute('comments', [new Comment("// I'm a new comment")]);
69-----
70<?php
71class Foo {
72    public function __construct()
73    {
74        // I'm a new comment
75
76    }
77}
78