perl 5.000d : [hint file updates]
[p5sagit/p5-mst-13.2.git] / x2p / str.h
1 /* $RCSfile: str.h,v $$Revision: 4.1 $$Date: 92/08/07 18:29:27 $
2  *
3  *    Copyright (c) 1991, Larry Wall
4  *
5  *    You may distribute under the terms of either the GNU General Public
6  *    License or the Artistic License, as specified in the README file.
7  *
8  * $Log:        str.h,v $
9  */
10
11 struct string {
12     char *      str_ptr;        /* pointer to malloced string */
13     double      str_nval;       /* numeric value, if any */
14     int         str_len;        /* allocated size */
15     int         str_cur;        /* length of str_ptr as a C string */
16     union {
17         STR *str_next;          /* while free, link to next free str */
18     } str_link;
19     char        str_pok;        /* state of str_ptr */
20     char        str_nok;        /* state of str_nval */
21 };
22
23 #define Nullstr Null(STR*)
24
25 /* the following macro updates any magic values this str is associated with */
26
27 #define STABSET(x) (x->str_link.str_magic && stabset(x->str_link.str_magic,x))
28
29 EXT STR **tmps_list;
30 EXT long tmps_max INIT(-1);
31
32 char *str_2ptr();
33 double str_2num();
34 STR *str_mortal();
35 STR *str_make();
36 STR *str_nmake();
37 char *str_gets();