2003-11-04 cesar lopez nataren <cesar@ciencias.unam.mx>
[mono.git] / mcs / gmcs / genericparser.cs
1 //
2 // GenericParser.cs: The Base Parser for the Mono compilers
3 //
4 // Author: A Rafael D Teixeira (rafaelteixeirabr@hotmail.com)
5 //
6 // Licensed under the terms of the GNU GPL
7 //
8 // Copyright (C) 2001 Ximian, Inc.
9 //
10 using System;
11 using System.Text;
12
13 namespace Mono.Languages
14 {
15         using System.Collections;
16
17         /// <summary>
18         /// Base class to support multiple Jay generated parsers
19         /// </summary>
20         public abstract class GenericParser
21         {
22                 // Name of the file we are parsing
23                 public string name;
24
25                 // Input stream to parse from.
26                 public System.IO.Stream input;
27
28                 public virtual string[] extensions()
29                 {
30                         string [] list = { ".cs" };
31                         return list;
32                 }
33
34                 public GenericParser()
35                 {
36                         //
37                         // DO NOTHING: Derived classes should do their iniatilization here duties
38                         //
39                 }
40
41                 protected bool yacc_verbose_flag = false;
42
43                 public bool yacc_verbose
44                 {
45                         set
46                         {
47                                 yacc_verbose_flag = value;
48                         }
49
50                         get
51                         {
52                                 return yacc_verbose_flag;
53                         }
54                 }
55         }
56 }
57
58
59