[asperl] added AS patch#3
[p5sagit/p5-mst-13.2.git] / perly.c
diff --git a/perly.c b/perly.c
index ff8a839..2cd4f05 100644 (file)
--- a/perly.c
+++ b/perly.c
@@ -6,11 +6,20 @@ static char yysccsid[] = "@(#)yaccpar 1.8 (Berkeley) 01/20/91";
 #include "EXTERN.h"
 #include "perl.h"
 
+#ifdef PERL_OBJECT
 static void
-dep()
+Dep(CPerlObj *pPerl)
+{
+    pPerl->deprecate("\"do\" to call subroutines");
+}
+#define dep() Dep(this)
+#else
+static void
+dep(void)
 {
     deprecate("\"do\" to call subroutines");
 }
+#endif
 
 #line 16 "perly.c"
 #define YYERRCODE 256
@@ -1303,8 +1312,7 @@ struct ysv {
 };
 
 void
-yydestruct(ptr)
-void* ptr;
+yydestruct(void *ptr)
 {
     struct ysv* ysave = (struct ysv*)ptr;
     if (ysave->yyss) Safefree(ysave->yyss);
@@ -1319,7 +1327,7 @@ void* ptr;
 }
 
 int
-yyparse()
+yyparse(void)
 {
     register int yym, yyn, yystate;
     register short *yyssp;
@@ -1330,8 +1338,10 @@ yyparse()
     int retval = 0;
 #if YYDEBUG
     register char *yys;
+#ifndef __cplusplus
     extern char *getenv();
 #endif
+#endif
 
     struct ysv *ysave = (struct ysv*)safemalloc(sizeof(struct ysv));
     SAVEDESTRUCTOR(yydestruct, ysave);