Pricefield | Lemmy
  • Communities
  • Create Post
  • Create Community
  • heart
    Support Lemmy
  • search
    Search
  • Login
  • Sign Up
@xia@lemmy.ca to Programmer Humor@lemmy.mlEnglish • 2 years ago

do as i say...

lemmy.ca

message-square
115
fedilink
1.08K

do as i say...

lemmy.ca

@xia@lemmy.ca to Programmer Humor@lemmy.mlEnglish • 2 years ago
message-square
115
fedilink
  • Skull giver
    link
    fedilink
    71•2 years ago

    Long, descriptive names are great! That’s how APIs like CNLabelContactRelationYoungerCousinMothersSiblingsSonOrFathersSistersSon make your code look so clean!

    • @xia@lemmy.caOP
      link
      fedilink
      English
      28•2 years ago

      I’m glad you provided a link, because I would not have believed you otherwise. Take my upvote.

      • Skull giver
        link
        fedilink
        15•
        edit-2
        2 years ago

        It’s an English name for something another language (I believe Chinese) has a simple name for. Kind of how the translations for “nephew” and “cousin” are the same word in my native language, but much more specific. The iOS contacts app has fields for these if you want to label your contacts as such.

        Cant use the same defence for CMMetadataFormatDescriptionCreateWithMetadataFormatDescriptionAndMetadataSpecifications, though.

        It’s not just Apple, Microsoft has ConvertSecurityDescriptorToStringSecurityDescriptorA but that one is honestly not even that bad.

        • @CanadaPlus@lemmy.sdf.org
          link
          fedilink
          3•
          edit-2
          2 years ago

          Yeah, this is actually a non-example, but the concept is still valid. I think the real solution is to make use of OOP and go with a short, descriptive name that’s available in scope.

Programmer Humor@lemmy.ml

!programmerhumor@lemmy.ml
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.
  • 4 users / day
  • 38 users / week
  • 134 users / month
  • 1.63K users / 6 months
  • 4 subscribers
  • 1.75K Posts
  • 37.7K Comments
  • Modlog
  • mods:
  • @cat_programmer@lemmy.ml
  • @AgreeableLandscape@lemmy.ml
  • UI: 0.18.4
  • BE: 0.18.2
  • Modlog
  • Instances
  • Docs
  • Code
  • join-lemmy.org