Skip to content

Commit

Permalink
syntax highlight go examples
Browse files Browse the repository at this point in the history
  • Loading branch information
jftuga committed Mar 15, 2024
1 parent 0ca578e commit 7ff5642
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Expand Up @@ -38,7 +38,7 @@ possible to integrate `exhaustive` with your own analysis driver program.

Given an enum:

```
```go
package token // import "example.org/token"

type Token int
Expand All @@ -54,7 +54,7 @@ const (

and code that switches on the enum:

```
```go
package calc

import "example.org/token"
Expand All @@ -78,7 +78,7 @@ calc.go:6:2: missing cases in switch of type token.Token: token.Multiply, token.
Specify flag `-check=switch,map` to additionally check exhaustiveness of keys
in map literals. For example:

```
```go
var m = map[token.Token]rune{
token.Add: '+',
token.Subtract: '-',
Expand Down

0 comments on commit 7ff5642

Please sign in to comment.