Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2 | mjames | 1 | %{ |
2 | /* |
||
3 | * $Header: c:\\cygwin\\cvsroot/Vert03/net_src/net_lex.l,v 1.1.1.1 2003/11/04 23:34:59 mjames Exp $ |
||
4 | * |
||
5 | * $Log: net_lex.l,v $ |
||
6 | * Revision 1.1.1.1 2003/11/04 23:34:59 mjames |
||
7 | * Imported into local repositrory |
||
8 | * |
||
9 | * Revision 1.9 2002/10/02 19:37:28 MJAMES |
||
10 | * Moved dummy functions to a separate support file. |
||
11 | * |
||
12 | * Used correct number of arguments to define_pin |
||
13 | * |
||
14 | * Revision 1.8 2002/09/18 09:18:37 mjames |
||
15 | * Added dummy function to make code link to create final application |
||
16 | * |
||
17 | * Revision 1.7 2002/09/09 10:36:20 mjames |
||
18 | * Checkpoint checkin |
||
19 | * |
||
20 | * Revision 1.6 2002/08/14 12:09:27 mjames |
||
21 | * Tidied up some blank lines |
||
22 | * |
||
23 | * Revision 1.5 2002/01/16 11:22:46 mjames |
||
24 | * database.h header file is read in first as it undefined DLL stuff irrelevant |
||
25 | * to HPUX |
||
26 | * |
||
27 | * Revision 1.4 2001/12/13 22:21:36 mjames |
||
28 | * Using #ident with header to identify file |
||
29 | * |
||
30 | * Added dummy function to satisfy linker needs for read command |
||
31 | * |
||
32 | * Revision 1.3 2001/10/31 22:20:08 mjames |
||
33 | * Tidying up problematical comments caused by CVS |
||
34 | * 'intelligent' comment guessing |
||
35 | * |
||
36 | * Revision 1.2 2001/06/06 12:10:20 mjames |
||
37 | * Move from HPUX |
||
38 | * |
||
39 | * Revision 1.1 2001/02/12 10:51:29 mjames |
||
40 | * Inserted new correct version number in vertcl_main.c |
||
41 | * |
||
42 | * Added lex files to the list. |
||
43 | * |
||
44 | * Revision 1.22 2000/10/04 10:37:07 10:37:07 mjames (Mike James) |
||
45 | * Part of Release PSAVAT01 |
||
46 | * |
||
47 | * Revision 1.21 2000/10/02 11:04:16 11:04:16 mjames (Mike James) |
||
48 | * new_vhdl |
||
49 | * |
||
50 | * Revision 1.20 2000/09/27 14:42:16 14:42:16 mjames (Mike James) |
||
51 | * Part of Release Sep_27_ST_2000 |
||
52 | * |
||
53 | * Revision 1.19 2000/09/21 10:15:46 10:15:46 mjames (Mike James) |
||
54 | * Part of Release Sep21Alpha |
||
55 | * |
||
56 | * Revision 1.18 2000/08/25 09:57:13 09:57:13 mjames (Mike James) |
||
57 | * Part of Release Aug25_alpha |
||
58 | * |
||
59 | * Revision 1.17 2000/08/16 08:57:29 08:57:29 mjames (Mike James) |
||
60 | * Part of Release CD01_Aug2000 |
||
61 | * |
||
62 | * Revision 1.16 2000/08/14 14:45:10 14:45:10 mjames (Mike James) |
||
63 | * Part of Release Aug_14_2000 |
||
64 | * |
||
65 | * Revision 1.15 2000/08/11 08:30:31 08:30:31 mjames (Mike James) |
||
66 | * Part of Release Aug_11_2000 |
||
67 | * |
||
68 | * Revision 1.14 2000/08/09 10:31:45 10:31:45 mjames (Mike James) |
||
69 | * Part of Release Aug__9_2000 |
||
70 | * |
||
71 | * Revision 1.13 2000/05/31 11:42:55 11:42:55 mjames (Mike James) |
||
72 | * Part of Release May_31_2000 |
||
73 | * |
||
74 | * Revision 1.12 2000/05/08 17:01:36 17:01:36 mjames (Mike James) |
||
75 | * Part of Release May__8_2000 |
||
76 | * |
||
77 | * Revision 1.11 2000/05/08 16:59:29 16:59:29 mjames (Mike James) |
||
78 | * Part of Release May__8_2000 |
||
79 | * |
||
80 | * Revision 1.10 2000/05/08 16:57:06 16:57:06 mjames (Mike James) |
||
81 | * Part of Release May__8_2000 |
||
82 | * |
||
83 | * Revision 1.9 2000/03/08 16:19:17 16:19:17 mjames (Mike James) |
||
84 | * New version including PC |
||
85 | * |
||
86 | * Revision 1.6 2000/01/20 15:58:46 15:58:46 mjames (Mike James) |
||
87 | * Part of Release R22 |
||
88 | * |
||
89 | * Revision 1.5 99/12/22 11:15:26 11:15:26 mjames (Mike James) |
||
90 | * Part of Release Dec_22_1999 |
||
91 | * |
||
92 | * Revision 1.4 99/06/25 14:35:43 14:35:43 mjames (Mike James) |
||
93 | * Added in reference to expression.h, but no changes made |
||
94 | * to the function of acfread yet. |
||
95 | * |
||
96 | * Revision 1.3 98/02/11 11:26:42 11:26:42 mjames (Mike James) |
||
97 | * Checked in for version 6.2a |
||
98 | * |
||
99 | * Revision 1.2 97/04/23 08:45:04 08:45:04 mjames (Mike James) |
||
100 | * CHecked in for release rel23041997 |
||
101 | * |
||
102 | * Revision 1.1 96/12/13 08:43:24 08:43:24 mjames (Mike James) |
||
103 | * Initial revision |
||
104 | * |
||
105 | * Revision 1.14 96/07/19 14:38:28 14:38:28 mjames (Mike James) |
||
106 | * Update to give to PRL |
||
107 | * |
||
108 | * Revision 1.13 1996/07/12 15:52:12 mjames |
||
109 | * Sorted out things like Alias and Jumpers |
||
110 | * Work Correctly |
||
111 | * Print COrrectly |
||
112 | * |
||
113 | * Revision 1.12 96/06/17 10:52:22 10:52:22 mjames (Mike James) |
||
114 | * Tidying up |
||
115 | * |
||
116 | * Revision 1.11 96/06/04 11:52:43 11:52:43 mjames (Mike James) |
||
117 | * Slight modifications |
||
118 | * |
||
119 | * Revision 1.10 96/04/26 16:03:54 16:03:54 mjames (Mike James) |
||
120 | * Set the limit on token length to be consistent with the rest of the code |
||
121 | * |
||
122 | * Revision 1.9 96/03/29 14:47:24 14:47:24 mjames (Mike James) |
||
123 | * Added VHDL netlist writing to the capabilities of ACFREAD |
||
124 | * |
||
125 | * Revision 1.8 96/03/18 13:51:30 13:51:30 mjames (Mike James) |
||
126 | * Real Revision 2.1 |
||
127 | * |
||
128 | * Revision 1.6 96/02/13 09:13:19 09:13:19 mjames (Mike James) |
||
129 | * Updated to be version 2.0 with net joining |
||
130 | * |
||
131 | * Revision 1.5 96/02/07 16:01:27 16:01:27 mjames (Mike James) |
||
132 | * Added correct RCS header |
||
133 | * |
||
134 | * Revision 1.4 96/02/07 15:50:32 15:50:32 mjames (Mike James) |
||
135 | * Added RCS ident message |
||
136 | * |
||
137 | * Revision 1.3 96/01/10 13:13:24 13:13:24 mjames (Mike James) |
||
138 | * Works in debug mode with EPLD listings and PCB layout |
||
139 | * |
||
140 | * Revision 1.2 96/01/08 15:23:44 15:23:44 mjames (Mike James) |
||
141 | * Managing to make sense of things now |
||
142 | * |
||
143 | * Revision 1.1 96/01/07 12:40:11 Mike_James |
||
144 | * Initial revision |
||
145 | * |
||
146 | * Revision 1.1 96/01/04 17:55:24 17:55:24 mjames (Mike James) |
||
147 | * Initial revision |
||
148 | * |
||
149 | * Revision 1.2 96/01/04 11:37:16 11:37:16 mjames (Mike James) |
||
150 | * Compete parsing of FIT and ACF with ignore of junk . |
||
151 | * |
||
152 | * Revision 1.1 96/01/04 10:18:25 10:18:25 mjames (Mike James) |
||
153 | * Initial revision |
||
154 | * |
||
155 | * */ |
||
156 | |||
157 | #include <stdio.h> |
||
158 | /* see makefile for why */ |
||
159 | #include "vertcl_main.h" |
||
160 | #include "expression.h" |
||
161 | #include "generic.h" |
||
162 | #include "database.h" |
||
163 | |||
164 | #include "net_yacc.h" |
||
165 | #include "lx_support.h" |
||
166 | #define YYLMAX MAXIDLEN |
||
167 | |||
168 | #ident "@(#)$Header: c:\\cygwin\\cvsroot/Vert03/net_src/net_lex.l,v 1.1.1.1 2003/11/04 23:34:59 mjames Exp $" |
||
169 | |||
170 | extern int yyval; |
||
171 | |||
172 | extern int lineno; |
||
173 | %} |
||
174 | |||
175 | L [A-Za-z\~\-] |
||
176 | |||
177 | L2 [A-Za-z0-9_/\~\-\*] |
||
178 | |||
179 | Ct [ -\~] |
||
180 | |||
181 | Cm [^\n] |
||
182 | |||
183 | D [0-9] |
||
184 | Spc [ \r\t] |
||
185 | |||
186 | S [^\"] |
||
187 | Q [\"] |
||
188 | |||
189 | |||
190 | %% |
||
191 | "\$PACKAGES" { free_strings(&lx_first,&lx_last);return (PACKAGES); }; |
||
192 | "\$NETS" { free_strings(&lx_first,&lx_last);return (NETS); }; |
||
193 | "\$END" { free_strings(&lx_first,&lx_last);return(END); }; |
||
194 | |||
195 | |||
196 | ";" { return(SEMI); }; |
||
197 | "!" { return(PLING); }; |
||
198 | "." { return(DOT); }; |
||
199 | "," { return(COMMA); }; |
||
200 | |||
201 | |||
202 | |||
203 | |||
204 | {Q}{S}*{Q} { yylval.string = make_string(yytext,&lx_first,&lx_last) ; /* do it anyway */ |
||
205 | return(ASTRING); }; |
||
206 | {L2}{L2}* { yylval.string = make_string(yytext,&lx_first,&lx_last) ; /* do it anyway */ |
||
207 | return(ASTRING); }; |
||
208 | |||
209 | "--"{Cm}*"\n" { lineno++; return(NL);/* VHDL comment */ }; |
||
210 | "/\*"{Ct}*"*\/" { break; /* c comment */ }; |
||
211 | |||
212 | {Spc} { break; /* white space */ }; |
||
213 | "\n" { lineno++; return(NL); }; |
||
214 | %% |