This file is indexed.

/usr/include/styx/prs_abs.h is in styx-dev 2.0.1-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
/* ------------------------------------------------------------------------ */
/*                                                                          */
/* [prs_abs.h]              Abstract LR Parser Interface                    */
/*                                                                          */
/* Copyright (c) 2002 by D\olle, Manns                                      */
/* ------------------------------------------------------------------------ */

/* File generated by 'ctoh'. Don't change manually. */

#ifndef prs_abs_INCL
#define prs_abs_INCL


#include "prs_dfn.h"


#ifdef __cplusplus
extern "C" {
#endif


/* 
   <p>This module [prs_abs] provides an abstract LR parser interface for the
   term generation module <a href="ptm_gen.htm">[ptm_gen]</a>.
   <p>It can be used to integrate an externally defined parser with the STYX term
   generation facility.
*/

/* ----------------------------- The Types --------------------------------- */

AbstractType(AbsPlr_T); /* Abstract parser interface type */

/*  
  Types of the parser (interface and configuration) functions
*/

typedef int      (*PF_cfgsize )(Abs_T parser);
typedef int      (*PF_symType )(Abs_T parser, int symID);
typedef c_string (*PF_symName )(Abs_T parser, int symID);
typedef int      (*PF_startSym)(Abs_T parser, int startID);
typedef int      (*PF_prodNT  )(Abs_T parser, int prodID);
typedef c_string (*PF_prodName)(Abs_T parser, int prodID);
typedef int      (*PF_dynprod )(Abs_T parser, int prodID);
typedef int      (*PIF_nextTok)(AbsPlr_T pconfig);
typedef c_string (*PIF_curTok )(AbsPlr_T pconfig);
typedef Any_T    (*PIF_topVal )(AbsPlr_T pconfig);
typedef Any_T    (*PIF_shift  )(AbsPlr_T pconfig, int symID);
typedef Any_T    (*PIF_reduce )
                 (
                   AbsPlr_T pconfig, int symcnt, int prodID, c_bool accept
                 );
typedef c_bool   (*PIF_parse  )
                 (
                   AbsPlr_T pconfig, c_string symStart, c_bool early
                 );
typedef c_bool   (*PIF_accept )(AbsPlr_T pconfig);
typedef void     (*PIF_error  )(AbsPlr_T pconfig);
typedef void     (*PIF_debug  )(AbsPlr_T pconfig, Any_T value);

/* ---------------------------- Init & Quit -------------------------------- */

AbsPlr_T AP_init(void);             /* creates an abstract parser interface */

void AP_quit(AbsPlr_T pconfig)
/* removes abstract parser interface 'pconfig' */
;


/* --------------- Specification of the external parser interface ---------- */

void AP_setParser(AbsPlr_T pconfig, Abs_T parser)
/* specifies the external 'parser' of the abstract interface 'pconfig' */
;


/* 
  <p>An external defined parser must provide the following interface
     functions. They have to be assigned to the abstract parser interface
     before initializing the term generation. That module calls them
     during the construction of the derivation tree.
*/

void AP_setFunSymCnt(AbsPlr_T pconfig, PF_cfgsize symCnt)
/* specifies 'symCnt' as corresponding function for PLR_symbolCnt
   in the abstract interface 'pconfig'
*/
;

void AP_setFunTokCnt(AbsPlr_T pconfig, PF_cfgsize tokCnt)
/* specifies 'tokCnt' as corresponding function for PLR_tokenCnt
   in the abstract interface 'pconfig'
*/
;

void AP_setFunProdCnt(AbsPlr_T pconfig, PF_cfgsize prodCnt)
/* specifies 'prodCnt' as corresponding function for PLR_prodCnt
   in the abstract interface 'pconfig'
*/
;

void AP_setFunSymType(AbsPlr_T pconfig, PF_symType symType)
/* specifies 'symType' as corresponding function for PLR_symType
   in the abstract interface 'pconfig'
*/
;

void AP_setFunSymName(AbsPlr_T pconfig, PF_symName symName)
/* specifies 'symName' as corresponding function for PLR_symName
   in the abstract interface 'pconfig'
*/
;

void AP_setFunStartSym(AbsPlr_T pconfig, PF_startSym startSym)
/* specifies 'startSym' as corresponding function for PLR_startSymbol
   in the abstract interface 'pconfig'
*/
;

void AP_setFunProdNT(AbsPlr_T pconfig, PF_prodNT prodNT)
/* specifies 'prodNT' as corresponding function for PLR_prodNonTerm
   in the abstract interface 'pconfig'
*/
;

void AP_setFunProdName(AbsPlr_T pconfig, PF_prodName prodName)
/* specifies 'prodName' as corresponding function for PLR_prodName
   in the abstract interface 'pconfig'
*/
;

void AP_setFunProdDynIdx(AbsPlr_T pconfig, PF_dynprod prodDynIdx)
/* specifies 'prodDynIdx' as corresponding function for PLR_prodDSymIdx
   in the abstract interface 'pconfig'
*/
;

void AP_setFunProdDynSym(AbsPlr_T pconfig, PF_dynprod prodDynSym)
/* specifies 'prodDynSym' as corresponding function for PLR_prodDSymSym
   in the abstract interface 'pconfig'
*/
;

void AP_setFunTopVal(AbsPlr_T pconfig, PIF_topVal topVal)
/* specifies 'topVal' as corresponding function for PLR_topVal
   in the abstract interface 'pconfig'
*/
;

void AP_setFunParse(AbsPlr_T pconfig, PIF_parse parse)
/* specifies 'parse' as corresponding function for PLR_parse
   in the abstract interface 'pconfig'
*/
;

void AP_setFunAccept(AbsPlr_T pconfig, PIF_accept accept)
/* specifies 'accept' as corresponding function for PLR_accept
   in the abstract interface 'pconfig'
*/
;


/* --------------- Specification of the external parser configuration ------ */

void AP_setExtCfg(AbsPlr_T pconfig, Abs_T extcfg)
/* specifies the external configuration 'extcfg'
   of the abstract interface 'pconfig'
*/
;


/* 
  <p>An external defined parser must be configurable by the following callback
     functions. These handlers will be defined and assigned by the term
     generation module and must be called by the parser during processing.
*/

void AP_setFunNextTok(AbsPlr_T pconfig, PIF_nextTok nextTok)
/* specifies 'nextTok' as "get next token" handler
   in the abstract interface 'pconfig'
*/
;

void AP_setFunCurTok(AbsPlr_T pconfig, PIF_curTok curTok)
/* specifies 'curTok' as "get current token name" handler
   in the abstract interface 'pconfig'
*/
;

void AP_setFunShift(AbsPlr_T pconfig, PIF_shift shift)
/* specifies 'shift' as "shift operation" handler
   in the abstract interface 'pconfig'
*/
;

void AP_setFunReduce(AbsPlr_T pconfig, PIF_reduce reduce)
/* specifies 'reduce' as "reduce operation" handler
   in the abstract interface 'pconfig'
*/
;

void AP_setFunError(AbsPlr_T pconfig, PIF_error error)
/* specifies 'error' as "error reporting" handler
   in the abstract interface 'pconfig'
*/
;

void AP_setFunDebug(AbsPlr_T pconfig, PIF_debug debug)
/* specifies 'debug' as "debugging" handler
   in the abstract interface 'pconfig'
*/
;


/* --------------- Accessing the external parser interface ----------------- */

Abs_T AP_getParser(AbsPlr_T pconfig)
/* get the external parser of the abstract interface 'pconfig' */
;

PF_cfgsize AP_getFunSymCnt(AbsPlr_T pconfig)
/* get the corresponding function for PLR_symbolCnt
   in the abstract interface 'pconfig'
*/
;

PF_cfgsize AP_getFunTokCnt(AbsPlr_T pconfig)
/* get the corresponding function for PLR_tokenCnt
   in the abstract interface 'pconfig'
*/
;

PF_cfgsize AP_getFunProdCnt(AbsPlr_T pconfig)
/* get the corresponding function for PLR_prodCnt
   in the abstract interface 'pconfig'
*/
;

PF_symType AP_getFunSymType(AbsPlr_T pconfig)
/* get the corresponding function for PLR_symType
   in the abstract interface 'pconfig'
*/
;

PF_symName AP_getFunSymName(AbsPlr_T pconfig)
/* get the corresponding function for PLR_symName
   in the abstract interface 'pconfig'
*/
;

PF_startSym AP_getFunStartSym(AbsPlr_T pconfig)
/* get the corresponding function for PLR_startSymbol
   in the abstract interface 'pconfig'
*/
;

PF_prodNT AP_getFunProdNT(AbsPlr_T pconfig)
/* get the corresponding function for PLR_prodNonTerm
   in the abstract interface 'pconfig'
*/
;

PF_prodName AP_getFunProdName(AbsPlr_T pconfig)
/* get the corresponding function for PLR_prodName
   in the abstract interface 'pconfig'
*/
;

PF_dynprod AP_getFunProdDynIdx(AbsPlr_T pconfig)
/* get the corresponding function for PLR_prodDSymIdx
   in the abstract interface 'pconfig'
*/
;

PF_dynprod AP_getFunProdDynSym(AbsPlr_T pconfig)
/* get the corresponding function for PLR_prodDSymSym
   in the abstract interface 'pconfig'
*/
;

PIF_topVal AP_getFunTopVal(AbsPlr_T pconfig)
/* get the corresponding function for PLR_topVal
   in the abstract interface 'pconfig'
*/
;

PIF_parse AP_getFunParse(AbsPlr_T pconfig)
/* get the corresponding function for PLR_parse
   in the abstract interface 'pconfig'
*/
;

PIF_accept AP_getFunAccept(AbsPlr_T pconfig)
/* get the corresponding function for PLR_accept
   in the abstract interface 'pconfig'
*/
;


/* --------------- Accessing the external parser configuration ------------- */

Abs_T AP_getExtCfg(AbsPlr_T pconfig)
/* get the external configuration
   of the abstract interface 'pconfig'
*/
;

PIF_nextTok AP_getFunNextTok(AbsPlr_T pconfig)
/* get the "get next token" handler
   in the abstract interface 'pconfig'
*/
;

PIF_curTok AP_getFunCurTok(AbsPlr_T pconfig)
/* get the "get current token name" handler
   in the abstract interface 'pconfig'
*/
;

PIF_shift AP_getFunShift(AbsPlr_T pconfig)
/* get the "shift operation" handler
   in the abstract interface 'pconfig'
*/
;

PIF_reduce AP_getFunReduce(AbsPlr_T pconfig)
/* get the "reduce operation" handler
   in the abstract interface 'pconfig'
*/
;

PIF_error AP_getFunError(AbsPlr_T pconfig)
/* get the "error reporting" handler
   in the abstract interface 'pconfig'
*/
;

PIF_debug AP_getFunDebug(AbsPlr_T pconfig)
/* get the "debugging" handler
   in the abstract interface 'pconfig'
*/
;



#ifdef __cplusplus
}
#endif

#endif