dgentile
- strlcpy() if you really just need a truncated but
NUL-terminated string (we provide a compat version, so
it's always available)
- xsnprintf() if you're sure that what you're copying
should fit
- strbuf or xstrfmt() if you need to handle
arbitrary-length heap-allocated strings
"As an example of the benefits of type-checking, in the Vulkan api, there are a lot of handles. VkRenderPass, VkPipeline, VkSwapchain, VkDevice, etc. All of these are just pointers. If we take a function like:
void vkDestroyCommandPool(VkDevice,VkCommandPool,const VkAllocationCallbacks*);`
And remove the type checking: void vkDestroyCommandPool(void*,void*,const void*);
It is the same API, but without type-checking. Even if the parameters are labelled, with this new API I could mess up and pass the wrong thing.The issue is the daughter doesn't have time to be creative. I program, edit videos, etc., but all of that I have to save for the weekends. The daughter probably doesn't have the energy to be creative and just uses their phone during some downtime.
With my generation we are not always on our phones like many would believe. Pre-covid we would gather and talk after school, during lunch, in class. If I went with my friends to lunch it is acceptable to check your phone but we would never find it acceptable to be on your phone the whole time.
The issue is probably not the daughter, but the workload.
1: Domain specific programs, and polish. Logic Pro X, Final Cut Pro X, Ableton, Cubase, Premier Pro, are are excellent pieces of software that people pay for and use every day. Where is the free software equivalent that isn't glitchy and has a usable, slick, ui? The more specific the case gets, and the less related to systems a Free Software project is, the less likely it is to exist or have any polish. I can list Postgres, Redis, Linux, OpenBSD, NetBSD, NodeJS, WebKit, SpiderMonkey, LLVM, GCC, Binutils, Busybox, etc., but where is the free software iMessage, Google Docs, Discord, iTunes, Steam, Google Maps, etc. There may be some of these projects out there for what I just listed, but none of them have a userbase as big as that proprietary software. The only things I can think of are VLC, Blender, and Android.
2: Free Software can only exist with Commercial Software. How many people that work in Free Software are software engineers working at a corporation? What pays for this Free Software to exist? Microsoft hosts github, big enough Free Software projects have budgets and employees at other companies paying for all of it.
1. Goto digitalocean.com or linode.com
2. Buy the smallest instance.
3. Install FreeBSD.
4. Let it run for the next 2 decades without ever needing to touch it.
In other classes, the teachers don't seem to grok that we have other classes, and instead will give us one "trivial 1 hour" assignment a day.
I'm starting to feel burnt out, unlike during actual school which was manageable for me. I would rather we were given an assignment or two a week in each class, or shorter assignments each day. (Thankfully two of my teachers get this)
Also, google classroom can be frustrating if the teacher doesn't use it well. Let's say they post a couple announcements a day, along with assignments, and there was a project assigned on Monday. I have to go hunting to see if there was something. It gets buried in a big stack, and sometimes it will just up and surprise me on Friday when it pops up as "Due today". This I blame more on google than the teachers, since I think there should be a way to visually represent the assignments that isn't a twitter feed.
I think Electron was the webdev community's response to this, and we really haven't gotten one on the app/systems developer side besides QT.
Or to rephrase, using Electron to "emulate" a web browser is cross-platform from the perspective of the electron user, while most other gui-ing solutions in C/C++, are not necessarily cross-platform, and therefore this leads to different set of challenges.
On the note of the HN's perceived hatred of JS, I think its because Javascript has tried to do too many things. Despite its quirks I like Javascript in the context of the web browser, but what I dislike it that it exists in applications and on the server side. The Atom editor should not take up 200 MB and take forever to boot. But it does because instead of taking the time (like sublime text) to write a rockstar system code, they instead used electron. The feeling I get sometimes is that JS developers want to program the same way they do in the browser, everywhere.