include/antlr3defs.h(3)

πŸ“¦ version 3.4, in fedora 43

πŸ’– include/antlr3defs.h β€” ANTLR3C πŸ’–

okay bestie, sit down, hydrate, because we're about to read a header file like it's the group chat. this is include/antlr3defs.h(3) from the ANTLR3C manual, and it's literally just the foundational ✨stuff✨ β€” the basic types and constants that the ANTLR3 Runtime builds everything else on top of. no drama, just vibes and #defines. πŸŽ€


✨ NAME ✨

include/antlr3defs.h β€” Basic type and constant definitions for ANTLR3 Runtime.

like, that's it. that's the whole job. it's the blueprint, the mood board, the little glue that holds the runtime together. 🫢


🌸 SYNOPSIS 🌸

first things first, it pulls in its little friend group:

#include <antlr3errors.h>
#include <antlr3config.h>
#include <stdio.h>
#include <antlr3interfaces.h>
#include <antlr3convertutf.h>

five besties, no more no less. πŸ’…

🧚 Macros

okay so this is the macro section and it is giving type-definition energy. every single one, coming right up, no skips, no cap:

  • #define _stat stat β€” the little alias situation, _stat maps to stat.
  • #define ANTLR3_API β€” it's here. that's the whole vibe.
  • #define ANTLR3_API β€” yes bestie, it shows up twice in the list. we don't question the ancients, we just document them faithfully. πŸ’€
  • #define ANTLR3_AVERAGE β€” no value attached, it's mysterious like that. ✨
  • #define ANTLR3_BE 1 β€” Indicates Big Endian for encodings where this makes sense.
  • #define ANTLR3_CDECL β€” calling convention placeholder, keeping it lowkey.
  • #define ANTLR3_CLOSESOCKET close β€” how we close a socket around these parts.
  • #define ANTLR3_ENC_8BIT 4 β€” General latin-1 or other 8 bit encoding scheme such as straight ASCII.
  • #define ANTLR3_ENC_EBCDIC 64 β€” Input is 8 bit EBCDIC (which we convert to 8 bit ASCII on the fly.
  • #define ANTLR3_ENC_UTF16 16 β€” UTF-16 encoding scheme (which also covers UCS2 as that does not have surrogates).
  • #define ANTLR3_ENC_UTF16BE 16 + ANTLR3_BE β€” UTF-16 but big endian, the combo meal. πŸ“
  • #define ANTLR3_ENC_UTF16LE 16 + ANTLR3_LE β€” same energy, little endian flavored.
  • #define ANTLR3_ENC_UTF32 32 β€” UTF-32 encoding scheme (basically straight 32 bit).
  • #define ANTLR3_ENC_UTF32BE 32 + ANTLR3_BE β€” 32 bit, big endian, iconic.
  • #define ANTLR3_ENC_UTF32LE 32 + ANTLR3_LE β€” 32 bit, little endian, also iconic.
  • #define ANTLR3_ENC_UTF8 8 β€” UTF-8 encoding scheme. the people's champion. πŸ‘‘
  • #define ANTLR3_FASTCALL β€” fast call placeholder, zoom zoom. πŸ’¨
  • #define ANTLR3_FUNC_PTR(ptr) β€” the function pointer cast macro, takes ptr.
  • #define ANTLR3_INLINE inline β€” ANTLR3_INLINE is just inline, keeping it simple fr fr.
  • #define ANTLR3_LE 2 β€” Indicates Little Endian for encoidngs where this makes sense. (typo is in the original bestie, we preserve the lore πŸ™ˆ)
  • #define ANTLR3_LIST_SIZE_HINT 63 β€” a lil size hint for lists, 63.
  • #define ANTLR3_SIZE_HINT 1025 β€” the general size hint, 1025.
  • #define ANTLR3_TRIE_DEPTH 31 β€” trie depth, 31, deep as the group chat archive.
  • #define ANTLR3_UINT32_CAST(ptr) β€” cast macro, takes ptr.
  • #define ANTLR3_UINT64_CAST(ptr) β€” another cast macro, also takes ptr.
  • #define ANTLR3_UINT64_LIT(lit) β€” 64-bit literal macro, takes lit.
  • #define INVALID_SOCKET ((SOCKET)-1) β€” the "this socket is NOT it" sentinel. πŸ’€

🌈 Typedefs

now the type aliases, aka the whole cast of characters. every one of them, character for character:

  • typedef uint64_t ANTLR3_BITWORD β€” the bit word, 64 bits of pure power. πŸ’ͺ
  • typedef uint32_t ANTLR3_BOOLEAN β€” it's a boolean, but make it 32 bits.
  • typedef int32_t ANTLR3_CHAR β€” a char that's signed and 32 bits wide, main character energy.
  • typedef FILE * ANTLR3_FDSC β€” file descriptor, it's a FILE * bestie.
  • typedef struct stat ANTLR3_FSTAT_STRUCT β€” the stat struct wearing an ANTLR3 name tag.
  • typedef int16_t ANTLR3_INT16 β€” 16-bit signed int, small but mighty. ✨
  • typedef int32_t ANTLR3_INT32 β€” 32-bit signed int.
  • typedef int64_t ANTLR3_INT64 β€” 64-bit signed int, big spender.
  • typedef int8_t ANTLR3_INT8 β€” 8-bit signed int, tiny icon.
  • typedef ANTLR3_UINT32 ANTLR3_INTKEY β€” the int key, riding on ANTLR3_UINT32.
  • typedef ANTLR3_INT32 ANTLR3_MARKER β€” the marker type, riding on ANTLR3_INT32.
  • typedef size_t ANTLR3_SALENT β€” salent is just size_t, periodt.
  • typedef struct sockaddr_in ANTLR3_SOCKADDRT β€” the socket address type, struct sockaddr_in coded.
  • typedef uint32_t ANTLR3_UCHAR β€” unsigned char but 32 bits, glow up. 🌸
  • typedef uint16_t ANTLR3_UINT16 β€” 16-bit unsigned int.
  • typedef uint32_t ANTLR3_UINT32 β€” 32-bit unsigned int.
  • typedef uint64_t ANTLR3_UINT64 β€” 64-bit unsigned int, absolute unit.
  • typedef uint8_t ANTLR3_UINT8 β€” 8-bit unsigned int.
  • typedef uint64_t * pANTLR3_BITWORD β€” pointer to a bit word. 🫢
  • typedef uint32_t * pANTLR3_BOOLEAN β€” pointer to a boolean.
  • typedef int32_t * pANTLR3_CHAR β€” pointer to a char.
  • typedef int16_t * pANTLR3_INT16 β€” pointer to an INT16.
  • typedef int32_t * pANTLR3_INT32 β€” pointer to an INT32.
  • typedef int64_t * pANTLR3_INT64 β€” pointer to an INT64.
  • typedef int8_t * pANTLR3_INT8 β€” pointer to an INT8.
  • typedef struct sockaddr * pANTLR3_SOCKADDRC β€” pointer to a struct sockaddr.
  • typedef struct sockaddr_in * pANTLR3_SOCKADDRT β€” pointer to a struct sockaddr_in.
  • typedef uint32_t * pANTLR3_UCHAR β€” pointer to an UCHAR.
  • typedef uint16_t * pANTLR3_UINT16 β€” pointer to an UINT16.
  • typedef uint32_t * pANTLR3_UINT32 β€” pointer to an UINT32.
  • typedef uint64_t * pANTLR3_UINT64 β€” pointer to an UINT64.
  • typedef uint8_t * pANTLR3_UINT8 β€” pointer to an UINT8.
  • typedef int SOCKET β€” and finally, SOCKET is just an int. slay. πŸ’…
heads up bestie, there are more parts coming β€” this was just the opening act. don't go anywhere. πŸ¦‹

✨ Functions ✨

  • ANTLR3_API pANTLR3_BASE_TREE_ADAPTOR ANTLR3_TREE_ADAPTORDebugNew(pANTLR3_STRING_FACTORY strFactory, pANTLR3_DEBUG_EVENT_LISTENER debugger) β€” Debugging version of the tree adaptor (not normally called as generated code calls setDebugEventListener instead which changes a normal token stream to a debugging stream and means that a user's instantiation code does not need to be changed just to debug with AW.
  • ANTLR3_API pANTLR3_BASE_TREE_ADAPTOR ANTLR3_TREE_ADAPTORNew(pANTLR3_STRING_FACTORY strFactory) β€” Create a new tree adaptor.
  • ANTLR3_API pANTLR3_ARBORETUM antlr3ArboretumNew(pANTLR3_STRING_FACTORY factory) β€” no description, just vibes πŸ¦‹
  • ANTLR3_API pANTLR3_BASE_RECOGNIZER antlr3BaseRecognizerNew(ANTLR3_UINT32 type, ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, iconic mystery πŸ’…
  • ANTLR3_API void antlr3BaseTreeAdaptorInit(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_DEBUG_EVENT_LISTENER debugger) β€” Given a pointer to a base tree adaptor structure (which is usually embedded in the super class the implements the tree adaptor used in the parse), initialize its function pointers and so on.
  • ANTLR3_API pANTLR3_BASE_TREE antlr3BaseTreeNew(pANTLR3_BASE_TREE tree) β€” no description, but the name is giving main character energy 🌟
  • ANTLR3_API pANTLR3_BITSET antlr3BitsetCopy(pANTLR3_BITSET_LIST blist) β€” no description, we move πŸ’œ
  • ANTLR3_API pANTLR3_BITSET antlr3BitsetList(pANTLR3_HASH_TABLE list) β€” no description, periodt πŸ’…
  • ANTLR3_API pANTLR3_BITSET antlr3BitsetLoad(pANTLR3_BITSET_LIST blist) β€” Creates a new bitset with at least one 64 bit bset of bits, but as many 64 bit sets as are required.
  • ANTLR3_API pANTLR3_BITSET antlr3BitsetNew(ANTLR3_UINT32 numBits) β€” no description, just the signature slaying ✨
  • ANTLR3_API pANTLR3_BITSET antlr3BitsetOf(ANTLR3_INT32 bit,...) β€” Creates a new bitset with at least one element, but as many elements are required.
  • ANTLR3_API void antlr3BitsetSetAPI(pANTLR3_BITSET bitset) β€” no description, we love a quiet icon πŸŽ€
  • ANTLR3_API ANTLR3_UCHAR antlr3c8toAntlrc(ANTLR3_INT8 inc) β€” le Provides basic utility functions to convert between the various Unicode character conversions.
  • ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenDebugStreamSourceNew(ANTLR3_UINT32 hint, pANTLR3_TOKEN_SOURCE source, pANTLR3_DEBUG_EVENT_LISTENER debugger) β€” no description, but the name is a whole paragraph πŸ’€
  • ANTLR3_API pANTLR3_COMMON_TOKEN antlr3CommonTokenNew(ANTLR3_UINT32 ttype) β€” no description, just token realness πŸͺ™
  • ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenStreamNew(ANTLR3_UINT32 hint) β€” no description, stream queen πŸ‘‘
  • ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenStreamSourceNew(ANTLR3_UINT32 hint, pANTLR3_TOKEN_SOURCE source) β€” no description, we respect the silence 🀫
  • ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNew(void) β€” no description, tree vibes only 🌳
  • ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNewFromToken(pANTLR3_COMMON_TOKEN tree) β€” no description, from token with love πŸ’–
  • ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNewFromTree(pANTLR3_COMMON_TREE tree) β€” no description, tree inception πŸŒ€
  • ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3CommonTreeNodeStreamNew(pANTLR3_STRING_FACTORY strFactory, ANTLR3_UINT32 hint) β€” no description, but the name is a mouthful 😭
  • ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3CommonTreeNodeStreamNewStream(pANTLR3_COMMON_TREE_NODE_STREAM inStream) β€” no description, stream on stream ✨
  • ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3CommonTreeNodeStreamNewTree(pANTLR3_BASE_TREE tree, ANTLR3_UINT32 hint) β€” no description, tree stream realness 🌈
  • ANTLR3_API pANTLR3_DEBUG_EVENT_LISTENER antlr3DebugListenerNew() β€” Create and initialize a new debug event listener that can be connected to by ANTLRWorks and any other debugger via a socket.
  • ANTLR3_API ANTLR3_INT32 antlr3dfapredict(void *ctx, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA cdfa) β€” From the input stream, predict what alternative will succeed using this DFA (representing the covering regular approximation to the underlying CFL).
  • ANTLR3_API ANTLR3_INT32 antlr3dfaspecialStateTransition(void *ctx, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA dfa, ANTLR3_INT32 s) β€” Default special state implementation.
  • ANTLR3_API ANTLR3_INT32 antlr3dfaspecialTransition(void *ctx, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA dfa, ANTLR3_INT32 s) β€” no description, just DFA drama 🎭
  • ANTLR3_API pANTLR3_HASH_ENUM antlr3EnumNew(pANTLR3_HASH_TABLE table) β€” Creates an enumeration structure to traverse the hash table.
  • ANTLR3_API pANTLR3_EXCEPTION antlr3ExceptionNew(ANTLR3_UINT32 exception, void *name, void *message, ANTLR3_BOOLEAN freeMessage) β€” Creates a new ANTLR3 exception structure.
  • ANTLR3_API pANTLR3_INPUT_STREAM antlr3FileStreamNew(pANTLR3_UINT8 fileName, ANTLR3_UINT32 encoding) β€” no description, file stream fantasy πŸ“
  • ANTLR3_API ANTLR3_UINT32 antlr3Hash(void *key, ANTLR3_UINT32 keylen) β€” Given an input key of arbitrary length, return a hash value of it.
  • ANTLR3_API pANTLR3_HASH_TABLE antlr3HashTableNew(ANTLR3_UINT32 sizeHint) β€” no description, hash table hype πŸ—‚οΈ
  • ANTLR3_API pANTLR3_INT_STREAM antlr3IntStreamNew(void) β€” no description, int stream icon ✨
  • ANTLR3_API pANTLR3_INT_TRIE antlr3IntTrieNew(ANTLR3_UINT32 depth) β€” no description, trie hard or go home πŸ’…
  • ANTLR3_API pANTLR3_LEXER antlr3LexerNew(ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, lexer queen πŸ‘‘
  • ANTLR3_API pANTLR3_LEXER antlr3LexerNewStream(ANTLR3_UINT32 sizeHint, pANTLR3_INPUT_STREAM input, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, stream lexer realness 🌊
  • ANTLR3_API pANTLR3_LIST antlr3ListNew(ANTLR3_UINT32 sizeHint) β€” no description, list it bestie πŸ“
  • ANTLR3_API void antlr3MTExceptionNew(pANTLR3_BASE_RECOGNIZER recognizer) β€” Creates a new Mismatched Token Exception and inserts in the recognizer exception stack.
  • ANTLR3_API void antlr3MTNExceptionNew(pANTLR3_BASE_RECOGNIZER recognizer) β€” Creates a new Mismatched Tree Nde Exception and inserts in the recognizer exception stack.
  • ANTLR3_API pANTLR3_PARSER antlr3ParserNew(ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, parser power πŸ’ͺ
  • ANTLR3_API pANTLR3_PARSER antlr3ParserNewStream(ANTLR3_UINT32 sizeHint, pANTLR3_TOKEN_STREAM tstream, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, stream parser slay 🌟
  • ANTLR3_API pANTLR3_PARSER antlr3ParserNewStreamDbg(ANTLR3_UINT32 sizeHint, pANTLR3_TOKEN_STREAM tstream, pANTLR3_DEBUG_EVENT_LISTENER dbg, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, debug parser energy πŸ›
  • ANTLR3_API void antlr3RecognitionExceptionNew(pANTLR3_BASE_RECOGNIZER recognizer) β€” no description, exception creation station πŸš‰
  • ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description) β€” no description, rewrite rule node stream fantasy πŸ”„
  • ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAEE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void *oneElement) β€” no description, AEE edition ✨
  • ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAEV(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR vector) β€” no description, AEV edition πŸ’«
  • ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description) β€” no description, subtree stream realness 🌳
  • ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAEE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void *oneElement) β€” no description, AEE subtree edition πŸƒ
  • ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAEV(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR vector) β€” no description, AEV subtree edition πŸ‚
  • ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM antlr3RewriteRuleTOKENStreamNewAE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description) β€” no description, token stream rewrite vibes πŸͺ™
  • ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM antlr3RewriteRuleTOKENStreamNewAEE(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void *oneElement) β€” no description, AEE token edition 🎟️
  • ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM antlr3RewriteRuleTOKENStreamNewAEV(pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR vector) β€” no description, AEV token edition 🎫
  • ANTLR3_API void antlr3SetCTAPI(pANTLR3_COMMON_TREE tree) β€” no description, set CT API realness πŸ’…
  • ANTLR3_API void antlr3SetTokenAPI(pANTLR3_COMMON_TOKEN token) β€” no description, set token API energy ⚑
  • ANTLR3_API void antlr3SetVectorApi(pANTLR3_VECTOR vector, ANTLR3_UINT32 sizeHint) β€” no description, set vector API vibes 🧬
  • ANTLR3_API pANTLR3_STACK antlr3StackNew(ANTLR3_UINT32 sizeHint) β€” no description, stack it up πŸ₯ž
  • ANTLR3_API pANTLR3_STRING_FACTORY antlr3StringFactoryNew(ANTLR3_UINT32 encoding) β€” no description, string factory fantasy 🧡
  • ANTLR3_API pANTLR3_INPUT_STREAM antlr3StringStreamNew(pANTLR3_UINT8 data, ANTLR3_UINT32 encoding, ANTLR3_UINT32 size, pANTLR3_UINT8 name) β€” no description, string stream slay πŸŽ€
  • ANTLR3_API pANTLR3_TOKEN_FACTORY antlr3TokenFactoryNew(pANTLR3_INPUT_STREAM input) β€” no description, token factory realness 🏭
  • ANTLR3_API pANTLR3_TOPO antlr3TopoNew() β€” Allocate and initialize a new ANTLR3 topological sorter, which can be used to define edges that identify numerical node indexes that depend on other numerical node indexes, which can then be sorted topologically such that any node is sorted after all its dependent nodes.
  • ANTLR3_API pANTLR3_TREE_NODE_STREAM antlr3TreeNodeStreamNew() β€” no description, tree node stream energy 🌲
  • ANTLR3_API pANTLR3_TREE_PARSER antlr3TreeParserNewStream(ANTLR3_UINT32 sizeHint, pANTLR3_COMMON_TREE_NODE_STREAM ctnstream, pANTLR3_RECOGNIZER_SHARED_STATE state) β€” no description, tree parser stream vibes 🌳
  • ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3UnbufTreeNodeStreamNew(pANTLR3_STRING_FACTORY strFactory, ANTLR3_UINT32 hint) β€” no description, unbuffered tree node stream realness πŸƒ
  • ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3UnbufTreeNodeStreamNewTree(pANTLR3_BASE_TREE tree, ANTLR3_UINT32 hint) β€” no description, unbuffered tree stream slay 🌿
  • ANTLR3_API pANTLR3_VECTOR_FACTORY antlr3VectorFactoryNew(ANTLR3_UINT32 sizeHint) β€” Vector factory creation.
  • ANTLR3_API pANTLR3_VECTOR antlr3VectorNew(ANTLR3_UINT32 sizeHint) β€” no description, vector newness πŸ§ͺ
  • ANTLR3_API void fillBufferExt(pANTLR3_COMMON_TOKEN_STREAM tokenStream) β€” no description, fill buffer ext extravaganza πŸŽ‰

πŸ’– Detailed Description πŸ’–

Basic type and constant definitions for ANTLR3 Runtime.

πŸ’… MACRO DEFINITION DOCUMENTATION πŸ’…

okay so this is the macro corner of the header, bestie, and it's a lot β€” every one of these little #defines gets its own moment, so buckle up πŸŽ€

  • #define _stat stat β€” literally just stat in a lil costume. Referenced by antlr3Fsize().
  • #define ANTLR3_API β€” shows up in antlr3CommonTreeNewFromTree(), antlr3UnbufTreeNodeStreamNew(), antlr3UnbufTreeNodeStreamNewTree(), getToken(), and toInt32_UTF16().
  • #define ANTLR3_API β€” yep, it's listed twice in the original docs, no extra lore attached to this second one. that's just how the source doc rolls πŸ’€
  • #define ANTLR3_AVERAGE β€” that's it. that's the whole entry.
  • #define ANTLR3_BE 1 β€” flags Big Endian, for the encodings where that's even a thing.
  • #define ANTLR3_CDECL β€” referenced by add(), addChild(), antlr3HashPut(), antlr3HashPutI(), antlr3ListAdd(), antlr3ListPut(), antlr3StackPush(), antlr3VectorAdd(), antlr3VectorFree(), antlr3VectorSet(), antlr3VectorSwap(), intTrieAdd(), newRaw8(), newRawUTF16(), stringFree(), toInt32_UTF16(), ANTLR3_HASH_ENTRY_struct::void(), ANTLR3_TRIE_ENTRY_struct::void(), ANTLR3_VECTOR_ELEMENT_struct::void(), and ANTLR3_VECTOR_struct::void().
  • #define ANTLR3_CLOSESOCKET close β€” referenced by handshake().
  • #define ANTLR3_ENC_8BIT 4 β€” general latin-1 or other 8 bit encoding scheme such as straight ASCII. Referenced by antlr3StringFactoryNew(), setupInputStream(), stringInit8(), and stringInitUTF16().
  • #define ANTLR3_ENC_EBCDIC 64 β€” input is 8 bit EBCDIC (which we convert to 8 bit ASCII on the fly. (yes the paren never closes, that's the original's energy, not mine 🫠) Referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF16 16 β€” UTF-16 encoding scheme (which also covers UCS2 as that does not have surrogates). Referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF16BE 16 + ANTLR3_BE β€” referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF16LE 16 + ANTLR3_LE β€” referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF32 32 β€” UTF-32 encoding scheme (basically straight 32 bit). Referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF32BE 32 + ANTLR3_BE β€” referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF32LE 32 + ANTLR3_LE β€” referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_ENC_UTF8 8 β€” UTF-8 encoding scheme, the icon itself ✨. Referenced by antlr3StringFactoryNew(), and setupInputStream().
  • #define ANTLR3_FASTCALL β€” no notes, no drama.
  • #define ANTLR3_FUNC_PTR( ptr) β€” Value: (void *)((ANTLR3_UINT32)(ptr)). Referenced by antlr38BitLT(), antlr38BitSeek(), antlr3EnumNew(), antlr3IntTrieNew(), antlr3ListNew(), antlr3StackNew(), antlr3VectorNew(), discardTokenType(), getRuleMemoization(), push(), and setTokenTypeChannel().
  • #define ANTLR3_INLINE inline β€” literally inline. the way that it just says what it is 😌
  • #define ANTLR3_LE 2 β€” indicates Little Endian for encoidngs where this makes sense. (yes, "encoidngs" β€” the typo is canon, don't @ me)
  • #define ANTLR3_LIST_SIZE_HINT 63 β€” that's the number, bestie.
  • #define ANTLR3_SIZE_HINT 1025 β€” and that's this number.
  • #define ANTLR3_TRIE_DEPTH 31 β€” and that's the depth.
  • #define ANTLR3_UINT32_CAST( ptr) β€” Value: (ANTLR3_UINT32)(ptr). Referenced by antlr3UTF16Substr(), antlr3UTF32Substr(), displayRecognitionError(), fillBuffer(), getUniqueID(), pop(), seek(), and toUTF8_UTF16().
  • #define ANTLR3_UINT64_CAST( ptr) β€” Value: (ANTLR3_UINT64)((ANTLR3_UINT32)(ptr)).
  • #define ANTLR3_UINT64_LIT( lit) β€” Value: lit##ULL.
  • #define INVALID_SOCKET ((SOCKET)-1) β€” referenced by handshake().

πŸ¦‹ TYPEDEF DOCUMENTATION πŸ¦‹

the whole roster, in order, zero skips 🫢

  • typedef uint64_t ANTLR3_BITWORD
  • typedef uint32_t ANTLR3_BOOLEAN
  • typedef int32_t ANTLR3_CHAR
  • typedef FILE* ANTLR3_FDSC
  • typedef struct stat ANTLR3_FSTAT_STRUCT
  • typedef int16_t ANTLR3_INT16
  • typedef int32_t ANTLR3_INT32
  • typedef int64_t ANTLR3_INT64
  • typedef int8_t ANTLR3_INT8
  • typedef ANTLR3_UINT32 ANTLR3_INTKEY
  • typedef ANTLR3_INT32 ANTLR3_MARKER
  • typedef size_t ANTLR3_SALENT
  • typedef struct sockaddr_in ANTLR3_SOCKADDRT
  • typedef uint32_t ANTLR3_UCHAR
  • typedef uint16_t ANTLR3_UINT16
  • typedef uint32_t ANTLR3_UINT32
  • typedef uint64_t ANTLR3_UINT64
  • typedef uint8_t ANTLR3_UINT8
  • typedef uint64_t * pANTLR3_BITWORD
  • typedef uint32_t * pANTLR3_BOOLEAN
  • typedef int32_t * pANTLR3_CHAR
  • typedef int16_t * pANTLR3_INT16
  • typedef int32_t * pANTLR3_INT32
  • typedef int64_t * pANTLR3_INT64
  • typedef int8_t * pANTLR3_INT8
  • typedef struct sockaddr* pANTLR3_SOCKADDRC
  • typedef struct sockaddr_in * pANTLR3_SOCKADDRT
  • typedef uint32_t * pANTLR3_UCHAR
  • typedef uint16_t * pANTLR3_UINT16
  • typedef uint32_t * pANTLR3_UINT32
  • typedef uint64_t * pANTLR3_UINT64
  • typedef uint8_t * pANTLR3_UINT8
  • typedef int SOCKET

πŸ‘‘ FUNCTION DOCUMENTATION πŸ‘‘

🌸 ANTLR3_TREE_ADAPTORDebugNew

ANTLR3_API pANTLR3_BASE_TREE_ADAPTOR ANTLR3_TREE_ADAPTORDebugNew (pANTLR3_STRING_FACTORY strFactory, pANTLR3_DEBUG_EVENT_LISTENER debugger)

the debugging version of the tree adaptor, bestie. and it's not normally called, because generated code calls setDebugEventListener instead, which flips a normal token stream into a debugging stream β€” meaning a user's instantiation code does not need to be changed just to debug with AW. lowkey genius, no cap πŸ’…

References: ANTLR3_TREE_ADAPTORNew(), antlr3BaseTreeAdaptorInit(), ANTLR3_BASE_TREE_ADAPTOR_struct::create, dbgCreate(), dbgSetTokenBoundaries(), and ANTLR3_BASE_TREE_ADAPTOR_struct::setTokenBoundaries.

Referenced by: ANTLR3_TREE_ADAPTORDebugNew(), and antlr3CommonTreeNodeStreamNew().


🌈 ANTLR3_TREE_ADAPTORNew

ANTLR3_API pANTLR3_BASE_TREE_ADAPTOR ANTLR3_TREE_ADAPTORNew (pANTLR3_STRING_FACTORY strFactory)

creates a brand new tree adaptor πŸŽ€ and here's the tea: even though it's making a new COMMON_TREE adaptor, it returns the address of the BASE_TREE interface β€” and any other adaptor that wants to be used as the tree element of a tree parse/build should do the exact same thing. it also has to be handed the address of a valid string factory, because we have no idea what the originating input stream's encoding type was. that way it can just rely on the original input stream's string factory, or one of the correct type that you supply. periodt.

References: antlr3ArboretumNew(), antlr3BaseTreeAdaptorInit(), antlr3TokenFactoryNew(), ANTLR3_COMMON_TREE_ADAPTOR_struct::arboretum, ANTLR3_COMMON_TREE_ADAPTOR_struct::baseAdaptor, ANTLR3_BASE_TREE_ADAPTOR_struct::create, create(), ANTLR3_BASE_TREE_ADAPTOR_struct::createToken, createToken(), ANTLR3_BASE_TREE_ADAPTOR_struct::createTokenFromToken, createTokenFromToken(), ctaFree(), ANTLR3_BASE_TREE_ADAPTOR_struct::deleteChild, deleteChild(), ANTLR3_BASE_TREE_ADAPTOR_struct::dupNode, dupNode(), ANTLR3_BASE_TREE_ADAPTOR_struct::errorNode, errorNode(), ANTLR3_BASE_TREE_ADAPTOR_struct::free, ANTLR3_BASE_TREE_ADAPTOR_struct::getChild, getChild(), ANTLR3_BASE_TREE_ADAPTOR_struct::getChildCount, getChildCount(), ANTLR3_BASE_TREE_ADAPTOR_struct::getChildIndex, getChildIndex(), ANTLR3_BASE_TREE_ADAPTOR_struct::getParent, getParent(), ANTLR3_BASE_TREE_ADAPTOR_struct::getText, getText(), ANTLR3_BASE_TREE_ADAPTOR_struct::getTokenStartIndex, getTokenStartIndex(), ANTLR3_BASE_TREE_ADAPTOR_struct::getTokenStopIndex, getTokenStopIndex(), ANTLR3_BASE_TREE_ADAPTOR_struct::getType, getType(), ANTLR3_BASE_TREE_ADAPTOR_struct::replaceChildren, replaceChildren(), ANTLR3_BASE_TREE_ADAPTOR_struct::setChild, setChild(), ANTLR3_BASE_TREE_ADAPTOR_struct::setChildIndex, setChildIndex(), ANTLR3_BASE_TREE_ADAPTOR_struct::setDebugEventListener, setDebugEventListener(), ANTLR3_BASE_TREE_ADAPTOR_struct::setParent, setParent(), ANTLR3_BASE_TREE_ADAPTOR_struct::setTokenBoundaries, setTokenBoundaries(), ANTLR3_BASE_TREE_ADAPTOR_struct::strFactory, ANTLR3_COMMON_TOKEN_struct::strFactory, ANTLR3_BASE_TREE_ADAPTOR_struct::super, ANTLR3_BASE_TREE_ADAPTOR_struct::tokenFactory, and ANTLR3_TOKEN_FACTORY_struct::unTruc.

Referenced by: ANTLR3_TREE_ADAPTORDebugNew(), and antlr3CommonTreeNodeStreamNew().


🧚 antlr3ArboretumNew

ANTLR3_API pANTLR3_ARBORETUM antlr3ArboretumNew (pANTLR3_STRING_FACTORY factory)

References: antlr3SetCTAPI(), antlr3StackNew(), antlr3VectorFactoryNew(), ANTLR3_COMMON_TREE_struct::baseTree, ANTLR3_ARBORETUM_struct::close, ANTLR3_COMMON_TREE_struct::factory, factoryClose(), ANTLR3_ARBORETUM_struct::newFromToken, newFromToken(), ANTLR3_ARBORETUM_struct::newFromTree, newFromTree(), newPool(), newPoolTree(), ANTLR3_ARBORETUM_struct::newTree, ANTLR3_ARBORETUM_struct::nilStack, ANTLR3_ARBORETUM_struct::pools, ANTLR3_BASE_TREE_struct::strFactory, ANTLR3_ARBORETUM_struct::thisPool, ANTLR3_ARBORETUM_struct::unTruc, and ANTLR3_ARBORETUM_struct::vFactory.

Referenced by: ANTLR3_TREE_ADAPTORNew().


πŸ’œ antlr3BaseTreeAdaptorInit

ANTLR3_API void antlr3BaseTreeAdaptorInit (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_DEBUG_EVENT_LISTENER debugger)

you hand it a pointer to a base tree adaptor structure β€” which is usually embedded in the super class that implements the tree adaptor used in the parse β€” and it initializes its function pointers and so on. setup arc, and it ate ✨

References: ANTLR3_DEBUG_EVENT_LISTENER_struct::adaptor, addChild(), ANTLR3_BASE_TREE_ADAPTOR_struct::addChild, addChildToken(), ANTLR3_BASE_TREE_ADAPTOR_struct::addChildToken, ANTLR3_BASE_TREE_ADAPTOR_struct::becomeRoot, becomeRoot(), ANTLR3_BASE_TREE_ADAPTOR_struct::becomeRootToken, becomeRootToken(), ANTLR3_BASE_TREE_ADAPTOR_struct::createTypeText, createTypeText(), ANTLR3_BASE_TREE_ADAPTOR_struct::createTypeToken, createTypeToken(), ANTLR3_BASE_TREE_ADAPTOR_struct::createTypeTokenText, createTypeTokenText(), dbgAddChild(), dbgAddChildToken(), dbgBecomeRoot(), dbgBecomeRootToken(), dbgCreateTypeText(), dbgCreateTypeToken(), dbgCreateTypeTokenText(), dbgDupTree(), dbgNil(), ANTLR3_BASE_TREE_ADAPTOR_struct::dupTree, dupTree(), ANTLR3_BASE_TREE_ADAPTOR_struct::dupTreeTT, dupTreeTT(), ANTLR3_BASE_TREE_ADAPTOR_struct::getChild, getChild(), ANTLR3_BASE_TREE_ADAPTOR_struct::getChildCount, getChildCount(), ANTLR3_BASE_TREE_ADAPTOR_struct::getText, getText(), ANTLR3_BASE_TREE_ADAPTOR_struct::getType, getType(), ANTLR3_BASE_TREE_ADAPTOR_struct::getUniqueID, getUniqueID(), ANTLR3_BASE_TREE_ADAPTOR_struct::isNilNode, isNilNode(), ANTLR3_BASE_TREE_ADAPTOR_struct::makeDot, makeDot(), ANTLR3_BASE_TREE_ADAPTOR_struct::nilNode, nilNode(), ANTLR3_BASE_TREE_ADAPTOR_struct::rulePostProcessing, rulePostProcessing(), ANTLR3_BASE_TREE_ADAPTOR_struct::setText, setText(), ANTLR3_BASE_TREE_ADAPTOR_struct::setText8, setText8(), ANTLR3_BASE_TREE_ADAPTOR_struct::setType, and setType().

Referenced by: ANTLR3_TREE_ADAPTORDebugNew(), ANTLR3_TREE_ADAPTORNew(), and setDebugEventListener().


πŸ“ antlr3BaseTreeNew

ANTLR3_API pANTLR3_BASE_TREE antlr3BaseTreeNew (pANTLR3_BASE_TREE tree)

References: addChild(), ANTLR3_BASE_TREE_struct::addChild, addChildren(), ANTLR3_BASE_TREE_struct::addChildren, ANTLR3_BASE_TREE_struct::children, ANTLR3_BASE_TREE_struct::deleteChild, deleteChild(), ANTLR3_BASE_TREE_struct::dupTree, dupTree(), ANTLR3_BASE_TREE_struct::freshenPACIndexes, freshenPACIndexes(), ANTLR3_BASE_TREE_struct::freshenPACIndexesAll, freshenPACIndexesAll(), ANTLR3_BASE_TREE_struct::getCharPositionInLine, getCharPositionInLine(), ANTLR3_BASE_TREE_struct::getChild, getChild(), ANTLR3_BASE_TREE_struct::getChildCount, getChildCount(), ANTLR3_BASE_TREE_struct::getFirstChildWithType, getFirstChildWithType(), ANTLR3_BASE_TREE_struct::getLine, getLine(), ANTLR3_BASE_TREE_struct::replaceChildren, replaceChildren(), ANTLR3_BASE_TREE_struct::setChild, setChild(), ANTLR3_BASE_TREE_struct::strFactory, ANTLR3_BASE_TREE_struct::toStringTree, and toStringTree().

ANTLR3_API pANTLR3_BITSET antlr3BitsetCopy (pANTLR3_BITSET_LIST blist)

bestie this one is literally just the dupe button for a bitset 🫢 it takes a pANTLR3_BITSET_LIST and hands you back a fresh pANTLR3_BITSET, and along the way it's touching:

  • ANTLR3_BITSET_LIST_struct::bits
  • ANTLR3_BITSET_struct::blist
  • ANTLR3_BITSET_LIST_struct::length

ANTLR3_API pANTLR3_BITSET antlr3BitsetList (pANTLR3_HASH_TABLE list)

you hand it a pANTLR3_HASH_TABLE and it manifests a whole entire pANTLR3_BITSET out of it ✨ it's building on:

  • ANTLR3_BITSET_struct::add
  • ANTLR3_SUCCESS
  • antlr3BitsetNew()
  • antlr3EnumNew()
  • ANTLR3_HASH_ENUM_struct::free
  • ANTLR3_HASH_ENUM_struct::next

Referenced by: getTokensList()


ANTLR3_API pANTLR3_BITSET antlr3BitsetLoad (pANTLR3_BITSET_LIST inBits)

it makes a new bitset that's got at least one 64 bit bset of bits, but as many 64 bit sets as are required. so like, minimum one, but it will absolutely keep going if it has to πŸ’…

Parameters

  • bset β€” a variable number of bits to add to the set, ending in -1 (impossible bit).

Returns

A new bit set with all of the specified bitmaps in it and the API initialized.

Call as:

  • pANTLR3_BITSET = antlrBitsetLoad(bset, bset11, ..., -1);
  • pANTLR3_BITSET = antlrBitsetOf(-1); Create empty bitset

Remarks

Stdargs function β€” you must supply -1 as the last parameter, and that -1 is NOT added to the set. no cap, do not forget it.

References

  • antlr3BitsetNew()
  • ANTLR3_BITSET_LIST_struct::bits
  • ANTLR3_BITSET_struct::blist
  • ANTLR3_BITSET_struct::grow
  • ANTLR3_BITSET_LIST_struct::length

Referenced by: combineFollows(), displayRecognitionError(), mismatchIsMissingToken(), and recoverFromMismatchedElement()


ANTLR3_API pANTLR3_BITSET antlr3BitsetNew (ANTLR3_UINT32 numBits)

the new-bitset factory, and it's clocking in with:

  • ANTLR3_BITSET_BITS
  • ANTLR3_BITSET_LOG_BITS
  • antlr3BitsetSetAPI()
  • ANTLR3_BITSET_LIST_struct::bits
  • ANTLR3_BITSET_struct::blist
  • ANTLR3_BITSET_LIST_struct::length

Referenced by: addEdge(), antlr3BitsetClone(), antlr3BitsetList(), antlr3BitsetLoad(), antlr3BitsetOf(), combineFollows(), and sortToArray()


ANTLR3_API pANTLR3_BITSET antlr3BitsetOf (ANTLR3_INT32 bit, ...)

creates a new bitset with at least one element, but as many elements as are required. same energy as the load one, just element-coded instead of bitmap-coded 🌸

Parameters

  • bit β€” a variable number of bits to add to the set, ending in -1 (impossible bit).

Returns

A new bit set with all of the specified elements added into it.

Call as:

  • pANTLR3_BITSET = antlrBitsetOf(n, n1, n2, -1);
  • pANTLR3_BITSET = antlrBitsetOf(-1); Create empty bitset

Remarks

Stdargs function β€” you must supply -1 as the last parameter, and it is NOT added to the set. that trailing -1 is the little periodt of the call πŸ’€

References

  • antlr3BitsetAdd()
  • antlr3BitsetNew()

Referenced by: getTokensType()


ANTLR3_API void antlr3BitsetSetAPI (pANTLR3_BITSET bitset)

this is the one that wires up the whole vtable and gives the bitset its entire personality πŸŽ€ it returns nothing, it just assigns, and the way that it's in cahoots with basically every bitset function… iconic.

References

  • ANTLR3_BITSET_struct::add
  • antlr3BitsetAdd()
  • antlr3BitsetClone()
  • antlr3BitsetEquals()
  • antlr3BitsetFree()
  • antlr3BitsetIsNil()
  • antlr3BitsetMember()
  • antlr3BitsetNumBits()
  • antlr3BitsetOR()
  • antlr3BitsetORInPlace()
  • antlr3BitsetRemove()
  • antlr3BitsetSize()
  • antlr3BitsetToIntList()
  • ANTLR3_BITSET_struct::bor
  • ANTLR3_BITSET_struct::borInPlace
  • ANTLR3_BITSET_struct::clone
  • ANTLR3_BITSET_struct::equals
  • ANTLR3_BITSET_struct::free
  • ANTLR3_BITSET_struct::grow
  • grow()
  • ANTLR3_BITSET_struct::isMember
  • ANTLR3_BITSET_struct::isNilNode
  • ANTLR3_BITSET_struct::numBits
  • ANTLR3_BITSET_struct::remove
  • ANTLR3_BITSET_struct::size
  • ANTLR3_BITSET_struct::toIntList

Referenced by: antlr3BitsetNew()


ANTLR3_API ANTLR3_UCHAR antlr3c8toAntlrc (ANTLR3_INT8 inc)

\File Provides basic utility functions to convert between the various Unicode character conversions. There are of course various packages that could be used instead of these functions, but then the Antlr 3 C runtime would be dependant on the particular package. Using ICU for this is a good idea if your project is already dependant on it. Convert 8 bit character to ANTLR char form.

like yes bestie, ICU is right there, but the runtime isn't about to get attached to it 😭

Parameters

  • inc β€” Input character to transform from 8 bit form.

Returns

ANTLR3_UCHAR encoding of the character.


ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenDebugStreamSourceNew (ANTLR3_UINT32 hint, pANTLR3_TOKEN_SOURCE source, pANTLR3_DEBUG_EVENT_LISTENER debugger)

a token stream but make it debugging πŸ› it hooks up all the dbg flavoured callbacks so you can actually watch what the stream is doing.

References

  • ANTLR3_INT_STREAM_struct::_LA
  • ANTLR3_TOKEN_STREAM_struct::_LT
  • ANTLR3_FALSE
  • antlr3CommonTokenStreamSourceNew()
  • ANTLR3_INT_STREAM_struct::consume
  • dbgConsume()
  • dbgLA()
  • dbgMark()
  • dbgRewindLast()
  • dbgRewindStream()
  • dbgSeek()
  • dbgTokLT()
  • ANTLR3_TOKEN_STREAM_struct::debugger
  • ANTLR3_TOKEN_STREAM_struct::initialStreamState
  • ANTLR3_TOKEN_STREAM_struct::istream
  • ANTLR3_INT_STREAM_struct::mark
  • ANTLR3_INT_STREAM_struct::rewind
  • ANTLR3_INT_STREAM_struct::rewindLast
  • ANTLR3_INT_STREAM_struct::seek
  • ANTLR3_COMMON_TOKEN_STREAM_struct::tstream

ANTLR3_API pANTLR3_COMMON_TOKEN antlr3CommonTokenNew (ANTLR3_UINT32 ttype)

new token just dropped πŸ‘‘ you pass the ttype and it hands back a pANTLR3_COMMON_TOKEN.

References

  • newToken()
  • ANTLR3_COMMON_TOKEN_struct::setType

Referenced by: antlr3CommonTreeNodeStreamNew(), newDownNode(), and newUpNode()


ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenStreamNew (ANTLR3_UINT32 hint)

okay so THIS one is the whole entire friend group πŸ’– it sets up a common token stream and it is entangled with… literally everything. deep breath:

References

  • _LA()
  • ANTLR3_INT_STREAM_struct::_LA
  • ANTLR3_TOKEN_STREAM_struct::_LT
  • ANTLR3_TOKENSTREAM
  • antlr3IntStreamNew()
  • antlr3TokenStreamNew()
  • antlr3VectorNew()
  • ANTLR3_INT_STREAM_struct::consume
  • consume()
  • discardOffChannel()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::discardOffChannelToks
  • ANTLR3_COMMON_TOKEN_STREAM_struct::discardTokenType
  • discardTokenType()
  • ANTLR3_TOKEN_STREAM_struct::get
  • get()
  • ANTLR3_INT_STREAM_struct::getSourceName
  • getSourceName()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::getTokenRange
  • getTokenRange()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::getTokens
  • getTokens()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::getTokensList
  • getTokensList()
  • ANTLR3_TOKEN_STREAM_struct::getTokenSource
  • getTokenSource()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::getTokensSet
  • getTokensSet()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::getTokensType
  • getTokensType()
  • ANTLR3_INT_STREAM_struct::index
  • ANTLR3_TOKEN_STREAM_struct::istream
  • ANTLR3_INT_STREAM_struct::mark
  • mark()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::p
  • ANTLR3_INT_STREAM_struct::release
  • release()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::reset
  • reset()
  • ANTLR3_INT_STREAM_struct::rewind
  • ANTLR3_INT_STREAM_struct::rewindLast
  • rewindLast()
  • rewindStream()
  • ANTLR3_INT_STREAM_struct::seek
  • seek()
  • ANTLR3_TOKEN_STREAM_struct::setDebugListener
  • setDebugListener()
  • ANTLR3_TOKEN_STREAM_struct::setTokenSource
  • setTokenSource()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::setTokenTypeChannel
  • setTokenTypeChannel()
  • ANTLR3_INT_STREAM_struct::size
  • size()
  • ANTLR3_INT_STREAM_struct::super
  • ANTLR3_TOKEN_STREAM_struct::super
  • tindex()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::tokens
  • tokLT()
  • ANTLR3_TOKEN_STREAM_struct::toString
  • toString()
  • ANTLR3_TOKEN_STREAM_struct::toStringSS
  • toStringSS()
  • ANTLR3_TOKEN_STREAM_struct::toStringTT
  • toStringTT()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::tstream
  • ANTLR3_INT_STREAM_struct::type

Referenced by: antlr3CommonTokenStreamSourceNew()


ANTLR3_API pANTLR3_COMMON_TOKEN_STREAM antlr3CommonTokenStreamSourceNew (ANTLR3_UINT32 hint, pANTLR3_TOKEN_SOURCE source)

the version that actually takes a pANTLR3_TOKEN_SOURCE πŸ¦‹ it makes the stream and then glues the source onto it.

References

  • ANTLR3_FALSE
  • ANTLR3_TOKEN_DEFAULT_CHANNEL
  • antlr3CommonTokenStreamNew()
  • antlr3CTSFree()
  • ANTLR3_COMMON_TOKEN_STREAM_struct::channel
  • ANTLR3_COMMON_TOKEN_STREAM_struct::channelOverrides
  • ANTLR3_COMMON_TOKEN_STREAM_struct::discardOffChannel
  • ANTLR3_COMMON_TOKEN_STREAM_struct::discardSet
  • ANTLR3_COMMON_TOKEN_STREAM_struct::free
  • ANTLR3_TOKEN_STREAM_struct::setTokenSource
  • ANTLR3_COMMON_TOKEN_STREAM_struct::tstream

Referenced by: antlr3CommonTokenDebugStreamSourceNew()


ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNew (void )

no args, no drama, just a brand new pANTLR3_COMMON_TREE 🌈

References

  • antlr3SetCTAPI()

Referenced by: antlr3CommonTreeNewFromToken()


ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNewFromToken (pANTLR3_COMMON_TOKEN tree)

hands it a pANTLR3_COMMON_TOKEN and gets a pANTLR3_COMMON_TREE back. token to tree pipeline, slay ✨

References

  • antlr3CommonTreeNew()
  • ANTLR3_COMMON_TREE_struct::token

Referenced by: newDownNode(), and newUpNode()


ANTLR3_API pANTLR3_COMMON_TREE antlr3CommonTreeNewFromTree (pANTLR3_COMMON_TREE tree)

tree in, tree out, no thoughts, just vibes 🧚

References

  • ANTLR3_API

antlr3CommonTreeNodeStreamNew

ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3CommonTreeNodeStreamNew
    (pANTLR3_STRING_FACTORY strFactory, ANTLR3_UINT32 hint)

okay bestie this one is the tree-node-stream maker πŸ’… it builds you a brand-new common tree node stream, and it takes a pANTLR3_STRING_FACTORY plus an ANTLR3_UINT32 hint.

References:

_LA(), ANTLR3_INT_STREAM_struct::_LA, _LT(),
ANTLR3_TREE_NODE_STREAM_struct::_LT,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::adaptor, addNavigationNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::addNavigationNode,
ANTLR3_COMMONTREENODE, ANTLR3_FALSE, ANTLR3_TEXT_CHARP,
ANTLR3_TOKEN_DOWN, ANTLR3_TOKEN_EOF, ANTLR3_TOKEN_INVALID,
ANTLR3_TOKEN_UP, ANTLR3_TREE_ADAPTORNew(), antlr3CommonTokenNew(),
antlr3CommonTreeNodeStreamFree(), antlr3IntStreamNew(),
antlr3SetCTAPI(), antlr3StackNew(), antlr3TreeNodeStreamNew(),
antlr3VectorNew(), ANTLR3_COMMON_TOKEN_struct::chars,
ANTLR3_INT_STREAM_struct::consume, consume(),
ANTLR3_TREE_NODE_STREAM_struct::ctns, DEFAULT_INITIAL_BUFFER_SIZE,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::DOWN,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::EOF_NODE,
ANTLR3_BASE_TREE_ADAPTOR_struct::free,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::free,
ANTLR3_TREE_NODE_STREAM_struct::free,
ANTLR3_TREE_NODE_STREAM_struct::get, get(),
ANTLR3_TREE_NODE_STREAM_struct::getTreeAdaptor, getTreeAdaptor(),
ANTLR3_TREE_NODE_STREAM_struct::getTreeSource, getTreeSource(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::hasUniqueNavigationNodes,
hasUniqueNavigationNodes(), ANTLR3_INT_STREAM_struct::index,
INITIAL_CALL_STACK_SIZE,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::INVALID_NODE,
ANTLR3_TREE_NODE_STREAM_struct::istream, ANTLR3_INT_STREAM_struct::mark,
mark(), ANTLR3_COMMON_TREE_NODE_STREAM_struct::markers,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::newDownNode, newDownNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::newUpNode, newUpNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::nodes,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::nodeStack,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::p,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::pop, pop(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::push, push(),
ANTLR3_INT_STREAM_struct::release, release(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::reset, reset(),
ANTLR3_INT_STREAM_struct::rewind, ANTLR3_INT_STREAM_struct::rewindLast,
rewindLast(), rewindMark(), ANTLR3_INT_STREAM_struct::seek, seek(),
ANTLR3_TREE_NODE_STREAM_struct::setUniqueNavigationNodes,
setUniqueNavigationNodes(), ANTLR3_INT_STREAM_struct::size, size(),
ANTLR3_COMMON_TOKEN_struct::strFactory,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::stringFactory,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::super,
ANTLR3_INT_STREAM_struct::super, ANTLR3_COMMON_TOKEN_struct::textState,
tindex(), ANTLR3_COMMON_TREE_NODE_STREAM_struct::tnstream,
ANTLR3_COMMON_TREE_struct::token, ANTLR3_COMMON_TOKEN_struct::tokText,
ANTLR3_TREE_NODE_STREAM_struct::toString, toString(),
ANTLR3_TREE_NODE_STREAM_struct::toStringSS, toStringSS(),
ANTLR3_TREE_NODE_STREAM_struct::toStringWork, toStringWork(),
ANTLR3_INT_STREAM_struct::type,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::uniqueNavigationNodes, and
ANTLR3_COMMON_TREE_NODE_STREAM_struct::UP.

Referenced by antlr3CommonTreeNodeStreamNewTree().


antlr3CommonTreeNodeStreamNewStream

ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM
    antlr3CommonTreeNodeStreamNewStream (pANTLR3_COMMON_TREE_NODE_STREAM
    inStream)

this one clones the vibe of an existing tree node stream into a fresh one πŸ¦‹ it takes a pANTLR3_COMMON_TREE_NODE_STREAM called inStream and hands you back a shiny new pANTLR3_COMMON_TREE_NODE_STREAM.

References:

_LA(), ANTLR3_INT_STREAM_struct::_LA, _LT(),
ANTLR3_TREE_NODE_STREAM_struct::_LT,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::adaptor, addNavigationNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::addNavigationNode,
ANTLR3_COMMONTREENODE, ANTLR3_FALSE, ANTLR3_TRUE,
antlr3CommonTreeNodeStreamFree(), antlr3IntStreamNew(),
antlr3SetCTAPI(), antlr3TreeNodeStreamNew(), antlr3VectorNew(),
ANTLR3_INT_STREAM_struct::consume, consume(),
ANTLR3_TREE_NODE_STREAM_struct::ctns, DEFAULT_INITIAL_BUFFER_SIZE,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::DOWN,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::EOF_NODE,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::free,
ANTLR3_TREE_NODE_STREAM_struct::free,
ANTLR3_TREE_NODE_STREAM_struct::get, get(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::getLookaheadSize,
getLookaheadSize(), ANTLR3_TREE_NODE_STREAM_struct::getTreeAdaptor,
getTreeAdaptor(), ANTLR3_TREE_NODE_STREAM_struct::getTreeSource,
getTreeSource(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::hasUniqueNavigationNodes,
hasUniqueNavigationNodes(), ANTLR3_INT_STREAM_struct::index,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::INVALID_NODE,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::isRewriter,
ANTLR3_TREE_NODE_STREAM_struct::istream, ANTLR3_INT_STREAM_struct::mark,
mark(), ANTLR3_COMMON_TREE_NODE_STREAM_struct::markers,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::newDownNode, newDownNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::newUpNode, newUpNode(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::nodes,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::nodeStack,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::p,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::pop, pop(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::push, push(),
ANTLR3_INT_STREAM_struct::release, release(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::reset, reset(),
ANTLR3_INT_STREAM_struct::rewind, ANTLR3_INT_STREAM_struct::rewindLast,
rewindLast(), rewindMark(), ANTLR3_COMMON_TREE_NODE_STREAM_struct::root,
ANTLR3_INT_STREAM_struct::seek, seek(),
ANTLR3_TREE_NODE_STREAM_struct::setUniqueNavigationNodes,
setUniqueNavigationNodes(), ANTLR3_INT_STREAM_struct::size, size(),
ANTLR3_COMMON_TOKEN_struct::strFactory,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::stringFactory,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::super,
ANTLR3_INT_STREAM_struct::super, tindex(),
ANTLR3_COMMON_TREE_NODE_STREAM_struct::tnstream,
ANTLR3_COMMON_TREE_struct::token,
ANTLR3_TREE_NODE_STREAM_struct::toString, toString(),
ANTLR3_TREE_NODE_STREAM_struct::toStringSS, toStringSS(),
ANTLR3_TREE_NODE_STREAM_struct::toStringWork, toStringWork(),
ANTLR3_INT_STREAM_struct::type,
ANTLR3_COMMON_TREE_NODE_STREAM_struct::uniqueNavigationNodes, and
ANTLR3_COMMON_TREE_NODE_STREAM_struct::UP.

antlr3CommonTreeNodeStreamNewTree

ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3CommonTreeNodeStreamNewTree
    (pANTLR3_BASE_TREE tree, ANTLR3_UINT32 hint)

slap a whole tree in there 🌳 give it your pANTLR3_BASE_TREE tree and an ANTLR3_UINT32 hint, and it spins up a pANTLR3_COMMON_TREE_NODE_STREAM for you.

References: antlr3CommonTreeNodeStreamNew(), ANTLR3_COMMON_TREE_NODE_STREAM_struct::root, and ANTLR3_BASE_TREE_struct::strFactory.


antlr3DebugListenerNew

ANTLR3_API pANTLR3_DEBUG_EVENT_LISTENER antlr3DebugListenerNew ()

Create and initialize a new debug event listener that can be connected to by ANTLRWorks and any other debugger via a socket. πŸ”Œ iconic honestly.

References:

addChild(), ANTLR3_DEBUG_EVENT_LISTENER_struct::addChild,
ANTLR3_DEBUG_EVENT_LISTENER_struct::becomeRoot, becomeRoot(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::beginBacktrack, beginBacktrack(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::beginResync, beginResync(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::commence, commence(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::consumeHiddenToken,
consumeHiddenToken(), ANTLR3_DEBUG_EVENT_LISTENER_struct::consumeNode,
consumeNode(), ANTLR3_DEBUG_EVENT_LISTENER_struct::consumeToken,
consumeToken(), ANTLR3_DEBUG_EVENT_LISTENER_struct::createNode,
createNode(), ANTLR3_DEBUG_EVENT_LISTENER_struct::createNodeTok,
createNodeTok(), DEFAULT_DEBUGGER_PORT,
ANTLR3_DEBUG_EVENT_LISTENER_struct::endBacktrack, endBacktrack(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::endResync, endResync(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::enterAlt, enterAlt(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::enterDecision, enterDecision(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::enterRule, enterRule(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::enterSubRule, enterSubRule(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::errorNode, errorNode(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::exitDecision, exitDecision(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::exitRule, exitRule(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::exitSubRule, exitSubRule(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::handshake, handshake(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::location, location(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::LT, LT(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::LTT, LTT(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::mark, mark(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::nilNode, nilNode(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::port,
ANTLR3_DEBUG_EVENT_LISTENER_struct::protocol_version,
ANTLR3_DEBUG_EVENT_LISTENER_struct::recognitionException,
recognitionException(), ANTLR3_DEBUG_EVENT_LISTENER_struct::rewind,
ANTLR3_DEBUG_EVENT_LISTENER_struct::rewindLast, rewindLast(),
rewindMark(), ANTLR3_DEBUG_EVENT_LISTENER_struct::semanticPredicate,
semanticPredicate(),
ANTLR3_DEBUG_EVENT_LISTENER_struct::setTokenBoundaries,
setTokenBoundaries(), ANTLR3_DEBUG_EVENT_LISTENER_struct::terminate, and
terminate().

Referenced by antlr3DebugListenerNewPort().


antlr3dfapredict

ANTLR3_API ANTLR3_INT32 antlr3dfapredict (void * ctx,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA
    cdfa)

From the input stream, predict what alternative will succeed using this DFA (representing the covering regular approximation to the underlying CFL). Return an alternative number 1..n. Throw an exception upon error. 😀 it will absolutely throw hands (an exception) if something goes sideways, no cap.

References:

ANTLR3_INT_STREAM_struct::_LA,
ANTLR3_CYCLIC_DFA_struct::accept, ANTLR3_TOKEN_EOF, ANTLR3_TRUE,
ANTLR3_INT_STREAM_struct::consume, ANTLR3_CYCLIC_DFA_struct::eof,
ANTLR3_CYCLIC_DFA_struct::eot,
ANTLR3_RECOGNIZER_SHARED_STATE_struct::error,
ANTLR3_INT_STREAM_struct::mark, mark(), ANTLR3_CYCLIC_DFA_struct::min,
noViableAlt(), ANTLR3_INT_STREAM_struct::rewind,
ANTLR3_CYCLIC_DFA_struct::special,
ANTLR3_CYCLIC_DFA_struct::specialStateTransition,
ANTLR3_BASE_RECOGNIZER_struct::state, and
ANTLR3_CYCLIC_DFA_struct::transition.

antlr3dfaspecialStateTransition

ANTLR3_API ANTLR3_INT32 antlr3dfaspecialStateTransition (void * ctx,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA
    dfa, ANTLR3_INT32 s)

Default special state implementation. the blueprint, the og, the standard πŸ’…


antlr3dfaspecialTransition

ANTLR3_API ANTLR3_INT32 antlr3dfaspecialTransition (void * ctx,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_INT_STREAM is, pANTLR3_CYCLIC_DFA
    dfa, ANTLR3_INT32 s)

antlr3EnumNew

ANTLR3_API pANTLR3_HASH_ENUM antlr3EnumNew (pANTLR3_HASH_TABLE table)

Creates an enumeration structure to traverse the hash table. 🧚 walk it like you own it.

Parameters

  • table β€” Table to enumerate

Returns

Pointer to enumeration structure.

References: ANTLR3_ERR_NOMEM, ANTLR3_FUNC_PTR, antlr3EnumFree(), antlr3EnumNext(), antlr3EnumNextEntry(), ANTLR3_HASH_ENUM_struct::bucket, ANTLR3_HASH_TABLE_struct::buckets, ANTLR3_HASH_BUCKET_struct::entries, ANTLR3_HASH_ENUM_struct::entry, ANTLR3_HASH_ENUM_struct::free, ANTLR3_HASH_ENUM_struct::next, and ANTLR3_HASH_ENUM_struct::table.

Referenced by antlr3BitsetList().


antlr3ExceptionNew

ANTLR3_API pANTLR3_EXCEPTION antlr3ExceptionNew (ANTLR3_UINT32 exception,
    void * name, void * message, ANTLR3_BOOLEAN freeMessage)

Creates a new ANTLR3 exception structure. πŸ’€ sometimes things go wrong and you gotta make it official.

  • exception β€” one of the ANTLR3_xxx_EXCEPTION indicators, like ANTLR3_RECOGNITION_EXCEPTION πŸ’…
  • message β€” pointer to the message string
  • freeMessage β€” set this to ANTLR3_TRUE if the message parameter should get freed by a call to ANTLR3_FREE() when the exception is destroyed

Returns

Pointer to a newly initialized exception structure, or an ANTLR3_ERR_xx defined value if it fails 😭

So here's the tea: an exception gets 'thrown' by a recognizer whenever it sees input that the grammar productions didn't predict, or whenever some other error condition happens. And bestie, in C we do not get the luxury of try and catch blocks πŸ™ˆ so instead, exceptions get added to a list inside the baserecognizer structure, in the order they occur. The last one thrown gets inserted at the head of the list, and the one that's currently installed is the one the newly installed exception points to. slay.

Remarks

Once an exception is created, you may add a pointer to your own structure, plus a pointer to a function that frees that structure when the exception is destroyed. cute and responsible πŸŽ€

See also

ANTLR3_EXCEPTION

References antlr3ExceptionFree(), antlr3ExceptionPrint(), ANTLR3_EXCEPTION_struct::freeEx, ANTLR3_EXCEPTION_struct::freeMessage, ANTLR3_EXCEPTION_struct::message, ANTLR3_EXCEPTION_struct::name, ANTLR3_EXCEPTION_struct::print, and ANTLR3_EXCEPTION_struct::type.

Referenced by antlr3RecognitionExceptionNew().


antlr3FileStreamNew πŸ¦‹

ANTLR3_API pANTLR3_INPUT_STREAM antlr3FileStreamNew (pANTLR3_UINT8 fileName, ANTLR3_UINT32 encoding)

References antlr3CreateFileStream(), ANTLR3_INPUT_STREAM_struct::encoding, ANTLR3_INPUT_STREAM_struct::fileName, ANTLR3_INPUT_STREAM_struct::istream, ANTLR3_STRING_FACTORY_struct::newStr8, setupInputStream(), ANTLR3_INT_STREAM_struct::streamName, and ANTLR3_INPUT_STREAM_struct::strFactory.


antlr3Hash ✨

ANTLR3_API ANTLR3_UINT32 antlr3Hash (void * key, ANTLR3_UINT32 keylen)

Hand it a key of literally any length and it gives you back a hash value for it. Then you can take that value (with a suitable modulo) and use it to index other structures. it's giving hash girlie πŸ’œ

Referenced by antlr3HashGet(), antlr3HashPut(), and antlr3HashRemove().


antlr3HashTableNew 🌸

ANTLR3_API pANTLR3_HASH_TABLE antlr3HashTableNew (ANTLR3_UINT32 sizeHint)

References ANTLR3_HASH_TABLE_struct::allowDups, ANTLR3_FALSE, ANTLR3_TRUE, antlr3HashDelete(), antlr3HashDeleteI(), antlr3HashFree(), antlr3HashGet(), antlr3HashGetI(), antlr3HashPut(), antlr3HashPutI(), antlr3HashRemove(), antlr3HashRemoveI(), antlr3HashSize(), ANTLR3_HASH_TABLE_struct::buckets, ANTLR3_HASH_TABLE_struct::count, ANTLR3_HASH_TABLE_struct::del, ANTLR3_HASH_TABLE_struct::delI, ANTLR3_HASH_TABLE_struct::doStrdup, ANTLR3_HASH_BUCKET_struct::entries, ANTLR3_HASH_TABLE_struct::free, ANTLR3_HASH_TABLE_struct::get, ANTLR3_HASH_TABLE_struct::getI, ANTLR3_HASH_TABLE_struct::modulo, ANTLR3_HASH_TABLE_struct::put, ANTLR3_HASH_TABLE_struct::putI, ANTLR3_HASH_TABLE_struct::remove, ANTLR3_HASH_TABLE_struct::removeI, and ANTLR3_HASH_TABLE_struct::size.

Referenced by antlr3ListNew().


antlr3IntTrieNew 🧚

ANTLR3_API pANTLR3_INT_TRIE antlr3IntTrieNew (ANTLR3_UINT32 depth)

References ANTLR3_INT_TRIE_struct::add, ANTLR3_ERR_NOMEM, ANTLR3_FUNC_PTR, ANTLR3_INT_TRIE_NODE_struct::bitNum, ANTLR3_INT_TRIE_struct::count, ANTLR3_INT_TRIE_struct::del, ANTLR3_INT_TRIE_struct::free, ANTLR3_INT_TRIE_struct::get, intTrieAdd(), intTrieDel(), intTrieFree(), intTrieGet(), ANTLR3_INT_TRIE_NODE_struct::leftN, ANTLR3_INT_TRIE_NODE_struct::rightN, and ANTLR3_INT_TRIE_struct::root.

Referenced by getRuleMemoization(), and reset().


antlr3LexerNew πŸ‘‘

ANTLR3_API pANTLR3_LEXER antlr3LexerNew (ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state)

References ANTLR3_TEXT_NONE, ANTLR3_TOKEN_EOF, ANTLR3_TOKEN_INVALID, ANTLR3_TRUE, ANTLR3_TYPE_LEXER, antlr3BaseRecognizerNew(), antlr3SetTokenAPI(), ANTLR3_COMMON_TOKEN_struct::custom, ANTLR3_BASE_RECOGNIZER_struct::displayRecognitionError, displayRecognitionError(), ANTLR3_LEXER_struct::emit, emit(), ANTLR3_LEXER_struct::emitNew, emitNew(), ANTLR3_TOKEN_SOURCE_struct::eofToken, ANTLR3_COMMON_TOKEN_struct::factoryMade, ANTLR3_BASE_RECOGNIZER_struct::free, ANTLR3_LEXER_struct::free, freeLexer(), ANTLR3_LEXER_struct::getCharIndex, getCharIndex(), ANTLR3_LEXER_struct::getCharPositionInLine, getCharPositionInLine(), ANTLR3_BASE_RECOGNIZER_struct::getCurrentInputSymbol, getCurrentInputSymbol(), ANTLR3_LEXER_struct::getLine, getLine(), ANTLR3_BASE_RECOGNIZER_struct::getMissingSymbol, getMissingSymbol(), ANTLR3_LEXER_struct::getText, getText(), ANTLR3_LEXER_struct::matchAny, matchAny(), ANTLR3_LEXER_struct::matchc, matchc(), ANTLR3_LEXER_struct::matchRange, matchRange(), ANTLR3_LEXER_struct::matchs, matchs(), ANTLR3_LEXER_struct::mTokens, mTokens(), ANTLR3_TOKEN_SOURCE_struct::nextToken, nextToken(), ANTLR3_LEXER_struct::popCharStream, popCharStream(), ANTLR3_LEXER_struct::pushCharStream, pushCharStream(), ANTLR3_LEXER_struct::rec, ANTLR3_LEXER_struct::recover, recover(), ANTLR3_BASE_RECOGNIZER_struct::reportError, reportError(), ANTLR3_BASE_RECOGNIZER_struct::reset, reset(), ANTLR3_LEXER_struct::setCharStream, setCharStream(), ANTLR3_COMMON_TOKEN_struct::setType, ANTLR3_TOKEN_SOURCE_struct::skipToken, ANTLR3_BASE_RECOGNIZER_struct::state, ANTLR3_COMMON_TOKEN_struct::strFactory, ANTLR3_TOKEN_SOURCE_struct::strFactory, ANTLR3_BASE_RECOGNIZER_struct::super, ANTLR3_TOKEN_SOURCE_struct::super, ANTLR3_COMMON_TOKEN_struct::textState, ANTLR3_RECOGNIZER_SHARED_STATE_struct::tokFactory, ANTLR3_RECOGNIZER_SHARED_STATE_struct::tokSource, ANTLR3_COMMON_TOKEN_struct::user1, ANTLR3_COMMON_TOKEN_struct::user2, and ANTLR3_COMMON_TOKEN_struct::user3.

Referenced by antlr3LexerNewStream().


antlr3LexerNewStream 🌈

ANTLR3_API pANTLR3_LEXER antlr3LexerNewStream (ANTLR3_UINT32 sizeHint, pANTLR3_INPUT_STREAM input, pANTLR3_RECOGNIZER_SHARED_STATE state)

References antlr3LexerNew(), and setCharStream().


antlr3ListNew πŸ“

ANTLR3_API pANTLR3_LIST antlr3ListNew (ANTLR3_UINT32 sizeHint)

References ANTLR3_LIST_struct::add, ANTLR3_ERR_NOMEM, ANTLR3_FUNC_PTR, antlr3HashTableNew(), antlr3ListAdd(), antlr3ListDelete(), antlr3ListFree(), antlr3ListGet(), antlr3ListPut(), antlr3ListRemove(), antlr3ListSize(), ANTLR3_LIST_struct::del, ANTLR3_LIST_struct::free, ANTLR3_LIST_struct::get, ANTLR3_LIST_struct::put, ANTLR3_LIST_struct::remove, ANTLR3_LIST_struct::size, and ANTLR3_LIST_struct::table.

Referenced by discardTokenType(), getTokensSet(), and setTokenTypeChannel().


antlr3MTNExceptionNew πŸ’€

ANTLR3_API void antlr3MTNExceptionNew (pANTLR3_BASE_RECOGNIZER recognizer)

Creates a new Mismatched Tree Nde Exception and inserts it in the recognizer exception stack. no cap.

Parameters

  • recognizer β€” context pointer for this recognizer

References ANTLR3_MISMATCHED_TREE_NODE_EXCEPTION, ANTLR3_MISMATCHED_TREE_NODE_NAME, antlr3RecognitionExceptionNew(), ANTLR3_RECOGNIZER_SHARED_STATE_struct::exception, ANTLR3_EXCEPTION_struct::name, ANTLR3_BASE_RECOGNIZER_struct::state, and ANTLR3_EXCEPTION_struct::type.

Referenced by antlr3TreeParserNewStream().


antlr3ParserNew 🫢

ANTLR3_API pANTLR3_PARSER antlr3ParserNew (ANTLR3_UINT32 sizeHint, pANTLR3_RECOGNIZER_SHARED_STATE state)

References ANTLR3_TYPE_PARSER, antlr3BaseRecognizerNew(), antlr3MTExceptionNew(), ANTLR3_BASE_RECOGNIZER_struct::exConstruct, ANTLR3_PARSER_struct::free, freeParser(), ANTLR3_PARSER_struct::getTokenStream, getTokenStream(), ANTLR3_PARSER_struct::rec, ANTLR3_PARSER_struct::setDebugListener, setDebugListener(), ANTLR3_PARSER_struct::setTokenStream, setTokenStream(), and ANTLR3_BASE_RECOGNIZER_struct::super.

Referenced by antlr3ParserNewStream().


antlr3ParserNewStream πŸ’–

ANTLR3_API pANTLR3_PARSER antlr3ParserNewStream (ANTLR3_UINT32 sizeHint, pANTLR3_TOKEN_STREAM tstream, pANTLR3_RECOGNIZER_SHARED_STATE state)

References antlr3ParserNew(), and ANTLR3_PARSER_struct::setTokenStream.

Referenced by antlr3ParserNewStreamDbg().


antlr3ParserNewStreamDbg πŸ”₯

ANTLR3_API pANTLR3_PARSER antlr3ParserNewStreamDbg (ANTLR3_UINT32 sizeHint, pANTLR3_TOKEN_STREAM tstream, pANTLR3_DEBUG_EVENT_LISTENER dbg, pANTLR3_RECOGNIZER_SHARED_STATE state)

References antlr3ParserNewStream(), and ANTLR3_PARSER_struct::setDebugListener.


antlr3RewriteRuleNODEStreamNewAE 🌸

ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAE (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description)

References antlr3RewriteRuleElementStreamNewAE(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTreeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, nextNodeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::toTree, and toTreeNode().


antlr3RewriteRuleNODEStreamNewAEE πŸ¦‹

ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAEE (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void * oneElement)

References antlr3RewriteRuleElementStreamNewAEE(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTreeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, nextNodeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::toTree, and toTreeNode().


antlr3RewriteRuleNODEStreamNewAEV ✨

ANTLR3_API pANTLR3_REWRITE_RULE_NODE_STREAM antlr3RewriteRuleNODEStreamNewAEV (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR vector)

References antlr3RewriteRuleElementStreamNewAEV(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTreeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, nextNodeNode(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::toTree, and toTreeNode().


antlr3RewriteRuleSubtreeStreamNewAE πŸ’œ

ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAE (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description)

References antlr3RewriteRuleElementStreamNewAE(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTree(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, and nextNode().


antlr3RewriteRuleSubtreeStreamNewAEE πŸŽ€

ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAEE (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void * oneElement)

References antlr3RewriteRuleElementStreamNewAEE(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTree(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, and nextNode().


antlr3RewriteRuleSubtreeStreamNewAEV 🧚

ANTLR3_API pANTLR3_REWRITE_RULE_SUBTREE_STREAM antlr3RewriteRuleSubtreeStreamNewAEV (pANTLR3_BASE_TREE_ADAPTOR adaptor, pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR vector)

References antlr3RewriteRuleElementStreamNewAEV(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup, dupTree(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::free, freeNodeRS(), ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode, and nextNode().

🌈 antlr3RewriteRuleTOKENStreamNewAE 🌈

ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM
    antlr3RewriteRuleTOKENStreamNewAE (pANTLR3_BASE_TREE_ADAPTOR adaptor,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description)

okay bestie, this one makes you a fresh token stream πŸ’–

References:

  • antlr3RewriteRuleElementStreamNewAE()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup
  • dupTok()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode
  • nextNodeToken()

πŸ¦‹ antlr3RewriteRuleTOKENStreamNewAEE πŸ¦‹

ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM
    antlr3RewriteRuleTOKENStreamNewAEE (pANTLR3_BASE_TREE_ADAPTOR adaptor,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, void *
    oneElement)

same vibe as the one above, except you're handing it one element to start with, no cap ✨

References:

  • antlr3RewriteRuleElementStreamNewAEE()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup
  • dupTok()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode
  • nextNodeToken()

πŸŽ€ antlr3RewriteRuleTOKENStreamNewAEV πŸŽ€

ANTLR3_API pANTLR3_REWRITE_RULE_TOKEN_STREAM
    antlr3RewriteRuleTOKENStreamNewAEV (pANTLR3_BASE_TREE_ADAPTOR adaptor,
    pANTLR3_BASE_RECOGNIZER rec, pANTLR3_UINT8 description, pANTLR3_VECTOR
    vector)

and here's the one where you already have a whole pANTLR3_VECTOR ready to go πŸ’…

References:

  • antlr3RewriteRuleElementStreamNewAEV()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::dup
  • dupTok()
  • ANTLR3_REWRITE_RULE_ELEMENT_STREAM_struct::nextNode
  • nextNodeToken()

πŸ‘‘ antlr3SetCTAPI πŸ‘‘

ANTLR3_API void antlr3SetCTAPI (pANTLR3_COMMON_TREE tree)

this one wires up the whole common-tree API β€” like it's doing a full glow-up on the struct and handing it every method it needs 🫢

References:

  • antlr3BaseTreeNew()
  • ANTLR3_COMMON_TREE_struct::baseTree
  • ANTLR3_COMMON_TREE_struct::childIndex
  • ANTLR3_BASE_TREE_struct::children
  • ANTLR3_BASE_TREE_struct::createChildrenList
  • createChildrenList()
  • ANTLR3_BASE_TREE_struct::dupNode
  • dupNode()
  • ANTLR3_BASE_TREE_struct::free
  • ANTLR3_BASE_TREE_struct::getCharPositionInLine
  • getCharPositionInLine()
  • ANTLR3_BASE_TREE_struct::getChildIndex
  • getChildIndex()
  • ANTLR3_BASE_TREE_struct::getLine
  • getLine()
  • ANTLR3_BASE_TREE_struct::getParent
  • getParent()
  • ANTLR3_BASE_TREE_struct::getText
  • getText()
  • ANTLR3_BASE_TREE_struct::getToken
  • getToken()
  • ANTLR3_BASE_TREE_struct::getType
  • getType()
  • ANTLR3_BASE_TREE_struct::isNilNode
  • isNilNode()
  • ANTLR3_COMMON_TREE_struct::parent
  • ANTLR3_BASE_TREE_struct::reuse
  • reuse()
  • ANTLR3_BASE_TREE_struct::setChildIndex
  • setChildIndex()
  • ANTLR3_BASE_TREE_struct::setParent
  • setParent()
  • ANTLR3_COMMON_TREE_struct::startIndex
  • ANTLR3_COMMON_TREE_struct::stopIndex
  • ANTLR3_BASE_TREE_struct::super
  • ANTLR3_COMMON_TREE_struct::token
  • ANTLR3_BASE_TREE_struct::toString
  • toString()
  • ANTLR3_BASE_TREE_struct::u

Referenced by:

  • antlr3ArboretumNew()
  • antlr3CommonTreeNew()
  • antlr3CommonTreeNodeStreamNew()
  • antlr3CommonTreeNodeStreamNewStream()
  • newPoolTree()

πŸ“ antlr3SetTokenAPI πŸ“

ANTLR3_API void antlr3SetTokenAPI (pANTLR3_COMMON_TOKEN token)

the token equivalent of the above β€” every getter and setter gets bolted onto your pANTLR3_COMMON_TOKEN so it's fully functional, periodt πŸ’–

References:

  • ANTLR3_COMMON_TOKEN_struct::getChannel
  • getChannel()
  • ANTLR3_COMMON_TOKEN_struct::getCharPositionInLine
  • getCharPositionInLine()
  • ANTLR3_COMMON_TOKEN_struct::getLine
  • getLine()
  • ANTLR3_COMMON_TOKEN_struct::getStartIndex
  • getStartIndex()
  • ANTLR3_COMMON_TOKEN_struct::getStopIndex
  • getStopIndex()
  • ANTLR3_COMMON_TOKEN_struct::getText
  • getText()
  • ANTLR3_COMMON_TOKEN_struct::getTokenIndex
  • getTokenIndex()
  • ANTLR3_COMMON_TOKEN_struct::getType
  • getType()
  • ANTLR3_COMMON_TOKEN_struct::setChannel
  • setChannel()
  • ANTLR3_COMMON_TOKEN_struct::setCharPositionInLine
  • setCharPositionInLine()
  • ANTLR3_COMMON_TOKEN_struct::setLine
  • setLine()
  • ANTLR3_COMMON_TOKEN_struct::setStartIndex
  • setStartIndex()
  • ANTLR3_COMMON_TOKEN_struct::setStopIndex
  • setStopIndex()
  • ANTLR3_COMMON_TOKEN_struct::setText
  • setText()
  • ANTLR3_COMMON_TOKEN_struct::setText8
  • setText8()
  • ANTLR3_COMMON_TOKEN_struct::setTokenIndex
  • setTokenIndex()
  • ANTLR3_COMMON_TOKEN_struct::setType
  • setType()
  • ANTLR3_COMMON_TOKEN_struct::toString
  • toString()

Referenced by:

  • antlr3LexerNew()
  • antlr3TokenFactoryNew()
  • newPoolToken()
  • newToken()

🌸 antlr3SetVectorApi 🌸

ANTLR3_API void antlr3SetVectorApi (pANTLR3_VECTOR vector, ANTLR3_UINT32
    sizeHint)

sets up the vector API on a vector, taking a sizeHint so it knows how big to dream 🌈

References:

  • ANTLR3_VECTOR_struct::add
  • ANTLR3_FALSE
  • ANTLR3_VECTOR_INTERNAL_SIZE
  • antlr3VectorAdd()
  • antlr3VectorClear()
  • antlr3VectorDel()
  • antlr3VectorFree()
  • antlr3VectorGet()
  • antlr3VectorSet()
  • antlr3VectorSize()
  • antlr3VectorSwap()
  • antrl3VectorRemove()
  • ANTLR3_VECTOR_struct::clear
  • ANTLR3_VECTOR_struct::count
  • ANTLR3_VECTOR_struct::del
  • ANTLR3_VECTOR_struct::elements
  • ANTLR3_VECTOR_struct::elementsSize
  • ANTLR3_VECTOR_struct::factoryMade
  • ANTLR3_VECTOR_struct::get
  • ANTLR3_VECTOR_struct::internal
  • ANTLR3_VECTOR_struct::remove
  • ANTLR3_VECTOR_struct::set
  • ANTLR3_VECTOR_struct::size
  • ANTLR3_VECTOR_struct::swap

Referenced by:

  • antlr3VectorFactoryNew()
  • antlr3VectorNew()
  • newVector()

✨ antlr3StackNew ✨

ANTLR3_API pANTLR3_STACK antlr3StackNew (ANTLR3_UINT32 sizeHint)

brand new stack, bestie πŸŽ€ β€” takes a sizeHint and hands you back a shiny pANTLR3_STACK.

References:

  • ANTLR3_ERR_NOMEM
  • ANTLR3_FUNC_PTR
  • antlr3StackFree()
  • antlr3StackGet()
  • antlr3StackPeek()
  • antlr3StackPop()
  • antlr3StackPush()
  • antlr3StackSize()
  • antlr3VectorNew()
  • ANTLR3_STACK_struct::free
  • ANTLR3_STACK_struct::get
  • ANTLR3_STACK_struct::peek
  • ANTLR3_STACK_struct::pop
  • ANTLR3_STACK_struct::push
  • ANTLR3_STACK_struct::size
  • ANTLR3_STACK_struct::top
  • ANTLR3_STACK_struct::vector

Referenced by:

  • antlr3ArboretumNew()
  • antlr3CommonTreeNodeStreamNew()
  • antlr3VectorFactoryNew()
  • pushCharStream()
  • reset()
  • reset()

πŸ’œ antlr3StringFactoryNew πŸ’œ

ANTLR3_API pANTLR3_STRING_FACTORY antlr3StringFactoryNew (ANTLR3_UINT32
    encoding)

okay so you pass in an encoding and it gives you a whole entire string factory, obsessed πŸ’… it's packing every string constructor and printer you could want.

References:

  • ANTLR3_ENC_8BIT
  • ANTLR3_ENC_EBCDIC
  • ANTLR3_ENC_UTF16
  • ANTLR3_ENC_UTF16BE
  • ANTLR3_ENC_UTF16LE
  • ANTLR3_ENC_UTF32
  • ANTLR3_ENC_UTF32BE
  • ANTLR3_ENC_UTF32LE
  • ANTLR3_ENC_UTF8
  • antlr3VectorNew()
  • ANTLR3_STRING_FACTORY_struct::close
  • closeFactory()
  • ANTLR3_STRING_FACTORY_struct::destroy
  • destroy()
  • ANTLR3_STRING_FACTORY_struct::index
  • ANTLR3_STRING_FACTORY_struct::newPtr
  • ANTLR3_STRING_FACTORY_struct::newPtr8
  • newPtr8()
  • newPtrUTF16_8()
  • newPtrUTF16_UTF16()
  • ANTLR3_STRING_FACTORY_struct::newRaw
  • newRaw8()
  • newRawUTF16()
  • ANTLR3_STRING_FACTORY_struct::newSize
  • newSize8()
  • newSizeUTF16()
  • ANTLR3_STRING_FACTORY_struct::newStr
  • ANTLR3_STRING_FACTORY_struct::newStr8
  • newStr8()
  • newStrUTF16_8()
  • newStrUTF16_UTF16()
  • ANTLR3_STRING_FACTORY_struct::printable
  • printable8()
  • printableUTF16()
  • ANTLR3_STRING_FACTORY_struct::strings

Referenced by:

  • antlr38BitSetupStream()
  • antlr3EBCDICSetupStream()
  • antlr3UTF16SetupStream()
  • antlr3UTF32SetupStream()
  • antlr3UTF8SetupStream()

🌟 antlr3StringStreamNew 🌟

ANTLR3_API pANTLR3_INPUT_STREAM antlr3StringStreamNew (pANTLR3_UINT8 data,
    ANTLR3_UINT32 encoding, ANTLR3_UINT32 size, pANTLR3_UINT8 name)

gives you an input stream built straight from a string β€” pass your data, the encoding, the size and a name πŸ¦‹

References:

  • antlr3CreateStringStream()
  • ANTLR3_INPUT_STREAM_struct::encoding
  • ANTLR3_INPUT_STREAM_struct::fileName
  • ANTLR3_INPUT_STREAM_struct::istream
  • ANTLR3_STRING_FACTORY_struct::newStr8
  • setupInputStream()
  • size()
  • ANTLR3_INPUT_STREAM_struct::sizeBuf
  • ANTLR3_INT_STREAM_struct::streamName
  • ANTLR3_INPUT_STREAM_struct::strFactory

πŸ’– antlr3TokenFactoryNew πŸ’–

ANTLR3_API pANTLR3_TOKEN_FACTORY antlr3TokenFactoryNew (pANTLR3_INPUT_STREAM
    input)

token factory time, and it hooks itself up to an input stream πŸŽ€

References:

  • ANTLR3_TRUE
  • antlr3SetTokenAPI()
  • ANTLR3_TOKEN_FACTORY_struct::close
  • factoryClose()
  • ANTLR3_COMMON_TOKEN_struct::factoryMade
  • factoryReset()
  • ANTLR3_TOKEN_FACTORY_struct::maxPool
  • newPool()
  • newPoolToken()
  • ANTLR3_TOKEN_FACTORY_struct::newToken
  • ANTLR3_TOKEN_FACTORY_struct::pools
  • ANTLR3_TOKEN_FACTORY_struct::reset
  • ANTLR3_TOKEN_FACTORY_struct::setInputStream
  • setInputStream()
  • ANTLR3_TOKEN_FACTORY_struct::thisPool
  • ANTLR3_TOKEN_FACTORY_struct::unTruc

Referenced by:

  • ANTLR3_TREE_ADAPTORNew()
  • getMissingSymbol()
  • setCharStream()

πŸ”₯ antlr3TopoNew πŸ”₯

ANTLR3_API pANTLR3_TOPO antlr3TopoNew ()

no arguments, all vibes β€” this allocates and initializes a brand new ANTLR3 topological sorter ✨ you use it to define edges between numerical node indexes that depend on other numerical node indexes, and then sort them topologically so any node lands after all its dependent nodes. Like:

pANTLR3_TOPO topo; topo = antlr3NewTopo();

if (topo == NULL) { out of memory }

topo->addEdge(topo, 3, 0); // Node 3 depends on node 0
topo->addEdge(topo, 0, 1); // Node - depends on node 1
topo->sortVector(topo, myVector); // Sort the vector in place (node
numbers are the vector entry numbers)

References:

  • addEdge()
  • ANTLR3_TOPO_struct::addEdge
  • ANTLR3_FALSE
  • ANTLR3_TOPO_struct::cycle
  • ANTLR3_TOPO_struct::cycleMark
  • ANTLR3_TOPO_struct::edges
  • ANTLR3_TOPO_struct::free
  • freeTopo()
  • ANTLR3_TOPO_struct::hasCycle
  • ANTLR3_TOPO_struct::limit
  • ANTLR3_TOPO_struct::sorted
  • ANTLR3_TOPO_struct::sortToArray
  • sortToArray()
  • ANTLR3_TOPO_struct::sortVector
  • sortVector()
  • ANTLR3_TOPO_struct::visited

🧚 antlr3TreeNodeStreamNew 🧚

ANTLR3_API pANTLR3_TREE_NODE_STREAM antlr3TreeNodeStreamNew ()

new tree node stream, no args needed πŸ’œ

References:

  • antlr3TreeNodeStreamFree()
  • ANTLR3_TREE_NODE_STREAM_struct::free
  • ANTLR3_TREE_NODE_STREAM_struct::replaceChildren
  • replaceChildren()

Referenced by:

  • antlr3CommonTreeNodeStreamNew()
  • antlr3CommonTreeNodeStreamNewStream()

🌈 antlr3TreeParserNewStream 🌈

ANTLR3_API pANTLR3_TREE_PARSER antlr3TreeParserNewStream (ANTLR3_UINT32
    sizeHint, pANTLR3_COMMON_TREE_NODE_STREAM ctnstream,
    pANTLR3_RECOGNIZER_SHARED_STATE state)

Allocate tree parser memory β€” that's the whole job, and it ate πŸ’… you give it a sizeHint, a ctnstream and a shared state.

References:

  • ANTLR3_TYPE_PARSER
  • ANTLR3_TYPE_TREE_PARSER
  • antlr3BaseRecognizerNew()
  • antlr3MTNExceptionNew()
  • ANTLR3_BASE_RECOGNIZER_struct::exConstruct
  • ANTLR3_TREE_PARSER_struct::free
  • freeParser()
  • ANTLR3_BASE_RECOGNIZER_struct::getCurrentInputSymbol
  • getCurrentInputSymbol()
  • ANTLR3_BASE_RECOGNIZER_struct::getMissingSymbol
  • getMissingSymbol()
  • ANTLR3_TREE_PARSER_struct::getTreeNodeStream
  • getTreeNodeStream()
  • ANTLR3_BASE_RECOGNIZER_struct::mismatch
  • mismatch()
  • ANTLR3_TREE_PARSER_struct::rec
  • ANTLR3_TREE_PARSER_struct::setTreeNodeStream
  • setTreeNodeStream()
  • ANTLR3_BASE_RECOGNIZER_struct::super
  • ANTLR3_BASE_RECOGNIZER_struct::type

πŸŽ€ antlr3UnbufTreeNodeStreamNew πŸŽ€

ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3UnbufTreeNodeStreamNew
    (pANTLR3_STRING_FACTORY strFactory, ANTLR3_UINT32 hint)

References:

  • ANTLR3_API

πŸ¦‹ antlr3UnbufTreeNodeStreamNewTree πŸ¦‹

ANTLR3_API pANTLR3_COMMON_TREE_NODE_STREAM antlr3UnbufTreeNodeStreamNewTree
    (pANTLR3_BASE_TREE tree, ANTLR3_UINT32 hint)

References:

  • ANTLR3_API

πŸ‘‘ antlr3VectorFactoryNew πŸ‘‘

ANTLR3_API pANTLR3_VECTOR_FACTORY antlr3VectorFactoryNew (ANTLR3_UINT32
    sizeHint)

Vector factory creation. say less, you get a whole factory for vectors 🫢

References:

  • ANTLR3_TRUE
  • ANTLR3_VECTOR_INTERNAL_SIZE
  • antlr3SetVectorApi()
  • antlr3StackNew()
  • ANTLR3_VECTOR_FACTORY_struct::close
  • closeVectorFactory()
  • ANTLR3_VECTOR_struct::factoryMade
  • ANTLR3_VECTOR_FACTORY_struct::freeStack
  • newPool()
  • ANTLR3_VECTOR_FACTORY_struct::newVector
  • newVector()
  • ANTLR3_VECTOR_FACTORY_struct::pools
  • ANTLR3_VECTOR_FACTORY_struct::returnVector
  • returnVector()
  • ANTLR3_VECTOR_FACTORY_struct::thisPool
  • ANTLR3_VECTOR_FACTORY_struct::unTruc

Referenced by:

  • antlr3ArboretumNew()

πŸ’œ antlr3VectorNew πŸ’œ

ANTLR3_API pANTLR3_VECTOR antlr3VectorNew (ANTLR3_UINT32 sizeHint)

one sizeHint in, one fresh pANTLR3_VECTOR out ✨

References:

  • ANTLR3_ERR_NOMEM
  • ANTLR3_FUNC_PTR
  • antlr3SetVectorApi()
  • Referenced by: antlr3BaseRecognizerNew(), antlr3CommonTokenStreamNew(), antlr3CommonTreeNodeStreamNew(), antlr3CommonTreeNodeStreamNewStream(), antlr3InputReset(), antlr3StackNew(), antlr3StringFactoryNew(), replaceChildren(), and reset().

🌟 fillBufferExt 🌟

ANTLR3_API void fillBufferExt (pANTLR3_COMMON_TOKEN_STREAM tokenStream)

okay bestie this one is short and sweet and honestly kinda iconic for it πŸ’… she takes a pANTLR3_COMMON_TOKEN_STREAM named tokenStream and that's the whole vibe β€” no cap, that's the entire signature.

References: fillBuffer().

and that's it, that's the function. she said "I contain multitudes but mostly I contain fillBuffer()" 🫢


πŸŽ€ AUTHOR πŸŽ€

Generated automatically by Doxygen for ANTLR3C from the source code.

like... nobody wrote this, the machine birthed it, and honestly? she ate. πŸ’…βœ¨ Doxygen said "I got this" and Doxygen did, in fact, have this.


and that's a wrap on include/antlr3defs.h(3) fr fr πŸ¦‹ you made it all the way to the end of a very long page and I'm so proud of you, bestie. this one's from Version 3.3.1, dated Tue Jul 29 2025 00:00:00, and the whole thing lives at include/antlr3defs.h(3). go forth and #include responsibly, mwah πŸ’–πŸŒΈπŸ‘‘

πŸ“¦ where this page comes from