cleishm / libcypher-parser

Cypher Parser Library
Apache License 2.0
147 stars 39 forks source link

Add AST annotation API #22

Closed cleishm closed 4 years ago

cleishm commented 4 years ago

The AST annotation API provides an easy way to attach annotations to nodes in an abstract syntax tree.

The cypher_ast_annotation_context_t provides a context for a set of annotations, and each context supports attaching one annotation per astnode.

A callback handler is supported, allowing annotations to be released when the AST or the annotation context are free'd.