| SYM_ENTRY | Type (Structure)

vat.h, files.h, unknown.h

typedef struct {

| char name[8];

| unsigned short compat;

| union {

| unsigned short flags_n;

| struct {

| unsigned int busy : 1, local : 1, flag1_5 : 1, flag1_4 : 1, collapsed : 1, twin : 1, archived : 1, in_view : 1;

| unsigned int folder : 1, overwritten : 1, checked : 1, hidden : 1, locked : 1, statvar : 1, graph_ref_1 : 1, graph_ref_0 : 1;

| } bits;

| } flags;

| HANDLE handle;

} SYM_ENTRY;

A structure representing a VAT symbol entry.

Principally, SYM_ENTRY consists of the symbol name, the flags, and the handle associated with the symbol. The flags are defined as a union, so you can access to all flags together using the field flags_n (in such case, constants defined in the enum SymFlags may be useful for bit masking), or access to individual flags (which are defined as bit fields) using the field bits. Some flags are unused, and some flags have an unknown meaning. At the moment, the known flags are: locked (set for locked symbols), hidden (set for symbols which are hidden for the TI-Basic; in fact, "hidden" files are files which are currently opened, i.e. in-use files), checked (set for symbols which are checked in VAR-LINK dialog), folder (set for folder entries), collapsed (set for collapsed folders; this makes sense only on AMS 2.xx), archived (set for archived symbols), twin (set for twin symols, see SymAddTwin), and local (set for local symbols). For example, if "SymPtr" is the pointer to the VAT symbol entry, the following command makes this symbol invisible for TIOS:

    SymPtr->flags.bits.hidden = 1;

Note that the twin bit may only be set if the symbol is really a twin symbol, i.e. an entry with the same name exists. Otherwise, the system will crash upon the next call to SymAdd.
The handle field always contains a handle to a MULTI_EXPR structure. It must contain valid data for the operating system to operate properly.
Each symbol has also associated compatibility flag (field compat). It determines how the symbol will behave during sending to unexpanded (non-Plus) TI-92. There are four possible values of the compatibility flag (these constants are defined in enum CompatFlags):

CF_NONE | Sends immediately
CF_CONVERT | Converts and sends
CF_ENHANCED | An enhanced token - may or may not work
CF_NEW | Will not be sent

A compatibilty number of CF_CONVERT or CF_NEW is determined from symbols context. CF_ENHANCED is related mainly for internal tokens, which does not appear in final results and programs.
Here is the list of token tags (see Tags) which belong to CF_CONVERT, CF_ENHANCED and CF_NEW categories:

Convert: | LOCALVAR_TAG
Enhanced: | _VAR_Q_TAG, PN_INFINITY_TAG, tag 0x5F (internal), START_TAG, ISTORE_TAG, ANS_TAG, ENTRY_TAG, MATRIX_TAG, ERROR_MSG_TAG, tags 0xF5, 0xF6 and 0xF7 (internal)

New:

PART_TAG, PN1_TAG, PN2_TAG, EIGVC_TAG, EIGVL_TAG, DASH_TAG, DESOLVE_TAG, FDASH_TAG, ASM_TAG, ISPRIME_TAG, OTH_TAG, ROTATE_TAG, PARENTH_START_TAG, PARENTH_END_TAG, MAT_START_TAG, MAT_END_TAG, LIST_START_TAG, LIST_END_TAG, COMMA_TAG, SEMICOLON_TAG, COMPLEX_ANGLE_TAG, SINGLE_QUOTE_TAG, QUOTE_TAG, POLCPLX_TAG, TMPCNV_TAG, DELTA_TMPCNV_TAG, GETUNITS_TAG, SETUNITS_TAG, BIN_TAG, HEX_TAG, INT2BIN_TAG, INT2DEC_TAG, INT2HEX_TAG, DET_TOL_TAG, REF_TOL_TAG, RREF_TOL_TAG, SIMULT_TOL_TAG, GETCONFG_TAG, V_AUGMENT_TAG, EYE_PSI_TAG, TPLOT_TAG, DIFTOL_TAG, ZEYE_PSI_TAG, T0_TAG, DTIME_TAG, NCURVES_TAG, FLDRES_TAG, ESTEP_TAG, ZT0DE_TAG, ZTMAXDE_TAG, ZTSTEPDE_TAG, ZTPLOTDE_TAG, NCONTOUR_TAG, DISPHOME_ITAG, EXEC_ITAG, ARCHIVE_ITAG, UNARCHIV_ITAG, LU_ITAG, QR_ITAG, BLDDATA_ITAG, DRWCTOUR_ITAG, NEWPROB_ITAG, SINREG_ITAG, LOGISTIC_ITAG, CUSTMON_ITAG, CUSTMOFF_ITAG, SENDCHAT_ITAG

Note: SYM_ENTRY structures are usually not locked, which means that pointers to them will become invalid if a heap compression occurs. Basically, this means that you can only operate on them for a short time in which you know that no heap compression can occur.