KiCad PCB EDA Suite
NL_T Namespace Reference

C++ does not put enum values in separate namespaces unless the enum itself is in a separate namespace. More...

Enumerations

enum  T {
  T_NONE = DSN_NONE, T_COMMENT = DSN_COMMENT, T_STRING_QUOTE = DSN_STRING_QUOTE, T_QUOTE_DEF = DSN_QUOTE_DEF,
  T_DASH = DSN_DASH, T_SYMBOL = DSN_SYMBOL, T_NUMBER = DSN_NUMBER, T_RIGHT = DSN_RIGHT,
  T_LEFT = DSN_LEFT, T_STRING = DSN_STRING, T_EOF = DSN_EOF, T_alias = 0,
  T_aliases, T_code, T_comp, T_components,
  T_datasheet, T_date, T_description, T_design,
  T_docs, T_export, T_field, T_fields,
  T_footprint, T_footprints, T_fp, T_lib,
  T_libpart, T_libparts, T_libraries, T_library,
  T_libsource, T_name, T_names, T_net,
  T_nets, T_node, T_num, T_part,
  T_pin, T_pins, T_ref, T_sheetpath,
  T_source, T_tool, T_tstamp, T_tstamps,
  T_uri, T_value, T_version
}
 enum T contains all this lexer's tokens. More...
 

Detailed Description

C++ does not put enum values in separate namespaces unless the enum itself is in a separate namespace.

All the token enums must be in separate namespaces otherwise the C++ compiler will eventually complain if it sees more than one DSNLEXER in the same compilation unit, say by mutliple header file inclusion. Plus this also enables re-use of the same enum name T. A typedef can always be used to clarify which enum T is in play should that ever be a problem. This is unlikely since Parse() functions will usually only be exposed to one header file like this one. But if there is a problem, then use: typedef NL_T::T T; within that problem area.

Enumeration Type Documentation

enum NL_T::T

enum T contains all this lexer's tokens.

Enumerator
T_NONE 
T_COMMENT 
T_STRING_QUOTE 
T_QUOTE_DEF 
T_DASH 
T_SYMBOL 
T_NUMBER 
T_RIGHT 
T_LEFT 
T_STRING 
T_EOF 
T_alias 
T_aliases 
T_code 
T_comp 
T_components 
T_datasheet 
T_date 
T_description 
T_design 
T_docs 
T_export 
T_field 
T_fields 
T_footprint 
T_footprints 
T_fp 
T_lib 
T_libpart 
T_libparts 
T_libraries 
T_library 
T_libsource 
T_name 
T_names 
T_net 
T_nets 
T_node 
T_num 
T_part 
T_pin 
T_pins 
T_ref 
T_sheetpath 
T_source 
T_tool 
T_tstamp 
T_tstamps 
T_uri 
T_value 
T_version 

Definition at line 26 of file netlist_lexer.h.

27  {
28  // these first few are negative special ones for syntax, and are
29  // inherited from DSNLEXER.
30  T_NONE = DSN_NONE,
34  T_DASH = DSN_DASH,
37  T_RIGHT = DSN_RIGHT, // right bracket: ')'
38  T_LEFT = DSN_LEFT, // left bracket: '('
39  T_STRING = DSN_STRING, // a quoted string, stripped of the quotes
40  T_EOF = DSN_EOF, // special case for end of file
41 
42  T_alias = 0,
43  T_aliases,
44  T_code,
45  T_comp,
48  T_date,
50  T_design,
51  T_docs,
52  T_export,
53  T_field,
54  T_fields,
57  T_fp,
58  T_lib,
59  T_libpart,
60  T_libparts,
62  T_library,
64  T_name,
65  T_names,
66  T_net,
67  T_nets,
68  T_node,
69  T_num,
70  T_part,
71  T_pin,
72  T_pins,
73  T_ref,
75  T_source,
76  T_tool,
77  T_tstamp,
78  T_tstamps,
79  T_uri,
80  T_value,
81  T_version
82  };