{"name":"BSV","scopeName":"source.bsv","patterns":[{"name":"meta.entity.package.bsv","match":"^\\s*(import|export|package)\\s+\\b([a-zA-Z_][a-zA-Z0-9_]*)\\b","captures":{"1":{"name":"keyword.control.import.bsv"},"2":{"name":"entity.name.package.bsv"}}},{"name":"meta.definition.defparam.bsv","match":"^\\s*(defparam)\\s+([a-zA-Z_][a-zA-Z0-9_]*)(.[a-zA-Z_][a-zA-Z0-9_]*)\\s*(=)","captures":{"1":{"name":"keyword.other.bsv"},"2":{"name":"entity.name.type.instance.bsv"},"3":{"name":"meta.module.parameters.bsv"},"4":{"name":"keyword.other.bsv"}}},{"name":"keyword.other.bsv","match":"\\b(automatic|cell|config|deassign|defparam|design|disable|edge|endconfig|endgenerate|endspecify|endtable|endtask|event|generate|genvar|ifnone|incdir|include|liblist|library|localparam|macromodule|negedge|noshowcancelled|posedge|pulsestyle_onevent|pulsestyle_ondetect|real|realtime|scalared|showcancelled|specify|specparam|table|task|time|use|vectored)\\b"},{"name":"keyword.control.bsv","match":"\\b(initial|always|wait|force|release|assign)\\b"},{"name":"keyword.other.bsv","match":"\\b(begin|end|fork|join)\\b"},{"name":"keyword.control.bsv","match":"\\b(matches|action|endaction|actionvalue|endactionvalue|ancestor|deriving|return|match|par|endpar|provisos|dependencies|determines|seq|endseq|schedule|port|clock|reset|no_reset|clocked_by|reset_by|default_clock|default_reset|output_clock|output_reset|input_clock|input_reset|same_family|import|numeric|type)\\b"},{"name":"keyword.typesystem.math.bsv","match":"\\b(TAdd|TSub|TLog|TExp|TMul|TDiv|TMin|TMax)\\b"},{"name":"keyword.typesystem.typeclass.bsv","match":"\\b(Bits|DefaultValue|Eq|Ord|Bounded|Arith|Literal|Bitwise|BitReduction|BitExtend|FShow|IsModule|Add|Max|Log|Mul|Div)\\b"},{"name":"keyword.control.bsv","match":"\\b(forever|repeat|while|for|if|else|case|casex|casez|default|endcase)\\b"},{"name":"keyword.control.import.bsv","match":"\\b(endpackage)\\b"},{"name":"meta.include.bsv","match":"^\\s*(`include)\\s+([\"\u003c].*[\"\u003e])","captures":{"1":{"name":"meta.preprocessor.bsv"},"2":{"name":"entity.name.type.include.bsv"}}},{"name":"meta.preprocessor.ifdef.bsv","match":"^\\s*(`ifdef|`ifndef|`undef|`define)\\s+([a-zA-Z_][a-zA-Z0-9_]*)\\b","captures":{"1":{"name":"meta.preprocessor.bsv"},"2":{"name":"constant.other.define.bsv"}}},{"name":"meta.preprocessor.bsv","match":"`(celldefine|default_nettype|define|else|elsif|endcelldefine|endif|ifdef|ifndef|include|line|nounconnected_drive|resetall|timescale|unconnected_drive|undef)\\b"},{"name":"meta.module.parameters.bsv","match":"[.][_a-zA-Z0-9]+"},{"name":"constant.language.bsv","match":"\\b(True|False)\\b"},{"name":"constant.other.define.bsv","match":"`\\b([a-zA-Z_][a-zA-Z0-9_]*)\\b"},{"include":"#comments"},{"include":"#pragma-compiler-bsv"},{"name":"storage.type.bsv","match":"\\b(let|module|endmodule|rule|endrule|rules|endrules|interface|endinterface|method|endmethod|function|endfunction|instance|endinstance|typeclass|endtypeclass|primitive|endprimitive)\\b"},{"name":"meta.case.bsv","match":"(?:^|\\{|,)\\s*\\b(?!endmodule|endrule|endinterface|endmethod|endfunction|endinstance|endtypeclass)\\b([a-zA-Z_][a-zA-Z0-9_]*)\\b\\s*(:)(?!:)\\s*","captures":{"1":{"name":"entity.name.state.bsv"},"2":{"name":"keyword.operator.bitwise.bsv"}}},{"include":"#all-types"},{"name":"keyword.operator.comparison.bsv","match":"(==|===|!=|!==|\u003c=|\u003e=|\u003c|\u003e)"},{"name":"keyword.operator.arithmetic.bsv","match":"(\\-|\\+|\\*|\\/|%)"},{"name":"keyword.operator.logical.bsv","match":"(!|\u0026\u0026|\\|\\||\\bor\\b)"},{"name":"keyword.operator.bitwise.bsv","match":"(\u0026|\\||\\^|~|\u003c\u003c|\u003e\u003e|\\?|:)"},{"name":"keyword.operator.parenthesis.curly.bsv","match":"({|})"},{"name":"keyword.operator.parenthesis.round.bsv","match":"(\\(|\\))"},{"name":"keyword.operator.parenthesis.square.bsv","match":"(\\[|\\])"},{"name":"keyword.delimiter.bsv","match":"([;,])"},{"name":"keyword.other.bsv","match":"(#|@|=)"},{"name":"support.type.bsv","match":"\\b(output|input|inout|and|nand|nor|or|xor|xnor|buf|not|bufif[01]|notif[01]|r?[npc]mos|tran|r?tranif[01]|pullup|pulldown)\\b"},{"name":"constant.numeric.real.bsv","match":"\\b(?i:(\\d+\\.\\d*(e[\\-\\+]?\\d+)?))(?=[^a-zA-Z_])"},{"name":"constant.numeric.bsv","match":"((\\b\\d+)?'s?([bB]\\s*(([0-1_xXzZ?]+)|(`[A-Z]+[_0-9a-zA-Z]*))|[oO]\\s*(([0-7_xXzZ?]+)|(`[A-Z]+[_0-9a-zA-Z]*))|[dD]\\s*(([0-9_xXzZ?]+)|(`[A-Z]+[_0-9a-zA-Z]*))|[hH]\\s*(([0-9a-fA-F_xXzZ?]+)|(`[A-Z]+[_0-9a-zA-Z]*)))((e|E)(\\+|-)?[0-9]+)?\\b)|(\\b\\d+\\b)"},{"include":"#strings"},{"name":"support.function.bsv","match":"\\$\\b([a-zA-Z_][a-zA-Z0-9_]*)\\b"}],"repository":{"all-types":{"patterns":[{"include":"#storage-type-bsv"},{"include":"#storage-type-standard-bsv"},{"include":"#storage-modifier-bsv"}]},"comments":{"patterns":[{"name":"comment.block.bsv","begin":"/\\*","end":"\\*/","captures":{"0":{"name":"punctuation.definition.comment.bsv"}}},{"name":"comment.line.double-slash.bsv","match":"(//).*$\\n?","captures":{"1":{"name":"punctuation.definition.comment.bsv"}}}]},"pragma-compiler-bsv":{"patterns":[{"name":"pragma.compiler.bsv","begin":"\\(\\*","end":"\\*\\)","captures":{"0":{"name":"punctuation.definition.comment.bsv"}}}]},"storage-modifier-bsv":{"name":"storage.modifier.bsv","match":"\\b(signed|unsigned|small|medium|large|supply[01]|strong[01]|pull[01]|weak[01]|highz[01])\\b"},"storage-type-bsv":{"name":"storage.type.bsv","match":"\\b(wire|tri|tri[01]|supply[01]|wand|triand|wor|trior|trireg|reg|parameter|integer|typedef|struct|enum|tagged|union)\\b"},"storage-type-standard-bsv":{"name":"storage.type.standard.bsv","match":"\\b(void|Action|ActionValue|Integer|Nat|Real|Inout|Bit|UInt|Int|Bool|Maybe|String|Either|Rules|Module|Clock|Reset|Power|Empty|Array|Reg|RWire|Wire|BypassWire|DWire|PulseWire|ReadOnly|WriteOnly|Vector|List|RegFile|FIFO|FIFOF|Stmt)\\b"},"strings":{"patterns":[{"name":"string.quoted.double.bsv","begin":"\"","end":"\"","patterns":[{"name":"constant.character.escape.bsv","match":"\\\\."}],"beginCaptures":{"0":{"name":"punctuation.definition.string.begin.bsv"}},"endCaptures":{"0":{"name":"punctuation.definition.string.end.bsv"}}}]}}}