diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-04-01 00:24:25 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-04-01 00:24:25 +0000 |
commit | cb359b415c42e7a6c1192036d2ee416133c9daa1 (patch) | |
tree | 2545e4df22aaa9707c207ced342943d1d95af4b8 | |
parent | 4ffa161021ef4153827d85743ff391e5d86446bc (diff) | |
download | perl-cb359b415c42e7a6c1192036d2ee416133c9daa1.tar.gz |
Integrate changes #9493,9494,9495,9496 from maintperl
into mainline.
fix a broken workaround for Borland compiler in change#4739
(caused weird "short reads" on DATA, which caused op/misc.t to fail)
nits spotted by Borland compiler
avoid redefinition warnings under Borland 5.02
various nits identified by the Borland 5.5 compiler; remove suppression
of a few warnings
p4raw-link: @9496 on //depot/maint-5.6/perl: 9d05ad52b0aa7d1f7d147da0c4dbc14de5fe4a37
p4raw-link: @9495 on //depot/maint-5.6/perl: 759997f1e719f33541bed70dd7f79bfa26a930b3
p4raw-link: @9494 on //depot/maint-5.6/perl: 01b59bde1cb7ff62776f3b83c0f2575c79a950a6
p4raw-link: @9493 on //depot/maint-5.6/perl: eea7051a8d4ef81c032143ab3193bc1240ab2e8f
p4raw-link: @4739 on //depot/perl: c39cd00800303e8967294e98aa4c427a1872a251
p4raw-id: //depot/perl@9497
p4raw-integrated: from //depot/maint-5.6/perl@9492 'merge in' sv.c
utf8.h (@9288..) toke.c (@9292..) ext/File/Glob/bsd_glob.c
(@9415..) win32/makefile.mk (@9426..) win32/win32.h (@9494..)
-rw-r--r-- | ext/File/Glob/bsd_glob.c | 2 | ||||
-rw-r--r-- | sv.c | 10 | ||||
-rw-r--r-- | toke.c | 2 | ||||
-rw-r--r-- | utf8.h | 2 | ||||
-rw-r--r-- | win32/makefile.mk | 5 | ||||
-rw-r--r-- | win32/win32.h | 7 |
6 files changed, 16 insertions, 12 deletions
diff --git a/ext/File/Glob/bsd_glob.c b/ext/File/Glob/bsd_glob.c index 6e2c9f1e85..1a12ddfaa8 100644 --- a/ext/File/Glob/bsd_glob.c +++ b/ext/File/Glob/bsd_glob.c @@ -674,7 +674,7 @@ glob3(Char *pathbuf, Char *pathend, Char *pattern, * and dirent.h as taking pointers to differently typed opaque * structures. */ - Direntry_t *(*readdirfunc)(); + Direntry_t *(*readdirfunc)(DIR*); *pathend = BG_EOS; errno = 0; @@ -7680,8 +7680,8 @@ Perl_gp_dup(pTHX_ GP *gp) MAGIC * Perl_mg_dup(pTHX_ MAGIC *mg) { - MAGIC *mgret = (MAGIC*)NULL; - MAGIC *mgprev; + MAGIC *mgprev = (MAGIC*)NULL; + MAGIC *mgret; if (!mg) return (MAGIC*)NULL; /* look for it in the table first */ @@ -7692,10 +7692,10 @@ Perl_mg_dup(pTHX_ MAGIC *mg) for (; mg; mg = mg->mg_moremagic) { MAGIC *nmg; Newz(0, nmg, 1, MAGIC); - if (!mgret) - mgret = nmg; - else + if (mgprev) mgprev->mg_moremagic = nmg; + else + mgret = nmg; nmg->mg_virtual = mg->mg_virtual; /* XXX copy dynamic vtable? */ nmg->mg_private = mg->mg_private; nmg->mg_type = mg->mg_type; @@ -4182,6 +4182,8 @@ Perl_yylex(pTHX) (void)PerlIO_seek(PL_rsfp, 0L, 0); } if (PerlLIO_setmode(PerlIO_fileno(PL_rsfp), O_TEXT) != -1) { + /* XXX see note in do_binmode() */ + ((FILE*)PL_rsfp)->flags &= ~_F_BIN; if (loc > 0) PerlIO_seek(PL_rsfp, loc, 0); } @@ -82,7 +82,7 @@ END_EXTERN_C #define UTF_CONTINUATION_MARK 0x80 #define UTF_ACCUMULATION_SHIFT 6 #define UTF_CONTINUATION_MASK ((U8)0x3f) -#define UTF8_ACCUMULATE(old, new) ((old) << UTF_ACCUMULATION_SHIFT | (((U8)new) & UTF_CONTINUATION_MASK)) +#define UTF8_ACCUMULATE(old, new) (((old) << UTF_ACCUMULATION_SHIFT) | (((U8)new) & UTF_CONTINUATION_MASK)) #define UTF8_EIGHT_BIT_HI(c) ((((U8)(c))>>UTF_ACCUMULATION_SHIFT)|UTF_START_MARK(2)) #define UTF8_EIGHT_BIT_LO(c) (((((U8)(c)))&UTF_CONTINUATION_MASK)|UTF_CONTINUATION_MARK) diff --git a/win32/makefile.mk b/win32/makefile.mk index 3f6f9c2a19..499453bcaf 100644 --- a/win32/makefile.mk +++ b/win32/makefile.mk @@ -356,8 +356,8 @@ RSC = rc # Options # INCLUDES = -I$(COREDIR) -I.\include -I. -I.. -I"$(CCINCDIR)" -#PCHFLAGS = -H -Hc -H=c:\temp\bcmoduls.pch -DEFINES = -DWIN32 -D_MT $(CRYPT_FLAG) +#PCHFLAGS = -H -Hc -H=c:\temp\bcmoduls.pch +DEFINES = -DWIN32 $(CRYPT_FLAG) LOCDEFS = -DPERLDLL -DPERL_CORE SUBSYS = console CXX_FLAG = -P @@ -381,6 +381,7 @@ EXEOUT_FLAG = -e LIBOUT_FLAG = .IF "$(BCCOLD)" != "define" LINK_FLAGS += -Gn +DEFINES += -D_MT .END .IF "$(BCCVCL)" == "define" LIBC = cp32mti.lib vcl.lib vcl50.lib vclx50.lib vcle50.lib diff --git a/win32/win32.h b/win32/win32.h index 232542c580..05a568b6e7 100644 --- a/win32/win32.h +++ b/win32/win32.h @@ -165,8 +165,11 @@ struct utsname { #ifdef __BORLANDC__ /* Borland C++ */ +#if (__BORLANDC__ <= 0x520) #define _access access #define _chdir chdir +#endif + #define _getpid getpid #define wcsicmp _wcsicmp #include <sys/types.h> @@ -183,8 +186,6 @@ struct utsname { #pragma warn -aus /* "'foo' is assigned a value that is never used" */ #pragma warn -use /* "'foo' is declared but never used" */ #pragma warn -csu /* "comparing signed and unsigned values" */ -#pragma warn -pro /* "call to function with no prototype" */ -#pragma warn -stu /* "undefined structure 'foo'" */ /* Borland is picky about a bare member function name used as its ptr */ #ifdef PERL_OBJECT @@ -306,7 +307,7 @@ extern int mkstemp(const char *path); #define init_os_extras Perl_init_os_extras DllExport void Perl_win32_init(int *argcp, char ***argvp); -DllExport void Perl_init_os_extras(); +DllExport void Perl_init_os_extras(void); DllExport void win32_str_os_error(void *sv, DWORD err); DllExport int RunPerl(int argc, char **argv, char **env); |