KiCad PCB EDA Suite
specctra_keywords.cpp
Go to the documentation of this file.
1 
2 /* Do not modify this file it was automatically generated by the
3  * TokenList2DsnLexer CMake script.
4  *
5  * Include this file in your lexer class to provide the keywords for
6  * your DSN lexer.
7  */
8 
9 #include <specctra_lexer.h>
10 
11 using namespace DSN;
12 
13 #define TOKDEF(x) { #x, T_##x }
14 
16  TOKDEF( absolute ),
17  TOKDEF( add_group ),
18  TOKDEF( add_pins ),
19  TOKDEF( added ),
20  TOKDEF( allow_antenna ),
21  TOKDEF( allow_redundant_wiring ),
22  TOKDEF( amp ),
23  TOKDEF( ancestor ),
24  TOKDEF( antipad ),
25  TOKDEF( aperture_type ),
26  TOKDEF( array ),
27  TOKDEF( attach ),
28  TOKDEF( attr ),
29  TOKDEF( average_pair_length ),
30  TOKDEF( back ),
31  TOKDEF( base_design ),
32  TOKDEF( bbv_ctr2ctr ),
33  TOKDEF( bend_keepout ),
34  TOKDEF( bond ),
35  TOKDEF( both ),
36  TOKDEF( bottom ),
37  TOKDEF( bottom_layer_sel ),
38  TOKDEF( boundary ),
39  TOKDEF( brickpat ),
40  TOKDEF( bundle ),
41  TOKDEF( bus ),
42  TOKDEF( bypass ),
43  TOKDEF( capacitance_resolution ),
44  TOKDEF( capacitor ),
45  TOKDEF( case_sensitive ),
46  TOKDEF( cct1 ),
47  TOKDEF( cct1a ),
48  TOKDEF( center_center ),
49  TOKDEF( checking_trim_by_pin ),
50  TOKDEF( circ ),
51  TOKDEF( circle ),
52  TOKDEF( circuit ),
53  TOKDEF( class ),
54  TOKDEF( class_class ),
55  TOKDEF( classes ),
56  TOKDEF( clear ),
57  TOKDEF( clearance ),
58  TOKDEF( cluster ),
59  TOKDEF( cm ),
60  TOKDEF( color ),
61  TOKDEF( colors ),
62  TOKDEF( comment ),
63  TOKDEF( comp ),
64  TOKDEF( comp_edge_center ),
65  TOKDEF( comp_order ),
66  TOKDEF( component ),
67  TOKDEF( composite ),
68  TOKDEF( conductance_resolution ),
69  TOKDEF( conductor ),
70  TOKDEF( conflict ),
71  TOKDEF( connect ),
72  TOKDEF( constant ),
73  TOKDEF( contact ),
74  TOKDEF( control ),
75  TOKDEF( corner ),
76  TOKDEF( corners ),
77  TOKDEF( cost ),
78  TOKDEF( created_time ),
79  TOKDEF( cross ),
80  TOKDEF( crosstalk_model ),
81  TOKDEF( current_resolution ),
82  TOKDEF( delete_pins ),
83  TOKDEF( deleted ),
84  TOKDEF( deleted_keepout ),
85  TOKDEF( delta ),
86  TOKDEF( diagonal ),
87  TOKDEF( direction ),
88  TOKDEF( directory ),
89  TOKDEF( discrete ),
90  TOKDEF( effective_via_length ),
91  TOKDEF( elongate_keepout ),
92  TOKDEF( exclude ),
93  TOKDEF( expose ),
94  TOKDEF( extra_image_directory ),
95  TOKDEF( family ),
96  TOKDEF( family_family ),
97  TOKDEF( family_family_spacing ),
98  TOKDEF( fanout ),
99  TOKDEF( farad ),
100  TOKDEF( file ),
101  TOKDEF( fit ),
102  TOKDEF( fix ),
103  TOKDEF( flip_style ),
104  TOKDEF( floor_plan ),
105  TOKDEF( footprint ),
106  TOKDEF( forbidden ),
107  TOKDEF( force_to_terminal_point ),
108  TOKDEF( forgotten ),
109  TOKDEF( free ),
110  TOKDEF( fromto ),
111  TOKDEF( front ),
112  TOKDEF( front_only ),
113  TOKDEF( gap ),
114  TOKDEF( gate ),
115  TOKDEF( gates ),
116  TOKDEF( generated_by_freeroute ),
117  TOKDEF( global ),
118  TOKDEF( grid ),
119  TOKDEF( group ),
120  TOKDEF( group_set ),
121  TOKDEF( guide ),
122  TOKDEF( hard ),
123  TOKDEF( height ),
124  TOKDEF( high ),
125  TOKDEF( history ),
126  TOKDEF( horizontal ),
127  TOKDEF( host_cad ),
128  TOKDEF( host_version ),
129  TOKDEF( image ),
130  TOKDEF( image_conductor ),
131  TOKDEF( image_image ),
132  TOKDEF( image_image_spacing ),
133  TOKDEF( image_outline_clearance ),
134  TOKDEF( image_set ),
135  TOKDEF( image_type ),
136  TOKDEF( inch ),
137  TOKDEF( include ),
138  TOKDEF( include_pins_in_crosstalk ),
139  TOKDEF( inductance_resolution ),
140  TOKDEF( insert ),
141  TOKDEF( instcnfg ),
142  TOKDEF( inter_layer_clearance ),
143  TOKDEF( jumper ),
144  TOKDEF( junction_type ),
145  TOKDEF( keepout ),
146  TOKDEF( kg ),
147  TOKDEF( kohm ),
148  TOKDEF( large ),
149  TOKDEF( large_large ),
150  TOKDEF( layer ),
151  TOKDEF( layer_depth ),
152  TOKDEF( layer_noise_weight ),
153  TOKDEF( layer_pair ),
154  TOKDEF( layer_rule ),
155  TOKDEF( length ),
156  TOKDEF( length_amplitude ),
157  TOKDEF( length_factor ),
158  TOKDEF( length_gap ),
159  TOKDEF( library ),
160  TOKDEF( library_out ),
161  TOKDEF( limit ),
162  TOKDEF( limit_bends ),
163  TOKDEF( limit_crossing ),
164  TOKDEF( limit_vias ),
165  TOKDEF( limit_way ),
166  TOKDEF( linear ),
167  TOKDEF( linear_interpolation ),
168  TOKDEF( load ),
169  TOKDEF( lock_type ),
170  TOKDEF( logical_part ),
171  TOKDEF( logical_part_mapping ),
172  TOKDEF( low ),
173  TOKDEF( match_fromto_delay ),
174  TOKDEF( match_fromto_length ),
175  TOKDEF( match_group_delay ),
176  TOKDEF( match_group_length ),
177  TOKDEF( match_net_delay ),
178  TOKDEF( match_net_length ),
179  TOKDEF( max_delay ),
180  TOKDEF( max_len ),
181  TOKDEF( max_length ),
182  TOKDEF( max_noise ),
183  TOKDEF( max_restricted_layer_length ),
184  TOKDEF( max_stagger ),
185  TOKDEF( max_stub ),
186  TOKDEF( max_total_delay ),
187  TOKDEF( max_total_length ),
188  TOKDEF( max_total_vias ),
189  TOKDEF( medium ),
190  TOKDEF( mhenry ),
191  TOKDEF( mho ),
192  TOKDEF( microvia ),
193  TOKDEF( mid_driven ),
194  TOKDEF( mil ),
195  TOKDEF( min_gap ),
196  TOKDEF( mirror ),
197  TOKDEF( mirror_first ),
198  TOKDEF( mixed ),
199  TOKDEF( mm ),
200  TOKDEF( negative_diagonal ),
201  TOKDEF( net ),
202  TOKDEF( net_number ),
203  TOKDEF( net_out ),
204  TOKDEF( net_pin_changes ),
205  TOKDEF( nets ),
206  TOKDEF( network ),
207  TOKDEF( network_out ),
208  TOKDEF( no ),
209  TOKDEF( noexpose ),
210  TOKDEF( noise_accumulation ),
211  TOKDEF( noise_calculation ),
212  TOKDEF( normal ),
213  TOKDEF( object_type ),
214  TOKDEF( off ),
215  TOKDEF( off_grid ),
216  TOKDEF( offset ),
217  TOKDEF( on ),
218  TOKDEF( open ),
219  TOKDEF( opposite_side ),
220  TOKDEF( order ),
221  TOKDEF( orthogonal ),
222  TOKDEF( outline ),
223  TOKDEF( overlap ),
224  TOKDEF( pad ),
225  TOKDEF( pad_pad ),
226  TOKDEF( padstack ),
227  TOKDEF( pair ),
228  TOKDEF( parallel ),
229  TOKDEF( parallel_noise ),
230  TOKDEF( parallel_segment ),
231  TOKDEF( parser ),
232  TOKDEF( part_library ),
233  TOKDEF( path ),
234  TOKDEF( pcb ),
235  TOKDEF( permit_orient ),
236  TOKDEF( permit_side ),
237  TOKDEF( physical ),
238  TOKDEF( physical_part_mapping ),
239  TOKDEF( piggyback ),
240  TOKDEF( pin ),
241  TOKDEF( pin_allow ),
242  TOKDEF( pin_cap_via ),
243  TOKDEF( pin_via_cap ),
244  TOKDEF( pin_width_taper ),
245  TOKDEF( pins ),
246  TOKDEF( pintype ),
247  TOKDEF( place ),
248  TOKDEF( place_boundary ),
249  TOKDEF( place_control ),
250  TOKDEF( place_keepout ),
251  TOKDEF( place_rule ),
252  TOKDEF( placement ),
253  TOKDEF( plan ),
254  TOKDEF( plane ),
255  TOKDEF( pn ),
256  TOKDEF( point ),
257  TOKDEF( polygon ),
258  TOKDEF( polyline_path ),
259  TOKDEF( position ),
260  TOKDEF( positive_diagonal ),
261  TOKDEF( power ),
262  TOKDEF( power_dissipation ),
263  TOKDEF( power_fanout ),
264  TOKDEF( prefix ),
265  TOKDEF( primary ),
266  TOKDEF( priority ),
267  TOKDEF( property ),
268  TOKDEF( protect ),
269  TOKDEF( qarc ),
270  TOKDEF( quarter ),
271  TOKDEF( radius ),
272  TOKDEF( ratio ),
273  TOKDEF( ratio_tolerance ),
274  TOKDEF( rect ),
275  TOKDEF( reduced ),
276  TOKDEF( region ),
277  TOKDEF( region_class ),
278  TOKDEF( region_class_class ),
279  TOKDEF( region_net ),
280  TOKDEF( relative_delay ),
281  TOKDEF( relative_group_delay ),
282  TOKDEF( relative_group_length ),
283  TOKDEF( relative_length ),
284  TOKDEF( reorder ),
285  TOKDEF( reroute_order_viols ),
286  TOKDEF( resistance_resolution ),
287  TOKDEF( resistor ),
288  TOKDEF( resolution ),
289  TOKDEF( restricted_layer_length_factor ),
290  TOKDEF( room ),
291  TOKDEF( rotate ),
292  TOKDEF( rotate_first ),
293  TOKDEF( round ),
294  TOKDEF( roundoff_rotation ),
295  TOKDEF( route ),
296  TOKDEF( route_to_fanout_only ),
297  TOKDEF( routes ),
298  TOKDEF( routes_include ),
299  TOKDEF( rule ),
300  TOKDEF( same_net_checking ),
301  TOKDEF( sample_window ),
302  TOKDEF( saturation_length ),
303  TOKDEF( sec ),
304  TOKDEF( secondary ),
305  TOKDEF( self ),
306  TOKDEF( sequence_number ),
307  TOKDEF( session ),
308  TOKDEF( set_color ),
309  TOKDEF( set_pattern ),
310  TOKDEF( shape ),
311  TOKDEF( shield ),
312  TOKDEF( shield_gap ),
313  TOKDEF( shield_loop ),
314  TOKDEF( shield_tie_down_interval ),
315  TOKDEF( shield_width ),
316  TOKDEF( side ),
317  TOKDEF( signal ),
318  TOKDEF( site ),
319  TOKDEF( small ),
320  TOKDEF( smd ),
321  TOKDEF( snap ),
322  TOKDEF( snap_angle ),
323  TOKDEF( soft ),
324  TOKDEF( source ),
325  TOKDEF( space_in_quoted_tokens ),
326  TOKDEF( spacing ),
327  TOKDEF( spare ),
328  TOKDEF( spiral_via ),
329  TOKDEF( square ),
330  TOKDEF( stack_via ),
331  TOKDEF( stack_via_depth ),
332  TOKDEF( standard ),
333  TOKDEF( starburst ),
334  TOKDEF( status ),
335  TOKDEF( structure ),
336  TOKDEF( structure_out ),
337  TOKDEF( subgate ),
338  TOKDEF( subgates ),
339  TOKDEF( substituted ),
340  TOKDEF( such ),
341  TOKDEF( suffix ),
342  TOKDEF( super_placement ),
343  TOKDEF( supply ),
344  TOKDEF( supply_pin ),
345  TOKDEF( swapping ),
346  TOKDEF( switch_window ),
347  TOKDEF( system ),
348  TOKDEF( tandem_noise ),
349  TOKDEF( tandem_segment ),
350  TOKDEF( tandem_shield_overhang ),
351  TOKDEF( term_only ),
352  TOKDEF( terminal ),
353  TOKDEF( terminator ),
354  TOKDEF( test ),
355  TOKDEF( test_points ),
356  TOKDEF( testpoint ),
357  TOKDEF( threshold ),
358  TOKDEF( time_length_factor ),
359  TOKDEF( time_resolution ),
360  TOKDEF( tjunction ),
361  TOKDEF( tolerance ),
362  TOKDEF( top ),
363  TOKDEF( topology ),
364  TOKDEF( total ),
365  TOKDEF( track_id ),
366  TOKDEF( turret ),
367  TOKDEF( type ),
368  TOKDEF( um ),
369  TOKDEF( unassigned ),
370  TOKDEF( unconnects ),
371  TOKDEF( unit ),
372  TOKDEF( up ),
373  TOKDEF( use_array ),
374  TOKDEF( use_layer ),
375  TOKDEF( use_net ),
376  TOKDEF( use_via ),
377  TOKDEF( value ),
378  TOKDEF( vertical ),
379  TOKDEF( via ),
380  TOKDEF( via_array_template ),
381  TOKDEF( via_at_smd ),
382  TOKDEF( via_keepout ),
383  TOKDEF( via_number ),
384  TOKDEF( via_rotate_first ),
385  TOKDEF( via_site ),
386  TOKDEF( via_size ),
387  TOKDEF( virtual_pin ),
388  TOKDEF( volt ),
389  TOKDEF( voltage_resolution ),
390  TOKDEF( was_is ),
391  TOKDEF( way ),
392  TOKDEF( weight ),
393  TOKDEF( width ),
394  TOKDEF( window ),
395  TOKDEF( wire ),
396  TOKDEF( wire_keepout ),
397  TOKDEF( wires ),
398  TOKDEF( wires_include ),
399  TOKDEF( wiring ),
400  TOKDEF( write_resolution ),
401  TOKDEF( x ),
402  TOKDEF( xy ),
403  TOKDEF( y )
404 };
405 
406 const unsigned SPECCTRA_LEXER::keyword_count = unsigned( sizeof( SPECCTRA_LEXER::keywords )/sizeof( SPECCTRA_LEXER::keywords[0] ) );
407 
408 
409 const char* SPECCTRA_LEXER::TokenName( T aTok )
410 {
411  const char* ret;
412 
413  if( aTok < 0 )
414  ret = DSNLEXER::Syntax( aTok );
415  else if( (unsigned) aTok < keyword_count )
416  ret = keywords[aTok].name;
417  else
418  ret = "token too big";
419 
420  return ret;
421 }
This source file implements export and import capabilities to the specctra dsn file format...
Definition: specctra.cpp:62
T
enum T contains all this lexer's tokens.
static const int delta[8][2]
Definition: solve.cpp:112
static const KEYWORD keywords[]
Auto generated lexer keywords table and length:
static const unsigned keyword_count
static const char * TokenName(DSN::T aTok)
Function TokenName returns the name of the token in ASCII form.
static double square(int x)
Definition: trigo.cpp:138
Struct KEYWORD holds a keyword string and its unique integer token.
Definition: dsnlexer.h:40
static VRML_COLOR colors[VRML_COLOR_LAST]
#define TOKDEF(x)
static const char * Syntax(int aTok)
Definition: dsnlexer.cpp:272