From 72fc6bd82beeda7d1f70e8ec4f88bf239583cd89 Mon Sep 17 00:00:00 2001 From: Slizov Vadim Date: Thu, 1 Mar 2018 23:14:51 +0200 Subject: [PATCH] Update README.md --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 581d7f7..06fa79f 100644 --- a/README.md +++ b/README.md @@ -56,6 +56,14 @@ func main() { $GOPATH/bin/php-parser /path/to/file/or/dir ``` +## Namespace resolver + +Namespace resolver is a visitor that traverses nodes and resolves nodes fully qualified name. +It does not change AST but collects resolved names into `map[node.Node]string` + +- For `Class`, `Interface`, `Trait`, `Function`, `ConstList` nodes collects name with current namespace. +- For `Name`, `Relative`, `FullyQualified` nodes resolves `use` aliases and collects a fully qualified name. + ## Roadmap - [X] Lexer - [x] PHP 7 syntax analyzer