summaryrefslogtreecommitdiff
path: root/gdb/m2-exp.y
diff options
context:
space:
mode:
authorMarkus Deuling <deuling@de.ibm.com>2008-01-18 09:12:19 +0000
committerMarkus Deuling <deuling@de.ibm.com>2008-01-18 09:12:19 +0000
commita1f5383a6e6630a882aab5557eca39d5c963a27c (patch)
tree5da0bc5d9a1ee6d40b8647855585cb3cb1ff63bc /gdb/m2-exp.y
parent76c1408a41208166b54858bf763809c8039e1ec1 (diff)
downloadgdb-a1f5383a6e6630a882aab5557eca39d5c963a27c.tar.gz
* jv-exp.y (yylex): Replace DEPRECATED_STREQN with the appropriate
function calls. * m2-exp.y (yylex): Likewise. * objc-exp.y (yylex): Likewise. * defs.h (DEPRECATED_STREQN): Remove.
Diffstat (limited to 'gdb/m2-exp.y')
-rw-r--r--gdb/m2-exp.y9
1 files changed, 5 insertions, 4 deletions
diff --git a/gdb/m2-exp.y b/gdb/m2-exp.y
index 9fd62cc0464..143252fd6bd 100644
--- a/gdb/m2-exp.y
+++ b/gdb/m2-exp.y
@@ -845,7 +845,7 @@ yylex ()
/* See if it is a special token of length 2 */
for( i = 0 ; i < (int) (sizeof tokentab2 / sizeof tokentab2[0]) ; i++)
- if(DEPRECATED_STREQN(tokentab2[i].name, tokstart, 2))
+ if (strncmp (tokentab2[i].name, tokstart, 2) == 0)
{
lexptr += 2;
return tokentab2[i].token;
@@ -1002,7 +1002,8 @@ yylex ()
/* Lookup special keywords */
for(i = 0 ; i < (int) (sizeof(keytab) / sizeof(keytab[0])) ; i++)
- if(namelen == strlen(keytab[i].keyw) && DEPRECATED_STREQN(tokstart,keytab[i].keyw,namelen))
+ if (namelen == strlen (keytab[i].keyw)
+ && strncmp (tokstart, keytab[i].keyw, namelen) == 0)
return keytab[i].token;
yylval.sval.ptr = tokstart;
@@ -1076,12 +1077,12 @@ yylex ()
else
{
/* Built-in BOOLEAN type. This is sort of a hack. */
- if(DEPRECATED_STREQN(tokstart,"TRUE",4))
+ if (strncmp (tokstart, "TRUE", 4) == 0)
{
yylval.ulval = 1;
return M2_TRUE;
}
- else if(DEPRECATED_STREQN(tokstart,"FALSE",5))
+ else if (strncmp (tokstart, "FALSE", 5) == 0)
{
yylval.ulval = 0;
return M2_FALSE;