Branch: Tag:

2003-02-08

2003-02-08 03:49:23 by Martin Stjernholm <mast@lysator.liu.se>

Replaced MAKE_SHARED_CONSTANT_STRING with either MAKE_CONST_STRING or
REF_MAKE_CONST_STRING as appropriate.

Rev: src/builtin.cmod:1.115
Rev: src/interpret.h:1.126
Rev: src/iterators.cmod:1.34
Rev: src/language.yacc:1.315
Rev: src/las.c:1.324
Rev: src/opcodes.c:1.135
Rev: src/program.c:1.479
Rev: src/treeopt.in:1.73

2:   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: language.yacc,v 1.314 2003/02/04 18:17:33 mast Exp $ + || $Id: language.yacc,v 1.315 2003/02/08 03:49:22 mast Exp $   */      %pure_parser
113:   /* This is the grammar definition of Pike. */      #include "global.h" - RCSID("$Id: language.yacc,v 1.314 2003/02/04 18:17:33 mast Exp $"); + RCSID("$Id: language.yacc,v 1.315 2003/02/08 03:49:22 mast Exp $");   #ifdef HAVE_MEMORY_H   #include <memory.h>   #endif
848:       if ($1 & ID_VARIANT) {    struct pike_string *bad_arg_str; -  MAKE_CONSTANT_SHARED_STRING(bad_arg_str, +  MAKE_CONST_STRING(bad_arg_str,    "Bad number of arguments!\n");       fprintf(stderr, "Required args: %d\n", num_required_args);
863:    mkefuncallnode("aggregate",    mkstrnode(bad_arg_str))),    NULL)); -  free_string(bad_arg_str); +     }       {
991:       if(!$3)    { -  struct pike_string *s; -  MAKE_CONSTANT_SHARED_STRING(s,""); -  $3=mkstrnode(s); -  free_string(s); +  $3=mkstrnode(empty_pike_string);    }       if($3->u.sval.u.string->len &&
2277:    struct pike_string *create_string = NULL;    int f;    -  MAKE_CONSTANT_SHARED_STRING(create_string, "create"); +  MAKE_CONST_STRING(create_string, "create");       /* First: Deduce the type for the create() function. */    push_type(T_VOID); /* Return type. */
2377:    pop_compiler_frame();    free_node($4);    free_type(type); -  free_string(create_string); +     }    ;   
3254:    | '.' TOK_IDENTIFIER    {    struct pike_string *dot; -  MAKE_CONSTANT_SHARED_STRING(dot, "."); +  MAKE_CONST_STRING(dot, ".");    if (call_handle_import(dot)) {    node *tmp=mkconstantsvaluenode(Pike_sp-1);    pop_stack();
3263:    }    else    $$=mknewintnode(0); -  free_string(dot); +     if(Pike_compiler->last_identifier) free_string(Pike_compiler->last_identifier);    copy_shared_string(Pike_compiler->last_identifier, $2->u.sval.u.string);    free_node($2);