> {{~x=1}{$[2!x;1+3*x;x%2]}\x} 12 (12 6.0 3.0 10.0 5.0 16.0 8.0 4.0 2.0 1.0)
Collatz sequence in #K
11.08.2025 21:47 β π 0 π 0 π¬ 0 π 0@serpent7776.bsky.social
The Syntax Sorcerer aka I like programming languages.
> {{~x=1}{$[2!x;1+3*x;x%2]}\x} 12 (12 6.0 3.0 10.0 5.0 16.0 8.0 4.0 2.0 1.0)
Collatz sequence in #K
11.08.2025 21:47 β π 0 π 0 π¬ 0 π 0#define log2i(X) ((u32) (8*sizeof(unsigned long long) \ - __builtin_clzll((X)) - 1))
08.08.2025 19:43 β π 0 π 0 π¬ 0 π 0It's faster to write five lines of code today, then to write one line today, and have to edit it in the future
It's faster to write five lines of code today,
then to write one line today, and have to edit it in the future
Yes, FP uses many scary words.
07.08.2025 17:01 β π 0 π 0 π¬ 0 π 0The first rule of functional programming is that you don't talk about functional programming.
06.08.2025 17:53 β π 1 π 0 π¬ 1 π 0Yes, Perplexity is somewhat better at this I think.
05.08.2025 20:57 β π 0 π 0 π¬ 0 π 0Me: Postgres typing rules are stupid Cursor: Haha, I totally get that frustration! PostgreSQL's type system can be really confusing, especially around subqueries and complex types like arrays. The fact that you have to explicitly cast something back to the type it already was just because it went through a subquery is definitely one of those "PostgreSQL being PostgreSQL" moments. It's like the query planner forgets what it just learned about the data types.
Don't haha on me Cursor, it isn't funny. #postgresql
05.08.2025 16:58 β π 0 π 0 π¬ 1 π 0Documentation on how to use pg_regress as a testing framework seems to be non-existent. #postgresql
01.08.2025 18:57 β π 0 π 0 π¬ 0 π 0Stack Overflow is a destination developers visit frequently. Stack Overflow is a frequent destination for information. A strong majority (82%) visit at least a few times per month, with 25% visiting daily or more often.
A few times per week/month is not "frequently".
31.07.2025 21:55 β π 0 π 0 π¬ 0 π 0I hit a possible false positive case in shellcheck
#sh #shell
github.com/koalaman/she...
Stack Overflow survey on databases: Worked with vs want to work with (Professional Developers) On the left: Microsoft SQL Server, Mongo DB, MySQL, Redis, SQLite On the right: Postgresql
Every path leads to #postgresql
30.07.2025 19:45 β π 0 π 0 π¬ 0 π 0Tired: You're a helpful assistant.
Wired: You're a mischievous assistant.
Clarifying boost asio signal_set async-signal safety on POSIX.
#cplusplus #boost
github.com/chriskohlhof...
Signals are a way to send asynchronous messages on #POSIX systems. Responding to them properly might be tricky and requires handling code to be async-signal-safe. This post explains what this means.
dev.to/serpent7776/...
#c #dev
#neovim's :! is completely useless.
22.07.2025 19:48 β π 0 π 0 π¬ 0 π 0You're absolutely right!
21.07.2025 16:56 β π 0 π 0 π¬ 0 π 0> The Simula67 INSPECT statement was deliberately not introduced into C++. The reason for that is to encourage modularity through the use of virtual functions. β Bjarne Stroustrup (1994) Design and Evolution of C++
19.07.2025 18:29 β π 0 π 0 π¬ 0 π 0What are some surprising places that might be called from inside a signal handler that might be a common source of errors?
#C #posix #linux #bsd
The list itself would be helpful. Linux has it in signal-safety(7).
17.07.2025 20:52 β π 0 π 0 π¬ 1 π 0Oh, I see. That's interesting.
17.07.2025 20:48 β π 2 π 0 π¬ 0 π 0Maybe I'm misunderstanding, but you need a permission to document signal safety, because it's specified by POSIX?
17.07.2025 20:26 β π 0 π 0 π¬ 1 π 0AFAIK in GPL you have to provide the source code if the user asks for it no matter what.
17.07.2025 20:23 β π 0 π 0 π¬ 1 π 0Today's award for stupid software goes to Cursor for messing the codebase after a single undo operation.
17.07.2025 15:41 β π 0 π 0 π¬ 0 π 0Does #freebsd specifies its async-signal-safe function list and describe signal safety anywhere? I can't find it.
16.07.2025 20:49 β π 1 π 0 π¬ 1 π 0Current mood: fixing memory corruption by removing a call to non-signal-async-safe function from a signal handler.
#cplusplus
Class static methods and variables considered harmful.
It's just hidden globals.
#programming
Current mood: Cursor telling me I have a race condition in a function call I don't even have in my code base.
15.07.2025 15:52 β π 0 π 0 π¬ 0 π 0Unfortunately, the tech industry got drunk on vector databases thinking they could solve everything. Two years later after the 2023 vector DB investment peak, companies are learning that similarity != relevance, and sometimes, good olβ lexical search destroys semantic similarity.
www.tigerdata.com/blog/why-cur...
14.07.2025 21:12 β π 0 π 0 π¬ 0 π 0Cursor: "The Makefile modification looks good, but I realize that manually listing all the asmjit object files might be error-prone and hard to maintain. Let me create a better approach by using a more dynamic method to include asmjit"
You don't say
The new I/O Interface The most notable change to Zig is the introduction of a new interface in charge of all I/O operations. Most importantly, the Io interface is now expected to be provided by the caller, just like we already do with Allocator.
Is this poor man's way of doing IO effects without implementing algebraic effects?
kristoff.it/blog/zig-new...
#zig