SDF Chatter
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
☆ Yσɠƚԋσʂ ☆@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 1 year ago

Debugging

lemmy.ml

message-square
22
link
fedilink
110

Debugging

lemmy.ml

☆ Yσɠƚԋσʂ ☆@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 1 year ago
message-square
22
link
fedilink
  • TheDoctor [they/them]@hexbear.net
    link
    fedilink
    English
    arrow-up
    10
    ·
    edit-2
    2 months ago

    deleted by creator

    • ☆ Yσɠƚԋσʂ ☆@lemmy.mlOP
      link
      fedilink
      arrow-up
      7
      ·
      1 year ago

      I find setters/getters are generally an antipattern because they obfuscate behavior. When you access a field you know what it looks like, but if you pass it through some implicit transformation in a getter then you have to know what that was.

      • TheDoctor [they/them]@hexbear.net
        link
        fedilink
        English
        arrow-up
        5
        ·
        edit-2
        2 months ago

        deleted by creator

        • ☆ Yσɠƚԋσʂ ☆@lemmy.mlOP
          link
          fedilink
          arrow-up
          6
          ·
          1 year ago

          lol yeah that sounds like a nightmare

    • jollyrogue@lemmy.ml
      link
      fedilink
      arrow-up
      4
      ·
      1 year ago

      Aren’t setters and getters discouraged in Python?

      I remember reading something like, “This isn’t C++ , and Python doesn’t have private vars. Just set the var directly.”

      • TheDoctor [they/them]@hexbear.net
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        2 months ago

        deleted by creator

Programmer Humor@lemmy.ml

programmerhumor@lemmy.ml

Subscribe from Remote Instance

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: !programmerhumor@lemmy.ml

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.
Visibility: Public
globe

This community can be federated to other instances and be posted/commented in by their users.

  • 81 users / day
  • 838 users / week
  • 2.1K users / month
  • 7.09K users / 6 months
  • 448 local subscribers
  • 39.5K subscribers
  • 1.96K Posts
  • 41K Comments
  • Modlog
  • mods:
  • AgreeableLandscape@lemmy.ml
  • cat_programmer@lemmy.ml
  • BE: 0.19.11
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org