Version 14 (modified by jkeenan, 12 years ago)

--

December 12 2009 Pre-Release Hackathon

Topics

  • 12 December 2009: Miscellaneous Hackathon - We'll focus on:
    • Merge CallSignature and Context. This work is being done in the context_unify3 branch.
    • Remove uses of ->strstart outside of src/string. Either use Parrot_str_to_cstring/Parrot_str_free_cstring bufstart. See r40983 for examples of both and ask on #parrot if you're not sure.
    • When in doubt, look at Parrot's  test coverage and write tests for code we don't currently cover.

Resources

context_unify3 branch

 Smolder report at r43007.

->strstart cleanup

Here are 73 instances of ->strstart in 19 files outside of src/string/.
(Note: Wiki formatting problems mean that the code listed for ./src/pmc/filehandle.pmc line 370 is not correct.)

Check off completed instances by editing wiki to put an asterisk after first 2 vertical bars.

FixedFileLineCodeRev/Editor/Comment
*./src/gc/mark_sweep.c312(char*) ((PMC*)b)->vtable->whoami->strstart);r43017 darbelo
./src/packfile/pf_items.c1331s->strstart, OFFS(pf, *cursor)));
./src/packfile/pf_items.c1389if (s->strstart) {
./src/packfile/pf_items.c1390mem_sys_memcopy(charcursor, s->strstart, s->bufused);
./src/pmc/filehandle.pmc370char * const r = readline(got_prompt ? prompt->strstart NULL);
./src/pmc/filehandle.pmc381fprintf(stderr, "%s", prompt->strstart);
./src/pmc/filehandle.pmc394&& (((char *)string_result->strstart)[len - 1] == '\n'
./src/pmc/filehandle.pmc395 ((char *)string_result->strstart)[len - 1] == '\r')) {
./src/pmc/eval.pmc284if ((size_t)(res->strstart) & 0xf) {
./src/pmc/eval.pmc285char *adr = res->strstart;
./src/pmc/eval.pmc287res->strstart = adr;
./src/pmc/eval.pmc296PackFile_pack(INTERP, pf, (opcode_t *)res->strstart);
./src/pmc/eval.pmc354if (PackFile_unpack(INTERP, pf, (opcode_t *)packed->strstart,
./src/io/win32.c493void * const buffer = s->strstart;
./src/io/unix.c556const char * const buffer = s->strstart;
./src/io/utf8.c64const utf8_t *u8ptr = (utf8_t *)((char *)s->strstart +
./src/io/portable.c306const size_t bytes = fread(s->strstart, 1, 1, fptr);
./src/io/portable.c311ungetc(*(char *)s->strstart, fptr);
./src/io/portable.c409void * const buffer = s->strstart;
./src/io/buffer.c303if (!s->strstart)
./src/io/buffer.c306out_buf = (unsigned char *)s->strstart;
./src/io/buffer.c442memmove(s->strstart, buffer_next, len);
./src/io/buffer.c510if (s->strstart) {
./src/io/buffer.c517out_buf = (unsigned char*)s->strstart + s->strlen;
./src/io/buffer.c529if (s->strstart) {
./src/io/buffer.c536out_buf = (unsigned char*)s->strstart + s->strlen;
./src/io/buffer.c568void * const buffer = s->strstart;
./src/io/socket_win32.c251if ((error = send((int)io->os_handle, (char *)s->strstart + byteswrote,(Win32-specific)
./src/io/socket_unix.c304if ((error = send(io->os_handle, (char *)s->strstart + byteswrote,
./src/utils.c585const char * const str_start = base->strstart;
./src/utils.c587const char * const search_str = search->strstart;
*./src/utils.c635const char * const search_start = search->strstart;r43011 cotto, r43014 mikehh
*./src/utils.c644const char * const base_start = (char *)base->strstart + current_offset;r43009 jkeenan
*./src/oo.c958bits = (((UINTVAL) method_name->strstart) >> 2) & TBL_SIZE_MASK;r43010 jkeenan
*./src/oo.c979while (e && e->strstart != method_name->strstart) {r43010 jkeenan
*./src/oo.c991e->strstart = method_name->strstart;r43010 jkeenan
./src/dynext.c335if (!STRING_IS_EMPTY(lib) && memcmp(lib->strstart, "lib", 3) == 0) {(Win32-specific)
./src/dynext.c336*handle = Parrot_dlopen((char *)lib->strstart + 3);(Win32-specific)
./src/dynext.c346if (!STRING_IS_EMPTY(lib) && memcmp(lib->strstart, "lib", 3) == 0) {(Cygwin-specific)
*./src/pmc_freeze.c348ignored = PF_store_number((opcode_t *)((ptrcast_t)s->strstart + used), &v);r43015 darbelo
*./src/pmc_freeze.c377ignored = PF_store_string((opcode_t *)((ptrcast_t)s->strstart + used), v);r43015 darbelo
./src/pmc_freeze.c399const char * const start = (char *)io->image->strstart;
./src/pmc_freeze.c400char **opcode = &io->image->strstart;
./src/pmc_freeze.c404io->image->bufused -= ((char *)io->image->strstart - start);
./src/pmc_freeze.c405io->image->strlen -= ((char *)io->image->strstart - start);
./src/pmc_freeze.c428const char * const start = (const char *)io->image->strstart;
./src/pmc_freeze.c429char **opcode = &io->image->strstart;
./src/pmc_freeze.c433io->image->bufused -= ((char *)io->image->strstart - start);
./src/pmc_freeze.c434io->image->strlen -= ((char *)io->image->strstart - start);
./src/pmc_freeze.c459char * const start = (char*)io->image->strstart;
./src/pmc_freeze.c460char * opcode = io->image->strstart;
./src/pmc_freeze.c464io->image->strstart = opcode;
./src/pmc_freeze.c535mem_sys_memcopy(s->strstart, pf->header, PACKFILE_HEADER_BYTES);
./src/pmc_freeze.c554mem_sys_memcopy(pf->header, s->strstart, PACKFILE_HEADER_BYTES);
./src/pmc_freeze.c560LVALUE_CAST(char *, s->strstart) += header_length;
./src/pmc_freeze.c1140LVALUE_CAST(char *, image->strstart) -= bufused;
./src/pmc_freeze.c1144PARROT_ASSERT(image->strstart >= (char *)Buffer_bufstart(image));