home *** CD-ROM | disk | FTP | other *** search
Text File | 1991-12-14 | 55.1 KB | 2,061 lines |
- Newsgroups: comp.sources.misc
- From: heitkoet@gorbi.informatik.uni-dortmund.de (Joerg Heitkoetter)
- Subject: v26i114: c++2latex - a C++ to LaTeX converter, Part02/03
- Message-ID: <1991Dec15.033422.23766@sparky.imd.sterling.com>
- X-Md4-Signature: 561d1e18c59322c524374760742b915a
- Date: Sun, 15 Dec 1991 03:34:22 GMT
- Approved: kent@sparky.imd.sterling.com
-
- Submitted-by: heitkoet@gorbi.informatik.uni-dortmund.de (Joerg Heitkoetter)
- Posting-number: Volume 26, Issue 114
- Archive-name: c++2latex/part02
- Environment: C++, LaTeX
-
- #!/bin/sh
- # do not concatenate these parts, unpack them in order with /bin/sh
- # file c++2latex.c continued
- #
- if test ! -r _shar_seq_.tmp; then
- echo 'Please unpack part 1 first!'
- exit 1
- fi
- (read Scheck
- if test "$Scheck" != 2; then
- echo Please unpack part "$Scheck" next!
- exit 1
- else
- exit 0
- fi
- ) < _shar_seq_.tmp || exit 1
- if test ! -f _shar_wnt_.tmp; then
- echo 'x - still skipping c++2latex.c'
- else
- echo 'x - continuing file c++2latex.c'
- sed 's/^X//' << 'SHAR_EOF' >> 'c++2latex.c' &&
- X 310, 196, 141, 312, 196, 267, 316, 313, 319, 196,
- X 141, 196, 314, 196, 196, 196, 196, 315, 196, 196,
- X 196, 196, 196, 320, 317, 196, 196, 196, 196, 196,
- X 196, 196, 196, 318, 303, 381, 382, 322, 321, 355,
- X
- X 196, 324, 196, 241, 243, 323, 241, 243, 334, 357,
- X 330, 326, 331, 325, 342, 328, 340, 358, 327, 332,
- X 335, 242, 244, 336, 333, 329, 339, 344, 345, 343,
- X 348, 353, 337, 341, 338, 347, 368, 196, 349, 350,
- X 346, 196, 351, 196, 352, 369, 369, 371, 196, 371,
- X 196, 196, 372, 372, 372, 264, 264, 264, 374, 196,
- X 374, 196, 196, 375, 375, 375, 140, 373, 196, 373,
- X 269, 269, 269, 269, 269, 269, 376, 376, 196, 140,
- X 373, 196, 405, 406, 407, 373, 196, 196, 409, 196,
- X 196, 410, 376, 408, 413, 196, 196, 414, 411, 412,
- X
- X 376, 415, 196, 196, 196, 196, 196, 196, 196, 196,
- X 416, 196, 196, 196, 196, 196, 196, 417, 196, 196,
- X 196, 196, 421, 419, 196, 420, 196, 196, 368, 418,
- X 196, 422, 196, 196, 196, 196, 196, 460, 460, 196,
- X 196, 423, 424, 425, 196, 433, 196, 196, 432, 196,
- X 426, 427, 437, 430, 196, 196, 429, 428, 196, 434,
- X 431, 435, 436, 442, 438, 446, 447, 196, 441, 439,
- X 440, 443, 444, 445, 484, 448, 372, 372, 372, 372,
- X 372, 372, 375, 375, 375, 375, 375, 375, 483, 486,
- X 196, 196, 485, 196, 487, 196, 488, 490, 489, 196,
- X
- X 196, 491, 196, 196, 196, 196, 196, 196, 196, 196,
- X 196, 196, 196, 492, 196, 196, 196, 196, 196, 196,
- X 196, 196, 196, 196, 196, 497, 196, 196, 196, 196,
- X 196, 196, 196, 196, 499, 196, 196, 493, 196, 495,
- X 494, 500, 498, 496, 501, 502, 504, 507, 510, 511,
- X 196, 503, 509, 512, 505, 508, 196, 506, 515, 518,
- X 514, 196, 543, 513, 542, 541, 544, 516, 517, 545,
- X 548, 547, 549, 546, 196, 196, 551, 550, 196, 196,
- X 196, 552, 556, 196, 553, 196, 555, 196, 196, 196,
- X 554, 196, 196, 196, 196, 196, 196, 196, 196, 196,
- X
- X 196, 196, 196, 196, 196, 196, 196, 196, 196, 557,
- X 559, 196, 196, 561, 196, 560, 196, 196, 558, 196,
- X 196, 564, 563, 567, 565, 196, 196, 196, 581, 562,
- X 584, 196, 566, 568, 601, 582, 585, 587, 588, 579,
- X 589, 580, 583, 590, 598, 586, 591, 592, 602, 196,
- X 196, 599, 604, 196, 196, 605, 597, 596, 600, 595,
- X 606, 603, 607, 67, 67, 67, 67, 67, 67, 67,
- X 67, 67, 72, 72, 72, 72, 72, 72, 72, 72,
- X 72, 76, 76, 76, 76, 76, 76, 76, 76, 76,
- X 81, 81, 81, 81, 81, 81, 81, 81, 81, 125,
- X
- X 125, 125, 125, 125, 125, 125, 125, 148, 148, 148,
- X 148, 191, 191, 191, 191, 191, 191, 191, 191, 191,
- X 193, 193, 193, 193, 193, 193, 193, 193, 193, 196,
- X 594, 196, 196, 196, 196, 201, 593, 201, 201, 201,
- X 201, 257, 196, 257, 257, 196, 196, 257, 270, 270,
- X 370, 370, 462, 462, 462, 196, 196, 196, 196, 196,
- X 196, 196, 196, 196, 196, 196, 578, 577, 576, 575,
- X 574, 573, 572, 571, 570, 569, 196, 196, 196, 196,
- X 196, 196, 196, 196, 540, 539, 538, 537, 536, 535,
- X 534, 533, 532, 531, 530, 529, 528, 527, 461, 368,
- X
- X 526, 525, 524, 523, 522, 521, 520, 519, 196, 196,
- X 196, 196, 196, 196, 196, 196, 196, 482, 481, 480,
- X 479, 478, 477, 476, 475, 474, 473, 472, 471, 470,
- X 469, 468, 467, 466, 465, 464, 463, 461, 459, 458,
- X 457, 456, 455, 454, 453, 452, 451, 450, 449, 196,
- X 196, 196, 196, 196, 196, 404, 403, 402, 401, 400,
- X 399, 398, 397, 396, 395, 394, 393, 392, 391, 390,
- X 389, 388, 387, 386, 385, 384, 383, 380, 379, 378,
- X 377, 367, 367, 366, 365, 364, 363, 360, 359, 356,
- X 196, 196, 304, 194, 192, 303, 302, 301, 296, 295,
- X
- X 290, 287, 286, 285, 284, 283, 282, 281, 280, 279,
- X 278, 277, 276, 275, 274, 273, 126, 272, 271, 261,
- X 256, 255, 254, 253, 246, 196, 200, 194, 192, 189,
- X 177, 176, 175, 174, 169, 168, 165, 154, 153, 152,
- X 151, 145, 127, 126, 122, 114, 113, 608, 13, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608
- X } ;
- X
- static const short int yy_chk[1218] =
- 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 31, 2, 607, 3, 4, 4, 606, 4, 100, 4,
- X 5, 5, 31, 5, 6, 6, 2, 6, 15, 7,
- X 7, 15, 7, 5, 7, 8, 8, 6, 8, 22,
- X
- X 8, 27, 9, 9, 3, 9, 10, 10, 29, 10,
- X 4, 41, 27, 7, 100, 22, 41, 29, 29, 8,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 11, 11,
- X 11, 11, 11, 11, 11, 11, 11, 11, 12, 20,
- X 62, 12, 20, 30, 103, 30, 30, 30, 36, 36,
- X
- X 66, 33, 48, 33, 33, 33, 12, 38, 38, 48,
- X 49, 50, 66, 50, 33, 48, 97, 33, 33, 49,
- X 51, 53, 50, 51, 56, 56, 103, 33, 53, 62,
- X 103, 20, 20, 33, 56, 251, 20, 56, 20, 92,
- X 63, 33, 20, 63, 251, 71, 20, 32, 71, 32,
- X 32, 32, 65, 73, 70, 65, 73, 99, 63, 70,
- X 32, 97, 77, 32, 32, 77, 82, 85, 91, 82,
- X 65, 95, 93, 32, 86, 98, 85, 85, 86, 32,
- X 86, 86, 86, 87, 94, 70, 92, 32, 87, 70,
- X 32, 101, 90, 70, 90, 87, 107, 90, 96, 102,
- X
- X 70, 175, 99, 70, 93, 70, 106, 70, 104, 175,
- X 91, 93, 98, 95, 93, 95, 91, 93, 91, 98,
- X 94, 111, 105, 108, 95, 112, 111, 171, 112, 94,
- X 242, 115, 118, 111, 115, 242, 107, 101, 94, 118,
- X 96, 107, 101, 96, 171, 96, 102, 104, 104, 102,
- X 106, 202, 109, 110, 126, 109, 110, 104, 205, 605,
- X 104, 105, 108, 126, 126, 187, 169, 172, 187, 105,
- X 109, 110, 188, 115, 115, 188, 105, 169, 115, 203,
- X 115, 117, 172, 117, 115, 176, 117, 176, 115, 134,
- X 134, 134, 117, 202, 205, 204, 137, 137, 137, 180,
- X
- X 134, 134, 180, 134, 126, 207, 182, 137, 137, 182,
- X 137, 206, 190, 134, 134, 190, 211, 180, 214, 134,
- X 137, 137, 203, 209, 182, 138, 137, 138, 138, 138,
- X 139, 208, 139, 139, 139, 210, 195, 207, 138, 195,
- X 212, 138, 138, 139, 204, 213, 139, 139, 140, 215,
- X 140, 138, 216, 140, 140, 140, 139, 138, 217, 206,
- X 206, 218, 139, 208, 219, 138, 211, 209, 214, 221,
- X 139, 222, 210, 223, 224, 227, 225, 210, 231, 226,
- X 228, 230, 232, 215, 212, 229, 235, 233, 234, 236,
- X 237, 240, 238, 213, 244, 277, 277, 216, 215, 244,
- X
- X 604, 218, 239, 241, 243, 217, 241, 243, 227, 247,
- X 224, 221, 225, 219, 232, 222, 231, 247, 221, 226,
- X 228, 241, 243, 229, 226, 223, 230, 233, 234, 232,
- X 237, 240, 229, 231, 229, 236, 259, 307, 237, 238,
- X 235, 311, 239, 312, 239, 259, 259, 262, 309, 262,
- X 313, 308, 262, 262, 262, 264, 264, 264, 265, 310,
- X 265, 315, 314, 265, 265, 265, 264, 264, 316, 264,
- X 268, 268, 268, 269, 269, 269, 270, 270, 317, 264,
- X 264, 318, 307, 308, 309, 264, 319, 320, 311, 321,
- X 322, 312, 270, 310, 314, 324, 325, 315, 313, 313,
- X
- X 270, 316, 326, 330, 331, 328, 332, 333, 336, 338,
- X 317, 334, 335, 337, 339, 342, 341, 318, 340, 343,
- X 345, 344, 322, 320, 350, 321, 348, 347, 369, 319,
- X 351, 324, 349, 353, 352, 408, 603, 369, 369, 601,
- X 411, 325, 326, 328, 410, 337, 413, 406, 336, 414,
- X 330, 331, 341, 334, 412, 415, 333, 332, 416, 338,
- X 335, 339, 340, 347, 342, 351, 352, 419, 345, 343,
- X 344, 348, 349, 350, 408, 353, 371, 371, 371, 372,
- X 372, 372, 374, 374, 374, 375, 375, 375, 406, 411,
- X 420, 421, 410, 426, 412, 422, 413, 415, 414, 424,
- X
- X 427, 416, 428, 432, 430, 429, 433, 434, 435, 431,
- X 437, 436, 438, 419, 439, 440, 443, 445, 442, 447,
- X 444, 487, 488, 448, 492, 426, 489, 493, 497, 491,
- X 490, 498, 499, 503, 428, 495, 496, 420, 502, 422,
- X 421, 429, 427, 424, 430, 431, 433, 436, 439, 440,
- X 500, 432, 438, 442, 434, 437, 501, 435, 444, 448,
- X 443, 504, 489, 442, 488, 487, 490, 445, 447, 491,
- X 495, 493, 496, 492, 505, 507, 498, 497, 508, 509,
- X 510, 499, 503, 511, 500, 512, 502, 513, 515, 541,
- X 501, 516, 542, 517, 545, 546, 553, 550, 551, 584,
- X
- X 552, 556, 557, 564, 567, 568, 582, 566, 579, 504,
- X 507, 583, 586, 509, 587, 508, 599, 590, 505, 592,
- X 600, 512, 511, 516, 513, 598, 591, 602, 545, 510,
- X 551, 589, 515, 517, 584, 546, 552, 556, 557, 541,
- X 564, 542, 550, 566, 579, 553, 567, 568, 586, 588,
- X 585, 582, 590, 581, 580, 592, 578, 577, 583, 575,
- X 599, 587, 602, 609, 609, 609, 609, 609, 609, 609,
- X 609, 609, 610, 610, 610, 610, 610, 610, 610, 610,
- X 610, 611, 611, 611, 611, 611, 611, 611, 611, 611,
- X 612, 612, 612, 612, 612, 612, 612, 612, 612, 613,
- X
- X 613, 613, 613, 613, 613, 613, 613, 614, 614, 614,
- X 614, 615, 615, 615, 615, 615, 615, 615, 615, 615,
- X 616, 616, 616, 616, 616, 616, 616, 616, 616, 617,
- X 573, 617, 617, 617, 617, 618, 571, 618, 618, 618,
- X 618, 619, 565, 619, 619, 563, 562, 619, 620, 620,
- X 621, 621, 622, 622, 622, 561, 560, 559, 558, 555,
- X 554, 549, 548, 547, 544, 543, 540, 539, 538, 531,
- X 528, 527, 525, 524, 523, 519, 518, 514, 506, 494,
- X 486, 485, 484, 483, 481, 480, 478, 477, 476, 475,
- X 474, 473, 471, 470, 468, 467, 466, 465, 462, 460,
- X
- X 459, 458, 456, 455, 454, 453, 452, 449, 446, 441,
- X 425, 423, 418, 417, 409, 407, 405, 404, 403, 401,
- X 400, 399, 398, 397, 396, 395, 394, 393, 392, 391,
- X 388, 387, 384, 383, 382, 381, 378, 370, 366, 365,
- X 364, 363, 362, 361, 360, 359, 358, 357, 356, 346,
- X 329, 327, 323, 306, 305, 301, 300, 299, 298, 297,
- X 296, 295, 294, 293, 292, 291, 290, 289, 288, 287,
- X 285, 283, 282, 281, 280, 279, 278, 276, 275, 274,
- X 273, 258, 257, 255, 254, 253, 252, 249, 248, 246,
- X 220, 201, 197, 193, 191, 183, 181, 177, 174, 173,
- X
- X 170, 168, 167, 165, 164, 163, 162, 161, 160, 159,
- X 158, 157, 156, 155, 154, 153, 150, 147, 143, 133,
- X 125, 121, 120, 119, 116, 89, 88, 80, 79, 75,
- X 60, 59, 58, 57, 55, 54, 52, 47, 46, 45,
- X 43, 37, 26, 23, 21, 18, 17, 13, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X
- X 608, 608, 608, 608, 608, 608, 608, 608, 608, 608,
- X 608, 608, 608, 608, 608, 608, 608
- X } ;
- X
- static yy_state_type yy_last_accepting_state;
- static YY_CHAR *yy_last_accepting_cpos;
- X
- /* the intent behind this definition is that it'll catch
- X * any uses of REJECT which flex missed
- X */
- #define REJECT reject_used_but_not_detected
- #define yymore() yymore_used_but_not_detected
- #define YY_MORE_ADJ 0
- X
- /* these variables are all declared out here so that section 3 code can
- X * manipulate them
- X */
- /* points to current character in buffer */
- static YY_CHAR *yy_c_buf_p = (YY_CHAR *) 0;
- static int yy_init = 1; /* whether we need to initialize */
- static int yy_start = 0; /* start state number */
- 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 */
- static int yy_did_buffer_switch_on_eof;
- X
- static yy_state_type yy_get_previous_state YY_PROTO(( void ));
- static yy_state_type yy_try_NUL_trans YY_PROTO(( yy_state_type current_state ));
- static int yy_get_next_buffer YY_PROTO(( void ));
- static void yyunput YY_PROTO(( YY_CHAR c, YY_CHAR *buf_ptr ));
- void yyrestart YY_PROTO(( FILE *input_file ));
- void yy_switch_to_buffer YY_PROTO(( YY_BUFFER_STATE new_buffer ));
- void yy_load_buffer_state YY_PROTO(( void ));
- YY_BUFFER_STATE yy_create_buffer YY_PROTO(( FILE *file, int size ));
- void yy_delete_buffer YY_PROTO(( YY_BUFFER_STATE b ));
- void yy_init_buffer YY_PROTO(( YY_BUFFER_STATE b, FILE *file ));
- X
- #define yy_new_buffer yy_create_buffer
- X
- #ifdef __cplusplus
- static int yyinput YY_PROTO(( void ));
- #else
- static int input YY_PROTO(( void ));
- #endif
- X
- YY_DECL
- X {
- X register yy_state_type yy_current_state;
- X register YY_CHAR *yy_cp, *yy_bp;
- X register int yy_act;
- X
- X
- X
- X INIT;
- X
- X
- X if ( yy_init )
- X {
- X YY_USER_INIT;
- 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 = 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 the
- X * 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;
- yy_match:
- X do
- X {
- X register YY_CHAR yy_c = yy_ec[*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 = yy_def[yy_current_state];
- X if ( yy_current_state >= 609 )
- X yy_c = yy_meta[yy_c];
- X }
- X yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- X ++yy_cp;
- X }
- X while ( yy_current_state != 608 );
- X yy_cp = yy_last_accepting_cpos;
- X yy_current_state = yy_last_accepting_state;
- X
- yy_find_action:
- X yy_act = yy_accept[yy_current_state];
- X
- X YY_DO_BEFORE_ACTION;
- X YY_USER_ACTION;
- X
- do_action: /* this label is used only to access EOF actions */
- X
- X
- X switch ( yy_act )
- X {
- X case 0: /* must backtrack */
- 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
- case 1:
- # line 109 "c++2latex.l"
- { CPP; BEGIN (INCLUDE); }
- X YY_BREAK
- case 2:
- # line 111 "c++2latex.l"
- case 3:
- # line 112 "c++2latex.l"
- case 4:
- # line 113 "c++2latex.l"
- case 5:
- # line 114 "c++2latex.l"
- case 6:
- # line 115 "c++2latex.l"
- case 7:
- # line 116 "c++2latex.l"
- case 8:
- # line 117 "c++2latex.l"
- case 9:
- # line 118 "c++2latex.l"
- case 10:
- # line 119 "c++2latex.l"
- case 11:
- # line 120 "c++2latex.l"
- case 12:
- # line 121 "c++2latex.l"
- case 13:
- # line 121 "c++2latex.l"
- CPP;
- X YY_BREAK
- case 14:
- *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
- yy_c_buf_p = yy_cp -= 1;
- YY_DO_BEFORE_ACTION; /* set up yytext again */
- # line 124 "c++2latex.l"
- { OUT ("$<$"); FONT (string_font);
- X SUB (yytext+1); OUT ("}$>$");
- X input(); INIT; }
- X YY_BREAK
- case 15:
- *yy_cp = yy_hold_char; /* undo effects of setting up yytext */
- yy_c_buf_p = yy_cp -= 1;
- YY_DO_BEFORE_ACTION; /* set up yytext again */
- # line 127 "c++2latex.l"
- { OUT ("\""); FONT (string_font);
- X SUB (yytext+1); OUT ("}\"");
- X input(); INIT; }
- X YY_BREAK
- case 16:
- # line 130 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 17:
- # line 131 "c++2latex.l"
- OUT ("\\mbox{}\\\\\n");
- X YY_BREAK
- case 18:
- # line 132 "c++2latex.l"
- { REPARSE; INIT; }
- X YY_BREAK
- case 19:
- # line 135 "c++2latex.l"
- case 20:
- # line 136 "c++2latex.l"
- case 21:
- # line 137 "c++2latex.l"
- case 22:
- # line 138 "c++2latex.l"
- case 23:
- # line 139 "c++2latex.l"
- case 24:
- # line 140 "c++2latex.l"
- case 25:
- # line 141 "c++2latex.l"
- case 26:
- # line 142 "c++2latex.l"
- case 27:
- # line 143 "c++2latex.l"
- case 28:
- # line 144 "c++2latex.l"
- case 29:
- # line 145 "c++2latex.l"
- case 30:
- # line 146 "c++2latex.l"
- case 31:
- # line 147 "c++2latex.l"
- case 32:
- # line 148 "c++2latex.l"
- case 33:
- # line 149 "c++2latex.l"
- case 34:
- # line 150 "c++2latex.l"
- case 35:
- # line 151 "c++2latex.l"
- case 36:
- # line 152 "c++2latex.l"
- case 37:
- # line 153 "c++2latex.l"
- case 38:
- # line 154 "c++2latex.l"
- case 39:
- # line 155 "c++2latex.l"
- case 40:
- # line 156 "c++2latex.l"
- case 41:
- # line 157 "c++2latex.l"
- case 42:
- # line 158 "c++2latex.l"
- case 43:
- # line 159 "c++2latex.l"
- case 44:
- # line 160 "c++2latex.l"
- case 45:
- # line 161 "c++2latex.l"
- case 46:
- # line 162 "c++2latex.l"
- case 47:
- # line 163 "c++2latex.l"
- case 48:
- # line 164 "c++2latex.l"
- case 49:
- # line 165 "c++2latex.l"
- case 50:
- # line 166 "c++2latex.l"
- case 51:
- # line 167 "c++2latex.l"
- case 52:
- # line 168 "c++2latex.l"
- case 53:
- # line 169 "c++2latex.l"
- case 54:
- # line 170 "c++2latex.l"
- case 55:
- # line 171 "c++2latex.l"
- case 56:
- # line 172 "c++2latex.l"
- case 57:
- # line 173 "c++2latex.l"
- case 58:
- # line 174 "c++2latex.l"
- case 59:
- # line 175 "c++2latex.l"
- case 60:
- # line 176 "c++2latex.l"
- case 61:
- # line 177 "c++2latex.l"
- case 62:
- # line 178 "c++2latex.l"
- case 63:
- # line 179 "c++2latex.l"
- case 64:
- # line 180 "c++2latex.l"
- case 65:
- # line 181 "c++2latex.l"
- case 66:
- # line 182 "c++2latex.l"
- case 67:
- # line 183 "c++2latex.l"
- case 68:
- # line 184 "c++2latex.l"
- case 69:
- # line 185 "c++2latex.l"
- case 70:
- # line 186 "c++2latex.l"
- case 71:
- # line 187 "c++2latex.l"
- case 72:
- # line 188 "c++2latex.l"
- case 73:
- # line 188 "c++2latex.l"
- KEY;
- X YY_BREAK
- case 74:
- # line 189 "c++2latex.l"
- SYM ("rightarrow");
- X YY_BREAK
- case 75:
- # line 190 "c++2latex.l"
- SYM ("ll");
- X YY_BREAK
- case 76:
- # line 191 "c++2latex.l"
- SYM ("gg");
- X YY_BREAK
- case 77:
- # line 192 "c++2latex.l"
- SYM ("leq");
- X YY_BREAK
- case 78:
- # line 193 "c++2latex.l"
- SYM ("geq");
- X YY_BREAK
- case 79:
- # line 194 "c++2latex.l"
- SYM ("neq");
- X YY_BREAK
- case 80:
- # line 195 "c++2latex.l"
- SYM ("mid\\mid");
- X YY_BREAK
- case 81:
- # line 196 "c++2latex.l"
- SYM ("ldots");
- X YY_BREAK
- case 82:
- # line 197 "c++2latex.l"
- SYM ("ast=");
- X YY_BREAK
- case 83:
- # line 198 "c++2latex.l"
- SYM ("ll=");
- X YY_BREAK
- case 84:
- # line 199 "c++2latex.l"
- SYM ("gg=");
- X YY_BREAK
- case 85:
- # line 200 "c++2latex.l"
- SYM ("vee=");
- X YY_BREAK
- case 86:
- # line 201 "c++2latex.l"
- SYM ("mid=");
- X YY_BREAK
- case 87:
- # line 202 "c++2latex.l"
- SYM ("sim");
- X YY_BREAK
- case 88:
- # line 203 "c++2latex.l"
- SYM ("ast");
- X YY_BREAK
- case 89:
- # line 204 "c++2latex.l"
- SYM ("wedge");
- X YY_BREAK
- case 90:
- # line 205 "c++2latex.l"
- SYM ("mid");
- X YY_BREAK
- case 91:
- # line 206 "c++2latex.l"
- SYM ("rightarrow\\ast");
- X YY_BREAK
- case 92:
- # line 207 "c++2latex.l"
- OUT ("$/$");
- X YY_BREAK
- case 93:
- # line 208 "c++2latex.l"
- OUT ("$<$");
- X YY_BREAK
- case 94:
- # line 209 "c++2latex.l"
- OUT ("$>$");
- X YY_BREAK
- case 95:
- # line 210 "c++2latex.l"
- OUT ("\\&\\&");
- X YY_BREAK
- case 96:
- # line 211 "c++2latex.l"
- OUT ("\\%=");
- X YY_BREAK
- case 97:
- # line 212 "c++2latex.l"
- OUT ("\\&=");
- X YY_BREAK
- case 98:
- # line 213 "c++2latex.l"
- OUT ("\\{");
- X YY_BREAK
- case 99:
- # line 214 "c++2latex.l"
- OUT ("\\}");
- X YY_BREAK
- case 100:
- # line 215 "c++2latex.l"
- OUT ("\\&");
- X YY_BREAK
- case 101:
- # line 216 "c++2latex.l"
- OUT ("\\%");
- X YY_BREAK
- case 102:
- # line 217 "c++2latex.l"
- OUT ("-{}-");
- X YY_BREAK
- case 103:
- # line 218 "c++2latex.l"
- OUT (".$\\ast$");
- X YY_BREAK
- case 104:
- # line 220 "c++2latex.l"
- case 105:
- # line 221 "c++2latex.l"
- case 106:
- # line 222 "c++2latex.l"
- case 107:
- # line 223 "c++2latex.l"
- case 108:
- # line 224 "c++2latex.l"
- case 109:
- # line 225 "c++2latex.l"
- case 110:
- # line 226 "c++2latex.l"
- case 111:
- # line 227 "c++2latex.l"
- case 112:
- # line 228 "c++2latex.l"
- case 113:
- # line 229 "c++2latex.l"
- case 114:
- # line 230 "c++2latex.l"
- case 115:
- # line 231 "c++2latex.l"
- case 116:
- # line 232 "c++2latex.l"
- case 117:
- # line 233 "c++2latex.l"
- case 118:
- # line 234 "c++2latex.l"
- case 119:
- # line 235 "c++2latex.l"
- case 120:
- # line 236 "c++2latex.l"
- case 121:
- # line 237 "c++2latex.l"
- case 122:
- # line 237 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 123:
- # line 240 "c++2latex.l"
- case 124:
- # line 240 "c++2latex.l"
- SUB (yytext);
- X YY_BREAK
- X /* 1. Asterisk comments mini scanner */
- X /* 1.1. Curly brace comment */
- case 125:
- # line 244 "c++2latex.l"
- { BEGIN (BCOMMENT);
- X OUT ("\\}");
- X BTAB;
- X FONT (comment_font);
- X OUT ("/$\\ast$"); }
- X YY_BREAK
- X /* 1.2. Comments at the beginning of a line */
- case 126:
- # line 251 "c++2latex.l"
- { BEGIN (BCOMMENT);
- X FONT (comment_font);
- X REPARSE; }
- X YY_BREAK
- X /* 1.3. Other comments, aligned to right side of paper */
- case 127:
- # line 256 "c++2latex.l"
- { BEGIN (BCOMMENT);
- X if (aligntoright) {
- X OUT ("\\hfill");
- X } else {
- X CTAB;
- X }
- X FONT (comment_font);
- X OUT ("/$\\ast$"); }
- X YY_BREAK
- case 128:
- # line 265 "c++2latex.l"
- { INIT; OUT ("$\\ast$/}"); }
- X YY_BREAK
- case 129:
- # line 266 "c++2latex.l"
- OUT ("\\mbox{}\\\\\n");
- X YY_BREAK
- case 130:
- # line 267 "c++2latex.l"
- IND;
- X YY_BREAK
- case 131:
- # line 268 "c++2latex.l"
- SUB (yytext);
- X YY_BREAK
- X /* 2. Double slash ``//'' comments mini scanner */
- X /* 2.1. Curly brace comment */
- case 132:
- # line 272 "c++2latex.l"
- { BEGIN (SLASHCOMMENT);
- X OUT ("\\}");
- X BTAB;
- X FONT (comment_font);
- X OUT ("//");}
- X YY_BREAK
- X /* 2.2. Complete line comment */
- case 133:
- # line 279 "c++2latex.l"
- { BEGIN (SLASHCOMMENT);
- X FONT (comment_font);
- X REPARSE; }
- X YY_BREAK
- X /* 2.3. Other comments */
- case 134:
- # line 284 "c++2latex.l"
- { BEGIN (SLASHCOMMENT);
- X if (aligntoright) {
- X OUT ("\\hfill");
- X } else {
- X CTAB;
- X }
- X FONT (comment_font);
- X OUT ("//"); }
- X YY_BREAK
- case 135:
- # line 293 "c++2latex.l"
- { INIT; OUT ("}\\mbox{}\\\\\n"); }
- X YY_BREAK
- case 136:
- # line 294 "c++2latex.l"
- IND;
- X YY_BREAK
- case 137:
- # line 295 "c++2latex.l"
- SUB (yytext);
- X YY_BREAK
- case 138:
- # line 298 "c++2latex.l"
- { BEGIN (STRING);
- X FONT (string_font); OUT ("\""); }
- X YY_BREAK
- case 139:
- # line 300 "c++2latex.l"
- OUT ("$\\backslash\\backslash$");
- X YY_BREAK
- case 140:
- # line 301 "c++2latex.l"
- { OUT ("$\\backslash$"); SUB (yytext+1); }
- X YY_BREAK
- case 141:
- # line 302 "c++2latex.l"
- { INIT; OUT ("\"}"); }
- X YY_BREAK
- case 142:
- # line 303 "c++2latex.l"
- OUT ("\\mbox{}\\\\\n");
- X YY_BREAK
- case 143:
- # line 304 "c++2latex.l"
- IND;
- X YY_BREAK
- case 144:
- # line 305 "c++2latex.l"
- SUB (yytext);
- X YY_BREAK
- case 145:
- # line 308 "c++2latex.l"
- case 146:
- # line 309 "c++2latex.l"
- case 147:
- # line 310 "c++2latex.l"
- case 148:
- # line 310 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 149:
- # line 312 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 150:
- # line 315 "c++2latex.l"
- case 151:
- # line 316 "c++2latex.l"
- case 152:
- # line 317 "c++2latex.l"
- case 153:
- # line 317 "c++2latex.l"
- SUB (yytext);
- X YY_BREAK
- case 154:
- # line 319 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 155:
- # line 321 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 156:
- # line 323 "c++2latex.l"
- OUT ("$\\backslash$\\\\\n");
- X YY_BREAK
- case 157:
- # line 324 "c++2latex.l"
- IND;
- X YY_BREAK
- case 158:
- # line 325 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case 159:
- # line 326 "c++2latex.l"
- OUT ("\\newpage\n");
- X YY_BREAK
- case 160:
- # line 327 "c++2latex.l"
- OUT ("\\mbox{}\\\\\n");
- X YY_BREAK
- case 161:
- # line 329 "c++2latex.l"
- ECHO;
- X YY_BREAK
- case YY_STATE_EOF(INITIAL):
- case YY_STATE_EOF(STRING):
- case YY_STATE_EOF(BCOMMENT):
- case YY_STATE_EOF(INCLUDE):
- case YY_STATE_EOF(SLASHCOMMENT):
- case YY_STATE_EOF(CPLUSPLUS):
- X yyterminate();
- X
- X case YY_END_OF_BUFFER:
- X {
- X /* amount of text matched not including the EOB char */
- X int yy_amount_of_matched_text = yy_cp - yytext - 1;
- X
- X /* undo the effects of YY_DO_BEFORE_ACTION */
- X *yy_cp = yy_hold_char;
- X
- X /* note that here we test for yy_c_buf_p "<=" to the position
- X * of the first EOB in the buffer, since yy_c_buf_p will
- X * already have been incremented past the NUL character
- X * (since all states make transitions on EOB to the end-
- X * of-buffer state). Contrast this with the test in yyinput().
- X */
- X if ( yy_c_buf_p <= &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- X /* this was really a NUL */
- X {
- X yy_state_type yy_next_state;
- X
- X yy_c_buf_p = yytext + yy_amount_of_matched_text;
- X
- X yy_current_state = yy_get_previous_state();
- X
- X /* okay, we're now positioned to make the
- X * NUL transition. We couldn't have
- X * yy_get_previous_state() go ahead and do it
- X * for us because it doesn't know how to deal
- X * with the possibility of jamming (and we
- X * don't want to build jamming into it because
- X * then it will run more slowly)
- X */
- X
- X yy_next_state = yy_try_NUL_trans( yy_current_state );
- X
- X yy_bp = yytext + YY_MORE_ADJ;
- X
- X if ( yy_next_state )
- X {
- X /* consume the NUL */
- X yy_cp = ++yy_c_buf_p;
- X yy_current_state = yy_next_state;
- X goto yy_match;
- X }
- X
- X else
- X {
- X yy_cp = yy_last_accepting_cpos;
- X yy_current_state = yy_last_accepting_state;
- X goto yy_find_action;
- X }
- X }
- X
- X else switch ( yy_get_next_buffer() )
- X {
- X case EOB_ACT_END_OF_FILE:
- X {
- X yy_did_buffer_switch_on_eof = 0;
- X
- X if ( yywrap() )
- X {
- X /* note: because we've taken care in
- X * yy_get_next_buffer() to have set up yytext,
- X * we can now set up yy_c_buf_p so that if some
- X * total hoser (like flex itself) wants
- X * to call the scanner after we return the
- X * YY_NULL, it'll still work - another YY_NULL
- X * will get returned.
- X */
- X yy_c_buf_p = yytext + YY_MORE_ADJ;
- X
- X yy_act = YY_STATE_EOF((yy_start - 1) / 2);
- X goto do_action;
- X }
- X
- X else
- X {
- X if ( ! yy_did_buffer_switch_on_eof )
- X YY_NEW_FILE;
- X }
- X }
- X break;
- X
- X case EOB_ACT_CONTINUE_SCAN:
- X yy_c_buf_p = yytext + yy_amount_of_matched_text;
- X
- X yy_current_state = yy_get_previous_state();
- X
- X yy_cp = yy_c_buf_p;
- X yy_bp = yytext + YY_MORE_ADJ;
- X goto yy_match;
- X
- X case EOB_ACT_LAST_MATCH:
- X yy_c_buf_p =
- X &yy_current_buffer->yy_ch_buf[yy_n_chars];
- X
- X yy_current_state = yy_get_previous_state();
- X
- X yy_cp = yy_c_buf_p;
- X yy_bp = yytext + YY_MORE_ADJ;
- X goto yy_find_action;
- X }
- X break;
- X }
- X
- X default:
- #ifdef FLEX_DEBUG
- X printf( "action # %d\n", yy_act );
- #endif
- X YY_FATAL_ERROR(
- X "fatal flex scanner internal error--no action found" );
- X }
- X }
- X }
- X
- X
- /* yy_get_next_buffer - try to read in a new buffer
- X *
- X * synopsis
- X * int yy_get_next_buffer();
- X *
- X * returns a code representing an action
- X * EOB_ACT_LAST_MATCH -
- X * EOB_ACT_CONTINUE_SCAN - continue scanning from current position
- X * EOB_ACT_END_OF_FILE - end of file
- X */
- X
- static int yy_get_next_buffer()
- X
- X {
- X register YY_CHAR *dest = yy_current_buffer->yy_ch_buf;
- X register YY_CHAR *source = yytext - 1; /* copy prev. char, too */
- X register int number_to_move, i;
- X int ret_val;
- X
- X if ( yy_c_buf_p > &yy_current_buffer->yy_ch_buf[yy_n_chars + 1] )
- X YY_FATAL_ERROR(
- X "fatal flex scanner internal error--end of buffer missed" );
- X
- X /* try to read more data */
- X
- X /* first move last chars to start of buffer */
- X number_to_move = yy_c_buf_p - yytext;
- X
- X for ( i = 0; i < number_to_move; ++i )
- X *(dest++) = *(source++);
- X
- X if ( yy_current_buffer->yy_eof_status != EOF_NOT_SEEN )
- X /* don't do the read, it's not guaranteed to return an EOF,
- X * just force an EOF
- X */
- X yy_n_chars = 0;
- X
- X else
- X {
- X int num_to_read = yy_current_buffer->yy_buf_size - number_to_move - 1;
- X
- X if ( num_to_read > YY_READ_BUF_SIZE )
- X num_to_read = YY_READ_BUF_SIZE;
- X
- X else if ( num_to_read <= 0 )
- X YY_FATAL_ERROR( "fatal error - scanner input buffer overflow" );
- X
- X /* read in more data */
- X YY_INPUT( (&yy_current_buffer->yy_ch_buf[number_to_move]),
- X yy_n_chars, num_to_read );
- X }
- X
- X if ( yy_n_chars == 0 )
- X {
- X if ( number_to_move == 1 )
- X {
- X ret_val = EOB_ACT_END_OF_FILE;
- X yy_current_buffer->yy_eof_status = EOF_DONE;
- X }
- X
- X else
- X {
- X ret_val = EOB_ACT_LAST_MATCH;
- X yy_current_buffer->yy_eof_status = EOF_PENDING;
- X }
- X }
- X
- X else
- X ret_val = EOB_ACT_CONTINUE_SCAN;
- X
- X yy_n_chars += number_to_move;
- X yy_current_buffer->yy_ch_buf[yy_n_chars] = YY_END_OF_BUFFER_CHAR;
- X yy_current_buffer->yy_ch_buf[yy_n_chars + 1] = YY_END_OF_BUFFER_CHAR;
- X
- X /* yytext begins at the second character in yy_ch_buf; the first
- X * character is the one which preceded it before reading in the latest
- X * buffer; it needs to be kept around in case it's a newline, so
- X * yy_get_previous_state() will have with '^' rules active
- X */
- X
- X yytext = &yy_current_buffer->yy_ch_buf[1];
- X
- X return ( ret_val );
- X }
- X
- X
- /* yy_get_previous_state - get the state just before the EOB char was reached
- X *
- X * synopsis
- X * yy_state_type yy_get_previous_state();
- X */
- X
- static yy_state_type yy_get_previous_state()
- X
- X {
- X register yy_state_type yy_current_state;
- X register YY_CHAR *yy_cp;
- X
- X register YY_CHAR *yy_bp = yytext;
- X
- X yy_current_state = yy_start;
- X if ( yy_bp[-1] == '\n' )
- X ++yy_current_state;
- X
- X for ( yy_cp = yytext + YY_MORE_ADJ; yy_cp < yy_c_buf_p; ++yy_cp )
- X {
- X register YY_CHAR yy_c = (*yy_cp ? yy_ec[*yy_cp] : 1);
- 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 = yy_def[yy_current_state];
- X if ( yy_current_state >= 609 )
- X yy_c = yy_meta[yy_c];
- X }
- X yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- X }
- X
- X return ( yy_current_state );
- X }
- X
- X
- /* yy_try_NUL_trans - try to make a transition on the NUL character
- X *
- X * synopsis
- X * next_state = yy_try_NUL_trans( current_state );
- X */
- X
- #ifdef YY_USE_PROTOS
- static yy_state_type yy_try_NUL_trans( register yy_state_type yy_current_state )
- #else
- static yy_state_type yy_try_NUL_trans( yy_current_state )
- register yy_state_type yy_current_state;
- #endif
- X
- X {
- X register int yy_is_jam;
- X register YY_CHAR *yy_cp = yy_c_buf_p;
- X
- X register YY_CHAR yy_c = 1;
- 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 = yy_def[yy_current_state];
- X if ( yy_current_state >= 609 )
- X yy_c = yy_meta[yy_c];
- X }
- X yy_current_state = yy_nxt[yy_base[yy_current_state] + yy_c];
- X yy_is_jam = (yy_current_state == 608);
- X
- X return ( yy_is_jam ? 0 : yy_current_state );
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- static void yyunput( YY_CHAR c, register YY_CHAR *yy_bp )
- #else
- static void yyunput( c, yy_bp )
- YY_CHAR c;
- register YY_CHAR *yy_bp;
- #endif
- X
- X {
- X register YY_CHAR *yy_cp = yy_c_buf_p;
- X
- X /* undo effects of setting up yytext */
- X *yy_cp = yy_hold_char;
- X
- X if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- X { /* need to shift things up to make room */
- X register int number_to_move = yy_n_chars + 2; /* +2 for EOB chars */
- X register YY_CHAR *dest =
- X &yy_current_buffer->yy_ch_buf[yy_current_buffer->yy_buf_size + 2];
- X register YY_CHAR *source =
- X &yy_current_buffer->yy_ch_buf[number_to_move];
- X
- X while ( source > yy_current_buffer->yy_ch_buf )
- X *--dest = *--source;
- X
- X yy_cp += dest - source;
- X yy_bp += dest - source;
- X yy_n_chars = yy_current_buffer->yy_buf_size;
- X
- X if ( yy_cp < yy_current_buffer->yy_ch_buf + 2 )
- X YY_FATAL_ERROR( "flex scanner push-back overflow" );
- X }
- X
- X if ( yy_cp > yy_bp && yy_cp[-1] == '\n' )
- X yy_cp[-2] = '\n';
- X
- X *--yy_cp = c;
- X
- X /* note: the formal parameter *must* be called "yy_bp" for this
- X * macro to now work correctly
- X */
- X YY_DO_BEFORE_ACTION; /* set up yytext again */
- X }
- X
- X
- #ifdef __cplusplus
- static int yyinput()
- #else
- static int input()
- #endif
- X
- X {
- X int c;
- X YY_CHAR *yy_cp = yy_c_buf_p;
- X
- X *yy_cp = yy_hold_char;
- X
- X if ( *yy_c_buf_p == YY_END_OF_BUFFER_CHAR )
- X {
- X /* yy_c_buf_p now points to the character we want to return.
- X * If this occurs *before* the EOB characters, then it's a
- X * valid NUL; if not, then we've hit the end of the buffer.
- X */
- X if ( yy_c_buf_p < &yy_current_buffer->yy_ch_buf[yy_n_chars] )
- X /* this was really a NUL */
- X *yy_c_buf_p = '\0';
- X
- X else
- X { /* need more input */
- X yytext = yy_c_buf_p;
- X ++yy_c_buf_p;
- X
- X switch ( yy_get_next_buffer() )
- X {
- X case EOB_ACT_END_OF_FILE:
- X {
- X if ( yywrap() )
- X {
- X yy_c_buf_p = yytext + YY_MORE_ADJ;
- X return ( EOF );
- X }
- X
- X YY_NEW_FILE;
- X
- #ifdef __cplusplus
- X return ( yyinput() );
- #else
- X return ( input() );
- #endif
- X }
- X break;
- X
- X case EOB_ACT_CONTINUE_SCAN:
- X yy_c_buf_p = yytext + YY_MORE_ADJ;
- X break;
- X
- X case EOB_ACT_LAST_MATCH:
- #ifdef __cplusplus
- X YY_FATAL_ERROR( "unexpected last match in yyinput()" );
- #else
- X YY_FATAL_ERROR( "unexpected last match in input()" );
- #endif
- X }
- X }
- X }
- X
- X c = *yy_c_buf_p;
- X yy_hold_char = *++yy_c_buf_p;
- X
- X return ( c );
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- void yyrestart( FILE *input_file )
- #else
- void yyrestart( input_file )
- FILE *input_file;
- #endif
- X
- X {
- X yy_init_buffer( yy_current_buffer, input_file );
- X yy_load_buffer_state();
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- void yy_switch_to_buffer( YY_BUFFER_STATE new_buffer )
- #else
- void yy_switch_to_buffer( new_buffer )
- YY_BUFFER_STATE new_buffer;
- #endif
- X
- X {
- X if ( yy_current_buffer == new_buffer )
- X return;
- X
- X if ( yy_current_buffer )
- X {
- X /* flush out information for old buffer */
- X *yy_c_buf_p = yy_hold_char;
- X yy_current_buffer->yy_buf_pos = yy_c_buf_p;
- X yy_current_buffer->yy_n_chars = yy_n_chars;
- X }
- X
- X yy_current_buffer = new_buffer;
- X yy_load_buffer_state();
- X
- X /* we don't actually know whether we did this switch during
- X * EOF (yywrap()) processing, but the only time this flag
- X * is looked at is after yywrap() is called, so it's safe
- X * to go ahead and always set it.
- X */
- X yy_did_buffer_switch_on_eof = 1;
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- void yy_load_buffer_state( void )
- #else
- void yy_load_buffer_state()
- #endif
- X
- X {
- X yy_n_chars = yy_current_buffer->yy_n_chars;
- X yytext = yy_c_buf_p = yy_current_buffer->yy_buf_pos;
- X yyin = yy_current_buffer->yy_input_file;
- X yy_hold_char = *yy_c_buf_p;
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- YY_BUFFER_STATE yy_create_buffer( FILE *file, int size )
- #else
- YY_BUFFER_STATE yy_create_buffer( file, size )
- FILE *file;
- int size;
- #endif
- X
- X {
- X YY_BUFFER_STATE b;
- X
- X b = (YY_BUFFER_STATE) malloc( sizeof( struct yy_buffer_state ) );
- X
- X if ( ! b )
- X YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
- X
- X b->yy_buf_size = size;
- X
- X /* yy_ch_buf has to be 2 characters longer than the size given because
- X * we need to put in 2 end-of-buffer characters.
- X */
- X b->yy_ch_buf = (YY_CHAR *) malloc( (unsigned) (b->yy_buf_size + 2) );
- X
- X if ( ! b->yy_ch_buf )
- X YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
- X
- X yy_init_buffer( b, file );
- X
- X return ( b );
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- void yy_delete_buffer( YY_BUFFER_STATE b )
- #else
- void yy_delete_buffer( b )
- YY_BUFFER_STATE b;
- #endif
- X
- X {
- X if ( b == yy_current_buffer )
- X yy_current_buffer = (YY_BUFFER_STATE) 0;
- X
- X free( (char *) b->yy_ch_buf );
- X free( (char *) b );
- X }
- X
- X
- #ifdef YY_USE_PROTOS
- void yy_init_buffer( YY_BUFFER_STATE b, FILE *file )
- #else
- void yy_init_buffer( b, file )
- YY_BUFFER_STATE b;
- FILE *file;
- #endif
- X
- X {
- X b->yy_input_file = file;
- X
- X /* we put in the '\n' and start reading from [1] so that an
- X * initial match-at-newline will be true.
- X */
- X
- X b->yy_ch_buf[0] = '\n';
- X b->yy_n_chars = 1;
- X
- X /* we always need two end-of-buffer characters. The first causes
- X * a transition to the end-of-buffer state. The second causes
- X * a jam in that state.
- X */
- X b->yy_ch_buf[1] = YY_END_OF_BUFFER_CHAR;
- X b->yy_ch_buf[2] = YY_END_OF_BUFFER_CHAR;
- X
- X b->yy_buf_pos = &b->yy_ch_buf[1];
- X
- X b->yy_eof_status = EOF_NOT_SEEN;
- X }
- # line 329 "c++2latex.l"
- X
- X
- #include "main.c"
- SHAR_EOF
- echo 'File c++2latex.c is complete' &&
- chmod 0640 c++2latex.c ||
- echo 'restore of c++2latex.c failed'
- Wc_c="`wc -c < 'c++2latex.c'`"
- test 63841 -eq "$Wc_c" ||
- echo 'c++2latex.c: original size 63841, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= c++2latex.l ==============
- if test -f 'c++2latex.l' -a X"$1" != X"-c"; then
- echo 'x - skipping c++2latex.l (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting c++2latex.l (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'c++2latex.l' &&
- /*
- X * This is a flex input file but should be edited in -*-C-*- mode
- X *
- X * C++2LaTeX: Produce prettyprinted LaTeX files from C++ or C sources.
- X * Copyright (C) 1990 Norbert Kiesel
- X *
- X * This program is free software; you can redistribute it and/or modify
- X * it under the terms of the GNU General Public License as published by
- X * the Free Software Foundation; either version 1, or (at your option)
- X * any 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, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- X *
- X * Norbert Kiesel
- X * RWTH Aachen / Institut f. Informatik III
- X * Ahornstr. 55
- X * D-5100 Aachen
- X * West Germany
- X *
- X * Phone: +49 241 80-7266
- X * EUNET: norbert@rwthi3.uucp
- X * USENET: ...!mcvax!unido!rwthi3!norbert
- X * X.400: norbert@rwthi3.informatik.rwth-aachen.de
- X *
- X * Please contact me for any bugs you find in this code or any
- X * improvements! I'd also be very happy to get feedback where and
- X * how frequently this program is used (just drop a little mail :-).
- X *
- X * ---------------------------------------------------------------------
- X *
- X * C++2LaTeX 2.0:
- X * Produce even more prettyprinted LaTeX files from C++ or C sources.
- X *
- X * Copyright (C) 1991 Joerg Heitkoetter
- X * Systems Analysis Group, University of Dortmund, Germany.
- X * (heitkoet@gorbi.informatik.uni-dortmund.de).
- X *
- X */
- X
- %x STRING BCOMMENT INCLUDE SLASHCOMMENT
- %s CPLUSPLUS
- X
- %{
- #define KEY printf ("{\\%s %s}", keyword_font, yytext)
- #define CPP printf ("{\\%s \\%s}", cpp_font, yytext)
- #define SYM(x) printf ("$\\%s$", x)
- #define OUT(x) printf ("%s", x)
- #define BTAB printf ("\\hspace*{%d\\indentation}", tabtobrace)
- #define CTAB printf ("\\hspace*{%d\\indentation}", tabtocomment)
- #define FONT(x) printf ("{\\%s ",x);
- #define SUB(x) substitute(x)
- #define IND indent(yytext)
- #define INIT BEGIN (cplusplus_mode ? CPLUSPLUS : INITIAL);
- #define REPARSE yyless (0)
- X
- #include <stdio.h>
- X
- #ifdef ANSI_C
- X #ifdef C_PLUSPLUS
- X #error ANSI_C and C_PLUSPLUS are mutually exclusive
- X #else
- X int cplusplus_mode = 0;
- X #endif
- #else /* CPLUSPLUS or default */
- X int cplusplus_mode = 1;
- #endif
- X
- int complete_file = 0;
- int header = 0;
- int tabtotab = 8;
- int piped = 0;
- X
- int aligntoright = 1; /* align comments to the right -joke */
- int tabtobrace = 2; /* distance between closing brace and corresponding comment -joke */
- int tabtocomment = 4; /* distance between statement and corresponding comment -joke */
- X
- char *font_size = "10"; /* used to be 11 -joke */
- char *indentation = "0.5em";
- char *comment_font = "it";
- char *keyword_font = "bf";
- char *header_font = "sl";
- char *cpp_font = "tt";
- char *string_font = "tt";
- X
- #ifdef __STDC__
- void substitute(const char *);
- void indent(const char *);
- void newpage(int);
- void usage(const char *);
- #else
- void substitute();
- void indent();
- void newpage();
- void usage();
- #endif
- %}
- X
- %%
- X
- X INIT;
- X
- "#"[ \t]*"include" { CPP; BEGIN (INCLUDE); }
- "#"[ \t]*"define" |
- "#"[ \t]*"undef" |
- "#"[ \t]*"pragma" |
- "#"[ \t]*"if" |
- "#"[ \t]*"ifdef" |
- "#"[ \t]*"ifndef" |
- "#"[ \t]*"elif" |
- "#"[ \t]*"else" |
- "#"[ \t]*"error" |
- "#"[ \t]*"line" | /* added G++ special #line directive -joke */
- "#"[ \t]*"ex" | /* added G++ special #ex directive -joke */
- "#"[ \t]*"endif" CPP;
- X
- X
- <INCLUDE>"<"[^>]*/">" { OUT ("$<$"); FONT (string_font);
- X SUB (yytext+1); OUT ("}$>$");
- X input(); INIT; }
- <INCLUDE>\"[^\"]*/\" { OUT ("\""); FONT (string_font);
- X SUB (yytext+1); OUT ("}\"");
- X input(); INIT; }
- <INCLUDE>[ \t]+ ECHO;
- <INCLUDE>[\n] OUT ("\\mbox{}\\\\\n");
- <INCLUDE>. { REPARSE; INIT; }
- X
- "auto" |
- "double" |
- "int" |
- "struct" |
- "break" |
- "else" |
- "long" |
- "switch" |
- "case" |
- "enum" |
- "register" |
- "typedef" |
- "char" |
- "extern" |
- "return" |
- "union" |
- "const" |
- "float" |
- "short" |
- "unsigned" |
- "continue" |
- "for" |
- "signed" |
- "void" |
- "default" |
- "goto" |
- "sizeof" |
- "volatile" |
- "do" |
- "if" |
- "static" |
- "while" |
- <CPLUSPLUS>"new" |
- <CPLUSPLUS>"delete" |
- <CPLUSPLUS>"this" |
- <CPLUSPLUS>"operator" |
- <CPLUSPLUS>"class" |
- <CPLUSPLUS>"public" |
- <CPLUSPLUS>"protected" |
- <CPLUSPLUS>"private" |
- <CPLUSPLUS>"virtual" |
- <CPLUSPLUS>"friend" |
- <CPLUSPLUS>"inline" |
- <CPLUSPLUS>"dynamic" | /* added -joke */
- <CPLUSPLUS>"typeof" | /* added -joke */
- <CPLUSPLUS>"all" | /* G++ special added -joke */
- <CPLUSPLUS>"except" | /* G++ special added -joke */
- <CPLUSPLUS>"exception" | /* G++ special added -joke */
- <CPLUSPLUS>"raise" | /* G++ special added -joke */
- <CPLUSPLUS>"raises" | /* G++ special added -joke */
- <CPLUSPLUS>"reraise" | /* G++ special added -joke */
- <CPLUSPLUS>"try" | /* G++ special added -joke */
- <CPLUSPLUS>"asm" | /* added -joke */
- <CPLUSPLUS>"catch" | /* added -joke */
- <CPLUSPLUS>"overload" KEY;
- "->" SYM ("rightarrow");
- "<<" SYM ("ll");
- ">>" SYM ("gg");
- "<=" SYM ("leq");
- ">=" SYM ("geq");
- "!=" SYM ("neq");
- "||" SYM ("mid\\mid");
- "..." SYM ("ldots");
- "*=" SYM ("ast=");
- "<<=" SYM ("ll=");
- ">>=" SYM ("gg=");
- "^=" SYM ("vee=");
- "|=" SYM ("mid=");
- "~" SYM ("sim");
- "*" SYM ("ast");
- "^" SYM ("wedge");
- "|" SYM ("mid");
- <CPLUSPLUS>"->*" SYM ("rightarrow\\ast");
- "/" OUT ("$/$");
- "<" OUT ("$<$");
- ">" OUT ("$>$");
- "&&" OUT ("\\&\\&");
- "%=" OUT ("\\%=");
- "&=" OUT ("\\&=");
- "{" OUT ("\\{");
- "}" OUT ("\\}");
- "&" OUT ("\\&");
- "%" OUT ("\\%");
- "--" OUT ("-{}-");
- <CPLUSPLUS>".*" OUT (".$\\ast$");
- "?" |
- ":" |
- "=" |
- "," |
- "." |
- ";" |
- "!" |
- "-" |
- "+" |
- "/=" |
- "==" |
- "++" |
- "+=" |
- "-=" |
- "(" |
- ")" |
- "[" |
- "]" |
- <CPLUSPLUS>"::" ECHO;
- X
- <CPLUSPLUS>[a-zA-Z_$][a-zA-Z_$0-9]* |
- [a-zA-Z_][a-zA-Z_0-9]* SUB (yytext);
- X
- X /* 1. Asterisk comments mini scanner */
- X /* 1.1. Curly brace comment */
- "}"[ \t]*"/*" { BEGIN (BCOMMENT);
- X OUT ("\\}");
- X BTAB;
- X FONT (comment_font);
- X OUT ("/$\\ast$"); }
- X
- X /* 1.2. Comments at the beginning of a line */
- ^[ \t]*"/*" { BEGIN (BCOMMENT);
- X FONT (comment_font);
- X REPARSE; }
- X
- X /* 1.3. Other comments, aligned to right side of paper */
- "/*" { BEGIN (BCOMMENT);
- X if (aligntoright) {
- X OUT ("\\hfill");
- X } else {
- X CTAB;
- X }
- X FONT (comment_font);
- X OUT ("/$\\ast$"); }
- X
- <BCOMMENT>"*/" { INIT; OUT ("$\\ast$/}"); }
- <BCOMMENT>"\n" OUT ("\\mbox{}\\\\\n");
- <BCOMMENT>[ \t]+ IND;
- <BCOMMENT>. SUB (yytext);
- X
- X /* 2. Double slash ``//'' comments mini scanner */
- X /* 2.1. Curly brace comment */
- <CPLUSPLUS>}[ \t]*"//" { BEGIN (SLASHCOMMENT);
- X OUT ("\\}");
- X BTAB;
- X FONT (comment_font);
- X OUT ("//");}
- X
- X /* 2.2. Complete line comment */
- <CPLUSPLUS>^[ \t]*"//" { BEGIN (SLASHCOMMENT);
- X FONT (comment_font);
- X REPARSE; }
- X
- X /* 2.3. Other comments */
- <CPLUSPLUS>"//" { BEGIN (SLASHCOMMENT);
- X if (aligntoright) {
- X OUT ("\\hfill");
- X } else {
- X CTAB;
- X }
- X FONT (comment_font);
- X OUT ("//"); }
- X
- <SLASHCOMMENT>"\n" { INIT; OUT ("}\\mbox{}\\\\\n"); }
- <SLASHCOMMENT>[ \t]+ IND;
- <SLASHCOMMENT>. SUB (yytext);
- X
- X
- L?\" { BEGIN (STRING);
- X FONT (string_font); OUT ("\""); }
- <STRING>\\\\ OUT ("$\\backslash\\backslash$");
- <STRING>\\[bfnrtv'"] { OUT ("$\\backslash$"); SUB (yytext+1); }
- <STRING>\" { INIT; OUT ("\"}"); }
- <STRING>"\n" OUT ("\\mbox{}\\\\\n");
- <STRING>^[ \t]+ IND;
- <STRING>. SUB (yytext);
- X
- ([0-9]*\.[0-9]+[fFlL]?) |
- ([0-9]+\.[0-9]*[fFlL]?) |
- ([0-9]*\.?[0-9]+[eE][+-]?[0-9]+) |
- ([0-9]+\.?[0-9]*[eE][+-]?[0-9]+) ECHO;
- X
- [0-9]+[uUlL]? ECHO;
- X
- L?'[ -~]' |
- L?'\\[ntvbrfa\\?'"]' |
- L?'\\[0-7]{1,3}' |
- L?'\\x[0-9a-fA-F]{1,2}' SUB (yytext);
- X
- 0[0-7]+[uUlL]? ECHO;
- X
- 0x[0-9a-fA-F]+[uUlL]? ECHO;
- X
- "\\\n" OUT ("$\\backslash$\\\\\n");
- ^[ \t]+ IND;
- [ \t]+ ECHO;
- "\f"[\n]? OUT ("\\newpage\n");
- "\n" OUT ("\\mbox{}\\\\\n");
- X
- %%
- X
- #include "main.c"
- SHAR_EOF
- chmod 0640 c++2latex.l ||
- echo 'restore of c++2latex.l failed'
- Wc_c="`wc -c < 'c++2latex.l'`"
- test 8532 -eq "$Wc_c" ||
- echo 'c++2latex.l: original size 8532, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= config/README ==============
- if test ! -d 'config'; then
- echo 'x - creating directory config'
- mkdir 'config'
- fi
- if test -f 'config/README' -a X"$1" != X"-c"; then
- echo 'x - skipping config/README (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting config/README (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'config/README' &&
- This folder contains some stuff to support c++2latex's usage within
- imke configurated application programs.
- X
- X 1. `Imakefile' contains a DVI target generated by
- X
- X 2. `mkpt' a `make pretty definition target' tool based on the
- X imake rules provided by
- X
- X 3. `pretty.rules', which must be included from your `local.def'
- X files somewhere down your system's X11 tree
- X (e.g. /usr/local/X11/config/local.def)
- X
- This is just a demo, but we use it for our InterViews based CARTOON
- project...
- X
- Enjoy!
- X
- X -joke
- SHAR_EOF
- chmod 0640 config/README ||
- echo 'restore of config/README failed'
- Wc_c="`wc -c < 'config/README'`"
- test 498 -eq "$Wc_c" ||
- echo 'config/README: original size 498, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= config/mkpt ==============
- if test -f 'config/mkpt' -a X"$1" != X"-c"; then
- echo 'x - skipping config/mkpt (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting config/mkpt (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'config/mkpt' &&
- #!/bin/csh -f
- echo "#################################################"
- echo "# Pretty printing rules generated automagically"
- echo "# on `date` by `whoami`"
- echo "# using joke's *mkpt* csh script..."
- echo "# Now just type in: *make pretty*"
- echo "#################################################"
- echo "DVIS = \"
- foreach i ($argv)
- X if ("$i" != "$argv[$#argv]") then
- X echo " $i.dvi \"
- X else
- X echo " $i.dvi"
- X endif
- end
- echo ""
- echo "SimpleDviTarget(pretty)"
- foreach i ($argv)
- X echo "MakeDviFromSrc($i)"
- end
- SHAR_EOF
- chmod 0750 config/mkpt ||
- echo 'restore of config/mkpt failed'
- Wc_c="`wc -c < 'config/mkpt'`"
- test 508 -eq "$Wc_c" ||
- echo 'config/mkpt: original size 508, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= config/Imakefile ==============
- if test -f 'config/Imakefile' -a X"$1" != X"-c"; then
- echo 'x - skipping config/Imakefile (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting config/Imakefile (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'config/Imakefile' &&
- #################################################
- # Pretty printing rules generated automagically
- # on Thu Dec 5 15:58:03 MET 1991 by heitkoet
- # using joke's *mkpt* csh script...
- # Now just type in: *make pretty*
- #################################################
- DVIS = \
- X ../getopt.h.dvi \
- X ../demo.c.dvi \
- X ../getopt.c.dvi \
- X ../getopt1.c.dvi \
- X ../main.c.dvi \
- X ../version.c.dvi
- X
- SimpleDviTarget(pretty)
- MakeDviFromSrc(../getopt.h)
- MakeDviFromSrc(../demo.c)
- MakeDviFromSrc(../getopt.c)
- MakeDviFromSrc(../getopt1.c)
- MakeDviFromSrc(../main.c)
- MakeDviFromSrc(../version.c)
- SHAR_EOF
- chmod 0640 config/Imakefile ||
- echo 'restore of config/Imakefile failed'
- Wc_c="`wc -c < 'config/Imakefile'`"
- test 574 -eq "$Wc_c" ||
- echo 'config/Imakefile: original size 574, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= config/pretty.rules ==============
- if test -f 'config/pretty.rules' -a X"$1" != X"-c"; then
- echo 'x - skipping config/pretty.rules (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting config/pretty.rules (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'config/pretty.rules' &&
- /*
- X * Pretty Print rules setup -joke 07/06/91
- X */
- #ifndef TeXSuffix
- #define TeXSuffix tex
- #endif
- X
- #ifndef DviSuffix
- #define DviSuffix dvi
- #endif
- X
- #ifndef AuxSuffix
- #define AuxSuffix aux
- #endif
- X
- #ifndef LogSuffix
- #define LogSuffix log
- #endif
- X
- #ifndef LaTeXCmd
- #define LaTeXCmd latex
- #endif
- X
- #ifndef Cplusplus2LaTeXCmd
- #define Cplusplus2LaTeXCmd c++2latex
- #endif
- X
- X
- /*
- X * Set up pretty printing facility.
- X */
- X TEXSUFFIX = TeXSuffix
- X DVISUFFIX = DviSuffix
- X AUXSUFFIX = AuxSuffix
- X LOGSUFFIX = LogSuffix
- X
- X LATEXCMD = LaTeXCmd
- X CPLUSPLUS2LATEXCMD = Cplusplus2LaTeXCmd
- X
- X
- /*
- X * Make a Dvi file.
- X */
- #ifndef MakeDviRule
- #define MakeDviRule(dst,src) @@\
- dst.$(DVISUFFIX): src.$(TEXSUFFIX) @@\
- X @echo "LaTeXing src.$(TEXSUFFIX)" @@\
- X $(RM) dst.$(DVISUFFIX) @@\
- X $(LATEXCMD) src.$(TEXSUFFIX) @@\
- X $(RM) src.$(TEXSUFFIX) src.$(AUXSUFFIX) src.$(LOGSUFFIX)
- #endif
- X
- /*
- X * Make a LaTeX file.
- X */
- #ifndef MakeLaTeXRule
- #define MakeLaTeXRule(dst,src,flags) @@\
- dst.$(TEXSUFFIX): src @@\
- X @echo "C++2LaTeXing src" @@\
- X $(RM) dst.$(TEXSUFFIX) @@\
- X $(CPLUSPLUS2LATEXCMD) src flags -o dst.$(TEXSUFFIX)
- #endif
- X
- /*
- X * Make a Dvi file from a C++ source with flags.
- X */
- #ifndef MakeDviFromSrcFlags
- #define MakeDviFromSrcFlags(file,flags) @@\
- X MakeLaTeXRule(file,file,flags) @@\
- X MakeDviRule(file,file)
- #endif
- X
- /*
- X * Make a Dvi file from a C++ source.
- X */
- #ifndef MakeDviFromSrc
- #define MakeDviFromSrc(file) @@\
- X MakeDviFromSrcFlags(file,-h)
- #endif
- X
- /*
- X * Make a LaTeX file from a C++ source with flags.
- X */
- #ifndef MakeLaTeXFromSrcFlags
- #define MakeLaTeXFromSrcFlags(file,flags) @@\
- X MakeLaTeXRule(file,file,flags)
- #endif
- X
- /*
- X * Make a LaTeX file from a C++ source.
- X */
- #ifndef MakeLaTeXFromSrc
- #define MakeLaTeXFromSrc(file) @@\
- X MakeLaTeXFromSrcFlags(file,/**/)
- #endif
- X
- /*
- X * Build all Dvi files available.
- X */
- #ifndef BuildAllDviFiles
- #define BuildAllDviFiles(target,dvifiles) @@\
- target: dvifiles @@\
- X @echo ""
- #endif
- X
- /*
- X * The simple dvi target: all Dvi files are stand-alone LaTeX.
- X */
- #ifndef SimpleDviTarget
- #define SimpleDviTarget(name) @@\
- X BuildAllDviFiles(name,$(DVIS))
- #endif
- SHAR_EOF
- chmod 0640 config/pretty.rules ||
- echo 'restore of config/pretty.rules failed'
- Wc_c="`wc -c < 'config/pretty.rules'`"
- test 2149 -eq "$Wc_c" ||
- echo 'config/pretty.rules: original size 2149, current size' "$Wc_c"
- rm -f _shar_wnt_.tmp
- fi
- # ============= demo.c ==============
- if test -f 'demo.c' -a X"$1" != X"-c"; then
- echo 'x - skipping demo.c (File already exists)'
- rm -f _shar_wnt_.tmp
- else
- > _shar_wnt_.tmp
- echo 'x - extracting demo.c (Text)'
- sed 's/^X//' << 'SHAR_EOF' > 'demo.c' &&
- //
- // Copyright (c) 1991 University of Dortmund
- //
- // Permission to use, copy, modify, distribute, and sell this software and its
- // documentation for any purpose is hereby granted without fee, provided
- // that the above copyright notice appear in all copies and that both that
- // copyright notice and this permission notice appear in supporting
- // documentation, and that the name of UNIDO not be used in advertising or
- // publicity pertaining to distribution of the software without specific,
- // written prior permission. UNIDO makes no representations about
- SHAR_EOF
- true || echo 'restore of demo.c failed'
- fi
- echo 'End of part 2'
- echo 'File demo.c is continued in part 3'
- echo 3 > _shar_seq_.tmp
- exit 0
- exit 0 # Just in case...
- --
- Kent Landfield INTERNET: kent@sparky.IMD.Sterling.COM
- Sterling Software, IMD UUCP: uunet!sparky!kent
- Phone: (402) 291-8300 FAX: (402) 291-4362
- Please send comp.sources.misc-related mail to kent@uunet.uu.net.
-