(
    (comment)* @context
    .
    (type_declaration
        (type_spec
            name: (_) @name)
    ) @item
)

(
    (comment)* @context
    .
    (function_declaration
        name: (_) @name
    ) @item
)

(
    (comment)* @context
    .
    (method_declaration
        name: (_) @name
    ) @item
)
