Threads for landon

  1. 3

    As someone who doesn’t write C++, I find the necessity(?) of prefixing of some variables with ‘m’ because the compiler doesn’t help you distinguish which namespace a name comes from to be way more odd than which character set they’re written in…

    1. 3

      There’s no necessity, it’s just a convention. Think of it as Hungarian notation for scope instead of type (and I’m sure there are people who do both).

      1. 2

        This is a tooling issue. Good IDEs change the color of variable names, so it’s possible to differentiate between a variable and a field. In such case, writing m shouldn’t be necessary.

        1. 1

          A few reasons:

          It tells the reader that this is a field. An identifier in a C++ program may be resolved via various scopes:

          • A local in the current lambda
          • A local in the current function
          • A field (member) in the current object.
          • A variable visible in an anonymous namespace in the current compilation unit.
          • A global variable in one of the current namespaces.
          • A global variable with no namespace.

          For extra fun, these all shadow the later ones, so an identifier can (in the worst case) appear as all of these, with different meanings at each level[1]. By adding a prefix such as g on globals and m on fields, you disambiguate these and don’t need to rely on an IDE to tell you which you mean (not a great idea if, for example, people might need to read your code in the GitHub web view).

          Additionally, C++ puts member functions (methods) and member variables (fields) in the same namespace. If you want to have a public method called foo that returns some state then you can’t call the field that backs it foo. Some people prefix private members with an underscore to avoid this.

          [1] My favourite example of this is that UNIX defined a function called index, which is always present in a *NIX libc. You get really interesting interactions with the linker in C if you declare a mutable global called index, though thankfully modern linkers will now scream at you if you do.

        1. 5

          How do I pronounce it?

          1. 4

            Either ‘pass-er-in’ (rhymes with ‘grin’) or ‘pass-er-ine’ (rhymes with ‘brine’) work. Usually shortens to ‘pas-rin’ in conversation. It’s not the most obvious word to pronounce, to the extent that I’ve considered changing it to something else.

            1. 1

              To be honest, I read it as rhyming with tangerine.

          1. 3

            i love this article, it’s genuinely unclear to me if it

            is ironic.

            1. 1

              as the author, i can confirm that it’s not ironic!

              1. 1

                So, off topic, but why don’t you capitalize ‘I’? Also is the broken line wrapping deliberate? It… Sends a vibe…

                1. 4

                  OP writes only in lower case - why would you expect him or her to capitalize that one letter? :)

                  1. 3

                    the line wrap breakage is not intentional & i’ll try and make it better :3

                    it’s like me asking you why you used so many ellipses in your sentence - idk, stylistic choice. i like lowercase. :)

                    1. 1

                      csee cummings :)

              1. 6

                JavaScript. Straight up unadulterated static hosted prototypically architected, build system free, untyped JavaScript. There’s programs I’ve left completely unattended for 10 years that still work on every computer I own, including the 15 year old ones. Nothing this side of C comes close.

                A PL is only as long term viable as its runtime envirobment and toolchain. No ‘proper’ FP langs seem to care

                1. 3

                  Just as your simple JavaScript code is still running 10 years later, so would any code that is written in the simplest form of a language and self-contained (without external dependencies), for example:

                  • C – if one takes the simplest C code, one can build it without issues on most OS’s and I bet for years from now… (there are even a few C compilers out there that are very portable;)
                  • Scheme, especially R5RS – there are many Scheme implementations that are able to run the core parts of R5RS, and if not, one could cobbler together a Scheme interpreter in a matter of weeks, if not days;

                  So in this regard, the longevity of a code base is not especially given by the programming language, but by the way in which it was used.

                  1. 1

                    Yes.

                1. 3

                  What was this made with?

                  1. 7

                    WebGL, someone pointed this out on hacker news (its the top comment): https://ciechanow.ski/js/watch.js

                    1. 2

                      Doesn’t seem to work for me. I guess that’s what you get for running OpenBSD.

                  1. 46

                    If there’s anything that should be required to use free software, it should be biomedical devices. To have a part of your body only modifiable and controllable by a corporation that keeps the details as proprietary secrets is like something out of a cyberpunk dystopia. And yet, this article is a great example of it happening!

                    1. 5

                      I guess the counter-argument is that (as a society) we don’t want random people tinkering with medical implants, for the same reasons we don’t want people making snake-oil medicine or amateur surgeons.

                      I’d like to think there’s an acceptable middle-ground, but I’m not sure what that would even look like.

                      1. 18

                        I guess the counter-argument is that (as a society) we don’t want random people tinkering with medical implants, for the same reasons we don’t want people making snake-oil medicine or amateur surgeons.

                        There are actually pretty robust communities working towards automated insulin delivery and (IIRC) CPAP machines. And on the medication front you have RADVAC. There’s a lot of interesting exploration going on here.

                        I’d like to think there’s an acceptable middle-ground

                        One option I heard that appealed to me: the FDA should require code escrow for all medical devices, and release code for any devices that are still in service after the manufacturer ends support.

                        1. 7

                          Code escrow is a good first step.

                          But you need access to all the development tools like JTAG debuggers as well.

                          Also, this all breaks down of the device firmware is locked down, and / or requires signed code.

                          1. 3

                            Required signed code is fine - even good - but the key for signing code that runs inside your body should be your own private key.

                        2. 17

                          There’s nothing illegal or immoral about eating snake oil or trying to do surgery on yourself.

                          Segfaulting my own cyberware is pretty scary, but somebody else segfaulting it and having no recourse is scarier. The acceptable middle ground is sufficient documentation that a professional is capable of fixing it, and an amateur is capable of hurting themselves, but hopefully wise enough to choose a professional. This is how medicine works on stock hardware already.

                          1. 8

                            Requirungy something to be open source doesn’t imply that random people add random code.

                            People also tend to run custom versions of big open source projects. However I think you should have full access on software installed on your body and if you want to should be able to have it changed, just like body modification at large.

                            Will it be exploited by greedy companies? Certainly. But the same is true already for body modification and likely medicine at large. There’s always gonna be someone going as unethical as someone is legally allowed to to maximize profits.

                          2. 1

                            there don’t seem to be many companies creating this kind of technology. Adding additional burdens on them doesn’t seem like a promising way to promote these systems.

                            1. 21

                              Medicine has never really been a place where market dynamics did either well or good.

                              1. 11

                                Yeah, this might not be a problem which the free market is capable of solving on its own. Good thing there are ways to fix that too.

                            1. 7

                              That’s somewhat hilarious, yet depressing.

                              In 1999, on a Pentium MMX 100 and 32MB of RAM, you could easily start up Netscape (or IE, or Mozilla), go to one of many sites aggregating online games, pick almost anything, wait a while and then you’ll get very nice, colorful, engaging, memorable and smooth gameplay experience on almost every hit. It worked flawlessly on each platform which has support for Flash, no matter which browser, OS, environment and what else you had.

                              Right now, in 2022, using oh-so-modern stuff like “html5 canvas”, “audio context” and whatever you pull out to make JS pretend to be a serious business… you get this. And, if you add anything more complex, your $3000 Macbook Pro will overheat sooner or later, and the gameplay wouldn’t be even near the smoothness of Flash game running at silly PMMX with Windows 98.

                              What went wrong? Where we made that mistake? How to get back?

                              1. 13

                                I’m confused by this comment.

                                I’m on a Thinkpad T430, a computer from June 2012, nearly 10 year old hardware with integrated graphics, and this runs just fine and is about as smooth as you could get. The backing game logic just uses basic JavaScript, and uses AudioContext to generate music and sound effects on the fly.

                                This doesn’t even raise my load average above background. If you think this is choppy, try altering PLAYER_MOVE_STEP to a lower value, along with similar variables for the ships. There’s nothing wrong with this game, or this technology, from a performance standpoint, only the perception of choppiness due to how far ships and the player move in a frame (10px on a scaled canvas).

                                Commenters older than myself can probably comment on the Flash situation in 1999, but as I recall, Flash on older hardware was and is (if you have the misfortune of using it) a mess. This piece of programming isn’t “serious business”, and I’m wondering what qualifies as “serious business” outside of the browser-native game engines that are common (Phaser comes to mind).

                                All in all, I think you’ve set up a strawman to beat. There’s nothing wrong here.

                                1. 5

                                  I am old enough to remember the flash situation in 1999 and to have tried to make a game in it not different to this one at the time.

                                  Flash was a buggy mess with bad performance and even an even worse security model. HTML5 was (and is!) an improvement, but it is also more or less the same.

                                  Poorly programmed stuff both does and always has brought every system to it’s knees … Frantic drive clicking has been replaced with (on the balance, quieter) fan noise.

                                  Of course, you can find people who miss that comfortable banging of a spinning disk drive trying to keep up with some flash load or another (which, by the way, could take 10-20 minutes to pull off the network).

                                  And then, of course back in 1999, you would find the people who missed keying their own games in basic! Same as it ever was.

                                2. 5

                                  I don’t think a Pentium MMX would run flash very well, also, flash was programmed in ActionScript, which is basically JavaScript with a different stdlib. I think you might be seeing the past with somewhat rosy glasses…

                                  1. 3

                                    Couple of thoughts. Not sure if any of them are true, but these reflect the impression I am getting.

                                    Technical reasons

                                    How we make software dramatically changed. Everything is a framework now, there is massive amounts of “boilerplate” needed for many of these frameworks.

                                    One has to glue things together, everything got “bazaar” style. There is not much tightly integrated software, despite all these frameworks.

                                    There’s way too many competing options. With Adobe and Flash it was the default category (much like Photoshop nowadays). You chose it because you wanted to create an interactive app in the browser. Both the developer and the customers knew what the goal was. With all these options they all find their niches, which is another thing that changed. Everything needs to have its niche, people think about stuff like USPs maybe a bit too much, while Flash was more an all rounder.

                                    There is more developers, throwing out everything they do, because they learned “release early, release often”, even if they just spent a day on it. Maybe it lands them a job. So interesting projects tend to be buried. It’s just A LOT harder to find them. But if you go on websites that still exist where you’d previously find Flash games you still find new HTML 5 projects that are also more interesting. They just might not be findable on GitHub, lobste.rs, HN, etc.

                                    With lots of people developing lots of things going into many direction, just throwing stuff out there and never learning to care about even rudimentary performance, just bending things so they work, one often comes across code, that checks all boxes for complicated, hard to read, unmaintainable and slow. I think it’s easier to avoid if you have that one package, where you don’t glue things together.

                                    And I say that as someone who actually think it’s a good idea to glue things together, but one should do so with some focus and understanding what one does, instead of copying random example, tutorial, Stack Overflow code and bending it, when it’s not even “the right way” to approach a problem.

                                    Non-technical reasons

                                    It’s still there, just way better hidden, just like with many things. Everything yells for attention, so it’s also harder to find stuff. A great example are also these “curated” “awesome” lists, that often link to dead, unfinished or simply bad projects, because people will just add things they programmed or came across without curation, because who wants to show an empty list?

                                    So one needs to take some time to find them behind walls of unfinished, bad and simply loud projects. I think a large of it is really that compared to 1999 the internet today went from a semi-nerd place to mainstream. People that would have given you a weird look back then for spending hours in front of the computer talking to total strangers nowadays are always connected, get impatient if you don’t respond to an email in half an hour, have their Facebook, Instagram, LinkedIn, etc. account and flood the web with what’s less interesting or only interesting to them. Which probably is why echo-chambers are almost a requirement. Imagine if social networks would just throw everything at you.

                                    Of course for group efforts that means that might make it less likely for these not found interesting projects to accumulate contributors, especially if there is no or not much money behind it.

                                    1. 1

                                      Flash included its own version of JS (“ActionScript”), so there’s more than bad language choice affecting this.

                                    1. 11

                                      Someone wise once told me “it’s a poor craftsperson that blames their tools.”

                                      1. 7

                                        This has always bugged me as a saying because a good craftsman maintains his tools well and picks the right tool for the job. The underlying assumption in the saying is that you are using tools that you chose and that you had the option of selecting better tools.

                                        1. 1

                                          I dug into the history of the saying a while back and it’s originally something like “a poor craftsman has bad tools”, so more in line with what you said than how we use it now.

                                      1. 12

                                        I would be more sympathetic if this wasn’t peppered with rather nasty verbiage: “Blech,” “Blech,” “Blech,” “Blech,” “Beyond worthless,” Sarcastic “Cool. Very helpful,” “Horrifically insidious,” use of “Unintuitive” as objective, etc.

                                        Even if the criticisms are valid, using a polemic tone like this throws shade on the whole set of them because it makes it seem like the author is more interested in confirming an expectation than approaching a new system with an open mind.

                                        Also, some of the criticisms just don’t make sense to me. The docs are pretty meager, which should make them quick and easy to get through, yet several things ziglearn.org covers appear in this list. The stdlib docs claim they’re not great and refer to the source, the source contains tons of examples of usage in the form of test cases.

                                        1. 1

                                          I’m not sure how much I like the idea of Harry Fox Agency for software. This is how music works, and musicians are also pretty famous for not getting paid a lot, especially under the current distribution regime. Part of the problem is that for it to be worthwhile (i.e. a company can negotiate with one or two licensing agencies for all their deps), it needs to be large, and in order to not serve as a beaurocratic wealth concentrator (like the equivalent bodies in music, Spotify et al), it needs to be small.

                                          Also, how do you distribute the profits? if I depend on a web framework and a string padding library and i pay $100, it’s not fair to split it 50/50 cause a web framework is much more labor to build and maintain, but it’s also not clear to be how it could be set up to not prey on smaller/newer players, and not be outright hostile to folks who don’t want to use it at all.

                                          Tldr: musicians have been doing this for decades, and we don’t envy them.

                                          1. 1

                                            are also pretty famous for not getting paid a lot,

                                            Well, Open Source developer usually are not getting paid at all. Also there are differences between software and music, like: no one needs you to fix security issues in your song two years after you recorded it, or keeps asking you how to best play your song on their iPod and could you please record that song again only with a little faster beat, etc.

                                            BTW. I think “artists” are whining a lot, not realizing that they are producing most abundant intellectual commodity we have. There is so many songs recorded, that even if I pick a single genre I wouldn’t be able to listen to all of them once if I’ve listened my whole life. At this point, I don’t need any artist to record a single song ever again, and I would still not ran out of things to listen that I’d like and find novel. So someone producing more of that stuff and then complaining that it’s not paying well… I don’t know what to tell them. :D

                                            Also, how do you distribute the profits?

                                            That’s for free market to figure out.

                                            Also - as long as dual licensing model is preserved - all of these potential problems are business/market problems. Open Source users are unaffected. And business are used to wrangle, negotiate, etc. in the market economy. The whole thing is just an easy and efficient way for some people to opt-in into monetizing their software for commercial users. It doesn’t have to be perfect. As long as it’s a better alternative between giving everything away for free (liberal licensing), or making it commercial-entities hostile (copyleft), I think it’s still a win.

                                            1. 2

                                              Do you think you could use all the open source software out there? Do you actually want to live in a world where nobody makes new music? Would a world in which nobody makes new software actually be that bad?

                                              1. 2

                                                Do you actually want to live in a world where nobody makes new music?

                                                Would most people even notice?

                                          1. 9

                                            This is totally a nitpick, but “Rust has a really solid base of users now, in terms of number of users, diversity of domains, committent of users, size of users, etc” made me wonder if they’re happy about having more large people writing rust. Tall people? Heavy people? Maybe I’m getting the direction wrong, maybe small people? What size of user do we have now, and why is this size better than last year’s?

                                            🤡😆

                                            1. 3

                                              It took me a moment, but they probably mean e.g. large organisations vs small ones.

                                              1. 2

                                                Maybe we should be more gluttonous to put more weight behind the Rust ecosystem ;-)

                                                1. 1

                                                  I’m always ready to be more gluttonous.

                                              1. 3

                                                This is impressive

                                                1. 1

                                                  Everyone I’ve ever met who likes multi repos likes them because they let you develop without scheduled merge windows. This confuses me cause it seems like it should be a discussion between “CI-pulls” vs “devs-push” model.

                                                  1. 10

                                                    Ugh. I was already unhappy about how Zig programs have to pass an allocator reference all over the place, adding it to function signatures and object fields. But now that reference is going to be twice as big, i.e. taking up two ABI registers in calls and making all those structs 8 bytes bigger. Just to save a few cycles dereferencing it.

                                                    1. 23

                                                      Really. The everything-that-allocates-passes-an-allocator thing is one of my favorite pieces of Zig’s design. I like the fine-grained control it gives and it makes manual memory management pleasant.

                                                      1. 8

                                                        Passing an allocator is annoying until you want code that doesn’t allocate. This approach is building a bright future for resource-constrained (bare-metal) platforms. It becomes possible to identify allocating parts of code, and people will probably write much more allocationless libraries.

                                                        1. 8

                                                          And also opens up fine-grained control of when things are allocated/deallocated by allowing a selection of allocators whenever necessary.

                                                          Use a limited bump/arena allocator per API request and free everything at the end. Use a totally different allocator on the backend. Use the C allocator when passing pointers to C functions. It’s all good.

                                                          1. 1

                                                            It’s all good.

                                                            Unless I am missing something, with this design all allocations in Zig incur an overhead of a virtual function call . With this change, there is a better chance of devirtualuzation but AFAICS no guarantees of any kind. While this is probably not a big deal if your allocator ends up calling malloc(), for something like a stack-based arena this can be a significant overhead.

                                                            Contrast this to C++, where an allocator type can be (and is for all the std containers) a template parameter, which means your allocator calls can actually be inlined.

                                                            1. 1

                                                              overhead of a virtual function call

                                                              Branch prediction is a funny thing. Here are two functions; both do a lot of work and perform a lot of calls. One performs those calls directly, and one indirectly. On my machine, they take the same amount of time to execute (amd 3960x, about 0.6 seconds).

                                                              (Of course that is a microbenchmark and not representative; but I think the point is illustrative. E.G. jump to a thunk for your allocations and you won’t be so likely to blow out your btb. In the limit, use an inline cache.)

                                                        2. 5

                                                          It incentivise building abstractions that don’t allocate in perf critical calls.

                                                        1. 26

                                                          Doing this reminded me of the days I worked with Rust, and how wonderfully impossible a task like this would be. I don’t think I’m touching it again, I like my global atomic booleans.

                                                          Sorry, but I have to be That Rust Guy for a second: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=c6b087e83d6b54469c2c612778d7bcb7 Pretty? Not really. Difficult? Also not really.

                                                          1. 5

                                                            Huh 🤔 it really isn’t that much different from Swift.

                                                            I probably wasn’t that familiar with Atomics when I used Rust and trying to use global Booleans seemed impossible.

                                                            I still have a not-yet-finished project in Rust, where I tried to program a Raspberry Pi Zero with 8 planet shaped sensors, to record my voice when touching a sensor, and replay it just like it would be heard on that planet’s atmosphere.

                                                            And I’m still afraid of picking it up again because of all the message passing I had to do for simple Boolean flags. This lifted up some of that anxiety.

                                                            1. 11

                                                              Yeah, one of the tough things about Rust is that it’s big. It’s complicated, there’s lots of features that interact in complicated ways… there’s just lots of stuff going on. It’s hard to learn.

                                                            2. 2

                                                              If it’s not discoverable, it’s difficult

                                                              1. 2

                                                                But this is the obvious way to write a global atomic boolean? This is basically how I would’ve written it in C++ too, or Go. It’s literally just a global atomic boolean expressed as straightforwardly as possible.

                                                                1. 1

                                                                  But different people have different ways of trying to discover things, and what learning methods work for one person may not work well for another. Turns out teaching is hard.

                                                                2. 2

                                                                  global atomic booleans

                                                                  If I ever started a Nerdcore band, that’d be the name for it.

                                                                1. 7

                                                                  As usual, the touchpad (which Apple calls “trackpad”) is great, much better than any touchpad I have ever used on a PC laptop

                                                                  Here we go again…

                                                                  There is nothing special about the hardware (well, Apple is an early adopter of force-sensitive pads, but current Synaptics devices are force-sensitive too). Nothing magic about macOS either. It’s just usually compared against bad software. Windows 10 with any HID-multitouch touchpad feels pretty much the same as macOS. On the unix side, other than ensuring you’re not using anything legacy stuff (xf86-input-synaptics lol), you might need this patch to make scrolling look totally smooth in GTK apps (“might” because it already looks fine if the touchpad’s event rate is high enough, e.g. I never noticed any jitter with a 125Hz touchpad + 60Hz display).

                                                                  1. 29

                                                                    Honestly, I think you’re wrong. There’s nothing magical, but macOS is just so much more reliable than any trackpad I’ve used, and I’ve used trackpads across a relatively wide range of high-end non-Mac laptops. The mac is, for example, the only laptop line I’ve used which always, with 100% accuracy, detects a two finger click as a right click, regardless of how sloppy I am. All other laptops will sometimes just emit a left click rather than a right click if, say, my fingers aren’t horizontal enough or are too close. Also, Wayland currently has a horrible bug where touchpad scrolling is 1.5x faster than it should’ve been (https://gitlab.gnome.org/GNOME/mutter/-/issues/1731). Scrolling in Linux is also universally much more jittery than in macOS (yes, even with libinput drivers), where the screen will jump around a bit when I hold my fingers still. Macs are also the only systems I’ve used where a one-finger tap is registered instantly; there’s always at least what feels like a few hundred milliseconds of delay in Linux with libinput.

                                                                    There’s a lot to like about non-Mac hardware. But I still haven’t found any non-Mac laptops with a decent touch pad, even in the Mac’s price range. I don’t know if it’s a hardware thing or a software thing; I’m guessing it’s a combination.

                                                                    And maybe my experience isn’t representative. Maybe every non-Mac laptop I have ever laid my hands on in my life have just been especially bad. I don’t think so though.

                                                                    1. 9

                                                                      a few hundred milliseconds

                                                                      Simply no way. I’ve used Linux on the most random laptops since 2013 and have never noticed input latency this high and I used to play rhythm games with Synaptics touchpads.

                                                                      1. 5

                                                                        I might be exaggerating, I don’t know. All I know is that it doesn’t feel instant, and the number I hear people throw around as the delay that’s required for something to feel “instant” is 100ms, which puts my best guess somewhere above 100ms. Though you do adjust to it, and I didn’t really understand that there’s a delay before I used a Mac trackpad again and it felt unnaturally fast.

                                                                        Do note that I’m talking about tapping, not clicking. Clicking is always fast in my experience. And again, maybe there are differences in hardware here. But this one really feels like a software thing, and everyone’s using libinput these days.

                                                                        1. 3

                                                                          The latency is there, you just got used to it. Linux is pretty bad, unless you’re using the PREEMPT_RT patches.

                                                                          You can easily measure how bad it is by running cyclictest from rt-test, with SMP enabled and SCHED_FIFO policy. It will set alarms and then measure the difference between the requested time and the time it runs at.

                                                                          Minimum is irrelevant, average has some limited value, max is the column you want to look at. Unit is µs.

                                                                          With mainline kernel, you’ll see max cross into ms range in a matter of minutes, if not seconds. Leaving it running (its cpu usage is low) for a day or two, you’ll see max get into tens of milliseconds.

                                                                          linux-rt patchset does help, but only for scheduler latency. The userspace Linux input stack is another layer of bad.

                                                                          Latency is something that needs to be a core design target. Like security, it cannot be tacked in.

                                                                          To put things in perspective, AmigaOS (1985) input.device task ran with priority 20, making it the highest priority task in the system, which is realtime with hard priorities; if a higher priority task becomes runnable, it will run immediately.

                                                                      2. 2

                                                                        (“might” because it already looks fine if the touchpad’s event rate is high enough, e.g. I never noticed any jitter with a 125Hz touchpad + 60Hz display)

                                                                        So it sounds like there ARE hardware differences? I don’t know whether it’s hardware or software, but every time I use a Windows machine (and I’m talking about higher end Dell XPS laptops, mostly) I end up frustrated with the janky touchpad behavior. For example, the scrolling speed is always wonky and the device doesn’t pick up my two-finger scroll gesture until I’ve moved my fingers almost a centimeter.

                                                                        1. 4

                                                                          Agreed. I’ve used a lot of PCs with both Windows and Linux, and I’ve tried everything I could find to get the touchpads calibrated optimally and they never came close to a Mac, much to my frustration. That said, even Linux running on a Mac doesn’t have good trackpad options, so I don’t doubt that much of the problem is in software–but that’s not much of a consolation so long as “the right software” doesn’t exist for Linux.

                                                                          1. 1

                                                                            Funnily enough the author of the gtk patch was using an external Apple Magic Trackpad 2 which is 90Hz. Basically no one has noticed any jitter in gtk’s naive processing with internal trackpads :)

                                                                            doesn’t pick up my two-finger scroll gesture

                                                                            Windows probably has the highest thresholds for scroll recognition, though they shouldn’t be that big. Also, what applications are you testing with? I’ve heard that Windows does some weird delay with legacy apps that only support basic mouse scrolling. Something like modern browsers, which do use touchpad native panning APIs, shouldn’t be affected by that.

                                                                            1. 2

                                                                              When I find myself on a Windows device, I’m almost always using Chrome. Now that I’m thinking about it, though, I wonder if part of my frustration with trackpads on Windows is the (lack of) inertial scrolling. I’m accustomed to being able to kind of “flick” the trackpad lightly to scroll down a bit while I’m reading something, etc. Windows seems to stubbornly assume that I’m using a wheel mouse.

                                                                              1. 2

                                                                                Even with drivers and software that attempt to make scrolling ‘smooth’, it’s never anything like on MacOS, where it’s not that it’s just ‘smooth’, it’s that you scroll to where you expected. It’s almost like it’s been tuned to perfectly match expectations - and scroll there smoothly and so fast it never feels like it’s lagging behind. Connected to your fingers.

                                                                                I’d liken it to riding a lightweight road bike with higher end components. You move your body and the bike moves with you. You don’t feel like you’re dragging the bike along.

                                                                                1. 1

                                                                                  Chrome was developing the proper support for all this like 4 years ago so it’s definitely in the production release by now. Are you actually testing “precision touchpad” (HID-multitouch) devices?

                                                                                  1. 2

                                                                                    I have no idea what the hardware is, like I said, the machines I’ve used are new and new-ish Dell XPS laptops. My point isn’t that you can’t get a good experience on Windows, it’s that I haven’t gotten a good experience on Windows, even with $2500 laptops (equivalent in price to a Mac).

                                                                            2. 1

                                                                              There is nothing special about . . .

                                                                              I’ve always likened Mac vs. non-Mac trackpads to driving an e.g. BMW 335i vs. a Chevrolet truck. It’s just a more precise and overall nicer user experience.

                                                                              1. 1

                                                                                It could also be familiarity. Different vendors and OSs have different acceleration mappings. People who are used to macs use a not Mac and it feels wrong, and they tell everyone it’s bad. People who are used to windows or linear have the same experience. It’s like how my grandma’s cookies are just better than yours’s. I can’t explain it, and I don’t need to, it’s just true, and my whole family thinks so too. If you disagree you must be confused or misguided.

                                                                                Also, are the pads literally force sensitive? I’ve found putting my palm on it registers as more “force” than pushing hard on it, but my laptop is 7 years old and not apple.

                                                                                1. 1

                                                                                  putting my palm on it registers as more “force” than pushing hard on it

                                                                                  That means it’s not force sensitive, which makes sense for a 7-year-old not-Apple. On the non-Apple side, as I said, only the very latest Synaptics generation is force sensitive.

                                                                                  1. 1

                                                                                    Ok that makes sense, cause the one I have was billed as I think “pressure sensitive” or something weaseley like that. I’m not exactly a close follower of new laptop tech, historically I’ve only gotten new ones when the current one breaks. TBF I’m pretty impressed with how long this one has lasted.

                                                                              1. 7

                                                                                Why not just allow GET queries to contain body?

                                                                                1. 5

                                                                                  GET is defined to be cacheable by URL, which risks messing up the results if there’s any cache involved.

                                                                                  This spec adds an unprecedented feature of using request body as part of the cache key.

                                                                                  It’s a new request type, because you can’t mess with the oldest most common request type on the web.

                                                                                  1. 3

                                                                                    Especially given that several servers and clients already let you do this, it’s just against spec.

                                                                                    1. 3

                                                                                      Which spec?

                                                                                      RFC 7231 says it’s just undefined:

                                                                                      A payload within a GET request message has no defined semantics; sending a payload body on a GET request might cause some existing implementations to reject the request.

                                                                                      1. 1

                                                                                        Oh interesting. I guess I never looked into it but I had heard that.

                                                                                        1. 1

                                                                                          Well, Postel’s law would probably say it’s a bad idea in general, but if you control the backend it would be fine.

                                                                                  1. 9

                                                                                    In this post we will re-invent a form of math that is far superior to the one you learned in school.

                                                                                    My first thought was how hyperbolic that statement is, then I realized, yeah, geometric algebra…

                                                                                    1. 5

                                                                                      I don’t know what it is about geometric algebra that brings out the cranks. It’s very handy though that they call it geometric algebra instead of Clifford algebra.

                                                                                      1. 2

                                                                                        Over a century ago, the cranks were the ones excited about vectors.

                                                                                        Just remember what Lord Kelvin said:

                                                                                        “Symmetrical equations are good in their place, but ‘vector’ is a useless survival, or offshoot from quaternions, and has never been of the slightest use to any creature.”

                                                                                        Letter to G. F. FitzGerald (1896) as quoted in A History of Vector Analysis: The Evolution of the Idea of a Vectorial System (1994) by Michael J. Crowe, p. 120

                                                                                        1. 7

                                                                                          People have taken Clifford algebras very seriously. They’ve been used to try to make geometric sense of second cohomology groups, and the equivalent of Hodge theory has been worked out. Those efforts haven’t yielded a lot back. So far the returns on considering general Clifford algebras over just the exterior algebra have been brutally diminishing. But for some reason they’ve caught the imagination of a wider public. My comments are made as someone who wants to love them, but can’t justify doing so given that simpler tools yield more powerful results.

                                                                                          1. 3

                                                                                            IMO the big cool thing about Clifford algebra is how easy it is to teach and understand. Learning Cliifford algebra for me was a lot like when I bought a decent modern MIG welder. I’m genuinely confused as to why the precursors persist in curriculum in spite of being so obviously inferior.

                                                                                            1. 3

                                                                                              Why don’t you ask an actual working mathematician or theoretical physicist this question? Like quaternions, Clifford algebras are cool and elegant, but for whatever reason they just haven’t proven very useful in applications to either physics or other mathematics. Exterior algebra and differential forms, on the other hand, have proven themselves to be extremely useful in both theoretical and applied differential geometry (the theory of connections on principal and associated fiber bundles, which is the foundation of modern gauge theories in physics, is most naturally phrased in terms of differential forms).

                                                                                      2. 4

                                                                                        Yeah, the author kind of buried the lede, never actually naming this system until the very end. I started out with my crank-radar tingling, but the position made sense, so after a while I skipped forward to find what this is called, and it seems legit.

                                                                                        i see some people dissing it in the comments, but as someone who sort of hit a wall in 2nd-year college physics, I can say that the math derived here seems a lot clearer than the stuff I remember bouncing off of when learning rotational mechanics or E&M.

                                                                                        1. 3

                                                                                          To be honest, I didn’t really intend to diss geometric algebra. I’m largely impartial to the topic since it’s been over 8 years since any of the code I write has been related to geometry or the physical world in any way. However, I do remember being really impressed back then with how that formulation holds together and it definitely broadens one’s horizons. I don’t think the excitement these people have for it is baseless, but they do sound like me when I’m trying to explain to my half-asleep great great aunt and her neighbor why everybody should be using Nix.

                                                                                      1. 4

                                                                                        If only the folks excited about geometric algebra put a fraction of the effort into learning exterior algebra and differential forms, they would be in a much better position to understand modern differential geometry and the physics that uses it.

                                                                                        1. 1

                                                                                          Fraction of the effort of what?

                                                                                          1. 3

                                                                                            Learning geometric algebra, obviously (I thought).

                                                                                        1. 2

                                                                                          I don’t have a use for any of these tools :/

                                                                                          1. 2

                                                                                            Lucky you!