Lines Matching +defs:current +defs:buffer
44 # define SNPRINTF_G(nv, buffer, size, ndig) \
45 quadmath_snprintf(buffer, size, "%.*Qg", (int)ndig, (NV)(nv))
47 # define SNPRINTF_G(nv, buffer, size, ndig) \
48 PERL_UNUSED_RESULT(Gconvert((NV)(nv), (int)ndig, 0, buffer))
470 /* freeing GP entries may indirectly free the current GV;
720 struct arena_set *current = aroot;
727 Safefree(current);
1359 Expands the character buffer in the SV. If necessary, uses C<sv_unref> and
1360 upgrades the SV to C<SVt_PV>. Returns a pointer to the character buffer.
1452 just assigns a char buffer and returns a pointer to it.
1891 SV *const buffer = sv_newmortal();
1892 gv_efullname3(buffer, gv, "*");
1893 not_a_number(buffer);
2859 * buffer, including a zero byte. On success returns the written length,
2867 S_infnan_2pv(NV nv, char* buffer, size_t maxlen, char plus) {
2868 char* s = buffer;
2895 assert((s == buffer + 3) || (s == buffer + 4));
2897 return s - buffer;
2972 char *buffer;
2977 retval = buffer = savepvn("NULLREF", len);
3027 Newx(buffer, len, char);
3028 buffer_end = retval = buffer + len;
3049 buffer here. */
3050 assert (retval >= buffer);
3056 SAVEFREEPV(buffer);
3188 SV *const buffer = sv_newmortal();
3190 gv_efullname3(buffer, gv, "*");
3192 assert(SvPOK(buffer));
3193 if (SvUTF8(buffer))
3198 *lp = SvCUR(buffer);
3199 return SvPVX(buffer);
4563 * We swipe the string (steal the string buffer) if the SV on the
4570 * We also steal the buffer from a PADTMP (operator target) if it
4578 * copy-on-write. If the lhs already has a buffer big enough and the
4584 * consider whether the buffer is too large relative to the string
4586 * buffer in the expectation of reusing it. But turning such into
4587 * a COW buffer is counter-productive because it increases memory
4588 * usage by making readline allocate a new large buffer the sec-
4589 * ond time round. So, if the buffer is too large, again, we use
4592 * Finally, if there is no buffer on the left, or the buffer is too
4594 * string buffer.
4610 /* whose buffer is worth stealing */
4777 buffer, unlike C<undef $sv>.
4988 Returns a char * pointer to the SvPV buffer.
5221 C<NUL>, and the realloc will be skipped (I<i.e.>, the buffer is actually at
5322 we need to write to CowREFCNT, or de-RO the whole buffer if we are
5323 the only owner left of the buffer. */
5334 /* Else we are the only owner of the buffer. */
5339 /* This SV doesn't own the buffer, so need to Newx() a new one: */
5345 /* OK, so we don't need to copy our buffer. */
5368 /* OK, so we don't need to copy our buffer. */
5390 then a copy-on-write scalar drops its PV buffer (if any) and becomes
5449 /* Their buffer is already owned by someone else. */
5487 Efficient removal of characters from the beginning of the string buffer.
5489 pointer to somewhere inside the string buffer. C<ptr> becomes the first
5579 /* Fill the preceding buffer with sentinals to verify that no-one is
6891 * body. The PVX buffer is shared by multiple re's and only
7051 else { /* no more elements of current AV to free */
7063 else { /* no more fields in the current SV to free */
7073 /* no more elements of current HV to free */
8345 * in the strings were. The current bytes may or may not be
8423 * then comparing the current byte is sufficient, as there
8641 char *buffer = SvGROW(sv, (STRLEN)(recsize + append + 1)) + append;
8661 bytesread = PerlLIO_read(fd, buffer, recsize);
8668 bytesread = PerlIO_read(fp, buffer, recsize);
8674 char *bend = buffer + bytesread;
8675 char *bufp = buffer;
8700 STRLEN bufp_offset = bufp - buffer;
8719 buffer = SvGROW(sv, append + bytesread + readsize + 1) + append;
8720 bend = buffer + bytesread;
8737 bend = buffer + bytesread;
8738 bufp = buffer + bufp_offset;
8747 buffer[bytesread] = '\0';
8786 /* line is going to be appended to the existing buffer in the sv */
8824 * buffer reference count. */
8888 * We can do buffer based IO operations on this filehandle.
8891 * the buffer directly, it also means we know the upper bound
8892 * on the amount of data we might read of the current buffer
8901 STDCHAR *ptr; /* pointer into fp's read-ahead buffer */
8904 I32 shortbuffered; /* If the pv buffer is shorter than the amount
8905 of data left in the read-ahead buffer.
8906 If 0 then the pv buffer can hold the full
8918 * separators when they cross a read-ahead buffer boundary.
8921 * that may be longer than a single read ahead buffer.
8932 * going to be able to reuse the same pv buffer each call.) If there is
8936 * 2. When we scan forward we copy from the read-ahead buffer to the target
8937 * SV's pv buffer. While we go we watch for the end of the read-ahead buffer,
8946 * 4. If we run out of read-ahead buffer (cnt goes to 0) then we have to get
8947 * the IO system to read the next buffer. We do this by doing a getc(), which
8948 * returns a single char read (or EOF), and prefills the buffer, and also
8949 * allows us to find out how full the buffer is. We use this information to
8950 * SvGROW() the sv to the size remaining in the buffer, after which we copy
8954 * 5. If we run out of write-buffer then we SvGROW() it by the size of the
8955 * remaining space in the read-buffer.
8959 * and cross-read-buffer separators cleanly and efficiently at the cost
8966 /* get the number of bytes remaining in the read-ahead buffer
8982 * the rest of the read-ahead buffer */
8989 /* we have enough room to hold the full buffer, lets scream */
8993 /* extract the pointer to sv's string buffer, offset by append as necessary */
8995 /* extract the point to the read-ahead buffer */
9009 /* if there is stuff left in the read-ahead buffer */
9036 /* no separator, slurp the full buffer */
9047 /* we didn't have enough room to fit the line into the target buffer
9048 * so we must extend the target buffer and keep going */
9053 /* extned the target sv's buffer so it can hold the full read-ahead buffer */
9060 /* we need to refill the read-ahead buffer if possible */
9073 call PerlIO_getc() to let it prefill the lookahead buffer
9091 /* find out how much is left in the read-ahead buffer, and rextract its pointer */
9657 string buffer can be "stolen" if this SV is copied. See also
9710 are responsible for ensuring that the source buffer is at least
9711 C<len> bytes long. If the C<buffer> argument is NULL the new SV will be
9718 Perl_newSVpvn(pTHX_ const char *const buffer, const STRLEN len)
9721 sv_setpvn_fresh(sv,buffer,len);
11420 /* Implement a fast "%.0f": given a pointer to the end of a buffer (caller
11505 * of dynamically growing buffer might be better, start at just 16 bytes
11553 * The vhex is the pointer to the beginning of the output buffer of VHEX_SIZE.
11847 * output buffer, if the extraction index escaped the extraction
11848 * buffer, or if the ending output pointer didn't match the
12198 const char *fmtstart; /* character following the current '%' */
12199 const char *q; /* current position within format */
13334 /* Determine the buffer size needed for the various
13351 * For most of the format types the maximum buffer size needed
13361 * we over-estimate the needed buffer size, for example by
14042 /* open the current directory (so we can switch back) */
14064 /* Iterate once through dp, to get the file name at the current posi-
14072 * we could fit it in a buffer, we could not copy it
15565 Create and return a new interpreter by cloning the current one.
16064 /* current interpreter roots */
16765 char buffer[2];
16766 buffer[0] = gvtype;
16767 buffer[1] = 0;
16771 gv_fullname4(name, gv, buffer, 0);
16774 buffer[0] = '^';
16775 buffer[1] = SvPVX(name)[1] + 'A' - 1;
16778 version - ie substr($name, 1, 1) = $buffer; */
16779 sv_insert(name, 1, 1, buffer, 2);