1. 3

    Who’s ready to rewrite Mac System 7 in Rust?! It could really use the memory safety and concurrency.

    1. 3

      All of the best stuff I remember from classic Mac OS was because there was no memory safety. Most extensions worked by rooting around in the OS’s memory space and changing stuff around at will. There are good reasons not to bring that back to modern OS’s but losing it would make the classic mac notably less functional

      1. 2

        Look, I get it, we can build The Grouch in as an easter egg.

      2. 1

        I mean, you really want to start with System 6, no? It’s been a very long time since I did any programming on “Classic” Mac OS, so I could be confused.

        1. 4

          System 7 was a huge jump, especially in the UX. I wouldn’t go back any further.

          1. 1

            But it was clunky under the hood, is what I’m vaguely remembering. I do miss System 7/8, though.

            1. 3

              Oh god yes. Everything before Mac OS X was a dumpster fire under the hood. The Lisa had a pretty sound OS, from what I’ve heard, but the Macintosh project had to hack together a similar UX on a much smaller machine (128KB RAM, 64KB ROM, and 112KB floppies) so a lot of corners were cut. Most significantly it was designed to run only one app at a time, and adding multi-app support was a monstrous kludge that basically put all apps into a single process and single thread.

              (Apple knew this was a mess and were working on more solid replacement OSs since at least 1989, but for various reasons those projects all failed until NeXT came along and OS X took shape in 1997-2001.)

          2. 4

            System 7 drastically improved the mouthfeel; putting the two side by side reveals how much more polish is in there.

            1. 4

              I’m not going to lie, as an amateur mixologist, that’s the second weirdest reference to mouthfeel I’ve heard.

              1. 2

                Okay I’ll bite. What was the weirdest?

                1. 2

                  mildly sexua/adult languagel warning (within what youtube .. permits) https://youtu.be/j1dJ8whOM8E?t=545

              2. 2

                I’m glad someone is finally talking about the mouthfeel.

          1. 2

            Can you give some more context here? Aren’t most compiled languages a “Programming language that compiles into a x86 ELF executable”?

            1. 2

              Not my own stuff. This is a compiler that turns its C-similar language directly into x86 assembly. As in “forget about LLVM, and all the other complexity, just let me translate directly from source code into an assembly language.”

              Sure he hopes to also target something else later, including LLVM, but this makes for an interesting project especially when considering the bootstrap-from-nothing problem.

            1. 10

              I think an important direction for future programming language development is better support for writing single programs that span multiple nodes. It’s been done, e.g. erlang, but it would be nice to see more tight integration of network protocols into programming languages, or languages that can readily accommodate libraries that do this without a lot of fuss.

              There’s still some utility in IDLs like protobufs/capnproto in that realistically the whole world isn’t going to converge on one language any time soon, so having a nice way of describing an interface in a way that’s portable across languages is important for some use cases. But today we write a lot of plumbing code that we probably shouldn’t need to.

              1. 3

                I couldn’t agree more. Some sort of language feature or DSL or something would allow you to have your services architecture without paying quite so many of the costs for it.

                Type-checking cross-node calls, service fusion (i.e. co-locating services that communicate with each other on the same node to eliminate network traffic where possible), RPC inlining (at my company we have RPC calls that amount to just CPU work but they’re in different repos and different machines because they’re written by different teams; if the compiler had access to that information it could eliminate that boundary), something like a query planner for complex RPCs that decay to many other backend RPC calls (we pass object IDs between services but often many of them need the data about those same underlying objects so they all go out to the data access layer to look up the same objects). Some of that could be done by ops teams with implementation knowledge but in our case those implementations are changing all of the time so they’d be out of date by the time the ops team has time to figure out what’s going on under the hood. There’s a lot that a Sufficiently Smart Compiler(tm) can do given all of the information

                1. 3

                  There is also a view that it is a function of underlying OS (not a particular programming language) to seamlessly provide ‘resources’ (eg memory, CPU, scheduling) etc. across networked nodes.

                  This view is, sometimes, called Single Image OS (briefly discussed that angle in that thread as well )

                  Overall, I agree, of course, that creating safe, efficient and horizontally scalable programs – should much easier.

                  Hardware is going to continue to drive horizontal scalability capabilities (whether it is multiple cores, or multiple nodes, or multiple video/network cards)

                  1. 2

                    I was tempted to add some specifics about projects/ideas I thought were promising, but I’m kinda glad I didn’t, since everybody’s chimed with stuff they’re excited about and there’s a pretty wide range. Some of these I knew about others I didn’t, and this turned out to be way more interesting than if it had been about one thing!

                    1. 2

                      Yes, but: you need to avoid the mistakes of earlier attempts to do this, like CORBA, Java RMI, DistributedObjects, etc. A remote call is not the same as an in-process call, for all the reasons called out in the famous Fallacies Of Distributed Computing list. Earlier systems tried to shove that inconvenient truth under the rug, with the result that ugly things happened at runtime.

                      On the other hand, Erlang has of course been doing this well for a while.

                      I think we’re in better shape to deal with this now thanks all the recent work languages have been doing to provide async calls, Erlang-style channels, Actors, and better error handling through effect systems. (Shout out to Rust, Swift and Pony!)

                      1. 2

                        Yep! I’m encouraged by signs that we as a field have learned our lesson. See also: https://capnproto.org/rpc.html#distributed-objects

                        1. 1

                          Cap’nProto is already on my long list of stuff to get into…

                      2. 2

                        Great comment, yes, I completely agree.

                        This is linked from the article, but just in case you didn’t se it, http://catern.com/list_singledist.html lists a few attempts at exactly that. Including my own http://catern.com/caternetes.html

                        1. 2

                          This is what work like Spritely Goblins is hoping to push forward

                          1. 1

                            I think an important direction for future programming language development is better support for writing single programs that span multiple nodes.

                            Yes!

                            I think the model that has the most potential is something near to tuple spaces. That is, leaning in to the constraints, rather than trying to paper over them, or to prop up anachronistic models of computation.

                            1. 1

                              better support for writing single programs that span multiple nodes.

                              That’s one of the goals of Objective-S. Well, not really a specific goal, but more a result of the overall goal of generalising to components and connectors. And components can certainly be whole programs, and connectors can certainly be various forms of IPC.

                              Having support for node-spanning programs also illustrates the need to go beyond the current call/return focus in our programming languages. As long as the only linguistically supported way for two components to talk to each other is a procedure call, the only way to do IPC is transparent RPCs. And we all know how well that turned out.

                              1. 1

                                indeed! Stuff like https://www.unisonweb.org/ looks promising.

                              1. 0

                                What’s the point of this? Most of the unique features of zOS are only really useful or interesting if you’re running it on a mainframe, which this person isn’t doing. 90% of the blogpost is the person trying to get a copy of it in the first place, and talking about code licensing bullshit.

                                I don’t see why anyone would go through this trouble except out of curiosity, but as far as I can tell for ‘normal’ use it’s basically just a unix box with some quirks, which along with the earlier licensing BS makes it seem like a lot of effort for very little gain – compare with running something like 9front where it’s a mostly unique system and you can acquire the entire thing for free without much effort.

                                Can someone explain why this is useful / interesting to do?

                                1. 3

                                  What’s the point of this?

                                  It makes the OP happy. What other justification does he need?

                                  1. 1

                                    Ok, that’s cool. But this is a guide on installing it and he doesn’t really give me a reason to do any of that. He said part of his reason for installing it is to pass the knowledge on to the next generation, but he just utterly fails to give any kind of reason on why this is worthwhile knowledge to pass on if you’re not working literally as a sysadmin on wallstreet

                                  2. 2

                                    Calling z/OS a “unix box with quirks” is underselling it extremely. It’s quite a bizarre OS branch people know little about, but that’s because IBM has no hobbyist program and you only see it if you’re basically MIS at a Fortune 500.

                                    I don’t think there’s too much other than licensing bullshit in the OP either (it’s thin otherwise); he’d be better off using literally anything z/PDT for hyucks.

                                    1. 1

                                      Calling z/OS a “unix box with quirks” is underselling it extremely.

                                      And yet neither this blogpost, nor the wikipage for the operating system does anything to disabuse me of this notion, and there doesn’t seem to be any feature of this that is useful for someone running it on something that isn’t a mainframe.

                                      I don’t think there’s too much other than licensing bullshit in the OP either (it’s thin otherwise); he’d be better off using literally anything z/PDT for hyucks.

                                      yup

                                    2. 1

                                      They say why, it’s the first sentence

                                      Some people retire and buy an open top sports car or big motorbike. Up here in Orkney the weather can change every day, so instead of buying a fast car with an open top, when I retired, I got z/OS running on my laptop for the similar sort of price! This means I can continue “playing” with z/OS and MQ, and helping the next generation to use z/OS. At the end of this process I had the software installed on my laptop, many unwanted DVDs, and a lot of unnecessary cardboard

                                    1. 1

                                      Like any “why isn’t ___ more popular” question I’m sure this will attract a lot of plausible-sounding anecdotes but, like all such questions, the answer is almost certainly that tech fashion just didn’t go that way, it went some other way for no reason at all except happenstance. Why didn’t OS/2 become more popular? You can describe the history there but there’s no why, it just did. An identical world with one fewer butterfly probably went another way instead and they’re just as sure about why it went that way. If graph databases did become more popular you’d have the same folk explaining why it’s obvious that it happened that way.

                                      But for a baseless anecdote of my own: SQL can model graphs, if poorly, and there are some great SQL databases that already exist, so most people with a graph problem just write it as a SQL problem instead because they learnt how to use it in school and already know it and their friends and coworkers know it. Writing a database is difficult, hard work. Especially if you care about correctness. The number of people in the world that can do it is finite and for whatever historical set of reasonless circumstances they’re concentrated in the SQL space instead and that feeds itself.

                                        1. 32

                                          When an error in your code base can take down millions of users who depend upon it for vital work you should

                                          1. Have good CI
                                          2. Have extensive tests
                                          3. Make small changes at a time
                                          4. Have at least one set of extra eyes looking at your changes
                                          1. 15
                                            1. Make use of language features that push you towards correctness, for example static typing.
                                            1. 8

                                              I find it shocking how many people love “dynamic languages”

                                              1. 7

                                                I don’t. There’s a lot of neat tricks you can do at runtime in these systems that would require 10x more work to do at build time, because our build tools are awful and far too difficult to work with. Problem is that we only have the build-time understanding of things while we’re actually programming.

                                                Don’t get me wrong, I disagree with taking this side of the trade-off and I don’t think it’s worth it. But I also realise this is basically a value judgement. I have a lot of experience and would expect people to give my opinions weight, but I can’t prove it, and other rational people who are definitely no dumber than me feel the opposite, and I have to give their opinions weight too.

                                                If our tooling was better (including the languages themselves), a lot of the frustrations that lead people to build wacky stuff that only really works in loose languages would go away.

                                                1. 7

                                                  I don’t, because I used to be one of those people. Strong type systems are great if the type system can express the properties that I want to enforce. They’re an impediment otherwise. Most of the popular statically typed languages only let me express fairly trivial properties. To give a simple example: how many mainstream languages let me express, in the type system, the idea that I give a function a pointer to an object and it may not mutate any object that it reaches at an arbitrary depth of indirection from that pointer, but it can mutate other objects?

                                                  Static dispatch also often makes some optimisations and even features difficult. For example, in Cocoa there is an idiom called Key-Value Coding, which provides a uniform way of accessing properties of object trees, independent of how they are stored. The generic code in NSObject can use reflection to allow these to read and write instance variables or call methods. More interestingly, this is coupled with a pattern called Key-Value Observing, where you can register for notifications of changes before and after they take place on a given object. NSObject can implement this by method swizzling, which is possible only because of dynamic dispatch.

                                                  If your language has a rich structural and algebraic type system then you can do a lot of these things and still get the benefits of a static type checking.

                                                  1. 2

                                                    Regarding your example, honestly I am not 100% sure that I grasp what you are saying.

                                                    In something like C++ you can define a constant object and then explicitly define mutating parts of it. But I don’t think that quite covers it.

                                                    I have enjoyed some use of Haskell a few years back and was able to grasp at least some of it. But it gets complicated very fast.

                                                    But usually I am using languages such as c# and typescript. The former is getting a lot of nice features and the latter has managed to model a lot of JavaScript behaviour.

                                                    But I have no problem admitting that type systems are restrictive in their expressibility. But usually I can work within it without too many issues. I would love to see the features of Haskell and idris, and others become widely available - but the current languages don’t seem interested in that wider adoption.

                                                    1. 3

                                                      Regarding your example, honestly I am not 100% sure that I grasp what you are saying.

                                                      In something like C++ you can define a constant object and then explicitly define mutating parts of it. But I don’t think that quite covers it.

                                                      I don’t want an immutable object, I want an immutable view of an object graph. In C++ (ignoring the fact that you can cast it away) a const pointer or reference to an object can give you an immutable view of a single object, but if I give you a const std::vector<Foo*>&, then you are protected from modifying the elements by the fact that the object provides const overloads of operator[] and friends that return const references, but the programmer of std::vector had to do that. If I create a struct Foo { Bar *b ; ... } and pass you a const Foo* then you can mutate the Bar that you can reach via the b field. I don’t have anything in the type system that lets me exclude interior mutability.

                                                      This is something that languages like Pony and Verona support via viewpoint adaptation: if you have a capability that does not allow mutation then any capability that you load via it will also lack mutation ability.

                                                      But usually I am using languages such as c# and typescript. The former is getting a lot of nice features and the latter has managed to model a lot of JavaScript behaviour.

                                                      Typescript is a dynamic language, with some optional progressive typing, but it tries really hard to pretend to be a statically typed language with type inference and an algebraic and structural type system. If more static languages were like that then I think there would be far fewer fans of dynamic languages. For what it’s worth, we’re aiming to make the programmer experience for Verona very close to TypeScript (though with AoT compilation and with a static type system that does enough of the nice things that TypeScript does that it feels like a dynamically typed language).

                                                      1. 1

                                                        I really like the sounds of Verona.

                                                    2. 1

                                                      Strong type systems are great if the type system can express the properties that I want to enforce. They’re an impediment otherwise.

                                                      It’s not all-or-nothing. Type systems prevent certain classes of errors. Tests can help manage other classes of errors. There’s no magic bullet that catches all errors. That doesn’t mean we shouldn’t use these easily-accessible, industry-proven techniques.

                                                      Now, static typing itself has many other benefits than just correctness–documentation, tooling, runtime efficiency, enforcing clear contracts between modules being just a few. And yes, they do actually reduce bugs. This is proven.

                                                    3. 4

                                                      We have somewhat believable evidence that CI, testing, small increments, and review helps with defect reduction (sure, that’s not the same thing as defect consequence reduction, but maybe a good enough proxy?)

                                                      I have yet to see believable evidence that static languages do the same. Real evidence, not just “I feel my defects go down” – because I feel that too, but I know I’m a bad judge of such things.

                                                      1. 1

                                                        There are a few articles to this effect about migrations from JavaScript to TypeScript. If memory serves they’re tracking the number of runtime errors in production, or bugs discovered, or something else tangible.

                                                        1. 1

                                                          That sounds like the sort of setup that’d be plagued by confounders, and perhaps in particular selection bias. That said, I’d be happy to follow any more explicit references you have to that type of article. It used to be an issue close to my heart!

                                                          1. 1

                                                            I remember this one popping up on Reddit once or twice.

                                                            AirBNB claimed that 38% of their postmortem-analysed bugs would have been avoidable with TypeScript/static typing.

                                                        2. 1

                                                          Shrug, so don’t use them. They’re not for everyone or every use case. Nobody’s got a gun to your head. I find it baffling how many people like liquorice.

                                                          1. 1

                                                            Don’t worry, I don’t. I can still dislike the thing.

                                                      2. 6

                                                        And if you have millions of users, you also have millions of user’s data. Allowing unilateral code changes isn’t being a good steward of that data, either from a reliability or security perspective.

                                                      1. 6

                                                        It is exactly how much time it takes with Haskell if you are surrounded by other engineers who use it 2, but if an engineer learns Haskell on their own, they usually get stuck.

                                                        This is how I feel about a ton of things in computing. It’s also why SO is so popular, I think. Very often I “get” everything (to the extent I need to), but I have one specific question, or one error message, that I need resolved before I can feel productive. Or I have built up a personal mental model and I want to run it by someone to make sure it is correct (enough).

                                                        There’s nothing quite like having access to someone who knows more than you to accelerate learning.

                                                        1. 4

                                                          Heads up for anyone trying to learn anything FP-related, I found the FP Slack super useful for this when learning Haskell.

                                                          1. 3

                                                            There’s access to the knowledge but there’s also a lot of culture in programming languages that you learn much more quickly by contact. All of the “best practise” cargo cult stuff that you only learn by questions answered by “we usually solve that by…” and “don’t use feature X” and “everybody uses ____ library”

                                                          1. 6

                                                            Highly recommend you watch everything on his channel. He’s super smart and very entertaining

                                                            1. 1

                                                              This is kind of the mindset that people in crypto are so vocally opposed to.

                                                              “I did Cryptopals and I follow people on crypto twitter so I thought I could reverse this thing…”

                                                              Ugh. Interesting things in the article, but yeah. Concerning mindset.

                                                              1. 28

                                                                What? What’s concerning about someone having a go at reversing something? Who is so opposed to people trying out new skills?

                                                                1. 11

                                                                  To this point, I have always heard the advice around crypto as “don’t roll your own crypto systems until you have significant experience breaking others” - so I’m not sure at all why this should be a concerning mindset.

                                                                2. 10

                                                                  Er, why? Actually I think this person is fantastic.

                                                                  • Knows they’re in over their head a bit
                                                                  • Isn’t intimidated by a weird complicated system
                                                                  • Takes a methodical approach to pulling it apart, showing a grasp of principles
                                                                  • Sticks to it and succeeds
                                                                  • Knows that success in reversing crypto doesn’t mean you should roll your own
                                                                  • Ultimately decides to do something smarter
                                                                  • But learns a bunch along the way

                                                                  Beats 99% of the folks I see on the interweb.

                                                                  1. 8

                                                                    The paragraph is just telling you what credentials they have. It’s right before the sentence “I’ve had a little exposure to both cryptography and Javascript, but I’m definitely not a wizard at any of this stuff” and it’s right before they say (non-quote) “buuuuuut it wasn’t actually that hard”. The fact that it’s not a degree in cryptography is the point of that whole paragraph.

                                                                    1. 6

                                                                      There’s nothing wrong with being curious. They even decide at the very end that continuing would be foolish, and they decided to go with SSH.

                                                                      1. 3

                                                                        … and this is why mere programmers have the overwhelming impression that cryptography is “not for them”

                                                                        1. 17

                                                                          See Betteridge’s law of headlines:

                                                                          Any headline that ends in a question mark can be answered by the word no.

                                                                          1. 7

                                                                            The cover story of the January issue of the CACM was Does Facebook Use Sensitive Data for Advertising Purposes?.

                                                                            1. 7

                                                                              For every joke, somebody will point out that it’s not literally true

                                                                              – gthm’s law

                                                                          2. 6

                                                                            The linked post doesn’t disagree with you.

                                                                            can we see here that Microsoft is releasing more and more parts of Windows as open source?

                                                                            Windows will probably remain a proprietary product for some time, but I can imagine that the trend of releasing more and more code will continue

                                                                            This take seems quite reasonable.

                                                                            1. 2

                                                                              It was an open question and more of a thought than an answer. 😊

                                                                              1. 2

                                                                                i did read the article before replying and it is very sensible, i just couldn’t help myself 😅

                                                                              2. 4

                                                                                By ‘no’, do you mean:

                                                                                • No, it won’t become open-source,
                                                                                • Hard to say, but it’s unlikely it will become open-source,
                                                                                • No, you don’t want it to happen, because it will be bad for MS,
                                                                                • No, you don’t want it to happen, because it will be bad for other systems,
                                                                                • You think even if MS releases the source, it will never be truly open-source,
                                                                                • Something else?

                                                                                :^)

                                                                              1. 1

                                                                                I don’t see the point in making a new operating system if it has no novel features and so much legacy baggage.

                                                                                1. 11

                                                                                  Personal interest and desire to learn internals. Then you share it because you are proud of what you made.

                                                                                  I don’t see why people make this comment so frequently. It’s better to do something you’re interested in than stare at the wall.

                                                                                  1. 5

                                                                                    So don’t 🤷‍♀️ The author does, so they do it

                                                                                  1. 17

                                                                                    Here’s the summary of the licencing change:

                                                                                    We are moving our Apache 2.0-licensed source code in Elasticsearch and Kibana to be dual licensed under Server Side Public License (SSPL) and the Elastic License, giving users the choice of which license to apply. This license change ensures our community and customers have free and open access to use, modify, redistribute, and collaborate on the code. It also [restricts] cloud service providers from offering Elasticsearch and Kibana as a service without contributing back

                                                                                    I’m not clear on how this pairs with Drew’s summary of:

                                                                                    Elastic is no longer open source [and] has spit in the face of every single one of 1,573 contributors

                                                                                    The code that those folk wrote and contributed to still exists, right? Elastic is saying that further code that they themselves distribute, which includes code from those 1,573 contributors, will now be under some other licence. And I’ll grant that that’s not great, but Elastic isn’t sshing into all of your servers and deleting the code running on them. They aren’t retroactively undistributing or relicencing old code. They’re just releasing new code that they write under some other, less good, licence. Potential contributors going forward know that those are the terms going forward but the rug wasn’t pulled out from other them and they’re free to contribute to a fork instead, under whatever terms they like.

                                                                                    I’m undoutedly missing all of the context so I feel like I’m missing out on what’s happening that’s so terrible.

                                                                                    Yesterday I was offering beer at my bar for free and some folk kindly helped me develop the recipe and brew it. Today I’m going to start charging for it, and hey if you want to keep helping you’re welcome to but the old recipe’s still on the door outside if you want it. I don’t follow what’s worth being up in arms about.

                                                                                    1. 7

                                                                                      I was just trying to answer a similar comment in the HN thread when I got rate limited, so convenient that I can almost paste it into this thread instead :)

                                                                                      The community is built around the upstream project, and has a lot invested in their continued existence as an open source entity. This move will force the community to start from scratch to build a new entity which continues to meet those guarantees - something Elastic plans to capitalize on by capturing more users on its paid offering while the open source community struggles to set up a new entity at the same level of sophistication from scratch.

                                                                                      What Elastic done was within their rights, but it wasn’t right - so to speak.

                                                                                      1. 5

                                                                                        when I got rate limited

                                                                                        Fun fact, HN does not actually have rate limiting for regular users. It’s only applied to a few users who are flagged by the mods as annoying, but where a ban would cause more trouble than it’s worth. Beyond that there’s the shadowban or insta-flagging of comments.

                                                                                        If you get rate limited, it might be worth sending an email to the mods and asking what to change to get rid of it - that said, being rate limited on HN is something to be proud of ;)

                                                                                        1. 13
                                                                                          1. 9

                                                                                            https://jcs.org/2012/06/13/hellbanned_from_hacker_news

                                                                                            The last sentence of that post is the kicker.

                                                                                            1. 4
                                                                                            2. 6

                                                                                              They have a clickthrough rate limit, and because everything is form-based every click is a new page load. You can hit it pretty easily by hitting the comments link on like 10 posts. I’m not sure sure on how aggressive it is though, or if that’s what Drew is talking about.

                                                                                              1. 1

                                                                                                I can middle-click open the comments of the entire frontpage as fast as I can click and I don’t get rate limited. That said, the rate-limit for “troublesome” users applies not just to actions, but also to comments.

                                                                                                I do have enough karma to be able to downvote, though, so maybe that helps.

                                                                                                Your experience sounds like you’re on one of the lower ban levels.

                                                                                                1. 2

                                                                                                  I wonder if it’s load-based. I was able to click through to the comments for nearly every article on the front page without issue. It may also depend on if you commented recently or something…

                                                                                        1. 2

                                                                                          Do you not have code review?

                                                                                          1. 8

                                                                                            Sure. But I believe that tools should do as much code review as possible. If a tool can tell me that I forgot to remove some code immediately, that’s better than waiting a few minutes/hours for a human to extend effort to find the same problem.

                                                                                            I like to optimize for shorter feedback loops, and less human toil.

                                                                                            1. 2

                                                                                              The tooling surely helps for the most common things (like console.log which is really detectable). Here are some cases that slipped through to review lately:

                                                                                              • copied a thing (1) to make a more general thing (2), made all callers use (2), forgot to delete (1)
                                                                                              • noticed a wrongly spelled safeword
                                                                                              • just using the wrong interfaces (hard to describe in a generic way, “used abstractions of the wrong level”?)
                                                                                              • more soft but still annoying: “linking” to the wrong issue ID with a magic issue tracker term

                                                                                              So, I agree with your sentiment and the tooling looks great if adapted to your team’s standards, but an almost magic bullet could be: read your own code review before publishing it. It’s so annoying to read code outside your editor (mostly Gitlab’s GUI for my part), so it kind of hampers you to read code like you’re used to, in a good way.

                                                                                              NB “you” are hopefully the reader of this comment, I’m sure @jhall already does this.

                                                                                              1. 1

                                                                                                (Not to mention the countless times when console.log("debug") has been missed in code review, and made it into production anyway…)

                                                                                                1. 1

                                                                                                  If even an explicit console.log() isn’t caught, are you sure you have - effective - code review?

                                                                                                  (Saving the reviewer time by having the machine do it makes sense, of course!)

                                                                                                  1. 4

                                                                                                    It doesn’t matter how effective a code review is. Its still being done by a human, who are fallible. Even a NASA style code review has been known to let bugs through to “production”.

                                                                                              2. 4

                                                                                                Code review? Can’t you just never write bugs?

                                                                                                1. 2

                                                                                                  If you learn how to do that, I’ll buy the book! :D

                                                                                              1. 2

                                                                                                As far as I recall the greatest hurdle to applying these JIT-type techniques is the CPython maintainers explicitly wanting to keep such advanced techniques out of the CPython implementation for understandability reasons.

                                                                                                So this is a great list and all but what’s changed to mean that any of this plan will make it into the releases you say it will? And how did you get to “four distinct stages, each stage increasing the speed of CPython by (approximately) 50%” when none of the work has been done to show that that’s even possible?

                                                                                                The funding plan you give is more-or-less “it should be funded”. And there’s no mention in that repo of where this discussion with the CPython folk is happening.

                                                                                                1. 2

                                                                                                  you

                                                                                                  Note that I’m not the OP, just sharing this interesting-to-me plan.

                                                                                                1. 1

                                                                                                  FWIW Oil’s app bundle behaves like “true” and “false” just for kicks… Just like it behaves like “osh” and “oil”, in the style of busybox.

                                                                                                  As the post mentions, true and false are shells builtins, so you don’t need the executables in shell scripts. But what are the chances that some external program calls os.system("true")? Almost none, but they need to be there.

                                                                                                  So in theory on an Oil-based system you can just have symlinks to the Oil binary instead of another little hunk of C code that needs to be compiled.

                                                                                                  1. 11

                                                                                                    But what are the chances that some external program calls os.system("true")?

                                                                                                    I have system users with /etc/passwd shells set to /bin/false and I’ve definitely had occasion to do things like PAGER=/bin/true git log .... Little stuff like that comes up surprisingly often

                                                                                                    1. 1

                                                                                                      It’s more common to use /usr/sbin/nologin for that.

                                                                                                    2. 4

                                                                                                      Use hard links instead of symlinks for even better minimization of disk usage.

                                                                                                    1. 8

                                                                                                      Objective-C is refcounted. One way you can decrement a refcount is [obj release] and that does what you expect, destroying the object when the refcount hits 0. But if you’re writing Objective-C in the first place you’re probably using it via Cocoa or UIKit which is probably running you in an event loop. In this case you can instead [obj autorelease] which defers the refcount until this run of the event loop is over. The nice thing about that is that you can return very quickly from the current (probably interactive) action with your real work done and wait to do the bookkeeping work until you’d probably be waiting on I/O anyway.

                                                                                                      It would be nice if there were a way to structure rust arenas in such a way that the “current request”, whatever that means for your program, could gather up all of this pending work like this until you know you have some downtime. Or if you’re a short command line program, to never do it at all and wait for the process termination to clean everything up. This would really have to be at the language level since most of those drop insertions are going to be in third party library code.

                                                                                                      (I don’t write much Objective C or Swift and welcome corrections on the details)

                                                                                                      1. 2

                                                                                                        Isn’t rust able to do refcount as well? https://doc.rust-lang.org/std/sync/struct.Arc.html

                                                                                                        1. 4

                                                                                                          Yes but it isn’t a global “do refcounting everywhere”, it’s a utility function that lets you refcount a single object. You can’t force libraries to do it.

                                                                                                        1. 2

                                                                                                          I’ve heard a lot — and this is reiterated on the website — that fortran is supposedly quite fast. Why is that the case?

                                                                                                          1. 9

                                                                                                            Among the reasons: no pointer aliasing by default, intrinsic support for parallel array operations (do concurrent, forall, where loops; array ranges), easy access to OpenMP.

                                                                                                            1. 5

                                                                                                              Fortran does have some attributes that can make it fast (like no pointer aliasing) but generally what people are talking about is BLAS which was originally a library but now is more like an interface with many implementations and has several very fast implementations with hardware level optimisations like SIMD and even GPU. BLAS is the gold standard for performant linear algebra.

                                                                                                              1. 1

                                                                                                                It’s 63 years old. That’s a lot of room for optimization work.

                                                                                                                1. 1

                                                                                                                  Are you saying that my dad must be very optimised then? He sure needs a lot of medication to keep him going.

                                                                                                                  1. 3

                                                                                                                    Programming languages aren’t (directly) driven by biological processes. They don’t start failing/dying just because they are old.

                                                                                                              1. 2

                                                                                                                This is excellent work. I really like the line of thinking of mapping through soundex to remove words that sound similar and the alternating groups is even better as a quick checksum for missing words. It reminds me of rfc1751 which is a similar convention of turning bytes into words to be read aloud. I use rfc1751 in a project where I want to make it easier for humans to quickly glance at a fingerprint. In my case I use it to make output like

                                                                                                                === secrets.vm ===
                                                                                                                common name: secrets.vm
                                                                                                                fingerprint: b957e10c998faa9909cff3ba4ec35485d04708c3ecc7481fe14d7f07bc0229cd
                                                                                                                public key:  c15e697e4807793ef8a9461a7b2c6cf2266d1ec1480a594e83b54e7b75e07702
                                                                                                                public sign: f1db594eb55fe97657c57f2aa01afd1210a46d42d80d5552ac4d548162d4968e
                                                                                                                mnemonic:    AM ROBE KIT OMEN BATE ICY TROY RON WHAT HIP OMIT SUP LID CLAY AVER LEAR CAVE REEL CAN PAM FAN LUND RIFT ACME
                                                                                                                does that look right? [y/n]
                                                                                                                

                                                                                                                where the mnemonic is the rfc1751 reading of a sha256 hash of the three hex strings. It’s not perfect but I think it’s better for the glancability factor than the hex strings alone.

                                                                                                                One thing that might help both cases is to include some sort of chained checksum. That way if you’re reading over the phone into some decoding software it can tell you the moment you mistype something even if it’s a valid word. But I guess if you both have the encoding/decoding software you probably also have email clients.

                                                                                                                1. 2

                                                                                                                  If you haven’t used Charles, I highly recommend it. It’s really good. Maybe this is great too, I don’t know. But I’ve never regretted paying for Charles

                                                                                                                  1. 5

                                                                                                                    Another option is mitmproxy. Also open source, terminal and/or web interface, and it works great!

                                                                                                                    1. 2

                                                                                                                      What always puzzled me about Charles is the documentation is sparse and website isn’t updated. Is it still maintained and actively developed?