Example #1
0
        protected override void CommonEndVisit(ASTNode node)
        {
            if (!(node is SourceUnitList))
            {
                string relativePath = currentSourceUnit.AbsolutePath;
                string absolutePath = Path.Combine(context.SourceDirectory, relativePath);

                string   srcInfo       = node.Src;
                string[] tokens        = srcInfo.Split(':');
                int      startPosition = int.Parse(tokens[0]);
                int      lineNumber    = MapToLineNumber(relativePath, startPosition);

                context.AddSourceInfoForASTNode(node, absolutePath, lineNumber);
            }
        }