home *** CD-ROM | disk | FTP | other *** search
- From: joke@germany.eu.net (Joerg Heitkoetter)
- Newsgroups: comp.sources.misc
- Subject: v44i013: c++2latex - A set of LaTeX converters for the whole C family, v3.0, Part04/08
- Date: 7 Aug 1994 16:43:07 -0500
- Organization: Sterling Software
- Sender: kent@sparky.sterling.com
- Approved: kent@sparky.sterling.com
- Message-ID: <323khb$gm8@sparky.sterling.com>
- X-Md4-Signature: f921fe040a7db5e5744c029812670dbb
-
- Submitted-by: joke@germany.eu.net (Joerg Heitkoetter)
- Posting-number: Volume 44, Issue 13
- Archive-name: c++2latex/part04
- Environment: UNIX, Flex, LaTeX, Sun
-
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then feed it
- # into a shell via "sh file" or similar. To overwrite existing files,
- # type "sh file -c".
- # Contents: docs/world.c src/getopt.c src/objc2latex.c.A
- # Wrapped by kent@sparky on Sun Aug 7 16:11:53 1994
- PATH=/bin:/usr/bin:/usr/ucb:/usr/local/bin:/usr/lbin:$PATH ; export PATH
- echo If this archive is complete, you will see the following message:
- echo ' "shar: End of archive 4 (of 8)."'
- if test -f 'docs/world.c' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'docs/world.c'\"
- else
- echo shar: Extracting \"'docs/world.c'\" \(133 characters\)
- sed "s/^X//" >'docs/world.c' <<'END_OF_FILE'
- X/*
- X * The classical program
- X */
- X
- X#include <stdio.h>
- X
- Xvoid
- Xmain (argc, argv)
- Xint argc;
- Xchar **argv;
- X{
- X printf ("Hello world!\n");
- X}
- END_OF_FILE
- if test 133 -ne `wc -c <'docs/world.c'`; then
- echo shar: \"'docs/world.c'\" unpacked with wrong size!
- fi
- # end of 'docs/world.c'
- fi
- if test -f 'src/getopt.c' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'src/getopt.c'\"
- else
- echo shar: Extracting \"'src/getopt.c'\" \(19369 characters\)
- sed "s/^X//" >'src/getopt.c' <<'END_OF_FILE'
- X/* Getopt for GNU.
- X NOTE: getopt is now part of the C library, so if you don't know what
- X "Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu
- X before changing it!
- X
- X Copyright (C) 1987, 88, 89, 90, 91, 1992 Free Software Foundation, Inc.
- X
- X This program is free software; you can redistribute it and/or modify it
- X under the terms of the GNU General Public License as published by the
- X Free Software Foundation; either version 2, or (at your option) any
- X later version.
- X
- X This program is distributed in the hope that it will be useful,
- X but WITHOUT ANY WARRANTY; without even the implied warranty of
- X MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- X GNU General Public License for more details.
- X
- X You should have received a copy of the GNU General Public License
- X along with this program; if not, write to the Free Software
- X Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
- X
- X#ifdef HAVE_CONFIG_H
- X#include "config.h"
- X#endif
- X
- X/* AIX requires this to be the first thing in the file. */
- X#ifdef __GNUC__
- X#define alloca __builtin_alloca
- X#else /* not __GNUC__ */
- X#if defined (HAVE_ALLOCA_H) || (defined(sparc) && (defined(sun) || (!defined(USG) && !defined(SVR4) && !defined(__svr4__))))
- X#include <alloca.h>
- X#else
- X#ifdef _AIX
- X#pragma alloca
- X#else
- Xchar *alloca ();
- X#endif
- X#endif /* alloca.h */
- X#endif /* not __GNUC__ */
- X
- X#if !__STDC__ && !defined(const)
- X#define const
- X#endif
- X
- X#include <stdio.h>
- X
- X/* This needs to come after some library #include
- X to get __GNU_LIBRARY__ defined. */
- X#ifdef __GNU_LIBRARY__
- X#undef alloca
- X/* Don't include stdlib.h for non-GNU C libraries because some of them
- X contain conflicting prototypes for getopt. */
- X#include <stdlib.h>
- X#else /* Not GNU C library. */
- X#define __alloca alloca
- X#endif /* GNU C library. */
- X
- X/* If GETOPT_COMPAT is defined, `+' as well as `--' can introduce a
- X long-named option. Because this is not POSIX.2 compliant, it is
- X being phased out. */
- X/* #define GETOPT_COMPAT */
- X
- X/* This version of `getopt' appears to the caller like standard Unix `getopt'
- X but it behaves differently for the user, since it allows the user
- X to intersperse the options with the other arguments.
- X
- X As `getopt' works, it permutes the elements of ARGV so that,
- X when it is done, all the options precede everything else. Thus
- X all application programs are extended to handle flexible argument order.
- X
- X Setting the environment variable POSIXLY_CORRECT disables permutation.
- X Then the behavior is completely standard.
- X
- X GNU application programs can use a third alternative mode in which
- X they can distinguish the relative order of options and other arguments. */
- X
- X#include "getopt.h"
- X
- X/* For communication from `getopt' to the caller.
- X When `getopt' finds an option that takes an argument,
- X the argument value is returned here.
- X Also, when `ordering' is RETURN_IN_ORDER,
- X each non-option ARGV-element is returned here. */
- X
- Xchar *optarg = 0;
- X
- X/* Index in ARGV of the next element to be scanned.
- X This is used for communication to and from the caller
- X and for communication between successive calls to `getopt'.
- X
- X On entry to `getopt', zero means this is the first call; initialize.
- X
- X When `getopt' returns EOF, this is the index of the first of the
- X non-option elements that the caller should itself scan.
- X
- X Otherwise, `optind' communicates from one call to the next
- X how much of ARGV has been scanned so far. */
- X
- Xint optind = 0;
- X
- X/* The next char to be scanned in the option-element
- X in which the last option character we returned was found.
- X This allows us to pick up the scan where we left off.
- X
- X If this is zero, or a null string, it means resume the scan
- X by advancing to the next ARGV-element. */
- X
- Xstatic char *nextchar;
- X
- X/* Callers store zero here to inhibit the error message
- X for unrecognized options. */
- X
- Xint opterr = 1;
- X
- X/* Describe how to deal with options that follow non-option ARGV-elements.
- X
- X If the caller did not specify anything,
- X the default is REQUIRE_ORDER if the environment variable
- X POSIXLY_CORRECT is defined, PERMUTE otherwise.
- X
- X REQUIRE_ORDER means don't recognize them as options;
- X stop option processing when the first non-option is seen.
- X This is what Unix does.
- X This mode of operation is selected by either setting the environment
- X variable POSIXLY_CORRECT, or using `+' as the first character
- X of the list of option characters.
- X
- X PERMUTE is the default. We permute the contents of ARGV as we scan,
- X so that eventually all the non-options are at the end. This allows options
- X to be given in any order, even with programs that were not written to
- X expect this.
- X
- X RETURN_IN_ORDER is an option available to programs that were written
- X to expect options and other ARGV-elements in any order and that care about
- X the ordering of the two. We describe each non-option ARGV-element
- X as if it were the argument of an option with character code 1.
- X Using `-' as the first character of the list of option characters
- X selects this mode of operation.
- X
- X The special argument `--' forces an end of option-scanning regardless
- X of the value of `ordering'. In the case of RETURN_IN_ORDER, only
- X `--' can cause `getopt' to return EOF with `optind' != ARGC. */
- X
- Xstatic enum
- X{
- X REQUIRE_ORDER, PERMUTE, RETURN_IN_ORDER
- X} ordering;
- X
- X#ifdef __GNU_LIBRARY__
- X/* We want to avoid inclusion of string.h with non-GNU libraries
- X because there are many ways it can cause trouble.
- X On some systems, it contains special magic macros that don't work
- X in GCC. */
- X#include <string.h>
- X#define my_index strchr
- X#define my_bcopy(src, dst, n) memcpy ((dst), (src), (n))
- X#else
- X
- X/* Avoid depending on library functions or files
- X whose names are inconsistent. */
- X
- Xchar *getenv ();
- X
- Xstatic char *
- Xmy_index (string, chr)
- X char *string;
- X int chr;
- X{
- X while (*string)
- X {
- X if (*string == chr)
- X return string;
- X string++;
- X }
- X return 0;
- X}
- X
- Xstatic void
- Xmy_bcopy (from, to, size)
- X char *from, *to;
- X int size;
- X{
- X int i;
- X for (i = 0; i < size; i++)
- X to[i] = from[i];
- X}
- X#endif /* GNU C library. */
- X
- X/* Handle permutation of arguments. */
- X
- X/* Describe the part of ARGV that contains non-options that have
- X been skipped. `first_nonopt' is the index in ARGV of the first of them;
- X `last_nonopt' is the index after the last of them. */
- X
- Xstatic int first_nonopt;
- Xstatic int last_nonopt;
- X
- X/* Exchange two adjacent subsequences of ARGV.
- X One subsequence is elements [first_nonopt,last_nonopt)
- X which contains all the non-options that have been skipped so far.
- X The other is elements [last_nonopt,optind), which contains all
- X the options processed since those non-options were skipped.
- X
- X `first_nonopt' and `last_nonopt' are relocated so that they describe
- X the new indices of the non-options in ARGV after they are moved. */
- X
- Xstatic void
- Xexchange (argv)
- X char **argv;
- X{
- X int nonopts_size = (last_nonopt - first_nonopt) * sizeof (char *);
- X char **temp = (char **) __alloca (nonopts_size);
- X
- X /* Interchange the two blocks of data in ARGV. */
- X
- X my_bcopy ((char *) &argv[first_nonopt], (char *) temp, nonopts_size);
- X my_bcopy ((char *) &argv[last_nonopt], (char *) &argv[first_nonopt],
- X (optind - last_nonopt) * sizeof (char *));
- X my_bcopy ((char *) temp,
- X (char *) &argv[first_nonopt + optind - last_nonopt],
- X nonopts_size);
- X
- X /* Update records for the slots the non-options now occupy. */
- X
- X first_nonopt += (optind - last_nonopt);
- X last_nonopt = optind;
- X}
- X
- X/* Scan elements of ARGV (whose length is ARGC) for option characters
- X given in OPTSTRING.
- X
- X If an element of ARGV starts with '-', and is not exactly "-" or "--",
- X then it is an option element. The characters of this element
- X (aside from the initial '-') are option characters. If `getopt'
- X is called repeatedly, it returns successively each of the option characters
- X from each of the option elements.
- X
- X If `getopt' finds another option character, it returns that character,
- X updating `optind' and `nextchar' so that the next call to `getopt' can
- X resume the scan with the following option character or ARGV-element.
- X
- X If there are no more option characters, `getopt' returns `EOF'.
- X Then `optind' is the index in ARGV of the first ARGV-element
- X that is not an option. (The ARGV-elements have been permuted
- X so that those that are not options now come last.)
- X
- X OPTSTRING is a string containing the legitimate option characters.
- X If an option character is seen that is not listed in OPTSTRING,
- X return '?' after printing an error message. If you set `opterr' to
- X zero, the error message is suppressed but we still return '?'.
- X
- X If a char in OPTSTRING is followed by a colon, that means it wants an arg,
- X so the following text in the same ARGV-element, or the text of the following
- X ARGV-element, is returned in `optarg'. Two colons mean an option that
- X wants an optional arg; if there is text in the current ARGV-element,
- X it is returned in `optarg', otherwise `optarg' is set to zero.
- X
- X If OPTSTRING starts with `-' or `+', it requests different methods of
- X handling the non-option ARGV-elements.
- X See the comments about RETURN_IN_ORDER and REQUIRE_ORDER, above.
- X
- X Long-named options begin with `--' instead of `-'.
- X Their names may be abbreviated as long as the abbreviation is unique
- X or is an exact match for some defined option. If they have an
- X argument, it follows the option name in the same ARGV-element, separated
- X from the option name by a `=', or else the in next ARGV-element.
- X When `getopt' finds a long-named option, it returns 0 if that option's
- X `flag' field is nonzero, the value of the option's `val' field
- X if the `flag' field is zero.
- X
- X The elements of ARGV aren't really const, because we permute them.
- X But we pretend they're const in the prototype to be compatible
- X with other systems.
- X
- X LONGOPTS is a vector of `struct option' terminated by an
- X element containing a name which is zero.
- X
- X LONGIND returns the index in LONGOPT of the long-named option found.
- X It is only valid when a long-named option has been found by the most
- X recent call.
- X
- X If LONG_ONLY is nonzero, '-' as well as '--' can introduce
- X long-named options. */
- X
- Xint
- X_getopt_internal (argc, argv, optstring, longopts, longind, long_only)
- X int argc;
- X char *const *argv;
- X const char *optstring;
- X const struct option *longopts;
- X int *longind;
- X int long_only;
- X{
- X int option_index;
- X
- X optarg = 0;
- X
- X /* Initialize the internal data when the first call is made.
- X Start processing options with ARGV-element 1 (since ARGV-element 0
- X is the program name); the sequence of previously skipped
- X non-option ARGV-elements is empty. */
- X
- X if (optind == 0)
- X {
- X first_nonopt = last_nonopt = optind = 1;
- X
- X nextchar = NULL;
- X
- X /* Determine how to handle the ordering of options and nonoptions. */
- X
- X if (optstring[0] == '-')
- X {
- X ordering = RETURN_IN_ORDER;
- X ++optstring;
- X }
- X else if (optstring[0] == '+')
- X {
- X ordering = REQUIRE_ORDER;
- X ++optstring;
- X }
- X else if (getenv ("POSIXLY_CORRECT") != NULL)
- X ordering = REQUIRE_ORDER;
- X else
- X ordering = PERMUTE;
- X }
- X
- X if (nextchar == NULL || *nextchar == '\0')
- X {
- X if (ordering == PERMUTE)
- X {
- X /* If we have just processed some options following some non-options,
- X exchange them so that the options come first. */
- X
- X if (first_nonopt != last_nonopt && last_nonopt != optind)
- X exchange ((char **) argv);
- X else if (last_nonopt != optind)
- X first_nonopt = optind;
- X
- X /* Now skip any additional non-options
- X and extend the range of non-options previously skipped. */
- X
- X while (optind < argc
- X && (argv[optind][0] != '-' || argv[optind][1] == '\0')
- X#ifdef GETOPT_COMPAT
- X && (longopts == NULL
- X || argv[optind][0] != '+' || argv[optind][1] == '\0')
- X#endif /* GETOPT_COMPAT */
- X )
- X optind++;
- X last_nonopt = optind;
- X }
- X
- X /* Special ARGV-element `--' means premature end of options.
- X Skip it like a null option,
- X then exchange with previous non-options as if it were an option,
- X then skip everything else like a non-option. */
- X
- X if (optind != argc && !strcmp (argv[optind], "--"))
- X {
- X optind++;
- X
- X if (first_nonopt != last_nonopt && last_nonopt != optind)
- X exchange ((char **) argv);
- X else if (first_nonopt == last_nonopt)
- X first_nonopt = optind;
- X last_nonopt = argc;
- X
- X optind = argc;
- X }
- X
- X /* If we have done all the ARGV-elements, stop the scan
- X and back over any non-options that we skipped and permuted. */
- X
- X if (optind == argc)
- X {
- X /* Set the next-arg-index to point at the non-options
- X that we previously skipped, so the caller will digest them. */
- X if (first_nonopt != last_nonopt)
- X optind = first_nonopt;
- X return EOF;
- X }
- X
- X /* If we have come to a non-option and did not permute it,
- X either stop the scan or describe it to the caller and pass it by. */
- X
- X if ((argv[optind][0] != '-' || argv[optind][1] == '\0')
- X#ifdef GETOPT_COMPAT
- X && (longopts == NULL
- X || argv[optind][0] != '+' || argv[optind][1] == '\0')
- X#endif /* GETOPT_COMPAT */
- X )
- X {
- X if (ordering == REQUIRE_ORDER)
- X return EOF;
- X optarg = argv[optind++];
- X return 1;
- X }
- X
- X /* We have found another option-ARGV-element.
- X Start decoding its characters. */
- X
- X nextchar = (argv[optind] + 1
- X + (longopts != NULL && argv[optind][1] == '-'));
- X }
- X
- X if (longopts != NULL
- X && ((argv[optind][0] == '-'
- X && (argv[optind][1] == '-' || long_only))
- X#ifdef GETOPT_COMPAT
- X || argv[optind][0] == '+'
- X#endif /* GETOPT_COMPAT */
- X ))
- X {
- X const struct option *p;
- X char *s = nextchar;
- X int exact = 0;
- X int ambig = 0;
- X const struct option *pfound = NULL;
- X int indfound = 0;
- X
- X while (*s && *s != '=')
- X s++;
- X
- X /* Test all options for either exact match or abbreviated matches. */
- X for (p = longopts, option_index = 0; p->name;
- X p++, option_index++)
- X if (!strncmp (p->name, nextchar, s - nextchar))
- X {
- X if (s - nextchar == strlen (p->name))
- X {
- X /* Exact match found. */
- X pfound = p;
- X indfound = option_index;
- X exact = 1;
- X break;
- X }
- X else if (pfound == NULL)
- X {
- X /* First nonexact match found. */
- X pfound = p;
- X indfound = option_index;
- X }
- X else
- X /* Second nonexact match found. */
- X ambig = 1;
- X }
- X
- X if (ambig && !exact)
- X {
- X if (opterr)
- X fprintf (stderr, "%s: option `%s' is ambiguous\n",
- X argv[0], argv[optind]);
- X nextchar += strlen (nextchar);
- X optind++;
- X return '?';
- X }
- X
- X if (pfound != NULL)
- X {
- X option_index = indfound;
- X optind++;
- X if (*s)
- X {
- X /* Don't test has_arg with >, because some C compilers don't
- X allow it to be used on enums. */
- X if (pfound->has_arg)
- X optarg = s + 1;
- X else
- X {
- X if (opterr)
- X {
- X if (argv[optind - 1][1] == '-')
- X /* --option */
- X fprintf (stderr,
- X "%s: option `--%s' doesn't allow an argument\n",
- X argv[0], pfound->name);
- X else
- X /* +option or -option */
- X fprintf (stderr,
- X "%s: option `%c%s' doesn't allow an argument\n",
- X argv[0], argv[optind - 1][0], pfound->name);
- X }
- X nextchar += strlen (nextchar);
- X return '?';
- X }
- X }
- X else if (pfound->has_arg == 1)
- X {
- X if (optind < argc)
- X optarg = argv[optind++];
- X else
- X {
- X if (opterr)
- X fprintf (stderr, "%s: option `%s' requires an argument\n",
- X argv[0], argv[optind - 1]);
- X nextchar += strlen (nextchar);
- X return '?';
- X }
- X }
- X nextchar += strlen (nextchar);
- X if (longind != NULL)
- X *longind = option_index;
- X if (pfound->flag)
- X {
- X *(pfound->flag) = pfound->val;
- X return 0;
- X }
- X return pfound->val;
- X }
- X /* Can't find it as a long option. If this is not getopt_long_only,
- X or the option starts with '--' or is not a valid short
- X option, then it's an error.
- X Otherwise interpret it as a short option. */
- X if (!long_only || argv[optind][1] == '-'
- X#ifdef GETOPT_COMPAT
- X || argv[optind][0] == '+'
- X#endif /* GETOPT_COMPAT */
- X || my_index (optstring, *nextchar) == NULL)
- X {
- X if (opterr)
- X {
- X if (argv[optind][1] == '-')
- X /* --option */
- X fprintf (stderr, "%s: unrecognized option `--%s'\n",
- X argv[0], nextchar);
- X else
- X /* +option or -option */
- X fprintf (stderr, "%s: unrecognized option `%c%s'\n",
- X argv[0], argv[optind][0], nextchar);
- X }
- X nextchar = (char *) "";
- X optind++;
- X return '?';
- X }
- X }
- X
- X /* Look at and handle the next option-character. */
- X
- X {
- X char c = *nextchar++;
- X char *temp = my_index (optstring, c);
- X
- X /* Increment `optind' when we start to process its last character. */
- X if (*nextchar == '\0')
- X ++optind;
- X
- X if (temp == NULL || c == ':')
- X {
- X if (opterr)
- X {
- X if (c < 040 || c >= 0177)
- X fprintf (stderr, "%s: unrecognized option, character code 0%o\n",
- X argv[0], c);
- X else
- X fprintf (stderr, "%s: unrecognized option `-%c'\n", argv[0], c);
- X }
- X return '?';
- X }
- X if (temp[1] == ':')
- X {
- X if (temp[2] == ':')
- X {
- X /* This is an option that accepts an argument optionally. */
- X if (*nextchar != '\0')
- X {
- X optarg = nextchar;
- X optind++;
- X }
- X else
- X optarg = 0;
- X nextchar = NULL;
- X }
- X else
- X {
- X /* This is an option that requires an argument. */
- X if (*nextchar != '\0')
- X {
- X optarg = nextchar;
- X /* If we end this ARGV-element by taking the rest as an arg,
- X we must advance to the next element now. */
- X optind++;
- X }
- X else if (optind == argc)
- X {
- X if (opterr)
- X fprintf (stderr, "%s: option `-%c' requires an argument\n",
- X argv[0], c);
- X c = '?';
- X }
- X else
- X /* We already incremented `optind' once;
- X increment it again when taking next ARGV-elt as argument. */
- X optarg = argv[optind++];
- X nextchar = NULL;
- X }
- X }
- X return c;
- X }
- X}
- X
- Xint
- Xgetopt (argc, argv, optstring)
- X int argc;
- X char *const *argv;
- X const char *optstring;
- X{
- X return _getopt_internal (argc, argv, optstring,
- X (const struct option *) 0,
- X (int *) 0,
- X 0);
- X}
- X
- X#ifdef TEST
- X
- X/* Compile with -DTEST to make an executable for use in testing
- X the above definition of `getopt'. */
- X
- Xint
- Xmain (argc, argv)
- X int argc;
- X char **argv;
- X{
- X int c;
- X int digit_optind = 0;
- X
- X while (1)
- X {
- X int this_option_optind = optind ? optind : 1;
- X
- X c = getopt (argc, argv, "abc:d:0123456789");
- X if (c == EOF)
- X break;
- X
- X switch (c)
- X {
- X case '0':
- X case '1':
- X case '2':
- X case '3':
- X case '4':
- X case '5':
- X case '6':
- X case '7':
- X case '8':
- X case '9':
- X if (digit_optind != 0 && digit_optind != this_option_optind)
- X printf ("digits occur in two different argv-elements.\n");
- X digit_optind = this_option_optind;
- X printf ("option %c\n", c);
- X break;
- X
- X case 'a':
- X printf ("option a\n");
- X break;
- X
- X case 'b':
- X printf ("option b\n");
- X break;
- X
- X case 'c':
- X printf ("option c with value `%s'\n", optarg);
- X break;
- X
- X case '?':
- X break;
- X
- X default:
- X printf ("?? getopt returned character code 0%o ??\n", c);
- X }
- X }
- X
- X if (optind < argc)
- X {
- X printf ("non-option ARGV-elements: ");
- X while (optind < argc)
- X printf ("%s ", argv[optind++]);
- X printf ("\n");
- X }
- X
- X exit (0);
- X}
- X
- X#endif /* TEST */
- END_OF_FILE
- if test 19369 -ne `wc -c <'src/getopt.c'`; then
- echo shar: \"'src/getopt.c'\" unpacked with wrong size!
- fi
- # end of 'src/getopt.c'
- fi
- if test -f 'src/objc2latex.c.A' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'src/objc2latex.c.A'\"
- else
- echo shar: Extracting \"'src/objc2latex.c.A'\" \(34954 characters\)
- sed "s/^X//" >'src/objc2latex.c.A' <<'END_OF_FILE'
- X/* A lexical scanner generated by flex */
- X
- X/* Scanner skeleton version:
- X * $Header: /home/daffy/u0/vern/flex/flex-2.4.7/RCS/flex.skl,v 1.2 94/08/03 11:13:24 vern Exp $
- X */
- X
- X#define FLEX_SCANNER
- X
- X#include <stdio.h>
- X
- X
- X/* cfront 1.2 defines "c_plusplus" instead of "__cplusplus" */
- X#ifdef c_plusplus
- X#ifndef __cplusplus
- X#define __cplusplus
- X#endif
- X#endif
- X
- X
- X#ifdef __cplusplus
- X
- X#include <stdlib.h>
- X#include <unistd.h>
- X
- X/* Use prototypes in function declarations. */
- X#define YY_USE_PROTOS
- X
- X/* The "const" storage-class-modifier is valid. */
- X#define YY_USE_CONST
- X
- X#else /* ! __cplusplus */
- X
- X#ifdef __STDC__
- X
- X#define YY_USE_PROTOS
- X#define YY_USE_CONST
- X
- X#endif /* __STDC__ */
- X#endif /* ! __cplusplus */
- X
- X
- X#ifdef __TURBOC__
- X#define YY_USE_CONST
- X#endif
- X
- X
- X#ifndef YY_USE_CONST
- X#ifndef const
- X#define const
- X#endif
- X#endif
- X
- X
- X#ifdef YY_USE_PROTOS
- X#define YY_PROTO(proto) proto
- X#else
- X#define YY_PROTO(proto) ()
- X#endif
- X
- X/* Returned upon end-of-file. */
- X#define YY_NULL 0
- X
- X/* Promotes a possibly negative, possibly signed char to an unsigned
- X * integer for use as an array index. If the signed char is negative,
- X * we want to instead treat it as an 8-bit unsigned char, hence the
- X * double cast.
- X */
- X#define YY_SC_TO_UI(c) ((unsigned int) (unsigned char) c)
- X
- X/* Enter a start condition. This macro really ought to take a parameter,
- X * but we do it the disgusting crufty way forced on us by the ()-less
- X * definition of BEGIN.
- X */
- X#define BEGIN yy_start = 1 + 2 *
- X
- X/* Translate the current start state into a value that can be later handed
- X * to BEGIN to return to the state.
- X */
- X#define YY_START ((yy_start - 1) / 2)
- X
- X/* Action number for EOF rule of a given start state. */
- X#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
- X
- X/* Special action meaning "start processing a new file". Now included
- X * only for backward compatibility with previous versions of flex.
- X */
- X#define YY_NEW_FILE yyrestart( yyin )
- X
- X#define YY_END_OF_BUFFER_CHAR 0
- X
- X/* Size of default input buffer. */
- X#define YY_BUF_SIZE 16384
- X
- Xtypedef struct yy_buffer_state *YY_BUFFER_STATE;
- X
- Xextern int yyleng;
- Xextern FILE *yyin, *yyout;
- X
- X#ifdef __cplusplus
- Xextern "C" {
- X#endif
- X extern int yywrap YY_PROTO(( void ));
- X#ifdef __cplusplus
- X }
- X#endif
- X
- X#define EOB_ACT_CONTINUE_SCAN 0
- X#define EOB_ACT_END_OF_FILE 1
- X#define EOB_ACT_LAST_MATCH 2
- X
- X/* The funky do-while in the following #define is used to turn the definition
- X * int a single C statement (which needs a semi-colon terminator). This
- X * avoids problems with code like:
- X *
- X * if ( condition_holds )
- X * yyless( 5 );
- X * else
- X * do_something_else();
- X *
- X * Prior to using the do-while the compiler would get upset at the
- X * "else" because it interpreted the "if" statement as being all
- X * done when it reached the ';' after the yyless() call.
- X */
- X
- X/* Return all but the first 'n' matched characters back to the input stream. */
- X
- X#define yyless(n) \
- X do \
- X { \
- X /* Undo effects of setting up yytext. */ \
- X *yy_cp = yy_hold_char; \
- X yy_c_buf_p = yy_cp = yy_bp + n - YY_MORE_ADJ; \
- X YY_DO_BEFORE_ACTION; /* set up yytext again */ \
- X } \
- X while ( 0 )
- X
- X#define unput(c) yyunput( c, yytext_ptr )
- X
- X
- Xstruct yy_buffer_state
- X {
- X FILE *yy_input_file;
- X
- X char *yy_ch_buf; /* input buffer */
- X char *yy_buf_pos; /* current position in input buffer */
- X
- X /* Size of input buffer in bytes, not including room for EOB
- X * characters.
- X */
- X int yy_buf_size;
- X
- X /* Number of characters read into yy_ch_buf, not including EOB
- X * characters.
- X */
- X int yy_n_chars;
- X
- X /* Whether this is an "interactive" input source; if so, and
- X * if we're using stdio for input, then we want to use getc()
- X * instead of fread(), to make sure we stop fetching input after
- X * each newline.
- X */
- X int yy_is_interactive;
- X
- X /* Whether to try to fill the input buffer when we reach the
- X * end of it.
- X */
- X int yy_fill_buffer;
- X
- X int yy_buffer_status;
- X#define YY_BUFFER_NEW 0
- X#define YY_BUFFER_NORMAL 1
- X /* When an EOF's been seen but there's still some text to process
- X * then we mark the buffer as YY_EOF_PENDING, to indicate that we
- X * shouldn't try reading from the input source any more. We might
- X * still have a bunch of tokens to match, though, because of
- X * possible backing-up.
- X *
- X * When we actually see the EOF, we change the status to "new"
- X * (via yyrestart()), so that the user can continue scanning by
- X * just pointing yyin at a new input file.
- X */
- X#define YY_BUFFER_EOF_PENDING 2
- X };
- X
- Xstatic YY_BUFFER_STATE yy_current_buffer = 0;
- X
- X/* We provide macros for accessing buffer states in case in the
- X * future we want to put the buffer states in a more general
- X * "scanner state".
- X */
- X#define YY_CURRENT_BUFFER yy_current_buffer
- X
- X
- X/* yy_hold_char holds the character lost when yytext is formed. */
- Xstatic char yy_hold_char;
- X
- Xstatic int yy_n_chars; /* number of characters read into yy_ch_buf */
- X
- X
- Xint yyleng;
- X
- X/* Points to current character in buffer. */
- Xstatic char *yy_c_buf_p = (char *) 0;
- Xstatic int yy_init = 1; /* whether we need to initialize */
- Xstatic int yy_start = 0; /* start state number */
- X
- X/* Flag which is used to allow yywrap()'s to do buffer switches
- X * instead of setting up a fresh yyin. A bit of a hack ...
- X */
- Xstatic int yy_did_buffer_switch_on_eof;
- X
- Xstatic void yyunput YY_PROTO(( int c, char *buf_ptr ));
- Xvoid yyrestart YY_PROTO(( FILE *input_file ));
- Xvoid yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
- Xvoid yy_load_buffer_state YY_PROTO(( void ));
- XYY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
- Xvoid yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
- Xvoid yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
- X
- Xstatic int yy_start_stack_ptr = 0;
- Xstatic int yy_start_stack_depth = 0;
- Xstatic int *yy_start_stack = 0;
- Xstatic void yy_push_state YY_PROTO(( int new_state ));
- Xstatic void yy_pop_state YY_PROTO(( void ));
- Xstatic int yy_top_state YY_PROTO(( void ));
- X
- Xstatic void *yy_flex_alloc YY_PROTO(( unsigned int ));
- Xstatic void *yy_flex_realloc YY_PROTO(( void *, unsigned int ));
- Xstatic void yy_flex_free YY_PROTO(( void * ));
- X
- X#define yy_new_buffer yy_create_buffer
- X
- X#define INITIAL 0
- X#define STRING 1
- X#define INCLUDE 2
- X#define ASTCOMMENT 3
- X#define SLASHCOMMENT 4
- Xtypedef unsigned char YY_CHAR;
- Xtypedef int yy_state_type;
- XFILE *yyin = (FILE *) 0, *yyout = (FILE *) 0;
- Xextern char *yytext;
- X#define yytext_ptr yytext
- X
- X#ifndef yytext_ptr
- Xstatic void yy_flex_strncpy YY_PROTO(( char *, const char *, int ));
- X#endif
- X
- X#ifdef __cplusplus
- Xstatic int yyinput YY_PROTO(( void ));
- X#else
- Xstatic int input YY_PROTO(( void ));
- X#endif
- X
- Xstatic yy_state_type yy_get_previous_state YY_PROTO(( void ));
- Xstatic yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
- Xstatic int yy_get_next_buffer YY_PROTO(( void ));
- Xstatic void yy_fatal_error YY_PROTO(( const char msg[] ));
- X
- X/* Done after the current pattern has been matched and before the
- X * corresponding action - sets up yytext.
- X */
- X#define YY_DO_BEFORE_ACTION \
- X yytext_ptr = yy_bp; \
- X yyleng = yy_cp - yy_bp; \
- X yy_hold_char = *yy_cp; \
- X *yy_cp = '\0'; \
- X yy_c_buf_p = yy_cp;
- X
- X#define YY_END_OF_BUFFER 149
- Xstatic const short int yy_accept[417] =
- X { 0,
- X 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- X 149, 148, 145, 147, 146, 99, 125, 15, 111, 91,
- X 90, 148, 107, 108, 79, 101, 96, 100, 97, 82,
- X 138, 138, 94, 98, 83, 95, 84, 93, 148, 111,
- X 109, 148, 110, 80, 111, 111, 111, 111, 111, 111,
- X 111, 111, 111, 111, 111, 111, 111, 111, 111, 88,
- X 81, 89, 78, 144, 82, 131, 129, 128, 131, 130,
- X 20, 18, 19, 20, 20, 118, 117, 116, 118, 124,
- X 123, 122, 145, 146, 70, 0, 0, 0, 0, 0,
- X 0, 0, 111, 86, 85, 87, 0, 0, 73, 104,
- X
- X 105, 92, 106, 65, 0, 134, 114, 121, 102, 135,
- X 132, 138, 0, 138, 0, 66, 68, 103, 69, 67,
- X 0, 0, 0, 0, 0, 125, 0, 143, 76, 111,
- X 111, 111, 111, 111, 111, 111, 29, 111, 111, 111,
- X 111, 111, 111, 37, 111, 111, 111, 111, 111, 111,
- X 111, 111, 111, 111, 111, 111, 111, 77, 71, 0,
- X 0, 144, 0, 113, 120, 127, 126, 130, 18, 0,
- X 17, 0, 16, 117, 115, 123, 0, 0, 0, 0,
- X 8, 9, 0, 0, 0, 0, 0, 139, 0, 139,
- X 0, 0, 72, 0, 134, 134, 0, 135, 132, 0,
- X
- X 136, 133, 74, 75, 0, 0, 0, 0, 0, 0,
- X 21, 111, 111, 111, 111, 111, 111, 111, 111, 111,
- X 111, 111, 35, 111, 111, 39, 111, 111, 111, 111,
- X 111, 111, 111, 111, 111, 111, 111, 111, 111, 111,
- X 111, 111, 111, 112, 119, 113, 120, 0, 0, 0,
- X 0, 0, 0, 0, 0, 0, 0, 0, 0, 140,
- X 141, 0, 0, 0, 136, 134, 0, 137, 133, 0,
- X 0, 58, 0, 0, 0, 0, 22, 111, 25, 24,
- X 111, 111, 111, 111, 31, 32, 111, 111, 36, 111,
- X 40, 111, 111, 63, 111, 111, 111, 111, 111, 111,
- X
- X 111, 111, 111, 111, 53, 111, 111, 0, 4, 5,
- X 0, 0, 0, 0, 0, 0, 12, 0, 0, 0,
- X 142, 0, 56, 0, 0, 0, 0, 0, 23, 26,
- X 111, 111, 111, 111, 34, 111, 111, 111, 43, 111,
- X 111, 111, 111, 64, 111, 111, 111, 51, 111, 111,
- X 55, 0, 6, 7, 10, 0, 0, 0, 0, 14,
- X 0, 0, 0, 0, 0, 111, 111, 30, 33, 38,
- X 111, 42, 44, 45, 46, 47, 48, 111, 50, 111,
- X 111, 3, 11, 2, 0, 13, 57, 0, 0, 61,
- X 0, 111, 28, 111, 49, 111, 111, 1, 0, 0,
- X
- X 0, 27, 41, 52, 54, 0, 0, 62, 0, 60,
- X 0, 0, 0, 0, 59, 0
- X } ;
- X
- Xstatic const int yy_ec[256] =
- X { 0,
- X 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- X 1, 4, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 5, 6, 7, 8, 9, 10, 11, 12, 13,
- X 14, 15, 16, 17, 18, 19, 20, 21, 22, 22,
- X 22, 22, 22, 22, 22, 23, 23, 24, 25, 26,
- X 27, 28, 29, 30, 31, 31, 31, 31, 32, 33,
- X 9, 9, 9, 9, 9, 34, 9, 9, 9, 9,
- X 9, 9, 9, 9, 35, 9, 9, 9, 9, 9,
- X 36, 37, 38, 39, 9, 40, 41, 42, 43, 44,
- X
- X 45, 46, 47, 48, 49, 9, 50, 51, 52, 53,
- X 54, 55, 9, 56, 57, 58, 59, 60, 61, 62,
- X 63, 64, 65, 66, 67, 68, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1
- X } ;
- X
- Xstatic const int yy_meta[69] =
- X { 0,
- X 1, 1, 1, 1, 2, 2, 3, 2, 4, 2,
- X 2, 5, 2, 2, 2, 2, 2, 2, 2, 2,
- X 6, 6, 7, 2, 2, 2, 2, 2, 3, 2,
- X 7, 7, 7, 4, 4, 2, 3, 2, 2, 2,
- X 6, 6, 7, 7, 7, 6, 4, 4, 4, 4,
- X 4, 4, 8, 4, 4, 8, 4, 8, 4, 8,
- X 4, 8, 4, 4, 2, 2, 2, 2
- X } ;
- X
- Xstatic const short int yy_base[429] =
- X { 0,
- X 0, 67, 67, 73, 79, 86, 92, 96, 111, 115,
- X 636, 637, 98, 637, 632, 607, 637, 104, 0, 606,
- X 81, 595, 637, 637, 604, 63, 637, 97, 100, 111,
- X 145, 111, 637, 637, 101, 603, 108, 637, 95, 130,
- X 637, 626, 637, 601, 14, 571, 106, 120, 120, 107,
- X 572, 123, 571, 579, 136, 560, 569, 567, 572, 637,
- X 75, 173, 637, 181, 172, 637, 637, 637, 191, 186,
- X 637, 200, 637, 612, 590, 637, 204, 637, 597, 637,
- X 206, 637, 208, 637, 637, 210, 571, 163, 171, 566,
- X 558, 560, 0, 637, 637, 637, 600, 208, 637, 637,
- X
- X 637, 637, 637, 637, 592, 241, 637, 637, 637, 245,
- X 276, 281, 218, 637, 0, 583, 637, 637, 637, 582,
- X 563, 554, 169, 547, 560, 637, 567, 637, 637, 551,
- X 544, 556, 543, 558, 545, 551, 537, 538, 535, 535,
- X 538, 535, 532, 0, 180, 536, 38, 537, 533, 125,
- X 186, 531, 536, 529, 169, 194, 534, 637, 637, 230,
- X 233, 304, 237, 637, 637, 637, 637, 278, 279, 575,
- X 637, 553, 637, 280, 637, 312, 534, 244, 535, 522,
- X 637, 275, 522, 533, 522, 533, 529, 637, 560, 559,
- X 308, 0, 637, 315, 637, 320, 328, 637, 637, 334,
- X
- X 337, 288, 637, 637, 524, 228, 514, 510, 525, 515,
- X 0, 511, 523, 518, 506, 231, 520, 518, 514, 506,
- X 512, 515, 0, 501, 505, 0, 506, 503, 492, 504,
- X 493, 495, 502, 488, 486, 499, 485, 497, 487, 491,
- X 495, 497, 486, 637, 637, 637, 637, 487, 489, 489,
- X 484, 478, 486, 486, 475, 477, 482, 479, 480, 637,
- X 637, 351, 512, 346, 353, 637, 356, 359, 637, 466,
- X 468, 637, 470, 475, 468, 473, 0, 467, 0, 0,
- X 458, 466, 455, 462, 0, 0, 456, 453, 0, 457,
- X 0, 452, 452, 0, 449, 461, 451, 455, 460, 446,
- X
- X 458, 202, 447, 452, 0, 440, 452, 443, 637, 637,
- X 449, 438, 447, 447, 435, 431, 637, 437, 442, 475,
- X 637, 474, 637, 441, 439, 427, 433, 438, 0, 0,
- X 427, 428, 433, 424, 0, 431, 417, 421, 0, 429,
- X 426, 428, 412, 0, 421, 423, 421, 0, 413, 416,
- X 0, 419, 637, 637, 637, 417, 404, 417, 419, 637,
- X 414, 406, 411, 413, 389, 385, 358, 0, 0, 0,
- X 325, 0, 0, 0, 0, 0, 0, 318, 0, 317,
- X 310, 637, 637, 637, 303, 637, 637, 300, 293, 637,
- X 271, 273, 0, 256, 0, 263, 260, 637, 241, 233,
- X
- X 204, 0, 0, 0, 0, 200, 155, 637, 116, 637,
- X 93, 80, 29, 24, 637, 637, 382, 390, 398, 406,
- X 411, 418, 426, 434, 440, 443, 445, 448
- X } ;
- X
- Xstatic const short int yy_def[429] =
- X { 0,
- X 416, 1, 417, 417, 418, 418, 419, 419, 420, 420,
- X 416, 416, 416, 416, 416, 416, 416, 416, 421, 416,
- X 416, 422, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 421,
- X 416, 416, 416, 416, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 423, 424, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 421, 416, 416, 416, 416, 425, 416, 416,
- X
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 426, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 422, 416, 416, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 423,
- X 416, 424, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 427, 416, 416, 416, 416, 416, 416, 416, 416,
- X
- X 416, 426, 416, 416, 416, 416, 416, 416, 416, 416,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 428, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X
- X 421, 421, 421, 421, 421, 421, 421, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 421, 421, 421, 421, 421,
- X 421, 421, 421, 421, 421, 421, 421, 421, 421, 421,
- X 421, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 421, 421, 421, 421, 421, 421, 416, 416, 416,
- X
- X 416, 421, 421, 421, 421, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 0, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416
- X } ;
- X
- Xstatic const short int yy_nxt[706] =
- X { 0,
- X 12, 13, 14, 15, 13, 16, 17, 18, 19, 20,
- X 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
- X 31, 32, 32, 33, 34, 35, 36, 37, 38, 39,
- X 19, 19, 19, 40, 19, 41, 42, 43, 44, 12,
- X 45, 46, 47, 48, 49, 50, 51, 19, 52, 19,
- X 53, 19, 19, 19, 19, 54, 55, 56, 57, 58,
- X 59, 19, 19, 19, 60, 61, 62, 63, 64, 67,
- X 130, 64, 131, 68, 70, 67, 415, 70, 100, 68,
- X 72, 73, 414, 72, 228, 74, 65, 72, 73, 101,
- X 72, 95, 74, 77, 78, 229, 77, 77, 78, 83,
- X
- X 77, 158, 83, 69, 75, 86, 79, 96, 86, 69,
- X 79, 75, 81, 82, 102, 81, 81, 82, 105, 81,
- X 106, 106, 106, 103, 104, 107, 116, 117, 413, 110,
- X 108, 112, 112, 112, 119, 120, 126, 109, 121, 122,
- X 159, 127, 113, 123, 114, 114, 133, 87, 88, 124,
- X 412, 125, 89, 134, 90, 113, 411, 141, 91, 135,
- X 142, 114, 92, 110, 136, 111, 111, 112, 144, 114,
- X 138, 232, 139, 137, 160, 145, 113, 160, 114, 114,
- X 148, 140, 162, 149, 150, 162, 164, 168, 233, 113,
- X 168, 165, 161, 151, 152, 114, 153, 166, 109, 410,
- X
- X 163, 169, 166, 114, 169, 174, 115, 176, 174, 83,
- X 176, 86, 83, 178, 86, 179, 182, 239, 180, 190,
- X 207, 208, 183, 184, 181, 240, 234, 167, 191, 191,
- X 225, 160, 166, 200, 160, 200, 166, 226, 201, 201,
- X 201, 235, 241, 166, 242, 346, 166, 244, 166, 161,
- X 166, 246, 245, 87, 88, 347, 247, 409, 89, 408,
- X 90, 106, 106, 106, 91, 196, 196, 196, 92, 192,
- X 271, 272, 194, 195, 195, 407, 197, 198, 198, 168,
- X 169, 174, 168, 169, 174, 194, 195, 281, 282, 197,
- X 198, 195, 249, 406, 110, 198, 111, 111, 112, 110,
- X
- X 250, 112, 112, 112, 405, 162, 404, 113, 162, 199,
- X 199, 403, 113, 176, 114, 114, 176, 402, 253, 261,
- X 113, 269, 269, 163, 401, 113, 199, 254, 262, 262,
- X 264, 114, 264, 400, 199, 265, 265, 265, 269, 114,
- X 196, 196, 196, 267, 399, 267, 269, 398, 268, 268,
- X 268, 113, 266, 266, 201, 201, 201, 201, 201, 201,
- X 397, 396, 261, 395, 113, 266, 265, 265, 265, 394,
- X 266, 320, 320, 265, 265, 265, 268, 268, 268, 268,
- X 268, 268, 66, 66, 66, 66, 66, 66, 66, 66,
- X 71, 71, 71, 71, 71, 71, 71, 71, 76, 76,
- X
- X 76, 76, 76, 76, 76, 76, 80, 80, 80, 80,
- X 80, 80, 80, 80, 93, 393, 93, 93, 93, 97,
- X 97, 97, 97, 97, 97, 97, 170, 170, 170, 170,
- X 170, 170, 170, 170, 172, 172, 172, 172, 172, 172,
- X 172, 172, 189, 392, 189, 189, 391, 189, 202, 202,
- X 263, 263, 322, 322, 322, 390, 389, 388, 387, 386,
- X 385, 384, 383, 382, 381, 380, 379, 378, 377, 376,
- X 375, 374, 373, 372, 371, 370, 369, 368, 367, 366,
- X 365, 364, 363, 362, 361, 321, 261, 360, 359, 358,
- X 357, 356, 355, 354, 353, 352, 351, 350, 349, 348,
- X
- X 345, 344, 343, 342, 341, 340, 339, 338, 337, 336,
- X 335, 334, 333, 332, 331, 330, 329, 328, 327, 326,
- X 325, 324, 323, 321, 319, 318, 317, 316, 315, 314,
- X 313, 312, 311, 310, 309, 308, 307, 306, 305, 304,
- X 303, 302, 301, 300, 299, 298, 297, 296, 295, 294,
- X 293, 292, 291, 290, 289, 288, 287, 286, 285, 284,
- X 283, 280, 279, 278, 277, 276, 275, 274, 273, 270,
- X 260, 260, 259, 258, 257, 256, 255, 252, 251, 248,
- X 173, 171, 243, 238, 237, 236, 231, 230, 227, 224,
- X 223, 222, 221, 220, 219, 218, 217, 216, 215, 214,
- X
- X 213, 212, 211, 98, 210, 209, 206, 205, 204, 203,
- X 193, 188, 187, 186, 185, 177, 175, 173, 171, 157,
- X 156, 155, 154, 147, 146, 143, 132, 129, 128, 118,
- X 99, 98, 94, 85, 84, 416, 11, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X
- X 416, 416, 416, 416, 416
- X } ;
- X
- Xstatic const short int yy_chk[706] =
- X { 0,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- X 1, 1, 1, 1, 1, 1, 1, 1, 2, 3,
- X 45, 2, 45, 3, 4, 4, 414, 4, 26, 4,
- X 5, 5, 413, 5, 147, 5, 2, 6, 6, 26,
- X 6, 21, 6, 7, 7, 147, 7, 8, 8, 13,
- X
- X 8, 61, 13, 3, 5, 18, 7, 21, 18, 4,
- X 8, 6, 9, 9, 28, 9, 10, 10, 29, 10,
- X 29, 29, 29, 28, 28, 30, 35, 35, 412, 32,
- X 30, 32, 32, 32, 37, 37, 40, 30, 39, 39,
- X 61, 40, 32, 39, 32, 32, 47, 18, 18, 39,
- X 411, 39, 18, 47, 18, 32, 409, 50, 18, 47,
- X 50, 32, 18, 31, 48, 31, 31, 31, 52, 32,
- X 49, 150, 49, 48, 62, 52, 31, 62, 31, 31,
- X 55, 49, 64, 55, 55, 64, 65, 70, 150, 31,
- X 70, 65, 62, 55, 55, 31, 55, 69, 65, 407,
- X
- X 64, 72, 69, 31, 72, 77, 31, 81, 77, 83,
- X 81, 86, 83, 88, 86, 88, 89, 155, 88, 98,
- X 123, 123, 89, 89, 88, 155, 151, 69, 98, 98,
- X 145, 160, 69, 113, 160, 113, 69, 145, 113, 113,
- X 113, 151, 156, 69, 156, 302, 69, 161, 69, 160,
- X 69, 163, 161, 86, 86, 302, 163, 406, 86, 401,
- X 86, 106, 106, 106, 86, 110, 110, 110, 86, 98,
- X 206, 206, 106, 106, 106, 400, 110, 110, 110, 168,
- X 169, 174, 168, 169, 174, 106, 106, 216, 216, 110,
- X 110, 106, 178, 399, 111, 110, 111, 111, 111, 112,
- X
- X 178, 112, 112, 112, 397, 162, 396, 111, 162, 111,
- X 111, 394, 112, 176, 112, 112, 176, 392, 182, 191,
- X 111, 202, 202, 162, 391, 112, 111, 182, 191, 191,
- X 194, 112, 194, 389, 111, 194, 194, 194, 202, 112,
- X 196, 196, 196, 197, 388, 197, 202, 385, 197, 197,
- X 197, 196, 196, 196, 200, 200, 200, 201, 201, 201,
- X 381, 380, 262, 378, 196, 196, 264, 264, 264, 371,
- X 196, 262, 262, 265, 265, 265, 267, 267, 267, 268,
- X 268, 268, 417, 417, 417, 417, 417, 417, 417, 417,
- X 418, 418, 418, 418, 418, 418, 418, 418, 419, 419,
- X
- X 419, 419, 419, 419, 419, 419, 420, 420, 420, 420,
- X 420, 420, 420, 420, 421, 367, 421, 421, 421, 422,
- X 422, 422, 422, 422, 422, 422, 423, 423, 423, 423,
- X 423, 423, 423, 423, 424, 424, 424, 424, 424, 424,
- X 424, 424, 425, 366, 425, 425, 365, 425, 426, 426,
- X 427, 427, 428, 428, 428, 364, 363, 362, 361, 359,
- X 358, 357, 356, 352, 350, 349, 347, 346, 345, 343,
- X 342, 341, 340, 338, 337, 336, 334, 333, 332, 331,
- X 328, 327, 326, 325, 324, 322, 320, 319, 318, 316,
- X 315, 314, 313, 312, 311, 308, 307, 306, 304, 303,
- X
- X 301, 300, 299, 298, 297, 296, 295, 293, 292, 290,
- X 288, 287, 284, 283, 282, 281, 278, 276, 275, 274,
- X 273, 271, 270, 263, 259, 258, 257, 256, 255, 254,
- X 253, 252, 251, 250, 249, 248, 243, 242, 241, 240,
- X 239, 238, 237, 236, 235, 234, 233, 232, 231, 230,
- X 229, 228, 227, 225, 224, 222, 221, 220, 219, 218,
- X 217, 215, 214, 213, 212, 210, 209, 208, 207, 205,
- X 190, 189, 187, 186, 185, 184, 183, 180, 179, 177,
- X 172, 170, 157, 154, 153, 152, 149, 148, 146, 143,
- X 142, 141, 140, 139, 138, 137, 136, 135, 134, 133,
- X
- X 132, 131, 130, 127, 125, 124, 122, 121, 120, 116,
- X 105, 97, 92, 91, 90, 87, 79, 75, 74, 59,
- X 58, 57, 56, 54, 53, 51, 46, 44, 42, 36,
- X 25, 22, 20, 16, 15, 11, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X 416, 416, 416, 416, 416, 416, 416, 416, 416, 416,
- X
- X 416, 416, 416, 416, 416
- X } ;
- X
- Xstatic yy_state_type yy_last_accepting_state;
- Xstatic char *yy_last_accepting_cpos;
- X
- X/* The intent behind this definition is that it'll catch
- X * any uses of REJECT which flex missed.
- X */
- X#define REJECT reject_used_but_not_detected
- X#define yymore() yymore_used_but_not_detected
- X#define YY_MORE_ADJ 0
- Xchar *yytext;
- X# line 1 "src/objc2latex.l"
- X/* $Id: objc2latex.l,v 3.0 1994/01/15 17:07:09 joke Rel $ */
- X# line 6 "src/objc2latex.l"
- X#include "defs.h"
- X
- X/* Macros after this point can all be overridden by user definitions in
- X * section 1.
- X */
- X
- X#ifdef YY_MALLOC_DECL
- XYY_MALLOC_DECL
- X#else
- X#if __STDC__
- X#ifndef __cplusplus
- X#include <stdlib.h>
- X#endif
- X#else
- X/* Just try to get by without declaring the routines. This will fail
- X * miserably on non-ANSI systems for which sizeof(size_t) != sizeof(int)
- X * or sizeof(void*) != sizeof(int).
- X */
- X#endif
- X#endif
- X
- X/* Amount of stuff to slurp up with each read. */
- X#ifndef YY_READ_BUF_SIZE
- X#define YY_READ_BUF_SIZE 8192
- X#endif
- X
- X/* Copy whatever the last rule matched to the standard output. */
- X
- X#ifndef ECHO
- X/* This used to be an fputs(), but since the string might contain NUL's,
- X * we now use fwrite().
- X */
- X#define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
- X#endif
- X
- X/* Gets input and stuffs it into "buf". number of characters read, or YY_NULL,
- X * is returned in "result".
- X */
- X#ifndef YY_INPUT
- X#define YY_INPUT(buf,result,max_size) \
- X if ( yy_current_buffer->yy_is_interactive ) \
- X { \
- X int c = getc( yyin ); \
- X result = c == EOF ? 0 : 1; \
- X buf[0] = (char) c; \
- X } \
- X else if ( ((result = fread( buf, 1, max_size, yyin )) == 0) \
- X && ferror( yyin ) ) \
- X YY_FATAL_ERROR( "input in flex scanner failed" );
- X#endif
- X
- X/* No semi-colon after return; correct usage is to write "yyterminate();" -
- X * we don't want an extra ';' after the "return" because that will cause
- X * some compilers to complain about unreachable statements.
- X */
- X#ifndef yyterminate
- X#define yyterminate() return YY_NULL
- X#endif
- X
- X/* Number of entries by which start-condition stack grows. */
- X#ifndef YY_START_STACK_INCR
- X#define YY_START_STACK_INCR 25
- X#endif
- X
- X/* Report a fatal error. */
- X#ifndef YY_FATAL_ERROR
- X#define YY_FATAL_ERROR(msg) yy_fatal_error( msg )
- X#endif
- X
- X/* Default declaration of generated scanner - a define so the user can
- X * easily add parameters.
- X */
- X#ifndef YY_DECL
- X#define YY_DECL int yylex YY_PROTO(( void ))
- X#endif
- X
- X/* Code executed at the beginning of each rule, after yytext and yyleng
- X * have been set up.
- X */
- X#ifndef YY_USER_ACTION
- X#define YY_USER_ACTION
- X#endif
- X
- X/* Code executed at the end of each rule. */
- X#ifndef YY_BREAK
- X#define YY_BREAK break;
- X#endif
- X
- XYY_DECL
- X {
- X register yy_state_type yy_current_state;
- X register char *yy_cp, *yy_bp;
- X register int yy_act;
- X
- X# line 9 "src/objc2latex.l"
- X
- X INIT;
- X
- X
- X if ( yy_init )
- X {
- X#ifdef YY_USER_INIT
- X YY_USER_INIT;
- X#endif
- X
- X if ( ! yy_start )
- X yy_start = 1; /* first start state */
- X
- X if ( ! yyin )
- X yyin = stdin;
- X
- X if ( ! yyout )
- X yyout = stdout;
- X
- X if ( yy_current_buffer )
- X yy_init_buffer( yy_current_buffer, yyin );
- X else
- X yy_current_buffer =
- X yy_create_buffer( yyin, YY_BUF_SIZE );
- X
- X yy_load_buffer_state();
- X
- X yy_init = 0;
- X }
- X
- X while ( 1 ) /* loops until end-of-file is reached */
- X {
- X yy_cp = yy_c_buf_p;
- X
- X /* Support of yytext. */
- X *yy_cp = yy_hold_char;
- X
- X /* yy_bp points to the position in yy_ch_buf of the start of
- X * the current run.
- X */
- X yy_bp = yy_cp;
- X
- X yy_current_state = yy_start;
- X if ( yy_bp[-1] == '\n' )
- X ++yy_current_state;
- Xyy_match:
- X do
- X {
- X register YY_CHAR yy_c = yy_ec[YY_SC_TO_UI(*yy_cp)];
- X if ( yy_accept[yy_current_state] )
- X {
- X yy_last_accepting_state = yy_current_state;
- X yy_last_accepting_cpos = yy_cp;
- X }
- X while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
- X {
- X yy_current_state = (int) yy_def[yy_current_state];
- X if ( yy_current_state >= 417 )
- X yy_c = yy_meta[(unsigned int) yy_c];
- X }
- X yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- X ++yy_cp;
- X }
- X while ( yy_base[yy_current_state] != 637 );
- X
- Xyy_find_action:
- X yy_act = yy_accept[yy_current_state];
- X
- X YY_DO_BEFORE_ACTION;
- X
- X
- Xdo_action: /* This label is used only to access EOF actions. */
- X
- X
- X switch ( yy_act )
- X { /* beginning of action switch */
- X case 0: /* must back up */
- X /* undo the effects of YY_DO_BEFORE_ACTION */
- X *yy_cp = yy_hold_char;
- X yy_cp = yy_last_accepting_cpos;
- X yy_current_state = yy_last_accepting_state;
- X goto yy_find_action;
- X
- Xcase 1:
- X# line 13 "src/objc2latex.l"
- Xcase 2:
- XYY_USER_ACTION
- X# line 13 "src/objc2latex.l"
- X{ CPP; BEGIN (INCLUDE); } /* Objective-C #pragma-like directive */
- X YY_BREAK
- Xcase 3:
- XYY_USER_ACTION
- X# line 15 "src/objc2latex.l"
- X
- X YY_BREAK
- Xcase 4:
- X# line 17 "src/objc2latex.l"
- Xcase 5:
- X# line 18 "src/objc2latex.l"
- Xcase 6:
- X# line 19 "src/objc2latex.l"
- Xcase 7:
- X# line 20 "src/objc2latex.l"
- Xcase 8:
- X# line 21 "src/objc2latex.l"
- Xcase 9:
- X# line 22 "src/objc2latex.l"
- Xcase 10:
- X# line 23 "src/objc2latex.l"
- Xcase 11:
- X# line 24 "src/objc2latex.l"
- Xcase 12:
- X# line 25 "src/objc2latex.l"
- Xcase 13:
- X# line 26 "src/objc2latex.l"
- Xcase 14:
- XYY_USER_ACTION
- X# line 26 "src/objc2latex.l"
- XCPP;
- X YY_BREAK
- X /* cpp unary # and binary ## commands */
- Xcase 15:
- XYY_USER_ACTION
- X# line 29 "src/objc2latex.l"
- XCPP;
- X YY_BREAK
- Xcase 16:
- X*yy_cp = yy_hold_char; /* undo effects of setting up yytext */
- Xyy_c_buf_p = yy_cp -= 1;
- XYY_DO_BEFORE_ACTION; /* set up yytext again */
- XYY_USER_ACTION
- X# line 32 "src/objc2latex.l"
- X{ OUT ("$<$"); FONT (string_font);
- X SUB (yytext+1); OUT ("}$>$");
- X input(); INIT; }
- X YY_BREAK
- Xcase 17:
- X*yy_cp = yy_hold_char; /* undo effects of setting up yytext */
- Xyy_c_buf_p = yy_cp -= 1;
- XYY_DO_BEFORE_ACTION; /* set up yytext again */
- XYY_USER_ACTION
- X# line 35 "src/objc2latex.l"
- X{ OUT ("\""); FONT (string_font);
- X SUB (yytext+1); OUT ("}\"");
- X input(); INIT; }
- X YY_BREAK
- Xcase 18:
- XYY_USER_ACTION
- X# line 38 "src/objc2latex.l"
- XECHO;
- X YY_BREAK
- Xcase 19:
- XYY_USER_ACTION
- X# line 39 "src/objc2latex.l"
- XOUT ("\\mbox{}\\\\\n");
- X YY_BREAK
- Xcase 20:
- XYY_USER_ACTION
- X# line 40 "src/objc2latex.l"
- X{ REPARSE; INIT; }
- X YY_BREAK
- X /* from: gcc-2.2/c-parse.gperf */
- Xcase 21:
- X# line 45 "src/objc2latex.l"
- Xcase 22:
- X# line 46 "src/objc2latex.l"
- Xcase 23:
- X# line 47 "src/objc2latex.l"
- Xcase 24:
- X# line 48 "src/objc2latex.l"
- Xcase 25:
- X# line 49 "src/objc2latex.l"
- Xcase 26:
- X# line 50 "src/objc2latex.l"
- Xcase 27:
- X# line 51 "src/objc2latex.l"
- Xcase 28:
- X# line 52 "src/objc2latex.l"
- Xcase 29:
- X# line 53 "src/objc2latex.l"
- Xcase 30:
- X# line 54 "src/objc2latex.l"
- Xcase 31:
- X# line 55 "src/objc2latex.l"
- Xcase 32:
- X# line 56 "src/objc2latex.l"
- Xcase 33:
- X# line 57 "src/objc2latex.l"
- Xcase 34:
- X# line 58 "src/objc2latex.l"
- Xcase 35:
- X# line 59 "src/objc2latex.l"
- Xcase 36:
- X# line 60 "src/objc2latex.l"
- Xcase 37:
- X# line 61 "src/objc2latex.l"
- Xcase 38:
- X# line 62 "src/objc2latex.l"
- Xcase 39:
- X# line 63 "src/objc2latex.l"
- Xcase 40:
- X# line 64 "src/objc2latex.l"
- Xcase 41:
- X# line 65 "src/objc2latex.l"
- Xcase 42:
- X# line 66 "src/objc2latex.l"
- Xcase 43:
- X# line 67 "src/objc2latex.l"
- Xcase 44:
- X# line 68 "src/objc2latex.l"
- Xcase 45:
- X# line 69 "src/objc2latex.l"
- Xcase 46:
- X# line 70 "src/objc2latex.l"
- Xcase 47:
- X# line 71 "src/objc2latex.l"
- Xcase 48:
- X# line 72 "src/objc2latex.l"
- Xcase 49:
- X# line 73 "src/objc2latex.l"
- Xcase 50:
- X# line 74 "src/objc2latex.l"
- Xcase 51:
- X# line 75 "src/objc2latex.l"
- Xcase 52:
- X# line 76 "src/objc2latex.l"
- Xcase 53:
- X# line 77 "src/objc2latex.l"
- Xcase 54:
- X# line 78 "src/objc2latex.l"
- Xcase 55:
- X# line 79 "src/objc2latex.l"
- X /* from: gcc-2.2/objc.gperf */
- Xcase 56:
- X# line 82 "src/objc2latex.l"
- Xcase 57:
- X# line 83 "src/objc2latex.l"
- Xcase 58:
- X# line 84 "src/objc2latex.l"
- Xcase 59:
- X# line 85 "src/objc2latex.l"
- Xcase 60:
- X# line 86 "src/objc2latex.l"
- Xcase 61:
- X# line 87 "src/objc2latex.l"
- Xcase 62:
- X# line 88 "src/objc2latex.l"
- Xcase 63:
- X# line 89 "src/objc2latex.l"
- Xcase 64:
- XYY_USER_ACTION
- X# line 89 "src/objc2latex.l"
- XKEY;
- X YY_BREAK
- Xcase 65:
- XYY_USER_ACTION
- X# line 92 "src/objc2latex.l"
- XSYM ("rightarrow");
- X YY_BREAK
- Xcase 66:
- XYY_USER_ACTION
- X# line 93 "src/objc2latex.l"
- XSYM ("ll");
- X YY_BREAK
- Xcase 67:
- END_OF_FILE
- if test 34954 -ne `wc -c <'src/objc2latex.c.A'`; then
- echo shar: \"'src/objc2latex.c.A'\" unpacked with wrong size!
- elif test -f 'src/objc2latex.c.B'; then
- echo shar: Combining \"'src/objc2latex.c'\" \(58178 characters\)
- cat 'src/objc2latex.c.A' 'src/objc2latex.c.B' > 'src/objc2latex.c'
- if test 58178 -ne `wc -c <'src/objc2latex.c'`; then
- echo shar: \"'src/objc2latex.c'\" combined with wrong size!
- else
- rm src/objc2latex.c.A src/objc2latex.c.B
- fi
- fi
- # end of 'src/objc2latex.c.A'
- fi
- echo shar: End of archive 4 \(of 8\).
- cp /dev/null ark4isdone
- MISSING=""
- for I in 1 2 3 4 5 6 7 8 ; do
- if test ! -f ark${I}isdone ; then
- MISSING="${MISSING} ${I}"
- fi
- done
- if test "${MISSING}" = "" ; then
- echo You have unpacked all 8 archives.
- rm -f ark[1-9]isdone
- else
- echo You still must unpack the following archives:
- echo " " ${MISSING}
- fi
- exit 0
- exit 0 # Just in case...
-