Programming

julienbarnoin,
@julienbarnoin@mastodon.gamedev.place avatar

I'd like to suggest that anyone who says Copilot saves them time is an indication that they're not doing their job, ie accepted the code without taking the time to think through each line and its implications.

To properly review code, you have to consider for each variable, each expression, whether it's appropriate, how it interacts with the rest of the program, etc.

Since you didn't author the code I'd say this should take more time than if you wrote it yourself.

tony,
@tony@hoyle.me.uk avatar

@julienbarnoin
The only people who say this appear to be paid to do so by ad agencies.

Bad code can cost you hours especially if it looks superficially correct.

alexelcu,
@alexelcu@social.alexn.org avatar

This is old news, but there's now an official announcement — Apache Pekko is now a top-level project:

https://news.apache.org/foundation/entry/apache-software-foundation-announces-new-top-level-project-apache-pekko

SocketSecurity,
@SocketSecurity@fosstodon.org avatar

LDAPjs, an LDAP client and server API for Node.js, was decommissioned after its maintainer received an abusive email from a user, raising concerns about this form of abuse as a potential attack vector. https://socket.dev/blog/ldapjs-open-source-project-decommissioned-after-maintainer-receives-abusive-email

julienbarnoin,
@julienbarnoin@mastodon.gamedev.place avatar

Nowadays terminals and other text views can get rendered with GPU acceleration support, like the kitty terminal that I use.

🤔 That means we could get bloom, chromatic aberration, distortion, depth of field and other post process effects into our terminals, what are we waiting for?

hamoid,
@hamoid@genart.social avatar
jacob,
@jacob@me.dm avatar

“Which programming language should I use?”

#programming #softwaredevelopment #softwareengineering

stevensanderson,
@stevensanderson@mstdn.social avatar

🎉 New Post Alert! 🎉

Counting words in a string is a fundamental task in data analysis.

  1. Base R: Use strsplit(), a straightforward method to split strings and count words.

  2. stringr: The str_split() function from the stringr package makes the code more readable.

  3. stringi: For powerful and efficient string manipulation, stri_split_regex() from the stringi package is your go-to.

Happy coding! 🚀

#R

Post: https://www.spsanderson.com/steveondata/posts/2024-05-16/

damien_dupre,

@stevensanderson what about stringr::str_count(x, "\\w+")?

stevensanderson,
@stevensanderson@mstdn.social avatar

@damien_dupre yes that works too

TheErlef,
@TheErlef@genserver.social avatar

Don’t miss the chance to participate in the Erlang Workshop!

The Erlang Workshop brings together the open source, academic, and industrial communities of Erlang, other BEAM-related languages, actor model programming, distribution, and concurrency to discuss techniques, technologies, languages, and other relevant topics.

Important dates:

Paper submission: May 30
Notification: June 27
Camera Ready: July

Get to know more at this link: https://icfp24.sigplan.org/home/erlang-2024#Call-for-Papers

lorddimwit,
@lorddimwit@mastodon.social avatar

Who called it linear typing and not “once in a lifetime”

Who called it const and not “same as it ever was”

Who called it a stack trace and not “well, how did I get here?”

dannotdaniel,
@dannotdaniel@mastodon.social avatar

@lorddimwit who called it a core dump and not a FECALITY

julienbarnoin,
@julienbarnoin@mastodon.gamedev.place avatar

Not many people know about bleh debugging.
It's a technique I use when I want to check whether a certain piece of code is being compiled at all, such as if it's been ifdef'd out.

It works by inserting the following keyword in the piece of code you're looking at:

bleh

This is a special word that triggers an error in compilers of all programming languages, resulting in a message like "error: 'bleh' undeclared" if the code gets compiled. If not, the code is compiled out.

#programming #gamedev

bobmagicii,
@bobmagicii@phpc.social avatar

@julienbarnoin the technical term for that i think is tombstone. in my web work we're mostly looking to see if they leave markers in the logs.

joelanman,
@joelanman@hachyderm.io avatar

missing from native Node - write a file and create any necessary folders in the path

fs.writeFileSync('a/b/c.txt','hello', {recursive:true})  

joelanman,
@joelanman@hachyderm.io avatar

@jscholes ah you're right! I was sure it threw an error but recursive: true doesnt, thanks!

joelanman,
@joelanman@hachyderm.io avatar

you can do this, thanks @jscholes

const filepath = 'a/b'  
fs.mkdirSync(filepath, { recursive: true })  
fs.writeFileSync(filepath + '/c.txt', 'hello')  
viking,
@viking@fosstodon.org avatar

I have a newfound enormous appreciation for curl's ability to re-use connections in combination with the curl multi interface. Lightning fast way to make craploads of HTTPS requests!

#curl #programming

adnan,
@adnan@1210.nl avatar

@viking is that from the command line? How do you do it?

pixel,
@pixel@social.pixels.pizza avatar

Parsing JSON Data is a fundamental in modern SwiftUI apps. This comprehensive guide covers all the aspects of the Codable protocols in Swift.

#JSON #Programming #Swift #SwiftUI #macOS #iOS #visionOS #Codable
https://matteomanferdini.com/swift-parse-json/

davidbures,
@davidbures@mstdn.social avatar

@pixel Jk on the picture, this is probably the best guide I’ve seen so far. I’ve been struggling with adopting Codable for years

krisajenkins,
@krisajenkins@mastodon.social avatar

From to and beyond, there are coders that love the actor model. But how does it work? How do you design systems in an actor-based world?

Hugh McKee joins me to talk about the best patterns and approaches he's found for breaking the problem down and building an actor-system back up.

📺 Watch on YouTube: https://youtu.be/CBUWcUuG6Ss

🎧 Listen on Spotify: https://open.spotify.com/episode/6LvibKMNLLiJA1f1bfgzYI

jjimenezshaw,
@jjimenezshaw@mapstodon.space avatar

"If the authors of computer programming books wrote arithmetic textbooks..."

A colleague used this image to describe the documentation of a library. Meaning that the documentation was the example with the rabbits, but they have to use the library as the second part of the image.

davidbisset,
@davidbisset@phpc.social avatar

OH: "What's the difference between a light bulb and a #programmer?

A light bulb stops working when it burns out." #programming #webdev #burnout

davidbisset,
@davidbisset@phpc.social avatar

@webaware @nixCraft hence the “OH” :-)

davidbisset,
@davidbisset@phpc.social avatar

@webaware @nixCraft and I remember this joke at least a decade ago too. A classic.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • programming
  • kavyap
  • ngwrru68w68
  • GTA5RPClips
  • DreamBathrooms
  • mdbf
  • magazineikmin
  • thenastyranch
  • Youngstown
  • Durango
  • slotface
  • everett
  • vwfavf
  • rosin
  • Leos
  • normalnudes
  • khanakhh
  • cisconetworking
  • cubers
  • InstantRegret
  • ethstaker
  • osvaldo12
  • modclub
  • anitta
  • provamag3
  • tacticalgear
  • tester
  • megavids
  • JUstTest
  • All magazines