File: internal.h

package info (click to toggle)
global 6.6.5-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 18,308 kB
  • sloc: ansic: 39,589; javascript: 4,891; sh: 4,674; perl: 811; lisp: 696; makefile: 332; python: 213; yacc: 122
file content (56 lines) | stat: -rw-r--r-- 1,631 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/*
 * Copyright (c) 1998, 1999, 2000, 2001, 2003, 2010
 *	Tama Communications Corporation
 *
 * This file is part of GNU GLOBAL.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef _INTERNAL_H_
#define _INTERNAL_H_

#include "parser.h"
#include "strbuf.h"
#include "token.h"

#define PUT(type, tag, lno, line) do {					\
	DBG_PRINT(level, line);						\
	param->put(type, tag, lno, curfile, line, param->arg);		\
} while (0)

#ifdef DEBUG
#define DBG_PRINT(level, a) do {					\
	if (param->flags & PARSER_DEBUG)				\
		dbg_print(level, a);					\
} while (0)
#else
#define DBG_PRINT(level, a) do {} while (0)
#endif

/* parser procedures */
void C(const struct parser_param *);
void yacc(const struct parser_param *);
void Cpp(const struct parser_param *);
void java(const struct parser_param *);
void php(const struct parser_param *);
void assembly(const struct parser_param *);

void dbg_print(int, const char *);

extern STRBUF *asm_symtable;
void asm_initscan(void);
int asm_lex(const struct parser_param *);

#endif