Pricefield | Lemmy
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
@[email protected] to Programmer [email protected] • 2 years ago

Golang be like

i.imgur.com

message-square
140
fedilink
1.44K

Golang be like

i.imgur.com

@[email protected] to Programmer [email protected] • 2 years ago
message-square
140
fedilink
  • @[email protected]
    link
    fedilink
    13•2 years ago

    You mean a system like the compiler

    • @[email protected]
      link
      fedilink
      14•
      edit-2
      2 years ago

      Or a linter. Or code reviews. Or anything else. The nice thing is that if the compiler doesn’t demand something, it can be given to the engineer as an option. The compiler should have the option to do it. The option could even be defaulted on. Afaik there is no way in Golang to disable that error (this is the line that does it: https://github.com/golang/go/blob/04fb929a5b7991ed0945d05ab8015c1721958d82/src/go/types/stmt.go#L67-L69). like --no-pedantics or such. Golang’s compiler openly refuses to give engineers more choices in what they think is the best system to handle it.

      • @[email protected]
        link
        fedilink
        2•2 years ago

        Who needs an option to leave unused variables around the code base? Lazybones?

        • @[email protected]
          link
          fedilink
          5•2 years ago

          You’ve literally never commented out a line or two but left the variable declaration while debugging?

Programmer [email protected]

[email protected]
Create a post
You are not logged in. However you can subscribe from another Fediverse account, for example Lemmy or Mastodon. To do this, paste the following into the search field of your instance: [email protected]

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

  • Keep content in english
  • No advertisements
  • Posts must be related to programming or programmer topics
  • 23 users / day
  • 417 users / week
  • 1.63K users / month
  • 4.3K users / 6 months
  • 3 subscribers
  • 1.54K Posts
  • 54.7K Comments
  • Modlog
  • mods:
  • Feyter
  • adr1an
  • @[email protected]
  • Pierre-Yves Lapersonne
  • UI: 0.18.4
  • BE: 0.18.2
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org