Elektrine lite

← Feed

@fay59@tech.lgbt

Post #3433365

2026-06-27 19:14 UTC

@joe@f.duriansoftware.com @fclc@mast.hpc.social yeah, what I’m thinking is that at function boundaries you discourage AP integers, and you diagnose in places that the compiler cannot tell the upper bound of your integer. The diag is resolved by converting to a fixed-size integer type. Conversions that are known to succeed all the time Just Work, and if the compiler doesn’t know then you need to explicitly ask for truncation or an optional result

Replies (1)

  • @joe@f.duriansoftware.com 2026-06-27 19:17

    @fay59@tech.lgbt @fclc@mast.hpc.social my back-of-the-napkin design for this is basically exactly that, but I don’t think you need to let AP integers be reified at all necessarily, you can say that they are only allowed to exist as local variables or as parameters/returns of constant-evaluable functions

    Open ##3433364