summaryrefslogtreecommitdiff
path: root/perlio.c
Commit message (Collapse)AuthorAgeFilesLines
* Make "real" layers of ":utf8" and ":raw".Nick Ing-Simmons2001-01-211-15/+162
| | | | | | | So now PERLIO=utf8 perl ... does what Andreas wanted. Fix arg passing in open.pm (still have a Carp issue). p4raw-id: //depot/perlio@8511
* "Safe" signals - trial implementation.Nick Ing-Simmons2001-01-171-0/+3
| | | | | | | | gv.c tweaked to zero PL_sig_pend array perlio.c tweaked to PERL_ASYNC_CHECK() on EINTR util.c tweaked to not set SA_RESTART to give perlio.c a chance. Odd thing is that it "works" with PERLIO=stdio as well (linux). p4raw-id: //depot/perlio@8467
* FILE * in XS code for PerlIO world:Nick Ing-Simmons2001-01-061-2/+18
| | | | | | | - make PERLIO_NOT_STDIO 0 (co-existance) default for non PERL_CORE case. - Add FILE * T_STDIO typemap. - Finish PerlIO_findFILE() and PerlIO_extprtFILE() p4raw-id: //depot/perlio@8356
* Tweak perlio.c so that makedef.pl-exported perlsio_binmode()Nick Ing-Simmons2000-12-311-14/+14
| | | | | is available to be exported p4raw-id: //depot/perlio@8281
* Finish 1st pass of "encoding" layer e.g. :Nick Ing-Simmons2000-12-111-18/+7
| | | | | open($fh,"<encoding(iso8859-7)",$greek) || die; p4raw-id: //depot/perlio@8085
* Restore mmap function (broken by tweaks to shared bufferNick Ing-Simmons2000-12-111-6/+11
| | | | | layer for encode(xxxx)). p4raw-id: //depot/perlio@8082
* Not merge worthy...Nick Ing-Simmons2000-12-101-31/+51
| | | | | | | | Allow arg to layers e.g. open($fh,"<:encode(iso8859-15)",$name) syntax is modelled on attributes. Untested fix for io/utf8 on Win32 etc. Very clumsy start to the encode layer. p4raw-id: //depot/perlio@8076
* Make print, syswrite, send, readline, getc honour utf8-ness of PerlIO.Nick Ing-Simmons2000-12-091-1/+9
| | | | | | | | | | | | | | | (sysread, recv and write i.e. formats still to do...) Allow :utf8 or :bytes in PerlIO_apply_layers() so that open($fh,">:utf8","name") etc. work. - "applying" those just sets/clears the UTF8 bit of the top layer, so no extra overhead is involved. Tweak t/comp/require.t to add a 'use bytes' to permit its dubious writing of BOM to a non-utf8 stream. Add initial io/utf8.t Fix SvPVutf8() - sv_2pv() was not expecting to be called with something that was already SvPOK() - (we just fossiked with SvUTF8 bit). Fix that and also just use the SvPV macro in sv_2pvutf8() to avoid the issue/overhead. p4raw-id: //depot/perlio@8054
* Change PerlIO_(get|set)pos to take SV *Nick Ing-Simmons2000-12-071-27/+50
| | | | | Should fix, OS/2, VMS, (sfio??) p4raw-id: //depot/perlio@8025
* Various attempts at MSVC debug - not sure what hasNick Ing-Simmons2000-12-071-0/+2
| | | | | | | changed but works now. Seems atexit() _may_ work for DLLs built with MSVC so don't call cleanup that way. p4raw-id: //depot/perlio@8021
* Integrate perlio:Jarkko Hietaniemi2000-12-051-28/+78
|\ | | | | | | | | | | | | | | [ 7983] PERL_IMPLICIT_SYS (almost) works - something odd with "signal" p4raw-link: @7983 on //depot/perlio: 5f1a76d08cedee4f2888d077fe9593b03dd9bd13 p4raw-id: //depot/perl@7985
| * PERL_IMPLICIT_SYS (almost) works - something odd with "signal"Nick Ing-Simmons2000-12-041-28/+78
| | | | | | p4raw-id: //depot/perlio@7983
* | [ID 20001203.001] Not OK: perl v5.7.0 +DEVEL7965 on os2-64int-ld 2.30 ↵Yitzchak Scott-Thoennes2000-12-041-1/+9
|/ | | | | | | (UNINSTALLED) Message-Id: <200012040306.eB436rE18922@garcia.efn.org> p4raw-id: //depot/perl@7976
* PERL_IMPLICIT_SYS compiles but does not work.Nick Ing-Simmons2000-12-031-2/+31
| | | p4raw-id: //depot/perlio@7970
* Make iperlsys.h vector stdio not PerlIO.Nick Ing-Simmons2000-12-031-36/+36
| | | p4raw-id: //depot/perlio@7961
* Integrate mainlineNick Ing-Simmons2000-12-011-9/+9
|\ | | | | p4raw-id: //depot/perlio@7945
| * toke.c perlio.c -Wformat nitsRobin Barker2000-11-301-9/+9
| | | | | | | | | | Message-Id: <200011301427.OAA00030@tempest.npl.co.uk> p4raw-id: //depot/perl@7935
* | Fix 'mmap' lib/filehand.t (ungetc) test fail.Nick Ing-Simmons2000-12-011-28/+176
|/ | | | | | | | | | | Make 'unix' pass most tests - do unread by temporary push of layer ("pending") holding unread chars - fast_gets is now based on per-handle flag - relax one of io/pipe.t tests to allow print to fail and close to succeed so that it passes on unbuffered "unix" layer. Remaining fail is sporadic and a genuine race condition between parent/child in fork test. p4raw-id: //depot/perlio@7942
* Initial tidy of setmode() muddle (UNIX does not have, nor need it).Nick Ing-Simmons2000-11-281-25/+22
| | | p4raw-id: //depot/perlio@7906
* setmode() is a DOSish-only thing.Jarkko Hietaniemi2000-11-281-1/+3
| | | p4raw-id: //depot/perl@7901
* __FUNCTION__ isn't portable and trying to emulate it leadsJarkko Hietaniemi2000-11-271-7/+7
| | | | | | into practically spelling out the name of the function. Takes care of the bug 20001127.001. p4raw-id: //depot/perl@7886
* Integrate mainline.Nick Ing-Simmons2000-11-251-1/+5
|\ | | | | p4raw-id: //depot/perlio@7859
| * Undo the SOCKS workarounds, instead start using PerlIOJens Hamisch2000-11-251-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | if SOCKS is selected. Subject: perl@7847, [ID 20001030.005], close-patch, perlio - The big cleanup Date: Fri, 24 Nov 2000 18:31:30 +0100 Message-ID: <20001124183130.E28337@Strawberry.COM> Subject: Re: perl@7847, [ID 20001030.005], close-patch, perlio - Patch the patch ... From: Jens Hamisch <jens@Strawberry.COM> Date: Fri, 24 Nov 2000 19:11:51 +0100 Message-ID: <20001124191151.A28753@Strawberry.COM> p4raw-id: //depot/perl@7855
* | All tests pass on Win32/gcc/USE_PERLIO.Nick Ing-Simmons2000-11-251-5/+5
| | | | | | | | | | | | | | - when crlf layer is pushed make unix-level binary. - remove :crlf injection in pp_backtick in pp_sys.c - (Change dependacy of extension .dll's to perldll.def rather than perl.exe) p4raw-id: //depot/perlio@7857
* | Re-arrange crlf vs binary for platforms that care.Nick Ing-Simmons2000-11-241-115/+232
|/ | | | | | | | crlf layer is now "the" buffer layer and can turn its behaviour on/off. Lip-service to making stdio layer work on such platforms (untested). Now fails 3 tests rather than one, checkin to see if I can debug the issue under linux. (Do not merge.) p4raw-id: //depot/perlio@7853
* Win32/perlio Now just fails one io/argv.t test - lack Nick Ing-Simmons2000-11-231-1/+0
| | | | | of default :crlf on standard streams. p4raw-id: //depot/perlio@7844
* Win32 passes all but t/lib/peek.t with perlio and home-grown crlf.Nick Ing-Simmons2000-11-231-3/+27
| | | | | | peek fail is showing a real problem (multiple crlf layers are getting pushed.) p4raw-id: //depot/perlio@7843
* Implement PerlIO_binmode()Nick Ing-Simmons2000-11-231-70/+172
| | | | | | | | Fix PerlIOCrlf_unread() (*--ptr rather than *ptr-- ...) Test on UNIX with PERLIO="perlio crlf" to mimic Win32, make binmode in t/lib/io_tell.t unconditional so that works. Checkin just so Win32 machine can see these changes. p4raw-id: //depot/perlio@7842
* Implement crlf layer - not ready for merge.Nick Ing-Simmons2000-11-231-25/+229
| | | p4raw-id: //depot/perlio@7836
* Win32 PerlIO intermediate state now working as expected.Nick Ing-Simmons2000-11-221-7/+15
| | | | | | | | | | | | | | | | | | - In current state we are still using C runtime in text/binary mode and "crlf" layer is just a dummy (clone of perlio buffer layer). - PERLIO=stdio and PERLIO=unix pass all expected tests. - PERLIO=perlio fails t/lib/dprof.t because Dprof.xs calls PerlIO_tell() and PerlIO_seek() and the dummy crlf layer is not making adjustments for CRLF translation happening in C runtime. All other tests pass. Added note to README.win32 to point out the snags of doing a perl build with Norton AntiVirus turned on. Tweaked t/pragma/warnings.t so that when run stand-alone you can tell which file a fail comes from. Updated "canned" config.h to match the one generated. p4raw-id: //depot/perlio@7802
* Integrate perlio:Jarkko Hietaniemi2000-11-211-14/+91
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ 7796] Win32 builds and runs (mostly) with USE_PERLIO. PERLIO=perlio passes all tests. PERLIO=stdio (sadly the default) hangs in t.pragma/warnings.t #319 [ 7790] If we use (aTHX_ ...) then put Perl_ on the front. (Or drop the aTHX_). [ 7788] Make extra buffer layer work (dummy crlf layer) p4raw-link: @7796 on //depot/perlio: 83b075c35b61a28ca7e2629bb5d6e26f9e0354fe p4raw-link: @7790 on //depot/perlio: efeab7a8047d7136a0235c1cc7329f57d6a8bfdd p4raw-link: @7788 on //depot/perlio: 88b61e10dfef3b0642d1458a9fff93e5000f86b0 p4raw-id: //depot/perl@7797
| * Win32 builds and runs (mostly) with USE_PERLIO.Nick Ing-Simmons2000-11-211-1/+17
| | | | | | | | | | | | PERLIO=perlio passes all tests. PERLIO=stdio (sadly the default) hangs in t.pragma/warnings.t #319 p4raw-id: //depot/perlio@7796
| * Make extra buffer layer work (dummy crlf layer)Nick Ing-Simmons2000-11-201-13/+74
| | | | | | p4raw-id: //depot/perlio@7788
* | Re: Not OK: perl5.7.0 +DEVEL7706 +Duseperlio on AIX4.[23]Dominic Dunlop2000-11-211-0/+6
|/ | | | | | | | Message-Id: <p04320403b63b2c750dce@[192.168.1.4]> va_copy() and the need of it. See <http://wwwold.dkuug.dk/JTC1/SC22/WG14/www/docs/n907.ps>. p4raw-id: //depot/perl@7793
* Add dummy crlf layer (just as buffer)Nick Ing-Simmons2000-11-191-1/+36
| | | | | Correct 1st bug - one layer of indirection. p4raw-id: //depot/perlio@7755
* Special case :crlf and :raw in dummy PerlIO_apply_layersNick Ing-Simmons2000-11-191-0/+4
| | | p4raw-id: //depot/perlio@7751
* Compiler denit.Jarkko Hietaniemi2000-11-181-0/+2
| | | p4raw-id: //depot/perl@7743
* Lexical use open ... support:Nick Ing-Simmons2000-11-181-4/+54
| | | | | | | | | | | | add ->cop_io to COP structure in cop.h. Make mg.c and gv.c associate it with ${^OPEN}. Make lib/open.pm set it. Have sv.c, perl.c, pp_ctl.c, op.c manipulate it in a manner manner similar to ->cop_warnings. Have doio.c's do_open9 and pp_sys.c's pp_backticks use it as default and call new PerlIO_apply_layers(). Declare latter in perlio.h and define in perlio.c p4raw-id: //depot/perlio@7740
* Basic tweaks to do_open() type parsing to allow layer/disciplineNick Ing-Simmons2000-11-181-30/+36
| | | | | part to be isolated. p4raw-id: //depot/perlio@7736
* Experiment on use of attributes.pm interface.Nick Ing-Simmons2000-11-171-7/+92
| | | | | | | Valid generic fix to auto-vivify code in rv2gv - only "upgrade" to SVt_PVRV if not already something better (else vivify of say magic gets core dump). p4raw-id: //depot/perlio@7727
* Minor tweaks:Nick Ing-Simmons2000-11-161-2/+2
| | | | | | | | consistent way of getting 'rb', 'wb' etc. for binary opens move *perlio::layers to *open::layers a #define to show layers available DOSISH popen/PerlIO had export/import sense inverted. p4raw-id: //depot/perlio@7711
* Integrate perlio:Jarkko Hietaniemi2000-11-141-176/+75
|\ | | | | | | | | | | | | | | [ 7684] PerlIO #include and #ifdef re-work. p4raw-link: @7684 on //depot/perlio: 76ced9add7b621dfc9d4ecb534aeea8e131a418a p4raw-id: //depot/perl@7685
| * PerlIO #include and #ifdef re-work.Nick Ing-Simmons2000-11-141-176/+75
| | | | | | p4raw-id: //depot/perlio@7684
* | Redo #7679 with LFs instead of CRLFs.Jarkko Hietaniemi2000-11-141-14/+14
| | | | | | p4raw-id: //depot/perl@7680
* | Get PerlIO building on Win32Benjamin Stuhl2000-11-141-14/+14
|/ | | | | Message-ID: <20001113230808.18659.qmail@web6305.mail.yahoo.com> p4raw-id: //depot/perl@7679
* Make PerlIO_getpos() to behave like fgetpos() on return.Jarkko Hietaniemi2000-11-131-1/+1
| | | p4raw-id: //depot/perl@7672
* fputs() does return EOF on error but here we don't care.Jarkko Hietaniemi2000-11-131-1/+2
| | | p4raw-id: //depot/perl@7670
* [ID 20001112.008] perlio.c's PerlIO_getpos ingores error returnNicholas Clark2000-11-131-1/+1
| | | | | | | Message-Id: <E13v4S3-0000iY-00@Bagpuss.unfortu.net> Note: only one breakage of the two reported is fixed by this patch. p4raw-id: //depot/perl@7666
* Add aTHX_ to Perl_croak's (MULTIPLICITY et. al.)Nick Ing-Simmons2000-11-121-4/+4
| | | p4raw-id: //depot/perlio@7656
* More descriptive error for unknown perlio layers.Dominic Dunlop2000-11-111-1/+1
| | | | | | Subject: [PATCHES Bleadperl] Re: PerlIO - what all of you can all do. Message-Id: <p04320401b632c4c3335b@[192.168.1.4]> p4raw-id: //depot/perl@7650