Pass kind information into initTagEntry()
The usage in lregex is hacky (casting const char * to char *) but it's the quickest way to implement it right now (the question is whether we shouldn't revert back to POSIX regex and simply use the uctags implementation).
This commit is contained in:
parent
359c60b81b
commit
4fbd38f690
@ -400,7 +400,7 @@ extern void makeTagEntry (const tagEntryInfo *const tag)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
extern void initTagEntry (tagEntryInfo *const e, const char *const name)
|
extern void initTagEntry (tagEntryInfo *const e, const char *const name, const kindOption *kind)
|
||||||
{
|
{
|
||||||
Assert (File.source.name != NULL);
|
Assert (File.source.name != NULL);
|
||||||
memset (e, 0, sizeof (tagEntryInfo));
|
memset (e, 0, sizeof (tagEntryInfo));
|
||||||
@ -410,6 +410,7 @@ extern void initTagEntry (tagEntryInfo *const e, const char *const name)
|
|||||||
e->filePosition = getInputFilePosition ();
|
e->filePosition = getInputFilePosition ();
|
||||||
e->sourceFileName = getSourceFileTagPath ();
|
e->sourceFileName = getSourceFileTagPath ();
|
||||||
e->name = name;
|
e->name = name;
|
||||||
|
e->kind = kind;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -62,8 +62,7 @@ typedef struct sTagEntryInfo {
|
|||||||
boolean truncateLine; /* truncate tag line at end of tag name? */
|
boolean truncateLine; /* truncate tag line at end of tag name? */
|
||||||
const char *sourceFileName; /* name of source file */
|
const char *sourceFileName; /* name of source file */
|
||||||
const char *name; /* name of the tag */
|
const char *name; /* name of the tag */
|
||||||
const char *kindName; /* kind of tag */
|
const kindOption *kind; /* kind descriptor */
|
||||||
char kind; /* single character representation of kind */
|
|
||||||
struct {
|
struct {
|
||||||
const char* access;
|
const char* access;
|
||||||
const char* fileScope;
|
const char* fileScope;
|
||||||
@ -95,7 +94,7 @@ extern void closeTagFile (const boolean resize);
|
|||||||
extern void beginEtagsFile (void);
|
extern void beginEtagsFile (void);
|
||||||
extern void endEtagsFile (const char *const name);
|
extern void endEtagsFile (const char *const name);
|
||||||
extern void makeTagEntry (const tagEntryInfo *const tag);
|
extern void makeTagEntry (const tagEntryInfo *const tag);
|
||||||
extern void initTagEntry (tagEntryInfo *const e, const char *const name);
|
extern void initTagEntry (tagEntryInfo *const e, const char *const name, const kindOption *kind);
|
||||||
|
|
||||||
#endif /* _ENTRY_H */
|
#endif /* _ENTRY_H */
|
||||||
|
|
||||||
|
@ -10,6 +10,11 @@
|
|||||||
|
|
||||||
#include "general.h"
|
#include "general.h"
|
||||||
|
|
||||||
|
#define KIND_NULL '\0'
|
||||||
|
|
||||||
|
#define KIND_FILE_DEFAULT 'F'
|
||||||
|
#define KIND_FILE_DEFAULT_LONG "file"
|
||||||
|
|
||||||
typedef struct sKindOption {
|
typedef struct sKindOption {
|
||||||
boolean enabled; /* are tags for kind enabled? */
|
boolean enabled; /* are tags for kind enabled? */
|
||||||
char letter; /* kind letter */
|
char letter; /* kind letter */
|
||||||
|
@ -65,6 +65,7 @@ typedef struct sCppState {
|
|||||||
boolean resolveRequired; /* must resolve if/else/elif/endif branch */
|
boolean resolveRequired; /* must resolve if/else/elif/endif branch */
|
||||||
boolean hasAtLiteralStrings; /* supports @"c:\" strings */
|
boolean hasAtLiteralStrings; /* supports @"c:\" strings */
|
||||||
boolean hasCxxRawLiteralStrings; /* supports R"xxx(...)xxx" strings */
|
boolean hasCxxRawLiteralStrings; /* supports R"xxx(...)xxx" strings */
|
||||||
|
const kindOption *defineMacroKind;
|
||||||
struct sDirective {
|
struct sDirective {
|
||||||
enum eState state; /* current directive being processed */
|
enum eState state; /* current directive being processed */
|
||||||
boolean accept; /* is a directive syntactically permitted? */
|
boolean accept; /* is a directive syntactically permitted? */
|
||||||
@ -87,6 +88,7 @@ static cppState Cpp = {
|
|||||||
FALSE, /* resolveRequired */
|
FALSE, /* resolveRequired */
|
||||||
FALSE, /* hasAtLiteralStrings */
|
FALSE, /* hasAtLiteralStrings */
|
||||||
FALSE, /* hasCxxRawLiteralStrings */
|
FALSE, /* hasCxxRawLiteralStrings */
|
||||||
|
NULL, /* defineMacroKind */
|
||||||
{
|
{
|
||||||
DRCTV_NONE, /* state */
|
DRCTV_NONE, /* state */
|
||||||
FALSE, /* accept */
|
FALSE, /* accept */
|
||||||
@ -111,7 +113,8 @@ extern unsigned int getDirectiveNestLevel (void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
extern void cppInit (const boolean state, const boolean hasAtLiteralStrings,
|
extern void cppInit (const boolean state, const boolean hasAtLiteralStrings,
|
||||||
const boolean hasCxxRawLiteralStrings)
|
const boolean hasCxxRawLiteralStrings,
|
||||||
|
const kindOption *defineMacroKind)
|
||||||
{
|
{
|
||||||
BraceFormat = state;
|
BraceFormat = state;
|
||||||
|
|
||||||
@ -120,6 +123,7 @@ extern void cppInit (const boolean state, const boolean hasAtLiteralStrings,
|
|||||||
Cpp.resolveRequired = FALSE;
|
Cpp.resolveRequired = FALSE;
|
||||||
Cpp.hasAtLiteralStrings = hasAtLiteralStrings;
|
Cpp.hasAtLiteralStrings = hasAtLiteralStrings;
|
||||||
Cpp.hasCxxRawLiteralStrings = hasCxxRawLiteralStrings;
|
Cpp.hasCxxRawLiteralStrings = hasCxxRawLiteralStrings;
|
||||||
|
Cpp.defineMacroKind = defineMacroKind;
|
||||||
|
|
||||||
Cpp.directive.state = DRCTV_NONE;
|
Cpp.directive.state = DRCTV_NONE;
|
||||||
Cpp.directive.accept = TRUE;
|
Cpp.directive.accept = TRUE;
|
||||||
@ -310,13 +314,11 @@ static void makeDefineTag (const char *const name, boolean parameterized)
|
|||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
|
|
||||||
initTagEntry (&e, name);
|
initTagEntry (&e, name, Cpp.defineMacroKind);
|
||||||
|
|
||||||
e.lineNumberEntry = (boolean) (Option.locate != EX_PATTERN);
|
e.lineNumberEntry = (boolean) (Option.locate != EX_PATTERN);
|
||||||
e.isFileScope = isFileScope;
|
e.isFileScope = isFileScope;
|
||||||
e.truncateLine = TRUE;
|
e.truncateLine = TRUE;
|
||||||
e.kindName = "macro";
|
|
||||||
e.kind = 'd';
|
|
||||||
if (parameterized)
|
if (parameterized)
|
||||||
{
|
{
|
||||||
e.extensionFields.signature = getArglistFromFilePos(getInputFilePosition()
|
e.extensionFields.signature = getArglistFromFilePos(getInputFilePosition()
|
||||||
|
@ -37,7 +37,8 @@
|
|||||||
extern boolean isBraceFormat (void);
|
extern boolean isBraceFormat (void);
|
||||||
extern unsigned int getDirectiveNestLevel (void);
|
extern unsigned int getDirectiveNestLevel (void);
|
||||||
extern void cppInit (const boolean state, const boolean hasAtLiteralStrings,
|
extern void cppInit (const boolean state, const boolean hasAtLiteralStrings,
|
||||||
const boolean hasCxxRawLiteralStrings);
|
const boolean hasCxxRawLiteralStrings,
|
||||||
|
const kindOption *defineMacroKind);
|
||||||
extern void cppTerminate (void);
|
extern void cppTerminate (void);
|
||||||
extern void cppBeginStatement (void);
|
extern void cppBeginStatement (void);
|
||||||
extern void cppEndStatement (void);
|
extern void cppEndStatement (void);
|
||||||
|
@ -32,6 +32,7 @@
|
|||||||
#include "entry.h"
|
#include "entry.h"
|
||||||
#include "parse.h"
|
#include "parse.h"
|
||||||
#include "read.h"
|
#include "read.h"
|
||||||
|
#include "kind.h"
|
||||||
|
|
||||||
#ifdef HAVE_REGEX
|
#ifdef HAVE_REGEX
|
||||||
|
|
||||||
@ -53,13 +54,6 @@
|
|||||||
*/
|
*/
|
||||||
#if defined (POSIX_REGEX)
|
#if defined (POSIX_REGEX)
|
||||||
|
|
||||||
struct sKind {
|
|
||||||
boolean enabled;
|
|
||||||
char letter;
|
|
||||||
char* name;
|
|
||||||
char* description;
|
|
||||||
};
|
|
||||||
|
|
||||||
enum pType { PTRN_TAG, PTRN_CALLBACK };
|
enum pType { PTRN_TAG, PTRN_CALLBACK };
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@ -68,7 +62,7 @@ typedef struct {
|
|||||||
union {
|
union {
|
||||||
struct {
|
struct {
|
||||||
char *name_pattern;
|
char *name_pattern;
|
||||||
struct sKind kind;
|
kindOption kind;
|
||||||
} tag;
|
} tag;
|
||||||
struct {
|
struct {
|
||||||
regexCallback function;
|
regexCallback function;
|
||||||
@ -113,11 +107,11 @@ static void clearPatternSet (const langType language)
|
|||||||
{
|
{
|
||||||
eFree (p->u.tag.name_pattern);
|
eFree (p->u.tag.name_pattern);
|
||||||
p->u.tag.name_pattern = NULL;
|
p->u.tag.name_pattern = NULL;
|
||||||
eFree (p->u.tag.kind.name);
|
eFree ((char *)p->u.tag.kind.name);
|
||||||
p->u.tag.kind.name = NULL;
|
p->u.tag.kind.name = NULL;
|
||||||
if (p->u.tag.kind.description != NULL)
|
if (p->u.tag.kind.description != NULL)
|
||||||
{
|
{
|
||||||
eFree (p->u.tag.kind.description);
|
eFree ((char *)p->u.tag.kind.description);
|
||||||
p->u.tag.kind.description = NULL;
|
p->u.tag.kind.description = NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -134,16 +128,14 @@ static void clearPatternSet (const langType language)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
static void makeRegexTag (
|
static void makeRegexTag (
|
||||||
const vString* const name, const struct sKind* const kind)
|
const vString* const name, const kindOption* const kind)
|
||||||
{
|
{
|
||||||
Assert (kind != NULL);
|
Assert (kind != NULL);
|
||||||
if (kind->enabled)
|
if (kind->enabled)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
Assert (name != NULL && vStringLength (name) > 0);
|
Assert (name != NULL && vStringLength (name) > 0);
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), kind);
|
||||||
e.kind = kind->letter;
|
|
||||||
e.kindName = kind->name;
|
|
||||||
makeTagEntry (&e);
|
makeTagEntry (&e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -375,7 +367,7 @@ static void parseKinds (
|
|||||||
|
|
||||||
static void printRegexKind (const regexPattern *pat, unsigned int i, boolean indent)
|
static void printRegexKind (const regexPattern *pat, unsigned int i, boolean indent)
|
||||||
{
|
{
|
||||||
const struct sKind *const kind = &pat [i].u.tag.kind;
|
const kindOption *const kind = &pat [i].u.tag.kind;
|
||||||
const char *const indentation = indent ? " " : "";
|
const char *const indentation = indent ? " " : "";
|
||||||
Assert (pat [i].type == PTRN_TAG);
|
Assert (pat [i].type == PTRN_TAG);
|
||||||
printf ("%s%c %s %s\n", indentation,
|
printf ("%s%c %s %s\n", indentation,
|
||||||
|
@ -33,6 +33,13 @@
|
|||||||
static parserDefinitionFunc* BuiltInParsers[] = { PARSER_LIST };
|
static parserDefinitionFunc* BuiltInParsers[] = { PARSER_LIST };
|
||||||
parserDefinition** LanguageTable = NULL;
|
parserDefinition** LanguageTable = NULL;
|
||||||
unsigned int LanguageCount = 0;
|
unsigned int LanguageCount = 0;
|
||||||
|
static kindOption defaultFileKind = {
|
||||||
|
.enabled = FALSE,
|
||||||
|
.letter = KIND_FILE_DEFAULT,
|
||||||
|
.name = KIND_FILE_DEFAULT_LONG,
|
||||||
|
.description = KIND_FILE_DEFAULT_LONG,
|
||||||
|
};
|
||||||
|
|
||||||
tagEntryFunction TagEntryFunction = NULL;
|
tagEntryFunction TagEntryFunction = NULL;
|
||||||
void *TagEntryUserData = NULL;
|
void *TagEntryUserData = NULL;
|
||||||
|
|
||||||
@ -53,10 +60,7 @@ extern void makeSimpleTag (const vString* const name,
|
|||||||
if (name != NULL && vStringLength (name) > 0)
|
if (name != NULL && vStringLength (name) > 0)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), &(kinds [kind]));
|
||||||
|
|
||||||
e.kindName = kinds [kind].name;
|
|
||||||
e.kind = kinds [kind].letter;
|
|
||||||
|
|
||||||
makeTagEntry (&e);
|
makeTagEntry (&e);
|
||||||
}
|
}
|
||||||
@ -71,10 +75,8 @@ extern void makeSimpleScopedTag (const vString* const name,
|
|||||||
if (name != NULL && vStringLength (name) > 0)
|
if (name != NULL && vStringLength (name) > 0)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), &(kinds [kind]));
|
||||||
|
|
||||||
e.kindName = kinds [kind].name;
|
|
||||||
e.kind = kinds [kind].letter;
|
|
||||||
e.extensionFields.scopeKind = &(kinds [kind]);
|
e.extensionFields.scopeKind = &(kinds [kind]);
|
||||||
e.extensionFields.scopeName = scopeName;
|
e.extensionFields.scopeName = scopeName;
|
||||||
e.extensionFields.access = laccess;
|
e.extensionFields.access = laccess;
|
||||||
@ -91,6 +93,7 @@ extern parserDefinition* parserNew (const char* name)
|
|||||||
{
|
{
|
||||||
parserDefinition* result = xCalloc (1, parserDefinition);
|
parserDefinition* result = xCalloc (1, parserDefinition);
|
||||||
result->name = eStrdup (name);
|
result->name = eStrdup (name);
|
||||||
|
result->fileKind = &defaultFileKind;
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -101,6 +104,19 @@ extern const char *getLanguageName (const langType language)
|
|||||||
return LanguageTable [language]->name;
|
return LanguageTable [language]->name;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extern kindOption* getLanguageFileKind (const langType language)
|
||||||
|
{
|
||||||
|
kindOption* kind;
|
||||||
|
|
||||||
|
Assert (0 <= language && language < (int) LanguageCount);
|
||||||
|
|
||||||
|
kind = LanguageTable [language]->fileKind;
|
||||||
|
|
||||||
|
Assert (kind != KIND_NULL);
|
||||||
|
|
||||||
|
return kind;
|
||||||
|
}
|
||||||
|
|
||||||
extern langType getNamedLanguage (const char *const name)
|
extern langType getNamedLanguage (const char *const name)
|
||||||
{
|
{
|
||||||
langType result = LANG_IGNORE;
|
langType result = LANG_IGNORE;
|
||||||
@ -595,13 +611,11 @@ static void makeFileTag (const char *const fileName)
|
|||||||
if (Option.include.fileNames)
|
if (Option.include.fileNames)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, baseFilename (fileName));
|
initTagEntry (&tag, baseFilename (fileName), getInputLanguageFileKind ());
|
||||||
|
|
||||||
tag.isFileEntry = TRUE;
|
tag.isFileEntry = TRUE;
|
||||||
tag.lineNumberEntry = TRUE;
|
tag.lineNumberEntry = TRUE;
|
||||||
tag.lineNumber = 1;
|
tag.lineNumber = 1;
|
||||||
tag.kindName = "file";
|
|
||||||
tag.kind = 'F';
|
|
||||||
|
|
||||||
makeTagEntry (&tag);
|
makeTagEntry (&tag);
|
||||||
}
|
}
|
||||||
|
@ -46,6 +46,7 @@ typedef struct {
|
|||||||
char* name; /* name of language */
|
char* name; /* name of language */
|
||||||
kindOption* kinds; /* tag kinds handled by parser */
|
kindOption* kinds; /* tag kinds handled by parser */
|
||||||
unsigned int kindCount; /* size of `kinds' list */
|
unsigned int kindCount; /* size of `kinds' list */
|
||||||
|
kindOption* fileKind; /* kind for overriding the default fileKind */
|
||||||
const char* const* extensions; /* list of default extensions */
|
const char* const* extensions; /* list of default extensions */
|
||||||
const char* const* patterns; /* list of default file name patterns */
|
const char* const* patterns; /* list of default file name patterns */
|
||||||
parserInitialize initialize; /* initialization routine, if needed */
|
parserInitialize initialize; /* initialization routine, if needed */
|
||||||
@ -95,6 +96,7 @@ extern void makeSimpleScopedTag (const vString* const name, kindOption* const ki
|
|||||||
|
|
||||||
extern parserDefinition* parserNew (const char* name);
|
extern parserDefinition* parserNew (const char* name);
|
||||||
extern const char *getLanguageName (const langType language);
|
extern const char *getLanguageName (const langType language);
|
||||||
|
extern kindOption* getLanguageFileKind (const langType language);
|
||||||
extern langType getNamedLanguage (const char *const name);
|
extern langType getNamedLanguage (const char *const name);
|
||||||
extern langType getFileLanguage (const char *const fileName);
|
extern langType getFileLanguage (const char *const fileName);
|
||||||
extern void installLanguageMapDefault (const langType language);
|
extern void installLanguageMapDefault (const langType language);
|
||||||
|
@ -36,6 +36,11 @@ static MIOPos StartOfLine; /* holds deferred position of start of line */
|
|||||||
* FUNCTION DEFINITIONS
|
* FUNCTION DEFINITIONS
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
extern kindOption *getInputLanguageFileKind (void)
|
||||||
|
{
|
||||||
|
return getLanguageFileKind (File.input.language);
|
||||||
|
}
|
||||||
|
|
||||||
extern void freeSourceFileResources (void)
|
extern void freeSourceFileResources (void)
|
||||||
{
|
{
|
||||||
vStringDelete (File.input.name);
|
vStringDelete (File.input.name);
|
||||||
@ -217,13 +222,11 @@ static boolean parseLineDirective (void)
|
|||||||
lNum == 1)
|
lNum == 1)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, baseFilename (vStringValue (fileName)));
|
initTagEntry (&tag, baseFilename (vStringValue (fileName)), getInputLanguageFileKind ());
|
||||||
|
|
||||||
tag.isFileEntry = TRUE;
|
tag.isFileEntry = TRUE;
|
||||||
tag.lineNumberEntry = TRUE;
|
tag.lineNumberEntry = TRUE;
|
||||||
tag.lineNumber = 1;
|
tag.lineNumber = 1;
|
||||||
tag.kindName = "file";
|
|
||||||
tag.kind = 'F';
|
|
||||||
|
|
||||||
makeTagEntry (&tag);
|
makeTagEntry (&tag);
|
||||||
}
|
}
|
||||||
|
@ -102,6 +102,10 @@ extern inputFile File;
|
|||||||
/*
|
/*
|
||||||
* FUNCTION PROTOTYPES
|
* FUNCTION PROTOTYPES
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* InputFile: reading from fp in inputFile with updating fields in input fields */
|
||||||
|
extern kindOption *getInputLanguageFileKind (void);
|
||||||
|
|
||||||
extern void freeSourceFileResources (void);
|
extern void freeSourceFileResources (void);
|
||||||
extern boolean fileOpen (const char *const fileName, const langType language);
|
extern boolean fileOpen (const char *const fileName, const langType language);
|
||||||
extern boolean fileEOF (void);
|
extern boolean fileEOF (void);
|
||||||
|
@ -52,12 +52,10 @@ static kindOption AbcKinds[] = {
|
|||||||
static void makeAbcTag (const vString* const name, boolean name_before)
|
static void makeAbcTag (const vString* const name, boolean name_before)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue(name));
|
initTagEntry (&e, vStringValue(name), &(AbcKinds[0]));
|
||||||
|
|
||||||
if (name_before)
|
if (name_before)
|
||||||
e.lineNumber--; /* we want the line before the underline chars */
|
e.lineNumber--; /* we want the line before the underline chars */
|
||||||
e.kindName = AbcKinds[0].name;
|
|
||||||
e.kind = AbcKinds[0].letter;
|
|
||||||
|
|
||||||
makeTagEntry(&e);
|
makeTagEntry(&e);
|
||||||
}
|
}
|
||||||
|
@ -73,11 +73,9 @@ static void makeAsciidocTag (const vString* const name, const int kind)
|
|||||||
if (vStringLength (name) > 0)
|
if (vStringLength (name) > 0)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), &(AsciidocKinds [kind]));
|
||||||
|
|
||||||
e.lineNumber--; /* we want the line before the '---' underline chars */
|
e.lineNumber--; /* we want the line before the '---' underline chars */
|
||||||
e.kindName = AsciidocKinds [kind].name;
|
|
||||||
e.kind = AsciidocKinds [kind].letter;
|
|
||||||
|
|
||||||
if (nl && nl->type < kind)
|
if (nl && nl->type < kind)
|
||||||
{
|
{
|
||||||
|
@ -1454,13 +1454,11 @@ static void makeTag (const tokenInfo *const token,
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
initTagEntry (&e, vStringValue (token->name));
|
initTagEntry (&e, vStringValue (token->name), tagKind (type));
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.isFileScope = isFileScope;
|
e.isFileScope = isFileScope;
|
||||||
e.kindName = tagKind (type)->name;
|
|
||||||
e.kind = tagKind (type)->letter;
|
|
||||||
|
|
||||||
findScopeHierarchy (scope, st);
|
findScopeHierarchy (scope, st);
|
||||||
addOtherFields (&e, type, token, st, scope);
|
addOtherFields (&e, type, token, st, scope);
|
||||||
@ -3157,7 +3155,7 @@ static boolean findCTags (const unsigned int passCount)
|
|||||||
contextual_fake_count = 0;
|
contextual_fake_count = 0;
|
||||||
|
|
||||||
Assert (passCount < 3);
|
Assert (passCount < 3);
|
||||||
cppInit ((boolean) (passCount > 1), isLanguage (Lang_csharp), isLanguage (Lang_cpp));
|
cppInit ((boolean) (passCount > 1), isLanguage (Lang_csharp), isLanguage (Lang_cpp), &(CKinds [CK_DEFINE]));
|
||||||
|
|
||||||
exception = (exception_t) setjmp (Exception);
|
exception = (exception_t) setjmp (Exception);
|
||||||
retry = FALSE;
|
retry = FALSE;
|
||||||
|
@ -228,12 +228,10 @@ static void findCssTags (void)
|
|||||||
if (CssKinds[kind].enabled)
|
if (CssKinds[kind].enabled)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue (selector));
|
initTagEntry (&e, vStringValue (selector), &(CssKinds[kind]));
|
||||||
|
|
||||||
e.lineNumber = lineNumber;
|
e.lineNumber = lineNumber;
|
||||||
e.filePosition = filePosition;
|
e.filePosition = filePosition;
|
||||||
e.kindName = CssKinds[kind].name;
|
|
||||||
e.kind = (char) CssKinds[kind].letter;
|
|
||||||
|
|
||||||
makeTagEntry (&e);
|
makeTagEntry (&e);
|
||||||
}
|
}
|
||||||
|
@ -79,9 +79,7 @@ static void makeMemberTag (
|
|||||||
if (ErlangKinds [kind].enabled && vStringLength (identifier) > 0)
|
if (ErlangKinds [kind].enabled && vStringLength (identifier) > 0)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, vStringValue (identifier));
|
initTagEntry (&tag, vStringValue (identifier), &(ErlangKinds[kind]));
|
||||||
tag.kindName = ErlangKinds[kind].name;
|
|
||||||
tag.kind = ErlangKinds[kind].letter;
|
|
||||||
|
|
||||||
if (module != NULL && vStringLength (module) > 0)
|
if (module != NULL && vStringLength (module) > 0)
|
||||||
{
|
{
|
||||||
|
@ -488,7 +488,7 @@ static void makeFortranTag (tokenInfo *const token, tagType tag)
|
|||||||
const char *const name = vStringValue (token->string);
|
const char *const name = vStringValue (token->string);
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
|
|
||||||
initTagEntry (&e, name);
|
initTagEntry (&e, name, &(FortranKinds [token->tag]));
|
||||||
|
|
||||||
if (token->tag == TAG_COMMON_BLOCK)
|
if (token->tag == TAG_COMMON_BLOCK)
|
||||||
e.lineNumberEntry = (boolean) (Option.locate != EX_PATTERN);
|
e.lineNumberEntry = (boolean) (Option.locate != EX_PATTERN);
|
||||||
@ -496,8 +496,6 @@ static void makeFortranTag (tokenInfo *const token, tagType tag)
|
|||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.isFileScope = isFileScope (token->tag);
|
e.isFileScope = isFileScope (token->tag);
|
||||||
e.kindName = FortranKinds [token->tag].name;
|
|
||||||
e.kind = FortranKinds [token->tag].letter;
|
|
||||||
e.truncateLine = (boolean) (token->tag != TAG_LABEL);
|
e.truncateLine = (boolean) (token->tag != TAG_LABEL);
|
||||||
|
|
||||||
if (ancestorCount () > 0)
|
if (ancestorCount () > 0)
|
||||||
|
@ -523,15 +523,13 @@ static void makeTag (tokenInfo *const token, const goKind kind,
|
|||||||
const char *const name = vStringValue (token->string);
|
const char *const name = vStringValue (token->string);
|
||||||
|
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, name);
|
initTagEntry (&e, name, &(GoKinds [kind]));
|
||||||
|
|
||||||
if (!GoKinds [kind].enabled)
|
if (!GoKinds [kind].enabled)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.kindName = GoKinds [kind].name;
|
|
||||||
e.kind = GoKinds [kind].letter;
|
|
||||||
if (argList)
|
if (argList)
|
||||||
e.extensionFields.signature = argList;
|
e.extensionFields.signature = argList;
|
||||||
if (varType)
|
if (varType)
|
||||||
|
@ -224,12 +224,10 @@ static void makeJsTag (tokenInfo *const token, const jsKind kind, vString *const
|
|||||||
name = p + 1;
|
name = p + 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
initTagEntry (&e, name);
|
initTagEntry (&e, name, &(JsKinds [kind]));
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.kindName = JsKinds [kind].name;
|
|
||||||
e.kind = JsKinds [kind].letter;
|
|
||||||
|
|
||||||
if ( vStringLength(fullscope) > 0 )
|
if ( vStringLength(fullscope) > 0 )
|
||||||
{
|
{
|
||||||
|
@ -117,12 +117,10 @@ static void makeJsonTag (tokenInfo *const token, const jsonKind kind)
|
|||||||
if (! JsonKinds[kind].enabled)
|
if (! JsonKinds[kind].enabled)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
initTagEntry (&e, vStringValue (token->string));
|
initTagEntry (&e, vStringValue (token->string), &(JsonKinds[kind]));
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.kindName = JsonKinds[kind].name;
|
|
||||||
e.kind = JsonKinds[kind].letter;
|
|
||||||
|
|
||||||
if (vStringLength (token->scope) > 0)
|
if (vStringLength (token->scope) > 0)
|
||||||
{
|
{
|
||||||
|
@ -49,12 +49,10 @@ static boolean issame(const char *str)
|
|||||||
static void makeMarkdownTag (const vString* const name, boolean name_before)
|
static void makeMarkdownTag (const vString* const name, boolean name_before)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue(name));
|
initTagEntry (&e, vStringValue(name), &(MarkdownKinds [0]));
|
||||||
|
|
||||||
if (name_before)
|
if (name_before)
|
||||||
e.lineNumber--; /* we want the line before the underline chars */
|
e.lineNumber--; /* we want the line before the underline chars */
|
||||||
e.kindName = "variable";
|
|
||||||
e.kind = 'v';
|
|
||||||
|
|
||||||
makeTagEntry(&e);
|
makeTagEntry(&e);
|
||||||
}
|
}
|
||||||
|
@ -438,9 +438,7 @@ static objcKind parentType = K_INTERFACE;
|
|||||||
* add additional information to the tag. */
|
* add additional information to the tag. */
|
||||||
static void prepareTag (tagEntryInfo * tag, vString const *name, objcKind kind)
|
static void prepareTag (tagEntryInfo * tag, vString const *name, objcKind kind)
|
||||||
{
|
{
|
||||||
initTagEntry (tag, vStringValue (name));
|
initTagEntry (tag, vStringValue (name), &(ObjcKinds[kind]));
|
||||||
tag->kindName = ObjcKinds[kind].name;
|
|
||||||
tag->kind = ObjcKinds[kind].letter;
|
|
||||||
|
|
||||||
if (parentName != NULL)
|
if (parentName != NULL)
|
||||||
{
|
{
|
||||||
|
@ -44,15 +44,11 @@ static void createPascalTag (tagEntryInfo* const tag,
|
|||||||
{
|
{
|
||||||
if (PascalKinds [kind].enabled && name != NULL && vStringLength (name) > 0)
|
if (PascalKinds [kind].enabled && name != NULL && vStringLength (name) > 0)
|
||||||
{
|
{
|
||||||
initTagEntry (tag, vStringValue (name));
|
initTagEntry (tag, vStringValue (name), &(PascalKinds [kind]));
|
||||||
|
|
||||||
tag->kindName = PascalKinds [kind].name;
|
|
||||||
tag->kind = PascalKinds [kind].letter;
|
|
||||||
tag->extensionFields.signature = arglist;
|
tag->extensionFields.signature = arglist;
|
||||||
tag->extensionFields.varType = vartype;
|
tag->extensionFields.varType = vartype;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
initTagEntry (tag, NULL);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void makePascalTag (const tagEntryInfo* const tag)
|
static void makePascalTag (const tagEntryInfo* const tag)
|
||||||
|
@ -319,7 +319,7 @@ static void findPerlTags (void)
|
|||||||
* isSubroutineDeclaration() may consume several lines. So
|
* isSubroutineDeclaration() may consume several lines. So
|
||||||
* we record line positions.
|
* we record line positions.
|
||||||
*/
|
*/
|
||||||
initTagEntry(&e, vStringValue(name));
|
initTagEntry(&e, vStringValue(name), &(PerlKinds[kind]));
|
||||||
|
|
||||||
if (TRUE == isSubroutineDeclaration(cp)) {
|
if (TRUE == isSubroutineDeclaration(cp)) {
|
||||||
if (TRUE == PerlKinds[K_SUBROUTINE_DECLARATION].enabled) {
|
if (TRUE == PerlKinds[K_SUBROUTINE_DECLARATION].enabled) {
|
||||||
@ -330,9 +330,6 @@ static void findPerlTags (void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
e.kind = PerlKinds[kind].letter;
|
|
||||||
e.kindName = PerlKinds[kind].name;
|
|
||||||
|
|
||||||
makeTagEntry(&e);
|
makeTagEntry(&e);
|
||||||
|
|
||||||
if (Option.include.qualifiedTags && qualified &&
|
if (Option.include.qualifiedTags && qualified &&
|
||||||
|
@ -281,12 +281,10 @@ static void initPhpEntry (tagEntryInfo *const e, const tokenInfo *const token,
|
|||||||
parentKind = K_NAMESPACE;
|
parentKind = K_NAMESPACE;
|
||||||
}
|
}
|
||||||
|
|
||||||
initTagEntry (e, vStringValue (token->string));
|
initTagEntry (e, vStringValue (token->string), &(PhpKinds[kind]));
|
||||||
|
|
||||||
e->lineNumber = token->lineNumber;
|
e->lineNumber = token->lineNumber;
|
||||||
e->filePosition = token->filePosition;
|
e->filePosition = token->filePosition;
|
||||||
e->kindName = PhpKinds[kind].name;
|
|
||||||
e->kind = (char) PhpKinds[kind].letter;
|
|
||||||
|
|
||||||
if (access != ACCESS_UNDEFINED)
|
if (access != ACCESS_UNDEFINED)
|
||||||
e->extensionFields.access = accessToString (access);
|
e->extensionFields.access = accessToString (access);
|
||||||
@ -325,12 +323,10 @@ static void makeNamespacePhpTag (const tokenInfo *const token, const vString *co
|
|||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
|
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), &(PhpKinds[K_NAMESPACE]));
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.kindName = PhpKinds[K_NAMESPACE].name;
|
|
||||||
e.kind = (char) PhpKinds[K_NAMESPACE].letter;
|
|
||||||
|
|
||||||
makeTagEntry (&e);
|
makeTagEntry (&e);
|
||||||
}
|
}
|
||||||
|
@ -99,12 +99,10 @@ static const char *findValidAccessType (const char *const access)
|
|||||||
static void initPowerShellEntry (tagEntryInfo *const e, const tokenInfo *const token,
|
static void initPowerShellEntry (tagEntryInfo *const e, const tokenInfo *const token,
|
||||||
const powerShellKind kind, const char *const access)
|
const powerShellKind kind, const char *const access)
|
||||||
{
|
{
|
||||||
initTagEntry (e, vStringValue (token->string));
|
initTagEntry (e, vStringValue (token->string), &(PowerShellKinds[kind]));
|
||||||
|
|
||||||
e->lineNumber = token->lineNumber;
|
e->lineNumber = token->lineNumber;
|
||||||
e->filePosition = token->filePosition;
|
e->filePosition = token->filePosition;
|
||||||
e->kindName = PowerShellKinds[kind].name;
|
|
||||||
e->kind = (char) PowerShellKinds[kind].letter;
|
|
||||||
|
|
||||||
if (access != NULL)
|
if (access != NULL)
|
||||||
e->extensionFields.access = access;
|
e->extensionFields.access = access;
|
||||||
|
@ -113,27 +113,25 @@ static void makeFunctionTag (vString *const function,
|
|||||||
vString *const parent, int is_class_parent, const char *arglist)
|
vString *const parent, int is_class_parent, const char *arglist)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, vStringValue (function));
|
|
||||||
|
|
||||||
tag.kindName = PythonKinds[K_FUNCTION].name;
|
|
||||||
tag.kind = PythonKinds[K_FUNCTION].letter;
|
|
||||||
tag.extensionFields.signature = arglist;
|
|
||||||
|
|
||||||
if (vStringLength (parent) > 0)
|
if (vStringLength (parent) > 0)
|
||||||
{
|
{
|
||||||
if (is_class_parent)
|
if (is_class_parent)
|
||||||
{
|
{
|
||||||
tag.kindName = PythonKinds[K_METHOD].name;
|
initTagEntry (&tag, vStringValue (function), &(PythonKinds[K_METHOD]));
|
||||||
tag.kind = PythonKinds[K_METHOD].letter;
|
|
||||||
tag.extensionFields.scopeKind = &(PythonKinds[K_CLASS]);
|
tag.extensionFields.scopeKind = &(PythonKinds[K_CLASS]);
|
||||||
tag.extensionFields.scopeName = vStringValue (parent);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
initTagEntry (&tag, vStringValue (function), &(PythonKinds[K_FUNCTION]));
|
||||||
tag.extensionFields.scopeKind = &(PythonKinds[K_FUNCTION]);
|
tag.extensionFields.scopeKind = &(PythonKinds[K_FUNCTION]);
|
||||||
tag.extensionFields.scopeName = vStringValue (parent);
|
|
||||||
}
|
}
|
||||||
|
tag.extensionFields.scopeName = vStringValue (parent);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
initTagEntry (&tag, vStringValue (function), &(PythonKinds[K_FUNCTION]));
|
||||||
|
|
||||||
|
tag.extensionFields.signature = arglist;
|
||||||
|
|
||||||
addAccessFields (&tag, function, is_class_parent ? K_METHOD : K_FUNCTION,
|
addAccessFields (&tag, function, is_class_parent ? K_METHOD : K_FUNCTION,
|
||||||
vStringLength (parent) > 0, is_class_parent);
|
vStringLength (parent) > 0, is_class_parent);
|
||||||
@ -148,9 +146,7 @@ static void makeClassTag (vString *const class, vString *const inheritance,
|
|||||||
vString *const parent, int is_class_parent)
|
vString *const parent, int is_class_parent)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, vStringValue (class));
|
initTagEntry (&tag, vStringValue (class), &(PythonKinds[K_CLASS]));
|
||||||
tag.kindName = PythonKinds[K_CLASS].name;
|
|
||||||
tag.kind = PythonKinds[K_CLASS].letter;
|
|
||||||
if (vStringLength (parent) > 0)
|
if (vStringLength (parent) > 0)
|
||||||
{
|
{
|
||||||
if (is_class_parent)
|
if (is_class_parent)
|
||||||
@ -174,9 +170,7 @@ static void makeVariableTag (vString *const var, vString *const parent,
|
|||||||
boolean is_class_parent)
|
boolean is_class_parent)
|
||||||
{
|
{
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry (&tag, vStringValue (var));
|
initTagEntry (&tag, vStringValue (var), &(PythonKinds[K_VARIABLE]));
|
||||||
tag.kindName = PythonKinds[K_VARIABLE].name;
|
|
||||||
tag.kind = PythonKinds[K_VARIABLE].letter;
|
|
||||||
if (vStringLength (parent) > 0)
|
if (vStringLength (parent) > 0)
|
||||||
{
|
{
|
||||||
tag.extensionFields.scopeKind = &(PythonKinds[K_CLASS]);
|
tag.extensionFields.scopeKind = &(PythonKinds[K_CLASS]);
|
||||||
|
@ -61,13 +61,10 @@ static void installRRegex (const langType language)
|
|||||||
static void makeRTag(const vString* const name, rKind kind)
|
static void makeRTag(const vString* const name, rKind kind)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry(&e, vStringValue(name));
|
initTagEntry(&e, vStringValue(name), &(RKinds[kind]));
|
||||||
|
|
||||||
Assert(kind < KIND_COUNT);
|
Assert(kind < KIND_COUNT);
|
||||||
|
|
||||||
e.kindName = RKinds[kind].name;
|
|
||||||
e.kind = RKinds[kind].letter;
|
|
||||||
|
|
||||||
makeTagEntry(&e);
|
makeTagEntry(&e);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -70,11 +70,9 @@ static void makeRestTag (const vString* const name, const int kind)
|
|||||||
if (vStringLength (name) > 0)
|
if (vStringLength (name) > 0)
|
||||||
{
|
{
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, vStringValue (name));
|
initTagEntry (&e, vStringValue (name), &(RestKinds [kind]));
|
||||||
|
|
||||||
e.lineNumber--; /* we want the line before the '---' underline chars */
|
e.lineNumber--; /* we want the line before the '---' underline chars */
|
||||||
e.kindName = RestKinds [kind].name;
|
|
||||||
e.kind = RestKinds [kind].letter;
|
|
||||||
|
|
||||||
if (nl && nl->type < kind)
|
if (nl && nl->type < kind)
|
||||||
{
|
{
|
||||||
|
@ -213,7 +213,7 @@ static void emitRubyTag (vString* name, rubyKind kind)
|
|||||||
else
|
else
|
||||||
unqualified_name = qualified_name;
|
unqualified_name = qualified_name;
|
||||||
|
|
||||||
initTagEntry (&tag, unqualified_name);
|
initTagEntry (&tag, unqualified_name, &(RubyKinds [kind]));
|
||||||
if (vStringLength (scope) > 0) {
|
if (vStringLength (scope) > 0) {
|
||||||
Assert (0 <= parent_kind &&
|
Assert (0 <= parent_kind &&
|
||||||
(size_t) parent_kind < (sizeof RubyKinds / sizeof RubyKinds[0]));
|
(size_t) parent_kind < (sizeof RubyKinds / sizeof RubyKinds[0]));
|
||||||
@ -221,8 +221,6 @@ static void emitRubyTag (vString* name, rubyKind kind)
|
|||||||
tag.extensionFields.scopeKind = &(RubyKinds [parent_kind]);
|
tag.extensionFields.scopeKind = &(RubyKinds [parent_kind]);
|
||||||
tag.extensionFields.scopeName = vStringValue (scope);
|
tag.extensionFields.scopeName = vStringValue (scope);
|
||||||
}
|
}
|
||||||
tag.kindName = RubyKinds [kind].name;
|
|
||||||
tag.kind = RubyKinds [kind].letter;
|
|
||||||
makeTagEntry (&tag);
|
makeTagEntry (&tag);
|
||||||
|
|
||||||
nestingLevelsPush (nesting, name, kind);
|
nestingLevelsPush (nesting, name, kind);
|
||||||
|
@ -439,15 +439,12 @@ static void addTag (vString* ident, const char* type, const char* arg_list, int
|
|||||||
if (kind == K_NONE)
|
if (kind == K_NONE)
|
||||||
return;
|
return;
|
||||||
tagEntryInfo tag;
|
tagEntryInfo tag;
|
||||||
initTagEntry(&tag, ident->buffer);
|
initTagEntry(&tag, ident->buffer, &(rustKinds[kind]));
|
||||||
|
|
||||||
tag.lineNumber = line;
|
tag.lineNumber = line;
|
||||||
tag.filePosition = pos;
|
tag.filePosition = pos;
|
||||||
tag.sourceFileName = getSourceFileName();
|
tag.sourceFileName = getSourceFileName();
|
||||||
|
|
||||||
tag.kindName = rustKinds[kind].name;
|
|
||||||
tag.kind = rustKinds[kind].letter;
|
|
||||||
|
|
||||||
tag.extensionFields.signature = arg_list;
|
tag.extensionFields.signature = arg_list;
|
||||||
tag.extensionFields.varType = type;
|
tag.extensionFields.varType = type;
|
||||||
if (parent_kind != K_NONE)
|
if (parent_kind != K_NONE)
|
||||||
|
@ -439,12 +439,10 @@ static void makeSqlTag (tokenInfo *const token, const sqlKind kind)
|
|||||||
{
|
{
|
||||||
const char *const name = vStringValue (token->string);
|
const char *const name = vStringValue (token->string);
|
||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
initTagEntry (&e, name);
|
initTagEntry (&e, name, &(SqlKinds [kind]));
|
||||||
|
|
||||||
e.lineNumber = token->lineNumber;
|
e.lineNumber = token->lineNumber;
|
||||||
e.filePosition = token->filePosition;
|
e.filePosition = token->filePosition;
|
||||||
e.kindName = SqlKinds [kind].name;
|
|
||||||
e.kind = SqlKinds [kind].letter;
|
|
||||||
|
|
||||||
if (vStringLength (token->scope) > 0)
|
if (vStringLength (token->scope) > 0)
|
||||||
{
|
{
|
||||||
|
@ -51,10 +51,7 @@ static void makeTxt2tagsTag (const vString* const name,
|
|||||||
tagEntryInfo e;
|
tagEntryInfo e;
|
||||||
vString *scope = NULL;
|
vString *scope = NULL;
|
||||||
kindOption *kind = &Txt2tagsKinds[type];
|
kindOption *kind = &Txt2tagsKinds[type];
|
||||||
initTagEntry (&e, vStringValue(name));
|
initTagEntry (&e, vStringValue(name), kind);
|
||||||
|
|
||||||
e.kindName = kind->name;
|
|
||||||
e.kind = kind->letter;
|
|
||||||
|
|
||||||
if (nls->n > 0) {
|
if (nls->n > 0) {
|
||||||
int i;
|
int i;
|
||||||
|
@ -179,7 +179,7 @@ static gboolean init_tag(TMTag *tag, TMSourceFile *file, const tagEntryInfo *tag
|
|||||||
if (!tag_entry)
|
if (!tag_entry)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
type = tm_parser_get_tag_type(tag_entry->kind, file->lang);
|
type = tm_parser_get_tag_type(tag_entry->kind->letter, file->lang);
|
||||||
if (!tag_entry->name || type == tm_tag_undef_t)
|
if (!tag_entry->name || type == tm_tag_undef_t)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user