Lines 70-75
Link Here
|
70 |
|
70 |
|
71 |
hash_entry *symbol_hash[HASH_SIZE]; |
71 |
hash_entry *symbol_hash[HASH_SIZE]; |
72 |
|
72 |
|
|
|
73 |
static inline unsigned int hash(const char *s); |
73 |
inline unsigned int hash(const char *s) |
74 |
inline unsigned int hash(const char *s) |
74 |
{ |
75 |
{ |
75 |
unsigned int h = 0; |
76 |
unsigned int h = 0; |
Lines 82-87
Link Here
|
82 |
return abs(h % HASH_SIZE); |
83 |
return abs(h % HASH_SIZE); |
83 |
} |
84 |
} |
84 |
|
85 |
|
|
|
86 |
static inline void AddToHash(completion_list *cl); |
85 |
inline void AddToHash(completion_list *cl) |
87 |
inline void AddToHash(completion_list *cl) |
86 |
{ |
88 |
{ |
87 |
unsigned int h = hash(cl->symbol); |
89 |
unsigned int h = hash(cl->symbol); |
Lines 96-101
Link Here
|
96 |
} |
98 |
} |
97 |
|
99 |
|
98 |
/* mmmmm... free hash */ |
100 |
/* mmmmm... free hash */ |
|
|
101 |
static inline void FreeHash(void); |
99 |
inline void FreeHash(void) |
102 |
inline void FreeHash(void) |
100 |
{ |
103 |
{ |
101 |
unsigned int i; |
104 |
unsigned int i; |
Lines 117-122
Link Here
|
117 |
|
120 |
|
118 |
/* XML Helper Functions */ |
121 |
/* XML Helper Functions */ |
119 |
|
122 |
|
|
|
123 |
static inline char *XMLTagChild(xmlNodePtr node, const char *name); |
120 |
inline char *XMLTagChild(xmlNodePtr node, const char *name) |
124 |
inline char *XMLTagChild(xmlNodePtr node, const char *name) |
121 |
{ |
125 |
{ |
122 |
xmlNodePtr cur = node->xmlChildrenNode; |
126 |
xmlNodePtr cur = node->xmlChildrenNode; |
Lines 141-146
Link Here
|
141 |
return NULL; |
145 |
return NULL; |
142 |
} |
146 |
} |
143 |
|
147 |
|
|
|
148 |
static inline char *XMLTagAttr(xmlNodePtr node, const char *attr); |
144 |
inline char *XMLTagAttr(xmlNodePtr node, const char *attr) |
149 |
inline char *XMLTagAttr(xmlNodePtr node, const char *attr) |
145 |
{ |
150 |
{ |
146 |
xmlAttrPtr props = node->properties; |
151 |
xmlAttrPtr props = node->properties; |
Lines 167-172
Link Here
|
167 |
|
172 |
|
168 |
/* Look up functions for symbols and descriptions */ |
173 |
/* Look up functions for symbols and descriptions */ |
169 |
|
174 |
|
|
|
175 |
static inline completion_list *LookUpSymbol(const char *symbol); |
170 |
inline completion_list *LookUpSymbol(const char *symbol) |
176 |
inline completion_list *LookUpSymbol(const char *symbol) |
171 |
{ |
177 |
{ |
172 |
unsigned int h = hash(symbol); |
178 |
unsigned int h = hash(symbol); |
Lines 187-192
Link Here
|
187 |
return NULL; |
193 |
return NULL; |
188 |
} |
194 |
} |
189 |
|
195 |
|
|
|
196 |
static inline desc_url_list *LookUpDesc(completion_list *entry, const char *desc); |
190 |
inline desc_url_list *LookUpDesc(completion_list *entry, const char *desc) |
197 |
inline desc_url_list *LookUpDesc(completion_list *entry, const char *desc) |
191 |
{ |
198 |
{ |
192 |
desc_url_list *cur = entry->descs; |
199 |
desc_url_list *cur = entry->descs; |
Lines 206-211
Link Here
|
206 |
|
213 |
|
207 |
/* Add the given name, description and url to our completion list */ |
214 |
/* Add the given name, description and url to our completion list */ |
208 |
|
215 |
|
|
|
216 |
static inline int AddToCompletionList(const char *name, |
217 |
const char *desc, const char *url); |
209 |
inline int AddToCompletionList(const char *name, |
218 |
inline int AddToCompletionList(const char *name, |
210 |
const char *desc, const char *url) |
219 |
const char *desc, const char *url) |
211 |
{ |
220 |
{ |
Lines 274-279
Link Here
|
274 |
} |
283 |
} |
275 |
|
284 |
|
276 |
/* Encode the given string so that {X}Emacs will understand it */ |
285 |
/* Encode the given string so that {X}Emacs will understand it */ |
|
|
286 |
static inline char *Encode(const char *s); |
277 |
inline char *Encode(const char *s) |
287 |
inline char *Encode(const char *s) |
278 |
{ |
288 |
{ |
279 |
unsigned int extra_len = 0; |
289 |
unsigned int extra_len = 0; |
Lines 341-346
Link Here
|
341 |
|
351 |
|
342 |
/* Output the completion list in a way {X}Emacs can easily read in */ |
352 |
/* Output the completion list in a way {X}Emacs can easily read in */ |
343 |
|
353 |
|
|
|
354 |
static inline int OutputCompletionList(void); |
344 |
inline int OutputCompletionList(void) |
355 |
inline int OutputCompletionList(void) |
345 |
{ |
356 |
{ |
346 |
completion_list *cur = comp_list; |
357 |
completion_list *cur = comp_list; |
Lines 400-405
Link Here
|
400 |
|
411 |
|
401 |
/* Clean up */ |
412 |
/* Clean up */ |
402 |
|
413 |
|
|
|
414 |
static inline void FreeCompletionList(void); |
403 |
inline void FreeCompletionList(void) |
415 |
inline void FreeCompletionList(void) |
404 |
{ |
416 |
{ |
405 |
completion_list *cur = comp_list; |
417 |
completion_list *cur = comp_list; |
Lines 428-434
Link Here
|
428 |
} |
440 |
} |
429 |
|
441 |
|
430 |
/* Add the members of a compound to the completion list */ |
442 |
/* Add the members of a compound to the completion list */ |
431 |
|
443 |
static inline int AddCompoundMembers(xmlNodePtr compound, |
|
|
444 |
const char *name, const char *url); |
432 |
inline int AddCompoundMembers(xmlNodePtr compound, |
445 |
inline int AddCompoundMembers(xmlNodePtr compound, |
433 |
const char *name, const char *url) |
446 |
const char *name, const char *url) |
434 |
{ |
447 |
{ |