Sync whitespace and comments in main
This commit is contained in:
parent
967b572240
commit
ca65fa2236
@ -1,9 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1999-2002, Darren Hiebert
|
||||||
* Copyright (c) 1999-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions for reading command line arguments.
|
* This module contains functions for reading command line arguments.
|
||||||
*/
|
*/
|
||||||
@ -18,6 +17,7 @@
|
|||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
#include "args.h"
|
#include "args.h"
|
||||||
|
#include "debug.h"
|
||||||
#include "routines.h"
|
#include "routines.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -1,20 +1,21 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1999-2002, Darren Hiebert
|
||||||
* Copyright (c) 1999-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Defines external interface to command line argument reading.
|
* Defines external interface to command line argument reading.
|
||||||
*/
|
*/
|
||||||
#ifndef _ARGS_H
|
#ifndef CTAGS_MAIN_ARGS_H
|
||||||
#define _ARGS_H
|
#define CTAGS_MAIN_ARGS_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
*/
|
*/
|
||||||
#include "general.h" /* must always come first */
|
#include "general.h" /* must always come first */
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* DATA DECLARATIONS
|
* DATA DECLARATIONS
|
||||||
*/
|
*/
|
||||||
@ -53,6 +54,6 @@ extern void argSetLineMode (Arguments* const current);
|
|||||||
extern void argForth (Arguments* const current);
|
extern void argForth (Arguments* const current);
|
||||||
extern void argDelete (Arguments* const current);
|
extern void argDelete (Arguments* const current);
|
||||||
|
|
||||||
#endif /* _ARGS_H */
|
#endif /* CTAGS_MAIN_ARGS_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,13 +1,15 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 1996-2001, Darren Hiebert
|
* Copyright (c) 1996-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Program definitions
|
* Program definitions
|
||||||
*/
|
*/
|
||||||
#ifndef _CTAGS_H
|
#ifndef CTAGS_MAIN_CTAGS_H
|
||||||
#define _CTAGS_H
|
#define CTAGS_MAIN_CTAGS_H
|
||||||
|
|
||||||
|
#include "general.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* MACROS
|
* MACROS
|
||||||
@ -20,6 +22,6 @@
|
|||||||
#define AUTHOR_NAME "Darren Hiebert"
|
#define AUTHOR_NAME "Darren Hiebert"
|
||||||
#define AUTHOR_EMAIL "darren@hiebert.com"
|
#define AUTHOR_EMAIL "darren@hiebert.com"
|
||||||
|
|
||||||
#endif /* _CTAGS_H */
|
#endif /* CTAGS_MAIN_CTAGS_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1996-2002, Darren Hiebert
|
||||||
* Copyright (c) 1996-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions for creating tag entries.
|
* This module contains functions for creating tag entries.
|
||||||
*/
|
*/
|
||||||
@ -159,8 +158,8 @@ static void addPseudoTags (void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void updateSortedFlag (const char *const line,
|
static void updateSortedFlag (
|
||||||
MIO *const mio, MIOPos startOfLine)
|
const char *const line, MIO *const mio, MIOPos startOfLine)
|
||||||
{
|
{
|
||||||
const char *const tab = strchr (line, '\t');
|
const char *const tab = strchr (line, '\t');
|
||||||
|
|
||||||
|
@ -1,14 +1,13 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1998-2002, Darren Hiebert
|
||||||
* Copyright (c) 1998-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* External interface to entry.c
|
* External interface to entry.c
|
||||||
*/
|
*/
|
||||||
#ifndef _ENTRY_H
|
#ifndef CTAGS_MAIN_ENTRY_H
|
||||||
#define _ENTRY_H
|
#define CTAGS_MAIN_ENTRY_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -96,6 +95,6 @@ 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, const kindOption *kind);
|
extern void initTagEntry (tagEntryInfo *const e, const char *const name, const kindOption *kind);
|
||||||
|
|
||||||
#endif /* _ENTRY_H */
|
#endif /* CTAGS_MAIN_ENTRY_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,19 +1,18 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1998-2003, Darren Hiebert
|
||||||
* Copyright (c) 1998-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Provides the general (non-ctags-specific) environment assumed by all.
|
* Provides the general (non-ctags-specific) environment assumed by all.
|
||||||
*/
|
*/
|
||||||
#ifndef _GENERAL_H
|
#ifndef CTAGS_MAIN_GENERAL_H
|
||||||
#define _GENERAL_H
|
#define CTAGS_MAIN_GENERAL_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
*/
|
*/
|
||||||
#ifdef HAVE_CONFIG_H
|
#if defined (HAVE_CONFIG_H)
|
||||||
# include <config.h>
|
# include <config.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef macintosh
|
#ifdef macintosh
|
||||||
@ -151,6 +150,6 @@ extern void *unlink (const char *);
|
|||||||
extern char *getenv (const char *);
|
extern char *getenv (const char *);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* _GENERAL_H */
|
#endif /* CTAGS_MAIN_GENERAL_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -166,7 +166,7 @@ extern void cppEndStatement (void)
|
|||||||
* directives and may emit a tag for #define directives.
|
* directives and may emit a tag for #define directives.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* This puts a character back into the input queue for the source File.
|
/* This puts a character back into the input queue for the input File.
|
||||||
* Up to two characters may be ungotten.
|
* Up to two characters may be ungotten.
|
||||||
*/
|
*/
|
||||||
extern void cppUngetc (const int c)
|
extern void cppUngetc (const int c)
|
||||||
|
@ -2,11 +2,11 @@
|
|||||||
* Copyright (c) 2000-2003, Darren Hiebert
|
* Copyright (c) 2000-2003, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions for applying regular expression matching.
|
* This module contains functions for applying regular expression matching.
|
||||||
*
|
*
|
||||||
* The code for utlizing the Gnu regex package with regards to processing the
|
* The code for utilizing the Gnu regex package with regards to processing the
|
||||||
* regex option and checking for regex matches was adapted from routines in
|
* regex option and checking for regex matches was adapted from routines in
|
||||||
* Gnu etags.
|
* Gnu etags.
|
||||||
*/
|
*/
|
||||||
@ -91,6 +91,7 @@ static int SetUpper = -1; /* upper language index in list */
|
|||||||
* FUNCTION DEFINITIONS
|
* FUNCTION DEFINITIONS
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
static void clearPatternSet (const langType language)
|
static void clearPatternSet (const langType language)
|
||||||
{
|
{
|
||||||
if (language <= SetUpper)
|
if (language <= SetUpper)
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
* Copyright 2009-2011 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
* Copyright 2009-2011 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Defines external interface to scope nesting levels for tags.
|
* Defines external interface to scope nesting levels for tags.
|
||||||
*/
|
*/
|
||||||
|
@ -3,12 +3,12 @@
|
|||||||
* Copyright 2009-2011 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
* Copyright 2009-2011 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Defines external interface to scope nesting levels for tags.
|
* Defines external interface to scope nesting levels for tags.
|
||||||
*/
|
*/
|
||||||
#ifndef _NESTLEVEL_H
|
#ifndef CTAGS_MAIN_NESTLEVEL_H
|
||||||
#define _NESTLEVEL_H
|
#define CTAGS_MAIN_NESTLEVEL_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -47,6 +47,6 @@ extern void nestingLevelsPush(NestingLevels *nls,
|
|||||||
extern void nestingLevelsPop(NestingLevels *nls);
|
extern void nestingLevelsPop(NestingLevels *nls);
|
||||||
extern NestingLevel *nestingLevelsGetCurrent(NestingLevels *nls);
|
extern NestingLevel *nestingLevelsGetCurrent(NestingLevels *nls);
|
||||||
|
|
||||||
#endif /* _NESTLEVEL_H */
|
#endif /* CTAGS_MAIN_NESTLEVEL_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1996-2003, Darren Hiebert
|
||||||
* Copyright (c) 1996-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions to process command line options.
|
* This module contains functions to process command line options.
|
||||||
*/
|
*/
|
||||||
|
@ -106,6 +106,6 @@ extern void freeOptionResources (void);
|
|||||||
|
|
||||||
void addIgnoreListFromFile (const char *const fileName);
|
void addIgnoreListFromFile (const char *const fileName);
|
||||||
|
|
||||||
#endif /* _OPTIONS_H */
|
#endif /* CTAGS_MAIN_OPTIONS_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,11 +1,10 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1996-2003, Darren Hiebert
|
||||||
* Copyright (c) 1996-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions for managing source languages and
|
* This module contains functions for managing input languages and
|
||||||
* dispatching files to the appropriate language parser.
|
* dispatching files to the appropriate language parser.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -1,14 +1,13 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1998-2003, Darren Hiebert
|
||||||
* Copyright (c) 1998-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Private definitions for parsing support.
|
* Private definitions for parsing support.
|
||||||
*/
|
*/
|
||||||
#ifndef _PARSE_H
|
#ifndef CTAGS_MAIN_PARSE_H
|
||||||
#define _PARSE_H
|
#define CTAGS_MAIN_PARSE_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -63,8 +62,8 @@ typedef struct {
|
|||||||
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 */
|
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 */
|
||||||
simpleParser parser; /* simple parser (common case) */
|
simpleParser parser; /* simple parser (common case) */
|
||||||
rescanParser parser2; /* rescanning parser (unusual case) */
|
rescanParser parser2; /* rescanning parser (unusual case) */
|
||||||
@ -157,6 +156,6 @@ extern tagEntryFunction TagEntryFunction;
|
|||||||
extern void *TagEntryUserData;
|
extern void *TagEntryUserData;
|
||||||
extern void setTagEntryFunction(tagEntryFunction entry_function, void *user_data);
|
extern void setTagEntryFunction(tagEntryFunction entry_function, void *user_data);
|
||||||
|
|
||||||
#endif /* _PARSE_H */
|
#endif /* CTAGS_MAIN_PARSE_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,17 +1,16 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 2000-2003, Darren Hiebert
|
||||||
* Copyright (c) 2000-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* External interface to all language parsing modules.
|
* External interface to all language parsing modules.
|
||||||
*
|
*
|
||||||
* To add a new language parser, you need only modify this single source
|
* To add a new language parser, you need only modify this single input
|
||||||
* file to add the name of the parser definition function.
|
* file to add the name of the parser definition function.
|
||||||
*/
|
*/
|
||||||
#ifndef _PARSERS_H
|
#ifndef CTAGS_MAIN_PARSERS_H
|
||||||
#define _PARSERS_H
|
#define CTAGS_MAIN_PARSERS_H
|
||||||
|
|
||||||
/* Add the name of any new parser definition function here */
|
/* Add the name of any new parser definition function here */
|
||||||
/* keep src/tagmanager/tm_parser.h in sync */
|
/* keep src/tagmanager/tm_parser.h in sync */
|
||||||
@ -68,6 +67,6 @@
|
|||||||
ZephirParser, \
|
ZephirParser, \
|
||||||
PowerShellParser
|
PowerShellParser
|
||||||
|
|
||||||
#endif /* _PARSERS_H */
|
#endif /* CTAGS_MAIN_PARSERS_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -258,7 +258,7 @@ extern boolean fileOpen (const char *const fileName, const langType language)
|
|||||||
*/
|
*/
|
||||||
if (File.mio != NULL)
|
if (File.mio != NULL)
|
||||||
{
|
{
|
||||||
mio_free (File.mio); /* close any open source file */
|
mio_free (File.mio); /* close any open input file */
|
||||||
File.mio = NULL;
|
File.mio = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -365,8 +365,8 @@ static void fileNewline (void)
|
|||||||
File.newLine = FALSE;
|
File.newLine = FALSE;
|
||||||
File.input.lineNumber++;
|
File.input.lineNumber++;
|
||||||
File.source.lineNumber++;
|
File.source.lineNumber++;
|
||||||
DebugStatement ( if (Option.breakLine == File.lineNumber) lineBreak (); )
|
DebugStatement ( if (Option.breakLine == File.input.lineNumber) lineBreak (); )
|
||||||
DebugStatement ( debugPrintf (DEBUG_RAW, "%6ld: ", File.lineNumber); )
|
DebugStatement ( debugPrintf (DEBUG_RAW, "%6ld: ", File.input.lineNumber); )
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This function reads a single character from the stream, performing newline
|
/* This function reads a single character from the stream, performing newline
|
||||||
|
@ -1,14 +1,13 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1998-2002, Darren Hiebert
|
||||||
* Copyright (c) 1998-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* External interface to read.c
|
* External interface to read.c
|
||||||
*/
|
*/
|
||||||
#ifndef _READ_H
|
#ifndef CTAGS_MAIN_READ_H
|
||||||
#define _READ_H
|
#define CTAGS_MAIN_READ_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -40,8 +39,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
enum eCharacters {
|
enum eCharacters {
|
||||||
/* White space characters.
|
/* white space characters */
|
||||||
*/
|
|
||||||
SPACE = ' ',
|
SPACE = ' ',
|
||||||
NEWLINE = '\n',
|
NEWLINE = '\n',
|
||||||
CRETURN = '\r',
|
CRETURN = '\r',
|
||||||
@ -49,8 +47,7 @@ enum eCharacters {
|
|||||||
TAB = '\t',
|
TAB = '\t',
|
||||||
VTAB = '\v',
|
VTAB = '\v',
|
||||||
|
|
||||||
/* Some hard to read characters.
|
/* some hard to read characters */
|
||||||
*/
|
|
||||||
DOUBLE_QUOTE = '"',
|
DOUBLE_QUOTE = '"',
|
||||||
SINGLE_QUOTE = '\'',
|
SINGLE_QUOTE = '\'',
|
||||||
BACKSLASH = '\\',
|
BACKSLASH = '\\',
|
||||||
@ -120,6 +117,6 @@ extern boolean bufferOpen (unsigned char *buffer, size_t buffer_size,
|
|||||||
const char *const fileName, const langType language );
|
const char *const fileName, const langType language );
|
||||||
#define bufferClose fileClose
|
#define bufferClose fileClose
|
||||||
|
|
||||||
#endif /* _READ_H */
|
#endif /* CTAGS_MAIN_READ_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -473,7 +473,6 @@ extern char* absoluteFilename (const char *file)
|
|||||||
{
|
{
|
||||||
char *slashp, *cp;
|
char *slashp, *cp;
|
||||||
char *res = NULL;
|
char *res = NULL;
|
||||||
|
|
||||||
if (isAbsolutePath (file))
|
if (isAbsolutePath (file))
|
||||||
res = eStrdup (file);
|
res = eStrdup (file);
|
||||||
else
|
else
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
*
|
* Copyright (c) 1996-2002, Darren Hiebert
|
||||||
* Copyright (c) 1996-2001, Darren Hiebert
|
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions to sort the tag entries.
|
* This module contains functions to sort the tag entries.
|
||||||
*/
|
*/
|
||||||
@ -124,8 +123,8 @@ static int compareTags (const void *const one, const void *const two)
|
|||||||
return strcmp (line1, line2);
|
return strcmp (line1, line2);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void writeSortedTags (char **const table, const size_t numTags,
|
static void writeSortedTags (
|
||||||
const boolean toStdout)
|
char **const table, const size_t numTags, const boolean toStdout)
|
||||||
{
|
{
|
||||||
MIO *mio;
|
MIO *mio;
|
||||||
size_t i;
|
size_t i;
|
||||||
|
@ -1,13 +1,13 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 1998-2001, Darren Hiebert
|
* Copyright (c) 1998-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* External interface to sort.c
|
* External interface to sort.c
|
||||||
*/
|
*/
|
||||||
#ifndef _SORT_H
|
#ifndef CTAGS_MAIN_SORT_H
|
||||||
#define _SORT_H
|
#define CTAGS_MAIN_SORT_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -25,6 +25,6 @@ extern void externalSortTags (const boolean toStdout);
|
|||||||
extern void internalSortTags (const boolean toStdout);
|
extern void internalSortTags (const boolean toStdout);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* _SORT_H */
|
#endif /* CTAGS_MAIN_SORT_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* Copyright (c) 1999-2002, Darren Hiebert
|
* Copyright (c) 1999-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions managing resizable string lists.
|
* This module contains functions managing resizable string lists.
|
||||||
*/
|
*/
|
||||||
|
@ -2,12 +2,12 @@
|
|||||||
* Copyright (c) 1999-2002, Darren Hiebert
|
* Copyright (c) 1999-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Defines external interface to resizable string lists.
|
* Defines external interface to resizable string lists.
|
||||||
*/
|
*/
|
||||||
#ifndef _STRLIST_H
|
#ifndef CTAGS_MAIN_STRLIST_H
|
||||||
#define _STRLIST_H
|
#define CTAGS_MAIN_STRLIST_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -47,6 +47,6 @@ extern boolean stringListExtensionMatched (const stringList* const list, const c
|
|||||||
extern boolean stringListFileMatched (const stringList* const list, const char* const str);
|
extern boolean stringListFileMatched (const stringList* const list, const char* const str);
|
||||||
extern void stringListPrint (const stringList *const current);
|
extern void stringListPrint (const stringList *const current);
|
||||||
|
|
||||||
#endif /* _STRLIST_H */
|
#endif /* CTAGS_MAIN_STRLIST_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
/*
|
/*
|
||||||
*
|
|
||||||
* Copyright (c) 1998-2002, Darren Hiebert
|
* Copyright (c) 1998-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This module contains functions supporting resizeable strings.
|
* This module contains functions supporting resizeable strings.
|
||||||
*/
|
*/
|
||||||
@ -17,6 +16,7 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
|
|
||||||
|
#include "debug.h"
|
||||||
#include "routines.h"
|
#include "routines.h"
|
||||||
#include "vstring.h"
|
#include "vstring.h"
|
||||||
|
|
||||||
|
@ -2,12 +2,12 @@
|
|||||||
* Copyright (c) 1998-2002, Darren Hiebert
|
* Copyright (c) 1998-2002, Darren Hiebert
|
||||||
*
|
*
|
||||||
* This source code is released for free distribution under the terms of the
|
* This source code is released for free distribution under the terms of the
|
||||||
* GNU General Public License.
|
* GNU General Public License version 2 or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Provides the external interface for resizeable strings.
|
* Provides the external interface for resizeable strings.
|
||||||
*/
|
*/
|
||||||
#ifndef _VSTRING_H
|
#ifndef CTAGS_MAIN_VSTRING_H
|
||||||
#define _VSTRING_H
|
#define CTAGS_MAIN_VSTRING_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* INCLUDE FILES
|
* INCLUDE FILES
|
||||||
@ -52,7 +52,7 @@
|
|||||||
typedef struct sVString {
|
typedef struct sVString {
|
||||||
size_t length; /* size of buffer used */
|
size_t length; /* size of buffer used */
|
||||||
size_t size; /* allocated size of buffer */
|
size_t size; /* allocated size of buffer */
|
||||||
char * buffer; /* location of buffer */
|
char *buffer; /* location of buffer */
|
||||||
} vString;
|
} vString;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -81,6 +81,6 @@ extern void vStringTruncate (vString *const string, const size_t length);
|
|||||||
|
|
||||||
extern vString *vStringNewOwn (char *s);
|
extern vString *vStringNewOwn (char *s);
|
||||||
|
|
||||||
#endif /* _VSTRING_H */
|
#endif /* CTAGS_MAIN_VSTRING_H */
|
||||||
|
|
||||||
/* vi:set tabstop=4 shiftwidth=4: */
|
/* vi:set tabstop=4 shiftwidth=4: */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user