redbaron icon indicating copy to clipboard operation
redbaron copied to clipboard

Feature request: Add a node.remove() method

Open kenseehart opened this issue 6 years ago • 0 comments

The pattern del x.parent[x.index_on_parent] doesn't work in all cases. Deleting a node is a common operation, so it would be really neat if node.remove() would do it. This could leave the parent block empty. Perhaps this would insert a 'pass' on removing the last node.

kenseehart avatar Mar 01 '19 02:03 kenseehart