HNHacker News
TopNewBestAskShowJobs

bjz_

2,589 karma · joined April 19, 2013

- https://github.com/brendanzab - https://twitter.com/brendanzab
submissionscomments
bjz_··on Towards a Type System for Containers and AWS Lambda to Avoid Failures [pdf]
Interesting. Yeah, from what I understand the Erlang philosophy was to just throw out the idea of a type system and deal with faults dynamically, which is understandable given the time the language was created. But given what we've learned about type systems in the intervening years, it would be super nice to leverage a type system for this, and greatly reduce the testing overhead.

I'd love to see this in an event sourcing context too. This paper, “The Dark Side of Event Sourcing: Managing Data Conversion”, seems to hint at there being some interesting algebraic foundations to splitting and merging streams, adding new fields, etc: http://files.movereem.nl/2017saner-eventsourcing.pdf

bjz_··on Towards a Type System for Containers and AWS Lambda to Avoid Failures [pdf]
It's a bit like all the folks who recoil in horror when you say 'types' and all they can think of is Java.
bjz_··on Towards a Type System for Containers and AWS Lambda to Avoid Failures [pdf]
How are you going to handle updates and migrations of types? Something I've been thinking about in terms of dependently typed APIs is versioning and migration - but more at the code ecosystem level than in terms of running systems that can't be turned off. But there is kind of a similarity there. You can think of the ecosystem of written programs as kind of a distributed system. Would be nice to give library authors the tools to more gracefully migrate their consumers code in a type directed way, and to highlight potential problems prior to deployment, but this could equally apply in a distributed computing context.
bjz_··on Towards a Type System for Containers and AWS Lambda to Avoid Failures [pdf]
I'm really happy more work is being done in this space! Also nice to see nods to various attempts from the past - it's important we learn from their failings, but also their successes. It's too easy to get stuck in the mindset of "Ugh CORBA" and "noes, SOAP", without being able to see an opportunity there. Let's be persistent and figure this stuff out!
bjz_··on A Proposal for Package Versioning in Go
> I feel like Rust started out with solid dependency management in place, at least it's been there from the early days.

Rust had actually been through three failed package manager projects before they decided to bring in the domain experts at Tilde. Nice that at least that bit of churn has been forgotten - but yeah, it became obvious over that time just how non-trivial the problem is. Cargo makes it seem easy though ;)

bjz_··on 100 days with Rust: a series of brick walls
Yeah, much work is being done! As a long time user of Rust (for many years), I'm not super confident about using futures yet without the support of `impl Trait` - I mean, I could manage it, but I definitely would not want to inflict it on more sceptical coworkers. Thankfully this stuff is being worked on, and should be shipped in the not to distant future. The Rust team is great, and manages to get a huge amount done despite the many challenges in front of them! All while remaining positive and friendly! :)
bjz_··on Gallery of programming UIs
I came across the Alfa proof language recently (precursor to Epigram and Agda). Had this neat natural deduction editor: http://www.cse.chalmers.se/~hallgren/Alfa/Tutorial/ndstyle.h...
bjz_··on Overconfident Students, Dubious Employers
Agreed, and I think it's harmful to universities to expect that. We need universities to excel at what they are good at - preparing students to push the frontier of their field. They're not job factories for industry and shouldn't have to try to be.
bjz_··on Reason ML toolchain
Ah, that's great to hear!
bjz_··on Reason ML toolchain
Very bloated, lots of allocations, not compatible with other JS module systems, no uncurrying optimizations, no integer optimizations, etc. Bucklescript's output is pretty damn impressive on the other hand: https://reasonml.github.io/en/try.html (check out the factorial example, for instance)
bjz_··on Reason ML toolchain
Reason also has the benefit of Bucklescript which has very high-quality JS output - very friendly to VMs, and the rest of the JS tooling ecosystem. This is something where Elm is sadly lagging quite behind.
bjz_··on Return type polymorphism in Haskell
This is part of the reason why I still feel constrained when using systems where the type system is bolted on after the fact, like Typescript, Flow, or Dialyzer. You can gain so much leverage from the type system being able to generate code like this for you.

ML can do this, but you have to mention the module explicitly. OCaml's upcoming modular implicits will allow this with less boilerplate though.

bjz_··on Return type polymorphism in Haskell
This is one of the big things I miss from implementations of ad-hoc polymorphism in dynamically typed languages - for example protocols in Elixir or Clojure.
bjz_··on Why is Rust difficult?
I like to look beyond to other languages, like Idris, ATS, Sixten, F*, Lean, Koka, etc. Rust has many clunky parts that become more obvious through use, even though it is still my goto language. I find often the most zealous folks are those who come from scripting language or Java/C#-ish backgrounds, and have not yet delved further into the possibilities of static types and higher order abstractions.
bjz_··on Skia: an open source 2D graphics library
The Firefox and Servo team are currently hard at work on Pathfinder, which should solve this for both fonts and SVG. It'll run on the GPU like WebRender which is super exciting: https://github.com/pcwalton/pathfinder - alas it's still a WIP at the moment.
bjz_··on Skia: an open source 2D graphics library
There are many degrees of freedom to work on when it comes to mathematics, many perspectives to look at the same problem. Some are elegant, some are ugly, others are painful to work with, and make future progress hard. Just as it is with software. We constantly need to reassess our foundations, and not get too coupled to a single perspective, lest it drive us into a corner and stifle further innovation.
bjz_··on Rust in 2018: easier to use
> Not sure what you mean by "no forward references"?

I'm guessing they are talking about having implicit mutual recursion between items in a module, like Haskell has.

bjz_··on Rust in 2018: easier to use
> [1] I'd really like to see F# Computation Expressions instead of async/await. I know the language experts have said Haskell-like do notation doesn't work in Rust but I'm not sure if the F# tweaks would make it work or not.

I'd prefer a systems-y, zero-cost take on algebraic effects, similar to what OCaml is going to get. Could be much more extensible, and open things up to annotating whether functions panic or not, access global state, etc. Alas it's still a tricky research problem, even after all these years. There were some nice discussions from ICFP here - the comments strayed into talking about how effects might be implemented without a GC: https://www.youtube.com/watch?v=DNp3ifNpgPM

bjz_··on Rust in 2018: easier to use
The Rust Cookbook has made a start on this too! https://rust-lang-nursery.github.io/rust-cookbook/
bjz_··on Rust in 2018: easier to use
> and that all-important '&' gets lost in the verbosity

Perhaps some console colouring could help as well. I'd really like some type diffs on type mismatch errors (I think Dotty has this?). That could be super handy for quickly diagnosing errors - speaking as a reasonably experienced Rust user here.

bjz_··on Rust in 2018: easier to use
> Kakoune uses a clippy ASCII art for its immediate help, it's nice.

Had to look this up - very cute!

https://github.com/mawww/kakoune#screenshots

https://raw.githubusercontent.com/mawww/kakoune/master/doc/s...

bjz_··on Linear types can change the world (1990) [pdf]
> Which, y'know, good luck with that.

Most dependent type systems like Agda, Coq, Idris, Lean, and ATS have termination checking, so it is possible! They can't determine whether arbitrary programs terminate, but you can capture a large subset of programs. Turns out most code doesn't actually need Turing completeness.

bjz_··on Crystal 0.24.1 released
It takes a long time to build a language. Rust was in development for many years, and it has had the benefit of backing by Mozilla.
bjz_··on Clean – A functional programming language
> it is so easy to lose track of which "if" a nested "else" belongs to when modifying code, and, I've seen this being the source of so many bugs, that it has changed my opinion about whitespace-significant languages.

Having types and removing statements from the language make this much less of an issue

> I can let go of the syntax, just write and focus on my ideas and let my editor sort the mess at the end.

Elm has a whitespace significant syntax, but it too has an excellent code formatter tool.

bjz_··on Ask HN: CS and programming books of 2017
TDDwI is much more focused on more common programming problems than SF and using it like a general purpose language. Don't get me wrong, I love SF, but it might complement it, and be worth coming back to SF after TDDwI.
bjz_··on Ask HN: CS and programming books of 2017
Type-Driven Development with Idris: https://www.manning.com/books/type-driven-development-with-i...
bjz_··on Integrating “safe” languages into OpenBSD?
/r/rust is actually one of the better ones, thankfully.
bjz_··on Woman with Transplanted Uterus Gives Birth, the First in the U.S
I wish it didn't have to be one or the other. I guess it's human nature to tend towards thinking that choices have to be binary - I've often been guilty of it myself. Whenever somebody makes a choice that is different to our own we fear that it might dilute the possibility of us making our own choices, and so we become hostile. But it's important we work against this tendency.

I'm hoping that we'll be able to work towards a world have a world where stay-at home dads, stay-at home mums, surrogate pregnancies, same-sex parents, dual parental leave, etc, are all valid choices for bringing up children.

bjz_··on Type-safe GraphQL with OCaml
> The second is a good concurrency story, ideally one that is compatible with JS-style async/await keywords for easy interop

Algebraic effects are also in the works which will help with stuff like async/await, but works over arbitrary effects (not just async). Like monads but nicely composable without the ickiness of MTL. Alas it's still unclear what the ETA is. :( Something I'm really looking forward to!

https://www.reddit.com/r/ocaml/comments/63hgid/tracking_mult...

bjz_··on What's a reference in Rust?
Yeah, interestingly I think it's hard to understand what is going on with C because `T*` pointers can be used for many things. I found it easier to go to C after doing Rust because I had a deeper understanding of the semantics behind them. Was frustrating though because it never caught my mistakes!
← PreviousPage 5 of 25Next →