annotate runtime/syntax/hercules.vim @ 3484:982f84487daf v7.3.506

updated for version 7.3.506 Problem: GTK gives an error when selecting a non-existent file. Solution: Add a handler to avoid the error. (Christian Brabandt)
author Bram Moolenaar <bram@vim.org>
date Wed, 25 Apr 2012 17:10:16 +0200
parents 3fc0f57ecb91
children 43efa4f5a8ea
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: Hercules
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Dana Edwards <Dana_Edwards@avanticorp.com>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Extensions: *.vc,*.ev,*.rs
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Last change: Nov. 9, 2001
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 " Comment: Hercules physical IC design verification software ensures
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 " that an IC's physical design matches its logical design and
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " satisfies manufacturing rules.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 " For version 5.x: Clear all syntax items
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 " For version 6.x: Quit when a syntax file was already loaded
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 if version < 600
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 syntax clear
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 elseif exists("b:current_syntax")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 " Ignore case
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 " Hercules runset sections
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn keyword herculesType header assign_property alias assign
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 syn keyword herculesType options preprocess_options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 syn keyword herculesType explode_options technology_options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 syn keyword herculesType drc_options database_options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn keyword herculesType text_options lpe_options evaccess_options
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 syn keyword herculesType check_point compare_group environment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn keyword herculesType grid_check include layer_stats load_group
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 syn keyword herculesType restart run_only self_intersect set snap
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn keyword herculesType system variable waiver
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 " Hercules commands
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn keyword herculesStatement attach_property boolean cell_extent
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 syn keyword herculesStatement common_hierarchy connection_points
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 syn keyword herculesStatement copy data_filter alternate delete
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 syn keyword herculesStatement explode explode_all fill_pattern find_net
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 syn keyword herculesStatement flatten
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 syn keyword herculesStatement level negate polygon_features push
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 syn keyword herculesStatement rectangles relocate remove_overlap reverse select
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 syn keyword herculesStatement select_cell select_contains select_edge select_net size
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 syn keyword herculesStatement text_polygon text_property vertex area cut
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 syn keyword herculesStatement density enclose external inside_edge
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 syn keyword herculesStatement internal notch vectorize center_to_center
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 syn keyword herculesStatement length mask_align moscheck rescheck
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 syn keyword herculesStatement analysis buildsub init_lpe_db capacitor
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 syn keyword herculesStatement device gendev nmos pmos diode npn pnp
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 syn keyword herculesStatement resistor set_param save_property
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 syn keyword herculesStatement connect disconnect text text_boolean
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn keyword herculesStatement replace_text create_ports label graphics
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 syn keyword herculesStatement save_netlist_database lpe_stats netlist
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn keyword herculesStatement spice graphics_property graphics_netlist
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn keyword herculesStatement write_milkyway multi_rule_enclose
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn keyword herculesStatement if error_property equate compare
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 syn keyword herculesStatement antenna_fix c_thru dev_connect_check
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 syn keyword herculesStatement dev_net_count device_count net_filter
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 syn keyword herculesStatement net_path_check ratio process_text_opens
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 " Hercules keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 syn keyword herculesStatement black_box_file block compare_dir equivalence
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 syn keyword herculesStatement format gdsin_dir group_dir group_dir_usage
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 syn keyword herculesStatement inlib layout_path outlib output_format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 syn keyword herculesStatement output_layout_path schematic schematic_format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 syn keyword herculesStatement scheme_file output_block else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64 syn keyword herculesStatement and or not xor andoverlap inside outside by to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 syn keyword herculesStatement with connected connected_all texted_with texted
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
66 syn keyword herculesStatement by_property cutting edge_touch enclosing inside
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
67 syn keyword herculesStatement inside_hole interact touching vertex
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
68
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
69 " Hercules comments
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70 syn region herculesComment start="/\*" skip="/\*" end="\*/" contains=herculesTodo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
71 syn match herculesComment "//.*" contains=herculesTodo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
72
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73 " Preprocessor directives
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
74 syn match herculesPreProc "^#.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
75 syn match herculesPreProc "^@.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76 syn match herculesPreProc "macros"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
77
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
78 " Hercules COMMENT option
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79 syn match herculesCmdCmnt "comment.*=.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 " Spacings, Resolutions, Ranges, Ratios, etc.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
82 syn match herculesNumber "-\=\<[0-9]\+L\=\>\|0[xX][0-9]\+\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
83
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
84 " Parenthesis sanity checker
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
85 syn region herculesZone matchgroup=Delimiter start="(" matchgroup=Delimiter end=")" transparent contains=ALLBUT,herculesError,herculesBraceError,herculesCurlyError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
86 syn region herculesZone matchgroup=Delimiter start="{" matchgroup=Delimiter end="}" transparent contains=ALLBUT,herculesError,herculesBraceError,herculesParenError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
87 syn region herculesZone matchgroup=Delimiter start="\[" matchgroup=Delimiter end="]" transparent contains=ALLBUT,herculesError,herculesCurlyError,herculesParenError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
88 syn match herculesError "[)\]}]"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
89 syn match herculesBraceError "[)}]" contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 syn match herculesCurlyError "[)\]]" contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91 syn match herculesParenError "[\]}]" contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
93 " Hercules output format
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
94 "syn match herculesOutput "([0-9].*)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
95 "syn match herculesOutput "([0-9].*\;.*)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
96 syn match herculesOutput "perm\s*=.*(.*)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
97 syn match herculesOutput "temp\s*=\s*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
98 syn match herculesOutput "error\s*=\s*(.*)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
99
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
100 "Modify the following as needed. The trade-off is performance versus functionality.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
101 syn sync lines=100
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
102
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
103 " Define the default highlighting.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
104 " For version 5.7 and earlier: only when not done already
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
105 " For version 5.8 and later: only when an item doesn't have highlighting yet
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
106 if version >= 508 || !exists("did_hercules_syntax_inits")
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
107 if version < 508
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
108 let did_hercules_syntax_inits = 1
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
109 " Default methods for highlighting.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
110 command -nargs=+ HiLink hi link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
111 else
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
112 command -nargs=+ HiLink hi def link <args>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
113 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
114
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
115 HiLink herculesStatement Statement
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
116 HiLink herculesType Type
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
117 HiLink herculesComment Comment
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
118 HiLink herculesPreProc PreProc
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
119 HiLink herculesTodo Todo
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
120 HiLink herculesOutput Include
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
121 HiLink herculesCmdCmnt Identifier
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
122 HiLink herculesNumber Number
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
123 HiLink herculesBraceError herculesError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
124 HiLink herculesCurlyError herculesError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
125 HiLink herculesParenError herculesError
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
126 HiLink herculesError Error
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
127
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
128 delcommand HiLink
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
129 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
130
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
131 let b:current_syntax = "hercules"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
132
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
133 " vim: ts=8