This file is indexed.

/usr/include/ug/oopp.h is in libug-dev 3.12.1-2.

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
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
/****************************************************************************/
/*                                                                          */
/* File:      oopp.h                                                        */
/*                                                                          */
/* Purpose:   macros for implementing some rudimentary object-oriented      */
/*            techniques via the C preprocessor.                            */
/*                                                                          */
/* Author:    Klaus Birken                                                  */
/*            Institut fuer Computeranwendungen III                         */
/*            Universitaet Stuttgart                                        */
/*            Pfaffenwaldring 27                                            */
/*            70569 Stuttgart                                               */
/*            email: birken@ica3.uni-stuttgart.de                           */
/*            phone: 0049-(0)711-685-7007                                   */
/*            fax  : 0049-(0)711-685-7000                                   */
/*                                                                          */
/* History:   970720 kb  begin                                              */
/*                                                                          */
/* Remarks:                                                                 */
/*                                                                          */
/****************************************************************************/

/* RCS_ID
   $Header$
 */


#ifndef __OOPP_H__
#define __OOPP_H__

/****************************************************************************/
/*                                                                          */
/* basic text manipulation macros                                           */
/*                                                                          */
/****************************************************************************/

#define _CCAT(a,b)   a ## b
#define CCAT(a,b)    _CCAT(a,b)

#define CALL(a,b)    CCAT(CCAT(a,_),b)



/****************************************************************************/
/*                                                                          */
/* class declaration                                                        */
/*                                                                          */
/****************************************************************************/

/* from now on, we assume a previous '#define ClassPrefix XXX' */
/* construction of class-name */
#ifdef ClassPrefix
#define CN(C)            CCAT(ClassPrefix,C)
#else
#define CN(C)            C
#endif


/* from now on, we suppose a '#define ClassName XXX' for a given class */

#define Class            CN(ClassName)           /* internal class-name */
#define __Class          CCAT(_,Class)
#define ClassPtr         struct __Class *
#define ClassRef         ClassPtr
/* #define VoidRef          void * */
#define Class_Data_Begin typedef struct __Class {
#define Class_Data_End   } Class;

#define Method(M)        CCAT(CCAT(ClassName,_),M)

/* support for easy 'This' */
#define This             _oopp_this
/*
   #define DefThis          ClassRef
   #define ParamThis        ClassRef This
 */
#define DefThis          Class *
#define ParamThis        Class * This


/****************************************************************************/
/*                                                                          */
/* standard class methods                                                   */
/*                                                                          */
/****************************************************************************/


/*** constructor (NewClass) ***/
/* macros for prototype */
#define Method_New_      ClassPtr CCAT(New_,ClassName)
#define Method_New(O)    ClassPtr CCAT(CCAT(New_,ClassName),O)   /* overload */

/* macros for implementation */
#define Construct(item,check)      \
  ClassPtr item=(ClassPtr) OO_Allocate (sizeof(Class));  \
  { check; }

#define Destruct(item)   OO_Free(item)


/****************************************************************************/
/*                                                                          */
/* inheritance                                                              */
/*                                                                          */
/****************************************************************************/

#define BaseClass(BC)         typedef CN (BC) Class


/****************************************************************************/

#endif