CodeQL library for Go
codeql/go-all 1.1.2-dev (changelog, source)

Member predicate Expr::getKind

Gets the kind of this expression, which is an integer value representing the expression’s node type.

Note that the mapping from node types to integer kinds is considered an implementation detail and subject to change without notice.

int getKind()