Branch: refs/heads/master
Author: Landrok <landrok(a)users.noreply.github.com>
Committer: Frank Lanitz <frank(a)frank.uvena.de>
Date: Mon, 19 Sep 2016 07:33:47 UTC
Commit: d8ee2ccf8e4a477dd663c7966ed28c137cb00aa1
https://github.com/geany/geany/commit/d8ee2ccf8e4a477dd663c7966ed28c137cb00…
Log Message:
-----------
Fix some typos in French translation (#1227)
Modified Paths:
--------------
po/fr.po
Modified: po/fr.po
52 lines changed, 26 insertions(+), 26 deletions(-)
===================================================================
@@ -188,7 +188,7 @@ msgid ""
"disable it if you do not need it"
msgstr ""
"Charger ou non l'émulateur virtuel de terminal (VTE) au lancement, "
-"désactivez le si vous n'en avez pas besoin"
+"désactivez-le si vous n'en avez pas besoin"
#: ../data/geany.glade.h:36
msgid "Enable plugin support"
@@ -715,7 +715,7 @@ msgid ""
"where the compiler found a warning or an error"
msgstr ""
"Utilise ou non les indicateurs (un soulignage) pour mettre en avant les "
-"lignes ou le compilateur a trouvé un avertissement ou une erreur"
+"lignes où le compilateur a trouvé un avertissement ou une erreur"
#: ../data/geany.glade.h:141
msgid "Newline strips trailing spaces"
@@ -854,7 +854,7 @@ msgid ""
"Type a defined short character sequence and complete it to a more complex "
"string using a single keypress"
msgstr ""
-"Entrez une courte séquence de caractères prédéfinie et complétez la pour "
+"Entrez une courte séquence de caractères prédéfinie et complétez-la pour "
"obtenir une chaîne plus complexe en utilisant une seule touche"
#: ../data/geany.glade.h:169
@@ -939,7 +939,7 @@ msgid ""
msgstr ""
"Délai minimum (en millisecondes) entre deux mises à jour automatiques de la "
"liste de symboles. Un délai trop court peut avoir un impact sur les "
-"performances, en particulier avec de gros fichiers. Un délai de 0 désactives "
+"performances, en particulier avec de gros fichiers. Un délai de 0 désactive "
"les mises à jour automatiques."
#: ../data/geany.glade.h:185
@@ -1198,7 +1198,7 @@ msgstr "Encodage par défaut (nouveaux fichiers) :"
#: ../data/geany.glade.h:238
msgid "Sets the default encoding for newly created files"
msgstr ""
-"Définit le jeu de caractères utilisés par défaut lors de la création de "
+"Définit le jeu de caractères utilisé par défaut lors de la création de "
"nouveaux fichiers"
#: ../data/geany.glade.h:239
@@ -1247,7 +1247,7 @@ msgid ""
"mixed line endings in the same file"
msgstr ""
"S'assurer de toujours convertir les fins de lignes avant un enregistrement "
-"pour éviter les fins de lignes mixtes dans un même fichier"
+"pour éviter les fins de ligne mixtes dans un même fichier"
#: ../data/geany.glade.h:248
msgid "Strip trailing spaces and tabs"
@@ -1471,7 +1471,7 @@ msgstr "Afficher les numéros de ligne"
#: ../data/geany.glade.h:296 ../src/printing.c:241
msgid "Add line numbers to the printed page"
-msgstr "Ajouter les numéros de lignes à la page imprimée"
+msgstr "Ajouter les numéros de ligne à la page imprimée"
#: ../data/geany.glade.h:297 ../src/printing.c:244
msgid "Print page numbers"
@@ -1913,7 +1913,7 @@ msgstr "Afficher les e_spaces"
#: ../data/geany.glade.h:397
msgid "Show Line _Endings"
-msgstr "Afficher les fins d_e lignes"
+msgstr "Afficher les fins d_e ligne"
#: ../data/geany.glade.h:398
msgid "Show Indentation _Guides"
@@ -2021,7 +2021,7 @@ msgstr "Définir l'_encodage"
#: ../data/geany.glade.h:424
msgid "Set Line E_ndings"
-msgstr "Définir les fi_ns de lignes"
+msgstr "Définir les fi_ns de ligne"
#: ../data/geany.glade.h:425
msgid "Convert and Set to _CR/LF (Windows)"
@@ -2202,7 +2202,7 @@ msgid ""
"Space separated list of file patterns used for the find in files dialog (e."
"g. *.c *.h)"
msgstr ""
-"Liste de motifs de fichier, séparés par une espace, à utiliser dans le "
+"Liste de motifs de fichier, séparés par un espace, à utiliser dans le "
"dialogue de recherche dans les fichiers (par ex. *.c *.h)"
#: ../data/geany.glade.h:469 ../src/project.c:209
@@ -2360,7 +2360,7 @@ msgstr "Contributeurs"
msgid ""
"Some of the many contributors (for a more detailed list, see the file %s):"
msgstr ""
-"Quelques uns des principaux contributeurs (pour une liste plus détaillé, "
+"Quelques uns des principaux contributeurs (pour une liste plus détaillée, "
"voir le fichier %s) :"
#: ../src/about.c:407
@@ -2664,7 +2664,7 @@ msgid ""
"Note if you choose multiple files, they will all be opened with the chosen "
"encoding."
msgstr ""
-"Définit explicitement un encodage pour le fichier, si celui-ci ne serait pas "
+"Définit explicitement un encodage pour le fichier, si celui-ci n'était pas "
"détecté. Cela est utile lorsque vous savez que l'encodage d'un fichier ne "
"peut pas être détecté correctement par Geany.\n"
"Notez que si vous choisissez plusieurs fichiers, ils seront tous ouverts "
@@ -2684,7 +2684,7 @@ msgid ""
msgstr ""
"Définit explicitement un type de fichier pour ce fichier, s'il n'est pas "
"détecté par l'extension du nom de fichier.\n"
-"Notez que si vous choisissez plusieurs fichier, ils seront tous ouverts avec "
+"Notez que si vous choisissez plusieurs fichiers, ils seront tous ouverts avec "
"le type de fichier choisi."
#: ../src/dialogs.c:377 ../src/dialogs.c:467
@@ -3501,11 +3501,11 @@ msgstr "Diminuer l'indentation"
#: ../src/keybindings.c:469
msgid "Increase indent by one space"
-msgstr "Augmenter l'indentation d'une espace"
+msgstr "Augmenter l'indentation d'un espace"
#: ../src/keybindings.c:471
msgid "Decrease indent by one space"
-msgstr "Diminuer l'indentation d'une espace"
+msgstr "Diminuer l'indentation d'un espace"
#: ../src/keybindings.c:475
msgid "Send to Custom Command 1"
@@ -3828,7 +3828,7 @@ msgstr "Les raccourcis clavier suivants peuvent être configurés :"
#: ../src/keyfile.c:1027
msgid "Type here what you want, use it as a notice/scratch board"
msgstr ""
-"Écrivez ici ce que vous souhaitez, utilisez cela comme comme un tableau de "
+"Écrivez ici ce que vous souhaitez, utilisez cela comme un tableau de "
"notes"
#: ../src/keyfile.c:1254
@@ -4412,7 +4412,7 @@ msgid ""
msgstr ""
"Tester la correspondance des expressions régulières sur tout le tampon d'un "
"coup plutôt que ligne à ligne, ce qui permet aux correspondances de "
-"recouvrir plusieurs lignes. Dans ce mode les caractères de fin de ligne "
+"recouvrir plusieurs lignes. Dans ce mode, les caractères de fin de ligne "
"peuvent être capturés comme n'importe quel caractère."
#: ../src/search.c:341
@@ -4517,7 +4517,7 @@ msgstr ""
"Tous : recherche dans tous les fichiers\n"
"Projet : utilise les motifs de fichier définis dans les propriétés du "
"projet\n"
-"Personnalisé : utilise les motifs de fichiers spécifiés manuellement"
+"Personnalisé : utilise les motifs de fichier spécifiés manuellement"
#: ../src/search.c:896
msgid "Fi_les:"
@@ -4565,8 +4565,8 @@ msgstr "Autres options à passer à grep"
#, c-format
msgid "Found %d match for \"%s\"."
msgid_plural "Found %d matches for \"%s\"."
-msgstr[0] "%d correspondances trouvées pour « %s »."
-msgstr[1] "%d correspondance trouvée pour « %s »."
+msgstr[0] "%d correspondance trouvée pour « %s »."
+msgstr[1] "%d correspondances trouvées pour « %s »."
#: ../src/search.c:1425
#, c-format
@@ -4632,7 +4632,7 @@ msgid ""
msgstr ""
"Geany a essayé d'accéder au socket de domaine Unix d'une autre instance d'un "
"autre utilisateur.\n"
-"Ceci est une erreur fatale et Geany va maintenant fermer."
+"Ceci est une erreur fatale et Geany va maintenant se fermer."
#: ../src/spawn.c:94 ../src/spawn.c:144 ../src/spawn.c:188
msgid "Text ended before matching quote was found"
@@ -4984,7 +4984,7 @@ msgstr "Extension de fichier inconnue pour « %s ».\n"
#, c-format
msgid "Failed to create tags file, perhaps because no symbols were found.\n"
msgstr ""
-"Échec à la création du fichier de tags, probablement par ce qu'aucun symbole "
+"Échec à la création du fichier de tags, probablement parce qu'aucun symbole "
"n'a été trouvé.\n"
#: ../src/symbols.c:1619
@@ -5239,7 +5239,7 @@ msgid ""
"The executed custom command returned an error. Your selection was not "
"changed. Error message: %s"
msgstr ""
-"La commande personnalisée a retournée une erreur. Votre sélection n'a pas "
+"La commande personnalisée a retourné une erreur. Votre sélection n'a pas "
"été modifiée. Message d'erreur : %s"
#: ../src/tools.c:233
@@ -5487,7 +5487,7 @@ msgid ""
"another one."
msgstr ""
"Impossible d'appeler la commande configurée pour le navigateur. Corrigez-la "
-"ou entrez en une différente."
+"ou entrez-en une différente."
#: ../src/utils.c:375
msgid "Windows (CRLF)"
@@ -5875,7 +5875,7 @@ msgid ""
"Filter your files with the usual wildcards. Separate multiple patterns with "
"a space."
msgstr ""
-"Filtre vos fichiers avec vos jokers habituels. Séparez chaque motif par une "
+"Filtre vos fichiers avec vos jokers habituels. Séparez chaque motif par un "
"espace."
#: ../plugins/filebrowser.c:1164
@@ -6363,7 +6363,7 @@ msgstr "En haut et en bas"
#~ msgid "Set programs and options for compiling and viewing (La)TeX files."
#~ msgstr ""
-#~ "Définir les programmes et options utilisées pour compiler et visionner "
+#~ "Définir les programmes et options utilisés pour compiler et visionner "
#~ "les fichiers (La)Tex."
#~ msgid "DVI creation:"
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
Branch: refs/heads/master
Author: Matthew Brush <mbrush(a)codebrainz.ca>
Committer: GitHub <noreply(a)github.com>
Date: Sun, 11 Sep 2016 02:24:16 UTC
Commit: cc18dd0e60938141bc702ed3da3218e1144de2a4
https://github.com/geany/geany/commit/cc18dd0e60938141bc702ed3da3218e1144de…
Log Message:
-----------
Gracefully handle proxies registering invalid extensions (#1212)
It is very hard to debug if the proxy plugin happens to give
extensions starting with a dot. If they do, detect this case, warn
in the debug messages, and fix the extension. It seems unlikely
that files with two dot extensions will be desired, so it should
case no harm.
Modified Paths:
--------------
src/plugins.c
Modified: src/plugins.c
14 lines changed, 13 insertions(+), 1 deletions(-)
===================================================================
@@ -1966,6 +1966,18 @@ static void pm_show_dialog(GtkMenuItem *menuitem, gpointer user_data)
}
+static const gchar *fix_extension(const gchar *ext)
+{
+ if (*ext == '.')
+ {
+ g_warning(_("Proxy plugin extension '%s' starts with a dot, "
+ "stripping. Please fix your proxy plugin."), ext);
+ ext++;
+ }
+ return ext;
+}
+
+
/** Register the plugin as a proxy for other plugins
*
* Proxy plugins register a list of file extensions and a set of callbacks that are called
@@ -2017,7 +2029,7 @@ gboolean geany_plugin_register_proxy(GeanyPlugin *plugin, const gchar **extensio
foreach_strv(ext, extensions)
{
proxy = g_new(PluginProxy, 1);
- g_strlcpy(proxy->extension, *ext, sizeof(proxy->extension));
+ g_strlcpy(proxy->extension, fix_extension(*ext), sizeof(proxy->extension));
proxy->plugin = p;
/* prepend, so that plugins automatically override core providers for a given extension */
g_queue_push_head(&active_proxies, proxy);
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
Branch: refs/heads/master
Author: Matthew Brush <mbrush(a)codebrainz.ca>
Committer: GitHub <noreply(a)github.com>
Date: Sun, 11 Sep 2016 02:18:10 UTC
Commit: 7d172ceeb3b024c6d206758a0b80631c0b935590
https://github.com/geany/geany/commit/7d172ceeb3b024c6d206758a0b80631c0b935…
Log Message:
-----------
Improve GeanyProxyProbeResults a litte (#1213)
* Add GEANY_ prefix to enumerators.
* Use a discrete set of enumerators so the proxy doesn't have to
worry about flag bitmasks, which isn't required.
* Update documentation.
* Use the new enumerators in Geany.
* Improve debug output for bogus values a bit.
Modified Paths:
--------------
doc/plugins.dox
plugins/demoproxy.c
src/plugindata.h
src/plugins.c
Modified: doc/plugins.dox
13 lines changed, 6 insertions(+), 7 deletions(-)
===================================================================
@@ -768,9 +768,8 @@ done in the GeanyPluginFuncs::init function of the proxy plugin.
- GeanyProxyFuncs::probe may be implemented to probe if a plugin candidate (that has one of the
provided file extensions) is actually a plugin. This may depend on the plugin file itself in
case of ambiguity or availability of runtime dependencies or even configuration.
- @ref PROXY_IGNORED or @ref PROXY_MATCHED should be returned, possibly in combination
- with the @ref PROXY_NOLOAD flag. Not implementing GeanyProxyFuncs::probe at all is equivalent to
- always returning @ref PROXY_MATCHED.
+ @ref GeanyProxyProbeResults constants should be returned. Not implementing GeanyProxyFuncs::probe
+ at all is equivalent to always returning @ref GEANY_PROXY_MATCH.
- GeanyProxyFuncs::load must be implemented to actually load the plugin. It is called by Geany
when the user enables the sub-plugin. What "loading" means is entirely up to the proxy plugin and
probably depends on the interpreter of the dynamic language that shall be supported. After
@@ -807,17 +806,17 @@ Consider the 5 basic cases:
1) A candidate comes with a suitable file extension but is not a workable plugin file at all. For
example, your proxy supports plugins written in a shell script (.sh) but the shebang of that script
points to an incompatible shell (or even lacks a shebang). You should check for this in
-GeanyProxyFuncs::probe() and return @ref PROXY_IGNORED which hides that script from the Plugin
+GeanyProxyFuncs::probe() and return @ref GEANY_PROXY_IGNORE which hides that script from the Plugin
Manager and allows other enabled proxy plugins to pick it up. GeanyProxyFuncs::probe() returning
-@ref PROXY_IGNORED is an indication that the candidate is meant for another proxy, or the user
+@ref GEANY_PROXY_IGNORE is an indication that the candidate is meant for another proxy, or the user
placed the file by accident in one of Geany's plugin directories. In other words the candidate
simply doesn't correspond to your proxy. Thus any noise by debug messages for this case is
undesirable.
2) A proxy plugin provides its own, versioned API to sub-plugin. The API version of the sub-plugin
is not compatible with the API exposed by the proxy. GeanyProxyFuncs::probe() should never perform
a version check because its sole purpose is to indicate a proxy's correspondence to a given
-candidate. It should return @ref PROXY_MATCHED instead. Later, Geany will invoke the
+candidate. It should return @ref GEANY_PROXY_MATCH instead. Later, Geany will invoke the
GeanyProxyFuncs::load(), and this function is the right place for a version check. If it fails then
you simply do not call GEANY_PLUGIN_REGISTER(), but rather print a debug message. The result is
that the sub-plugin is not shown in the Plugin Manager at all. This is consistent with the
@@ -967,7 +966,7 @@ static gint demoproxy_probe(GeanyPlugin *proxy, const gchar *filename, gpointer
match = utils_str_equal(linebuf, "#!!PROXY_MAGIC!!\n");
fclose(f);
}
- return match ? PROXY_MATCHED : PROXY_IGNORED;
+ return match ? GEANY_PROXY_MATCH : GEANY_PROXY_IGNORE;
}
@endcode
Modified: plugins/demoproxy.c
2 lines changed, 1 insertions(+), 1 deletions(-)
===================================================================
@@ -116,7 +116,7 @@ static gint demoproxy_probe(GeanyPlugin *proxy, const gchar *filename, gpointer
match = utils_str_equal(linebuf, "#!!PROXY_MAGIC!!\n");
fclose(f);
}
- return match ? PROXY_MATCHED : PROXY_IGNORED;
+ return match ? GEANY_PROXY_MATCH : GEANY_PROXY_IGNORE;
}
Modified: src/plugindata.h
39 lines changed, 26 insertions(+), 13 deletions(-)
===================================================================
@@ -59,7 +59,7 @@ G_BEGIN_DECLS
* @warning You should not test for values below 200 as previously
* @c GEANY_API_VERSION was defined as an enum value, not a macro.
*/
-#define GEANY_API_VERSION 228
+#define GEANY_API_VERSION 229
/* hack to have a different ABI when built with GTK3 because loading GTK2-linked plugins
* with GTK3-linked Geany leads to crash */
@@ -341,31 +341,44 @@ void geany_plugin_set_data(GeanyPlugin *plugin, gpointer data, GDestroyNotify fr
/** Return values for GeanyProxyHooks::probe()
*
- * Only @c PROXY_IGNORED, @c PROXY_MATCHED or @c PROXY_MATCHED|PROXY_NOLOAD
- * are valid return values.
- *
* @see geany_plugin_register_proxy() for a full description of the proxy plugin mechanisms.
- *
- * @since 1.26 (API 226)
*/
typedef enum
{
+ /** @deprecated Use GEANY_PROXY_IGNORE instead.
+ * @since 1.26 (API 226)
+ */
+ PROXY_IGNORED,
+ /** @deprecated Use GEANY_PROXY_MATCH instead.
+ * @since 1.26 (API 226)
+ */
+ PROXY_MATCHED,
+ /** @deprecated Use GEANY_PROXY_RELATED instead.
+ * @since 1.26 (API 226)
+ */
+ PROXY_NOLOAD = 0x100,
/** The proxy is not responsible at all, and Geany or other plugins are free
* to probe it.
+ *
+ * @since 1.29 (API 229)
**/
- PROXY_IGNORED,
- /** The proxy is responsible for this file, and creates a plugin for it */
- PROXY_MATCHED,
-
- /** The proxy is does not directly load it, but it's still tied to the proxy
+ GEANY_PROXY_IGNORE = PROXY_IGNORED,
+ /** The proxy is responsible for this file, and creates a plugin for it.
+ *
+ * @since 1.29 (API 229)
+ */
+ GEANY_PROXY_MATCH = PROXY_MATCHED,
+ /** The proxy is does not directly load it, but it's still tied to the proxy.
*
* This is for plugins that come in multiple files where only one of these
* files is relevant for the plugin creation (for the PM dialog). The other
* files should be ignored by Geany and other proxies. Example: libpeas has
* a .plugin and a .so per plugin. Geany should not process the .so file
* if there is a corresponding .plugin.
+ *
+ * @since 1.29 (API 229)
*/
- PROXY_NOLOAD = 0x100,
+ GEANY_PROXY_RELATED = PROXY_MATCHED | PROXY_NOLOAD
}
GeanyProxyProbeResults;
@@ -379,7 +392,7 @@ GeanyProxyProbeResults;
struct GeanyProxyFuncs
{
/** Called to determine whether the proxy is truly responsible for the requested plugin.
- * A NULL pointer assumes the probe() function would always return @ref PROXY_MATCHED */
+ * A NULL pointer assumes the probe() function would always return @ref GEANY_PROXY_MATCH */
gint (*probe) (GeanyPlugin *proxy, const gchar *filename, gpointer pdata);
/** Called after probe(), to perform the actual job of loading the plugin */
gpointer (*load) (GeanyPlugin *proxy, GeanyPlugin *subplugin, const gchar *filename, gpointer pdata);
Modified: src/plugins.c
13 lines changed, 8 insertions(+), 5 deletions(-)
===================================================================
@@ -1038,19 +1038,22 @@ static PluginProxy* is_plugin(const gchar *file)
if (utils_str_casecmp(ext, proxy->extension) == 0)
{
Plugin *p = proxy->plugin;
- gint ret = PROXY_MATCHED;
+ gint ret = GEANY_PROXY_MATCH;
if (p->proxy_cbs.probe)
ret = p->proxy_cbs.probe(&p->public, file, p->cb_data);
switch (ret)
{
- case PROXY_MATCHED:
+ case GEANY_PROXY_MATCH:
return proxy;
- case PROXY_MATCHED|PROXY_NOLOAD:
+ case GEANY_PROXY_RELATED:
return NULL;
+ case GEANY_PROXY_IGNORE:
+ continue;
default:
- if (ret != PROXY_IGNORED)
- g_warning("Ignoring bogus return from proxy probe!\n");
+ g_warning("Ignoring bogus return value '%d' from "
+ "proxy plugin '%s' probe() function!", ret,
+ proxy->plugin->info.name);
continue;
}
}
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
Branch: refs/heads/master
Author: Jiří Techet <techet(a)gmail.com>
Committer: Jiří Techet <techet(a)gmail.com>
Date: Sun, 07 Aug 2016 16:31:30 UTC
Commit: ca65fa22367042ea8c88efab7e76d5f0ba209947
https://github.com/geany/geany/commit/ca65fa22367042ea8c88efab7e76d5f0ba209…
Log Message:
-----------
Sync whitespace and comments in main
Modified Paths:
--------------
ctags/main/args.c
ctags/main/args.h
ctags/main/ctags.h
ctags/main/entry.c
ctags/main/entry.h
ctags/main/general.h
ctags/main/lcpp.c
ctags/main/lregex.c
ctags/main/main.c
ctags/main/nestlevel.c
ctags/main/nestlevel.h
ctags/main/options.c
ctags/main/options.h
ctags/main/parse.c
ctags/main/parse.h
ctags/main/parsers.h
ctags/main/read.c
ctags/main/read.h
ctags/main/routines.c
ctags/main/sort.c
ctags/main/sort.h
ctags/main/strlist.c
ctags/main/strlist.h
ctags/main/vstring.c
ctags/main/vstring.h
Modified: ctags/main/args.c
8 lines changed, 4 insertions(+), 4 deletions(-)
===================================================================
@@ -1,23 +1,23 @@
/*
-*
-* Copyright (c) 1999-2001, Darren Hiebert
+* Copyright (c) 1999-2002, Darren Hiebert
*
* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include "args.h"
+#include "debug.h"
#include "routines.h"
/*
Modified: ctags/main/args.h
15 lines changed, 8 insertions(+), 7 deletions(-)
===================================================================
@@ -1,19 +1,20 @@
/*
-*
-* Copyright (c) 1999-2001, Darren Hiebert
+* Copyright (c) 1999-2002, Darren Hiebert
*
* 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.
*/
-#ifndef _ARGS_H
-#define _ARGS_H
+#ifndef CTAGS_MAIN_ARGS_H
+#define CTAGS_MAIN_ARGS_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
+
+#include <stdio.h>
/*
* DATA DECLARATIONS
@@ -53,6 +54,6 @@ extern void argSetLineMode (Arguments* const current);
extern void argForth (Arguments* const current);
extern void argDelete (Arguments* const current);
-#endif /* _ARGS_H */
+#endif /* CTAGS_MAIN_ARGS_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/ctags.h
12 lines changed, 7 insertions(+), 5 deletions(-)
===================================================================
@@ -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
-* GNU General Public License.
+* GNU General Public License version 2 or (at your option) any later version.
*
* Program definitions
*/
-#ifndef _CTAGS_H
-#define _CTAGS_H
+#ifndef CTAGS_MAIN_CTAGS_H
+#define CTAGS_MAIN_CTAGS_H
+
+#include "general.h"
/*
* MACROS
@@ -20,6 +22,6 @@
#define AUTHOR_NAME "Darren Hiebert"
#define AUTHOR_EMAIL "darren(a)hiebert.com"
-#endif /* _CTAGS_H */
+#endif /* CTAGS_MAIN_CTAGS_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/entry.c
21 lines changed, 10 insertions(+), 11 deletions(-)
===================================================================
@@ -1,29 +1,28 @@
/*
-*
-* 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
-* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <string.h>
-#include <ctype.h> /* to define isspace () */
+#include <ctype.h> /* to define isspace () */
#include <errno.h>
#include <glib.h>
#include <glib/gstdio.h>
#if defined (HAVE_SYS_TYPES_H)
-# include <sys/types.h> /* to declare off_t on some hosts */
+# include <sys/types.h> /* to declare off_t on some hosts */
#endif
#if defined (HAVE_TYPES_H)
-# include <types.h> /* to declare off_t on some hosts */
+# include <types.h> /* to declare off_t on some hosts */
#endif
@@ -159,14 +158,14 @@ static void addPseudoTags (void)
}
}
-static void updateSortedFlag (const char *const line,
- MIO *const mio, MIOPos startOfLine)
+static void updateSortedFlag (
+ const char *const line, MIO *const mio, MIOPos startOfLine)
{
const char *const tab = strchr (line, '\t');
if (tab != NULL)
{
- const long boolOffset = tab - line + 1; /* where it should be */
+ const long boolOffset = tab - line + 1; /* where it should be */
if (line [boolOffset] == '0' || line [boolOffset] == '1')
{
@@ -231,7 +230,7 @@ static long unsigned int updatePseudoTags (MIO *const mio)
}
line = readLineRaw (TagFile.vLine, mio);
}
- while (line != NULL) /* skip to end of file */
+ while (line != NULL) /* skip to end of file */
{
++linesRead;
line = readLineRaw (TagFile.vLine, mio);
Modified: ctags/main/entry.h
13 lines changed, 6 insertions(+), 7 deletions(-)
===================================================================
@@ -1,19 +1,18 @@
/*
-*
-* 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
-* GNU General Public License.
+* GNU General Public License version 2 or (at your option) any later version.
*
* External interface to entry.c
*/
-#ifndef _ENTRY_H
-#define _ENTRY_H
+#ifndef CTAGS_MAIN_ENTRY_H
+#define CTAGS_MAIN_ENTRY_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include "mio.h"
#include "vstring.h"
@@ -96,6 +95,6 @@ extern void endEtagsFile (const char *const name);
extern void makeTagEntry (const tagEntryInfo *const tag);
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: */
Modified: ctags/main/general.h
13 lines changed, 6 insertions(+), 7 deletions(-)
===================================================================
@@ -1,19 +1,18 @@
/*
-*
-* Copyright (c) 1998-2001, Darren Hiebert
+* Copyright (c) 1998-2003, Darren Hiebert
*
* 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.
*/
-#ifndef _GENERAL_H
-#define _GENERAL_H
+#ifndef CTAGS_MAIN_GENERAL_H
+#define CTAGS_MAIN_GENERAL_H
/*
* INCLUDE FILES
*/
-#ifdef HAVE_CONFIG_H
+#if defined (HAVE_CONFIG_H)
# include <config.h>
#endif
#ifdef macintosh
@@ -151,6 +150,6 @@ extern void *unlink (const char *);
extern char *getenv (const char *);
#endif
-#endif /* _GENERAL_H */
+#endif /* CTAGS_MAIN_GENERAL_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/lcpp.c
2 lines changed, 1 insertions(+), 1 deletions(-)
===================================================================
@@ -166,7 +166,7 @@ extern void cppEndStatement (void)
* 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.
*/
extern void cppUngetc (const int c)
Modified: ctags/main/lregex.c
5 lines changed, 3 insertions(+), 2 deletions(-)
===================================================================
@@ -2,11 +2,11 @@
* Copyright (c) 2000-2003, Darren Hiebert
*
* 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.
*
-* 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
* Gnu etags.
*/
@@ -91,6 +91,7 @@ static int SetUpper = -1; /* upper language index in list */
* FUNCTION DEFINITIONS
*/
+
static void clearPatternSet (const langType language)
{
if (language <= SetUpper)
Modified: ctags/main/main.c
2 lines changed, 1 insertions(+), 1 deletions(-)
===================================================================
@@ -71,7 +71,7 @@
/*
* MACROS
*/
-#define plural(value) (((unsigned long)(value) == 1L) ? "" : "s")
+#define plural(value) (((unsigned long)(value) == 1L) ? "" : "s")
/*
* DATA DEFINITIONS
Modified: ctags/main/nestlevel.c
2 lines changed, 1 insertions(+), 1 deletions(-)
===================================================================
@@ -3,7 +3,7 @@
* 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
-* 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.
*/
Modified: ctags/main/nestlevel.h
8 lines changed, 4 insertions(+), 4 deletions(-)
===================================================================
@@ -3,12 +3,12 @@
* 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
-* 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.
*/
-#ifndef _NESTLEVEL_H
-#define _NESTLEVEL_H
+#ifndef CTAGS_MAIN_NESTLEVEL_H
+#define CTAGS_MAIN_NESTLEVEL_H
/*
* INCLUDE FILES
@@ -47,6 +47,6 @@ extern void nestingLevelsPush(NestingLevels *nls,
extern void nestingLevelsPop(NestingLevels *nls);
extern NestingLevel *nestingLevelsGetCurrent(NestingLevels *nls);
-#endif /* _NESTLEVEL_H */
+#endif /* CTAGS_MAIN_NESTLEVEL_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/options.c
15 lines changed, 7 insertions(+), 8 deletions(-)
===================================================================
@@ -1,22 +1,21 @@
/*
-*
-* Copyright (c) 1996-2001, Darren Hiebert
+* Copyright (c) 1996-2003, Darren Hiebert
*
* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
-#include <ctype.h> /* to declare isspace () */
+#include <ctype.h> /* to declare isspace () */
#include "ctags.h"
#include "routines.h"
@@ -28,7 +27,7 @@
#define CTAGS_ENVIRONMENT "CTAGS"
-#define CTAGS_FILE "tags"
+#define CTAGS_FILE "tags"
/* The following separators are permitted for list options.
@@ -39,14 +38,14 @@
#define IGNORE_SEPARATORS ", \t\n"
#ifndef DEFAULT_FILE_FORMAT
-# define DEFAULT_FILE_FORMAT 2
+# define DEFAULT_FILE_FORMAT 2
#endif
#if defined (WIN32) || defined (HAVE_OPENDIR)
# define RECURSE_SUPPORTED
#endif
-#define isCompoundOption(c) (boolean) (strchr ("fohiILpDb", (c)) != NULL)
+#define isCompoundOption(c) (boolean) (strchr ("fohiILpDb", (c)) != NULL)
Modified: ctags/main/options.h
6 lines changed, 3 insertions(+), 3 deletions(-)
===================================================================
@@ -18,7 +18,7 @@
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <stdarg.h>
@@ -88,7 +88,7 @@ typedef struct sOptionValues {
/*
* GLOBAL VARIABLES
*/
-extern CONST_OPTION optionValues Option;
+extern CONST_OPTION optionValues Option;
/*
* FUNCTION PROTOTYPES
@@ -106,6 +106,6 @@ extern void freeOptionResources (void);
void addIgnoreListFromFile (const char *const fileName);
-#endif /* _OPTIONS_H */
+#endif /* CTAGS_MAIN_OPTIONS_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/parse.c
11 lines changed, 5 insertions(+), 6 deletions(-)
===================================================================
@@ -1,18 +1,17 @@
/*
-*
-* Copyright (c) 1996-2001, Darren Hiebert
+* Copyright (c) 1996-2003, Darren Hiebert
*
* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <string.h>
@@ -163,7 +162,7 @@ static vString* determineInterpreter (const char* const cmd)
{
vStringClear (interpreter);
for ( ; isspace (*p) ; ++p)
- ; /* no-op */
+ ; /* no-op */
for ( ; *p != '\0' && ! isspace (*p) ; ++p)
vStringPut (interpreter, (int) *p);
vStringTerminate (interpreter);
Modified: ctags/main/parse.h
33 lines changed, 16 insertions(+), 17 deletions(-)
===================================================================
@@ -1,21 +1,20 @@
/*
-*
-* Copyright (c) 1998-2001, Darren Hiebert
+* Copyright (c) 1998-2003, Darren Hiebert
*
* 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.
*/
-#ifndef _PARSE_H
-#define _PARSE_H
+#ifndef CTAGS_MAIN_PARSE_H
+#define CTAGS_MAIN_PARSE_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
-#include "parsers.h" /* contains list of parsers */
+#include "parsers.h" /* contains list of parsers */
#include "strlist.h"
#include "entry.h"
@@ -59,15 +58,15 @@ typedef struct {
typedef struct {
/* defined by parser */
- char* name; /* name of language */
- kindOption* kinds; /* tag kinds handled by parser */
- 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* patterns; /* list of default file name patterns */
- parserInitialize initialize; /* initialization routine, if needed */
- simpleParser parser; /* simple parser (common case) */
- rescanParser parser2; /* rescanning parser (unusual case) */
+ char* name; /* name of language */
+ kindOption* kinds; /* tag kinds handled by parser */
+ 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 *patterns; /* list of default file name patterns */
+ parserInitialize initialize; /* initialization routine, if needed */
+ simpleParser parser; /* simple parser (common case) */
+ rescanParser parser2; /* rescanning parser (unusual case) */
unsigned int method; /* See PARSE__... definitions above */
/* used internally */
@@ -157,6 +156,6 @@ extern tagEntryFunction TagEntryFunction;
extern void *TagEntryUserData;
extern void setTagEntryFunction(tagEntryFunction entry_function, void *user_data);
-#endif /* _PARSE_H */
+#endif /* CTAGS_MAIN_PARSE_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/parsers.h
13 lines changed, 6 insertions(+), 7 deletions(-)
===================================================================
@@ -1,17 +1,16 @@
/*
-*
-* Copyright (c) 2000-2001, Darren Hiebert
+* Copyright (c) 2000-2003, Darren Hiebert
*
* 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.
*
-* 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.
*/
-#ifndef _PARSERS_H
-#define _PARSERS_H
+#ifndef CTAGS_MAIN_PARSERS_H
+#define CTAGS_MAIN_PARSERS_H
/* Add the name of any new parser definition function here */
/* keep src/tagmanager/tm_parser.h in sync */
@@ -68,6 +67,6 @@
ZephirParser, \
PowerShellParser
-#endif /* _PARSERS_H */
+#endif /* CTAGS_MAIN_PARSERS_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/read.c
8 lines changed, 4 insertions(+), 4 deletions(-)
===================================================================
@@ -258,7 +258,7 @@ extern boolean fileOpen (const char *const fileName, const langType language)
*/
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;
}
@@ -365,8 +365,8 @@ static void fileNewline (void)
File.newLine = FALSE;
File.input.lineNumber++;
File.source.lineNumber++;
- DebugStatement ( if (Option.breakLine == File.lineNumber) lineBreak (); )
- DebugStatement ( debugPrintf (DEBUG_RAW, "%6ld: ", File.lineNumber); )
+ DebugStatement ( if (Option.breakLine == File.input.lineNumber) lineBreak (); )
+ DebugStatement ( debugPrintf (DEBUG_RAW, "%6ld: ", File.input.lineNumber); )
}
/* This function reads a single character from the stream, performing newline
@@ -412,7 +412,7 @@ static int iFileGetc (void)
if (next != NEWLINE)
mio_ungetc (File.mio, next);
- c = NEWLINE; /* convert CR into newline */
+ c = NEWLINE; /* convert CR into newline */
File.newLine = TRUE;
mio_getpos (File.mio, &StartOfLine);
}
Modified: ctags/main/read.h
33 lines changed, 15 insertions(+), 18 deletions(-)
===================================================================
@@ -1,19 +1,18 @@
/*
-*
-* 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
-* GNU General Public License.
+* GNU General Public License version 2 or (at your option) any later version.
*
* External interface to read.c
*/
-#ifndef _READ_H
-#define _READ_H
+#ifndef CTAGS_MAIN_READ_H
+#define CTAGS_MAIN_READ_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#include <stdio.h>
#include <ctype.h>
@@ -40,17 +39,15 @@
*/
enum eCharacters {
- /* White space characters.
- */
- SPACE = ' ',
- NEWLINE = '\n',
- CRETURN = '\r',
- FORMFEED = '\f',
- TAB = '\t',
- VTAB = '\v',
-
- /* Some hard to read characters.
- */
+ /* white space characters */
+ SPACE = ' ',
+ NEWLINE = '\n',
+ CRETURN = '\r',
+ FORMFEED = '\f',
+ TAB = '\t',
+ VTAB = '\v',
+
+ /* some hard to read characters */
DOUBLE_QUOTE = '"',
SINGLE_QUOTE = '\'',
BACKSLASH = '\\',
@@ -120,6 +117,6 @@ extern boolean bufferOpen (unsigned char *buffer, size_t buffer_size,
const char *const fileName, const langType language );
#define bufferClose fileClose
-#endif /* _READ_H */
+#endif /* CTAGS_MAIN_READ_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/routines.c
11 lines changed, 5 insertions(+), 6 deletions(-)
===================================================================
@@ -332,7 +332,7 @@ extern boolean isRecursiveLink (const char* const dirName)
char *const separator = strrchr (path, PATH_SEPARATOR);
if (separator == NULL)
break;
- else if (separator == path) /* backed up to root directory */
+ else if (separator == path) /* backed up to root directory */
*(separator + 1) = '\0';
else
*separator = '\0';
@@ -379,7 +379,7 @@ extern const char *baseFilename (const char *const filePath)
if (tail == NULL)
tail = filePath;
else
- ++tail; /* step past last delimiter */
+ ++tail; /* step past last delimiter */
return tail;
}
@@ -473,7 +473,6 @@ extern char* absoluteFilename (const char *file)
{
char *slashp, *cp;
char *res = NULL;
-
if (isAbsolutePath (file))
res = eStrdup (file);
else
@@ -519,7 +518,7 @@ extern char* absoluteFilename (const char *file)
else
{
#ifdef MSDOS_STYLE_PATH
- /* Canonicalize drive letter case. */
+ /* Canonicalize drive letter case. */
if (res [1] == ':' && islower (res [0]))
res [0] = toupper (res [0]);
#endif
@@ -572,11 +571,11 @@ extern char* relativeFilename (const char *file, const char *dir)
while (*fp++ == *dp++)
continue;
fp--;
- dp--; /* back to the first differing char */
+ dp--; /* back to the first differing char */
do
{ /* look at the equal chars until '/' */
if (fp == absdir)
- return absdir; /* first char differs, give up */
+ return absdir; /* first char differs, give up */
fp--;
dp--;
} while (*fp != '/');
Modified: ctags/main/sort.c
15 lines changed, 7 insertions(+), 8 deletions(-)
===================================================================
@@ -1,20 +1,19 @@
/*
-*
-* 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
-* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#if defined (HAVE_STDLIB_H)
-# include <stdlib.h> /* to declare malloc () */
+# include <stdlib.h> /* to declare malloc () */
#endif
#include <string.h>
#include <stdio.h>
@@ -124,8 +123,8 @@ static int compareTags (const void *const one, const void *const two)
return strcmp (line1, line2);
}
-static void writeSortedTags (char **const table, const size_t numTags,
- const boolean toStdout)
+static void writeSortedTags (
+ char **const table, const size_t numTags, const boolean toStdout)
{
MIO *mio;
size_t i;
@@ -186,7 +185,7 @@ extern void internalSortTags (const boolean toStdout)
break;
}
else if (*line == '\0' || strcmp (line, "\n") == 0)
- ; /* ignore blank lines */
+ ; /* ignore blank lines */
else
{
const size_t stringSize = strlen (line) + 1;
Modified: ctags/main/sort.h
12 lines changed, 6 insertions(+), 6 deletions(-)
===================================================================
@@ -1,18 +1,18 @@
/*
-* 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
-* GNU General Public License.
+* GNU General Public License version 2 or (at your option) any later version.
*
* External interface to sort.c
*/
-#ifndef _SORT_H
-#define _SORT_H
+#ifndef CTAGS_MAIN_SORT_H
+#define CTAGS_MAIN_SORT_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
/*
* FUNCTION PROTOTYPES
@@ -25,6 +25,6 @@ extern void externalSortTags (const boolean toStdout);
extern void internalSortTags (const boolean toStdout);
#endif
-#endif /* _SORT_H */
+#endif /* CTAGS_MAIN_SORT_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/strlist.c
2 lines changed, 1 insertions(+), 1 deletions(-)
===================================================================
@@ -2,7 +2,7 @@
* Copyright (c) 1999-2002, Darren Hiebert
*
* 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.
*/
Modified: ctags/main/strlist.h
8 lines changed, 4 insertions(+), 4 deletions(-)
===================================================================
@@ -2,12 +2,12 @@
* Copyright (c) 1999-2002, Darren Hiebert
*
* 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.
*/
-#ifndef _STRLIST_H
-#define _STRLIST_H
+#ifndef CTAGS_MAIN_STRLIST_H
+#define CTAGS_MAIN_STRLIST_H
/*
* 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 void stringListPrint (const stringList *const current);
-#endif /* _STRLIST_H */
+#endif /* CTAGS_MAIN_STRLIST_H */
/* vi:set tabstop=4 shiftwidth=4: */
Modified: ctags/main/vstring.c
14 lines changed, 7 insertions(+), 7 deletions(-)
===================================================================
@@ -1,22 +1,22 @@
/*
-*
* Copyright (c) 1998-2002, Darren Hiebert
*
* 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.
*/
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
-#include <limits.h> /* to define INT_MAX */
+#include <limits.h> /* to define INT_MAX */
#include <string.h>
#include <ctype.h>
+#include "debug.h"
#include "routines.h"
#include "vstring.h"
@@ -60,7 +60,7 @@ extern void vStringTruncate (vString *const string, const size_t length)
string->length = length;
vStringTerminate (string);
DebugStatement ( memset (string->buffer + string->length, 0,
- string->size - string->length); )
+ string->size - string->length); )
}
extern void vStringClear (vString *const string)
@@ -134,7 +134,7 @@ extern vString *vStringNewInit (const char *const s)
}
extern void vStringNCatS (
- vString *const string, const char *const s, const size_t length)
+ vString *const string, const char *const s, const size_t length)
{
const char *p = s;
size_t remain = length;
@@ -204,7 +204,7 @@ extern void vStringCopyS (vString *const string, const char *const s)
}
extern void vStringNCopyS (
- vString *const string, const char *const s, const size_t length)
+ vString *const string, const char *const s, const size_t length)
{
vStringClear (string);
vStringNCatS (string, s, length);
Modified: ctags/main/vstring.h
50 lines changed, 25 insertions(+), 25 deletions(-)
===================================================================
@@ -2,20 +2,20 @@
* Copyright (c) 1998-2002, Darren Hiebert
*
* 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.
*/
-#ifndef _VSTRING_H
-#define _VSTRING_H
+#ifndef CTAGS_MAIN_VSTRING_H
+#define CTAGS_MAIN_VSTRING_H
/*
* INCLUDE FILES
*/
-#include "general.h" /* must always come first */
+#include "general.h" /* must always come first */
#if defined(HAVE_STDLIB_H)
-# include <stdlib.h> /* to define size_t */
+# include <stdlib.h> /* to define size_t */
#endif
/*
@@ -26,33 +26,33 @@
#endif
#ifdef VSTRING_PUTC_MACRO
#define vStringPut(s,c) \
- (void)(((s)->length + 1 == (s)->size ? vStringAutoResize (s) : 0), \
- ((s)->buffer [(s)->length] = (c)), \
- ((c) == '\0' ? 0 : ((s)->buffer [++(s)->length] = '\0')))
+ (void)(((s)->length + 1 == (s)->size ? vStringAutoResize (s) : 0), \
+ ((s)->buffer [(s)->length] = (c)), \
+ ((c) == '\0' ? 0 : ((s)->buffer [++(s)->length] = '\0')))
#endif
-#define vStringValue(vs) ((vs)->buffer)
-#define vStringItem(vs,i) ((vs)->buffer[i])
-#define vStringLast(vs) ((vs)->buffer[(vs)->length - 1])
-#define vStringLength(vs) ((vs)->length)
-#define vStringSize(vs) ((vs)->size)
-#define vStringCat(vs,s) vStringCatS((vs), vStringValue((s)))
-#define vStringNCat(vs,s,l) vStringNCatS((vs), vStringValue((s)), (l))
-#define vStringCopy(vs,s) vStringCopyS((vs), vStringValue((s)))
-#define vStringNCopy(vs,s,l) vStringNCopyS((vs), vStringValue((s)), (l))
-#define vStringChar(vs,i) ((vs)->buffer[i])
-#define vStringTerminate(vs) vStringPut(vs, '\0')
-#define vStringLower(vs) toLowerString((vs)->buffer)
-#define vStringUpper(vs) toUpperString((vs)->buffer)
+#define vStringValue(vs) ((vs)->buffer)
+#define vStringItem(vs,i) ((vs)->buffer[i])
+#define vStringLast(vs) ((vs)->buffer[(vs)->length - 1])
+#define vStringLength(vs) ((vs)->length)
+#define vStringSize(vs) ((vs)->size)
+#define vStringCat(vs,s) vStringCatS((vs), vStringValue((s)))
+#define vStringNCat(vs,s,l) vStringNCatS((vs), vStringValue((s)), (l))
+#define vStringCopy(vs,s) vStringCopyS((vs), vStringValue((s)))
+#define vStringNCopy(vs,s,l) vStringNCopyS((vs), vStringValue((s)), (l))
+#define vStringChar(vs,i) ((vs)->buffer[i])
+#define vStringTerminate(vs) vStringPut(vs, '\0')
+#define vStringLower(vs) toLowerString((vs)->buffer)
+#define vStringUpper(vs) toUpperString((vs)->buffer)
/*
* DATA DECLARATIONS
*/
typedef struct sVString {
- size_t length; /* size of buffer used */
- size_t size; /* allocated size of buffer */
- char * buffer; /* location of buffer */
+ size_t length; /* size of buffer used */
+ size_t size; /* allocated size of buffer */
+ char *buffer; /* location of buffer */
} vString;
/*
@@ -81,6 +81,6 @@ extern void vStringTruncate (vString *const string, const size_t length);
extern vString *vStringNewOwn (char *s);
-#endif /* _VSTRING_H */
+#endif /* CTAGS_MAIN_VSTRING_H */
/* vi:set tabstop=4 shiftwidth=4: */
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).