data.tree
data.tree copied to clipboard
Remove reserved words
Currently, you cannot use reserved names as attributes of a Node object. This is a big limitation. Also, it requires lots of checking. For example, Node$new("name") currently works, but gives problems when accessing this node from it's parent.
There is no solution to this. Though a somewhat better approach would define:
- reserved names start with a .
- custom attributes can be anything, except they cannot start with a dot
This would also make checking much faster.
Another advantage would be that with code completion (e.g. in RStudio), you could simply type mynode$. and it would list all the non-custom attributes. Currently, these are all mixed, and that is sometimes confusing.