Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Search
Is there a "cleaner" implementation similar to map's? Yes: let map f = id >=> switch f This follows from two of your other equations: map f = bind (switch f) g >=> h = g >...
I'm learning monadic composition through Scott Wlaschin's Railway-oriented Programming post. Oncebind, switch, and >=> functions are defined, he introduces map to show how to "turn a one-trac...
This question probably stems from misunderstanding what case sensitivity is. Being case insensitive does not mean only allowing one case - in fact, it implies the opposite! If one case was treated ...
First, a reminder to future self (the figure RFC 3986, Section 3. Syntax Components complemented with Section 3.2. Authority): The following are two example URIs and their component parts: ...
The documentation for git stash list says list [<log-options>] List the stash entries that you currently have. Each stash entry is listed with its name (e.g. stash@{0} is the latest entry...
In SQL Server 2022+, there's a dedicated binning function called DATE_BUCKET. Each of these statements increments DATE_BUCKET with a bucket width of 1 from the origin time: DECLARE @date DATETI...
Context I was tasked with developing a way to consume RabbitMQ messages that have various priorities (actually different levels of QoS). My restrictions are: high priority messages should have ...
For future readers - based on input from Michael, and some research that was spurred by that improved version, this is the final config I arrived at: # https://gnutls.org/manual/html_node/certtool...
Code review part: Design (important!) Global variables/external linkage are to be avoided (Why is global evil?). You don't actually have private encapsulation in this code since the inte...
Global variables make the code hard to reason about This is especially visible when debugging. Say you have a function which errors. The stacktrace tells you where the function got it's arguments,...
The basics of good vs bad program design All programs are divided in classes. (Or modules/abstract data types/interfaces etc - a rose by any other name.) Each class should only be concerned with i...
I'm working on the architecture, where the assumption is to easily extend the options in the system and also to provide some kind of encapsulation (from the main we could only access the type1 / ty...
A global variable or object is in scope everywhere. That means it's possible to modify it from any part of your program. Imagine a mature program, made up of thousands of lines of code and dozens ...
Nothing in particular will go wrong. global is a valid and supported keyword, the code will work. There is no problem for the computer. The problem is for you. When something is global, it could b...
Many languages discourage global variables. Why is this?
The annotation processor must be compiled before it can be used. This is not a problem if you're using it as a dependency from Maven Central, for example. If you want to use a custom processor, you...
I have to keep reminding myself that a Giraffe project plugs into the ASP.NET Core pipeline or is itself an ASP.NET Core application , so if I can't find answers to my questions in the Giraff...
Having some trouble with giraffe-template on Mac M1, so decided to set up a Giraffe project manually. Started following the Doing it manually section of the Giraffe README, but got stuck right away...
In PHP why is using global like in the example below considered bad? $a = 1; class foo { public function bar() { global $a; // <-- Why is this considered bad? } } ...
You say this is a personal project. I am sure you were free to chose the technology. I ask, because Java, annotations and Mvn are good tools for some requirements, but not necessarily the most eas...
Personal Project: I am new to Maven and have spent a few weeks troubleshooting pom errors with chatGPT. Tutorials are hard to come by online, because annotation-processing in Java is more complica...
Based on what I know so far, there is no difference. Paket has been created more than 10 years ago to address (perceived?) shortcomings of NuGet. (Reading the .NET history made my head spin, and l...
Matthew's list is pretty good, although I don't think one has to do all the things on it as a "minimum." I offer one minimum and a couple nice-to-haves. Some of these I have learned as a contributo...
I don't actually know the answer to this, but I'll post a provisional one while we wait for someone wiser than me to chime in. I think this is a small subset of the real answer. Don't forget the...
Suppose someone has the requisite knowledge and skillset to contribute to a FOSS project, they have the free time to do so and they are aware of the project. Yet, they decide not to contribute. Thi...