SF.net SVN: geany: [2694] trunk
eht16 at users.sourceforge.net
eht16 at xxxxx
Sun Jun 15 17:50:15 UTC 2008
Revision: 2694
http://geany.svn.sourceforge.net/geany/?rev=2694&view=rev
Author: eht16
Date: 2008-06-15 10:50:07 -0700 (Sun, 15 Jun 2008)
Log Message:
-----------
Fix a regression introduced in latest bug fixes and fix some indentation and comments.
Modified Paths:
--------------
trunk/ChangeLog
trunk/tagmanager/python.c
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2008-06-15 15:24:44 UTC (rev 2693)
+++ trunk/ChangeLog 2008-06-15 17:50:07 UTC (rev 2694)
@@ -1,3 +1,10 @@
+2008-06-15 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
+
+ * tagmanager/python.c:
+ Fix a regression introduced in latest bug fixes and fix some
+ indentation and comments.
+
+
2008-06-11 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
* tagmanager/python.c:
@@ -8,7 +15,7 @@
Create Makefiles for src, tagmanager and scintilla sub directories
to be able to run make from within Geany.
* scintilla/scintilla-marshal.c:
- Updated generated marschal code for Scintilla.
+ Updated generated marshal code for Scintilla.
2008-06-10 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
Modified: trunk/tagmanager/python.c
===================================================================
--- trunk/tagmanager/python.c 2008-06-15 15:24:44 UTC (rev 2693)
+++ trunk/tagmanager/python.c 2008-06-15 17:50:07 UTC (rev 2694)
@@ -180,15 +180,15 @@
{
for (; *cp; cp++)
{
- if (*cp == '"' || *cp == '\'')
+ if (*cp == '"' || *cp == '\'')
{
cp = skipString(cp);
if (!*cp) break;
}
if (isIdentifierFirstCharacter ((int) *cp))
return cp;
- }
- return cp;
+ }
+ return cp;
}
/* Skip an identifier. */
@@ -196,7 +196,7 @@
{
while (isIdentifierCharacter ((int) *cp))
cp++;
- return cp;
+ return cp;
}
static const char *findDefinitionOrClass (const char *cp)
@@ -383,27 +383,27 @@
*/
static char const *find_triple_start(char const *string, char const **which)
{
- char const *cp = string;
+ char const *cp = string;
- for (; *cp; cp++)
+ for (; *cp; cp++)
{
- if (*cp == '"' || *cp == '\'')
+ if (*cp == '"' || *cp == '\'')
{
- if (strcmp(cp, doubletriple) == 0)
- {
- *which = doubletriple;
- return cp;
- }
- if (strcmp(cp, singletriple) == 0)
- {
- *which = singletriple;
- return cp;
- }
+ if (strncmp(cp, doubletriple, 3) == 0)
+ {
+ *which = doubletriple;
+ return cp;
+ }
+ if (strncmp(cp, singletriple, 3) == 0)
+ {
+ *which = singletriple;
+ return cp;
+ }
cp = skipString(cp);
if (!*cp) break;
}
}
- return NULL;
+ return NULL;
}
/* Find the end of a triple string as pointed to by "which", and update "which"
@@ -411,11 +411,11 @@
*/
static void find_triple_end(char const *string, char const **which)
{
- char const *s = string;
- while (1)
+ char const *s = string;
+ while (1)
{
- /* Check if the string ends in the same line. */
- s = strstr (s, *which);
+ /* Check if the string ends in the same line. */
+ s = strstr (s, *which);
if (!s) break;
s += 3;
*which = NULL;
@@ -435,7 +435,7 @@
const char *cp, *sp, *eq, *start;
cp = strstr(line, "=");
- if (! cp)
+ if (!cp)
return NULL;
eq = cp + 1;
while (*eq)
@@ -480,8 +480,8 @@
while ((line = (const char *) fileReadLine ()) != NULL)
{
const char *cp = line;
- char *longstring;
- const char *keyword, *variable;
+ char const *longstring;
+ char const *keyword, *variable;
int indent;
cp = skipSpace (cp);
@@ -489,7 +489,7 @@
if (*cp == '\0') /* skip blank line */
continue;
- /* Skip comment if we are not inside a multi-line string */
+ /* Skip comment if we are not inside a multi-line string. */
if (*cp == '#' && !longStringLiteral)
continue;
@@ -514,7 +514,7 @@
/* Deal with multiline string ending. */
if (longStringLiteral)
{
- find_triple_end(cp, &longStringLiteral);
+ find_triple_end(cp, &longStringLiteral);
continue;
}
@@ -522,14 +522,10 @@
longstring = find_triple_start(cp, &longStringLiteral);
if (longstring)
{
- /* Note: For our purposes, the line just ends at the first long
- * string. I.e. we don't parse for any tags in the rest of the
- * line, but we do look for the string ending of course.
- */
- *longstring = '\0';
-
longstring += 3;
find_triple_end(longstring, &longStringLiteral);
+ /* We don't parse for any tags in the rest of the line. */
+ continue;
}
/* Deal with def and class keywords. */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Commits
mailing list