Mercurial > cpython-lru_cache-weakref
annotate Include/mappingobject.h @ 1590:ac2e5cc29949 legacy-trunk
Added tests for missing host to open_http and open_gopher
| author | Guido van Rossum <guido@python.org> |
|---|---|
| date | Mon, 18 Apr 1994 09:39:56 +0000 |
| parents | 1d841587aede |
| children | 1940892d2fe3 |
| rev | line source |
|---|---|
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
1 #ifndef Py_MAPPINGOBJECT_H |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
2 #define Py_MAPPINGOBJECT_H |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
3 #ifdef __cplusplus |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
4 extern "C" { |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
5 #endif |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
6 |
|
1256
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
7 /*********************************************************** |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
8 Copyright 1991, 1992, 1993 by Stichting Mathematisch Centrum, |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
9 Amsterdam, The Netherlands. |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
10 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
11 All Rights Reserved |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
12 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
13 Permission to use, copy, modify, and distribute this software and its |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
14 documentation for any purpose and without fee is hereby granted, |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
15 provided that the above copyright notice appear in all copies and that |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
16 both that copyright notice and this permission notice appear in |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
17 supporting documentation, and that the names of Stichting Mathematisch |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
18 Centrum or CWI not be used in advertising or publicity pertaining to |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
19 distribution of the software without specific, written prior permission. |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
20 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
21 STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
22 THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
23 FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
24 FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
25 WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
26 ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
27 OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
28 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
29 ******************************************************************/ |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
30 |
|
1288
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
31 /* Mapping object type -- mapping from hashable object to object */ |
|
1256
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
32 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
33 extern typeobject Mappingtype; |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
34 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
35 #define is_mappingobject(op) ((op)->ob_type == &Mappingtype) |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
36 |
|
7aa9613ffd36
Generalized version of dictionaries, with compatibility hacks.
Guido van Rossum <guido@python.org>
parents:
diff
changeset
|
37 extern object *newmappingobject PROTO((void)); |
|
1288
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
38 extern object *mappinglookup PROTO((object *mp, object *key)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
39 extern int mappinginsert PROTO((object *mp, object *key, object *item)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
40 extern int mappingremove PROTO((object *mp, object *key)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
41 extern void mappingclear PROTO((object *mp)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
42 extern int mappinggetnext |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
43 PROTO((object *mp, int *pos, object **key, object **value)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
44 extern object *getmappingkeys PROTO((object *mp)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
45 extern object *getmappingvalues PROTO((object *mp)); |
|
9fed5726a36d
Several changes in one:
Guido van Rossum <guido@python.org>
parents:
1256
diff
changeset
|
46 extern object *getmappingitems PROTO((object *mp)); |
|
1398
1d841587aede
Added getmappingsize(). (Needed by previous checkin of posixmodule.c)
Guido van Rossum <guido@python.org>
parents:
1329
diff
changeset
|
47 extern int getmappingsize PROTO((object *mp)); |
|
1329
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
48 |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
49 #ifdef __cplusplus |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
50 } |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
51 #endif |
|
519c25039c6a
* Added support for X11 modules.
Guido van Rossum <guido@python.org>
parents:
1288
diff
changeset
|
52 #endif /* !Py_MAPPINGOBJECT_H */ |
