go-check-sumtype

A simple utility for running exhaustiveness checks on Go "sum types." (by alecthomas)

Go-check-sumtype Alternatives

Similar projects and alternatives to go-check-sumtype

  1. golangci-lint

    Fast linters runner for Go

  2. InfluxDB

    InfluxDB high-performance time series database. Collect, organize, and act on massive volumes of high-resolution data to power real-time intelligent systems.

    InfluxDB logo
  3. exhaustive

    Check exhaustiveness of switch statements of enum-like constants in Go source code.

  4. go-enum

    An enum generator for go

  5. enumer

    A Go tool to auto generate methods for your enums (by dmarkham)

  6. enum

    Type safe enums for Go without code generation or reflection (by orsinium-labs)

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a better go-check-sumtype alternative or higher similarity.

go-check-sumtype discussion

Log in or Post with

go-check-sumtype reviews and mentions

Posts with mentions or reviews of go-check-sumtype. We have used some of these posts to build our list of alternatives and similar projects. The last one was on 2024-07-12.
  • Enums in Go
    6 projects | news.ycombinator.com | 12 Jul 2024
    There are two linters that add those checks: https://github.com/nishanths/exhaustive for values and https://github.com/alecthomas/go-check-sumtype for types. Both are integrated into golangci-lint. I use both a lot and have only a positive experience.

    Having support from the language would be nice, though.

  • Hacking Go to give it sum types
    2 projects | /r/golang | 11 Nov 2023
    golangci-lint recently integrated go-check-sumtype. I recommend using golangci-lint as a pre-commit hook, but if you're in a real hurry you can replace "go build" with a shell script that runs go-check-sumtype instead. This is probably better than a weird hack, not that you're saying that the weird hack is a good idea anyhow.

Stats

Basic go-check-sumtype repo stats
2
32
4.8
23 days ago

alecthomas/go-check-sumtype is an open source project licensed under The Unlicense which is an OSI approved license.

The primary programming language of go-check-sumtype is Go.


Sponsored
InfluxDB high-performance time series database
Collect, organize, and act on massive volumes of high-resolution data to power real-time intelligent systems.
influxdata.com

Did you know that Go is
the 4th most popular programming language
based on number of references?