with debug
[prop.git] / prop-src / listimpl.h
blob141ec85fa8737894628f0f4cb5256d7caef4448c
1 ///////////////////////////////////////////////////////////////////////////////
2 // This file is generated automatically using Prop (version 2.3.6),
3 // last updated on Nov 2, 1999.
4 // The original source file is "listimpl.ph".
5 ///////////////////////////////////////////////////////////////////////////////
7 #line 1 "listimpl.ph"
8 #ifndef list_operations_implementations_h
9 #define list_operations_himplementations_
11 #include "basics.h"
13 //#pragma interface
15 template <class T>
16 int length (
17 #line 9 "listimpl.ph"
18 a_List<T> *
19 #line 9 "listimpl.ph"
21 { int len = 0;
23 #line 12 "listimpl.ph"
25 for (;;) {
26 if (l) {
27 #line 12 "listimpl.ph"
28 l = l->_2; len++;
29 #line 12 "listimpl.ph"
30 } else { goto L1; }
32 L1:;
34 #line 13 "listimpl.ph"
35 #line 13 "listimpl.ph"
37 return len;
40 template <class T>
42 #line 18 "listimpl.ph"
43 a_List<T> *
44 #line 18 "listimpl.ph"
45 append (a_List<T> *
46 #line 18 "listimpl.ph"
47 a, a_List<T> *
48 #line 18 "listimpl.ph"
51 #line 21 "listimpl.ph"
53 if (a) {
54 #line 21 "listimpl.ph"
55 return
56 #line 21 "listimpl.ph"
57 #line 21 "listimpl.ph"
58 list_1_(a->_1,append(a->_2,b))
59 #line 21 "listimpl.ph"
60 #line 21 "listimpl.ph"
62 #line 21 "listimpl.ph"
63 } else {
64 #line 20 "listimpl.ph"
65 return b;
66 #line 20 "listimpl.ph"
69 #line 22 "listimpl.ph"
70 #line 22 "listimpl.ph"
74 template <class T>
76 #line 26 "listimpl.ph"
77 a_List<T> *
78 #line 26 "listimpl.ph"
79 rev (a_List<T> *
80 #line 26 "listimpl.ph"
82 { a_List<T> *
83 #line 27 "listimpl.ph"
84 b =
85 #line 27 "listimpl.ph"
86 nil_1_
87 #line 27 "listimpl.ph"
88 #line 27 "listimpl.ph"
91 #line 28 "listimpl.ph"
92 #line 29 "listimpl.ph"
94 for (;;) {
95 if (a) {
96 #line 29 "listimpl.ph"
97 b =
98 #line 29 "listimpl.ph"
99 #line 29 "listimpl.ph"
100 list_1_(a->_1,b)
101 #line 29 "listimpl.ph"
102 #line 29 "listimpl.ph"
103 ; a = a->_2;
104 #line 29 "listimpl.ph"
105 } else { goto L2; }
107 L2:;
109 #line 30 "listimpl.ph"
110 #line 30 "listimpl.ph"
112 return b;
116 #endif
117 #line 36 "listimpl.ph"
119 ------------------------------- Statistics -------------------------------
120 Merge matching rules = yes
121 Number of DFA nodes merged = 2
122 Number of ifs generated = 3
123 Number of switches generated = 0
124 Number of labels = 0
125 Number of gotos = 0
126 Adaptive matching = enabled
127 Fast string matching = disabled
128 Inline downcasts = enabled
129 --------------------------------------------------------------------------