Haskell

jaror, in Bytestring-0.11.5.0 and bytestring-0.12.0.0
jaror avatar

Interesting that they consider removing a rewrite rule to be a breaking change.

jaror, in Hierarchical string diagrams and applications
jaror avatar

I know this is not directly related to Haskell and it uses a lot of category theory. But I think at least the introduction is relatively readable and already has some interesting observations, such as the criterions to compare notations:

A notation is better if it absorbes more equations, by which we mean that instead of using an explicit equation to identify two terms they become syntactically equal in the improved notation.

A superior notation absorbs more invariants, so that malformed terms cannot be written as such.

And their ultimate goal:

The ultimate aim of this tutorial is to persuade the reader to accept a new and multifaceted vision of syntax which we (rather grandly) call syntactic trinitarianism: terms, diagrams, graphs.

I would love a visualization tool for Haskell that converts terms into diagrams.

jaror, in [RFC] Bumping recommended GHC to 9.4.5 in GHCup
jaror avatar

I was still mainly using 9.2.8 since that is still the default on nixos unstable. But I think 9.4.5 seems stable enough to recommend.

kleidukos, in Monthly Ask Anything (July 2023)

Why must FinalizerPtr take a foreign function that uses the ccall calling convention? Is there a concrete thing preventing GHC from accepting capi?

glguy,

I suspect that comment predates the existence of capi and is trying to avoid having some other actual calling convention like stdcall because the function pointer is actually invoked from some C code in the RTS. capi is a sort of pseudo-calling-convention in that it generates some C code and then calls that stub.

Have you tried using a capi defined funptr there to see what happens?

kleidukos,

Thank you, that's indeed a reasonable suspicion. I haven't tried because this is for a PR that's been submitted to me and I actually have no idea how this could blow up in my face later (or even worse, not blow up an silently corrupt stuff)

kleidukos,

I have my answer: cAPI is fine: https://gitlab.haskell.org/ghc/ghc/-/issues/23599

fonnyx, in Testing federation

test

alphadog, in Testing federation

Wow, very cool. Thanks for participating in my experiment. :)

theGhostJW, in GHC activities report: April–May 2023

Thanks to all the ghc devs for all your hard work! The continued work on refactoring, error messages, runtime-retargetable ghc and Exception Backtrace Proposal all bode for a bright future for GHC.

someacnt, in Testing federation

Hello from kbin as well!

Zoroastyyr, in Testing federation

Hello from Lemmy.world!

Cyzaine, in Testing federation
Cyzaine avatar

Hi from Kbin!

jaror, in Testing federation
jaror avatar

It seems to work :D

treeowl, in Bitstring manipulation

I think your version is arguably even more confusing, though I certainly wish we had something clearer. If you can suggest something clearer and equally fast available using extant primitives/instructions, I'm all ears and will happily make the change.

jaror,
jaror avatar

I guess you could express it more Haskelly like:

padL 64 1 (cons 1 (takeWhileR (== 0) x))

(if we consider bitstrings to be Seq Bit and I hope that padL speaks for itself)

Would that be less confusing? Or can you try to explain what you find confusing?

romes, in Bitstring manipulation

I like the discussion, but I'm not sold on the solution :).

In particular, the {n+1} bit is not immediatly clear to me, it seems like the number of original number of bits is increasing hah!

jaror,
jaror avatar

Good point. I was thinking of transformation that preserve the length of the bitstring like if you're dealing with a type like Word64. Otherwise perhaps you could be more specific about it like this:

.{m}10{n} -> 1{m}0{n+1}
someacnt, in Monthly Ask Anything (June 2023)

Why is this place still so silent? Maybe because people are resistant to visiting lemmy?

jaror,
jaror avatar

There are only 19 subscribers as of now. Usually, I think the number of lurkers far outnumbers those who actively participate. But I agree that more activity would be nice.

By the way, this isn't a Lemmy instance. Kbin is a separate thing. But it does federate with Lemmy, so you might see some Lemmy content popping up on Kbin.

AphonicChaos, in Introduce Yourself

Do code-blocks work better than on reddit for mobile?

Fenced code block:

module Main where

main :: IO ()
main = do
    putStrLn "Hello, kbin!"

Indented 4 spaces:

module Main where

main :: IO ()
main = do
    putStrLn "Hello, kbin!"

update: Oh wow, looks like only inline code fragements work? Something like main = putStrLn "Hello, kbin!"
update 2: No syntax highlighting at all! That's probably a show-stopper.

jaror,
jaror avatar

AFAIK Reddit also doesn't have syntax highlighting, or does it? The blocks and inline code in your comment does render in a monospace font, so that's a good first step. I also believe kbin is still very new and might get more features like syntax highlighting in the future.

AphonicChaos,

You're right! I think the difference is that reddit puts a background around code so it stand out from "regular" text.

jaror,
jaror avatar

Styling for code blocks has been merged: https://codeberg.org/Kbin/kbin-core/pulls/494. I hope it goes live here soon.

jaror,
jaror avatar

@AphonicChaos the update has landed! Your code now has a dark grey background.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • haskell
  • kavyap
  • DreamBathrooms
  • modclub
  • tacticalgear
  • GTA5RPClips
  • magazineikmin
  • thenastyranch
  • Youngstown
  • InstantRegret
  • rosin
  • slotface
  • everett
  • mdbf
  • cubers
  • JUstTest
  • ngwrru68w68
  • normalnudes
  • cisconetworking
  • Durango
  • khanakhh
  • Leos
  • ethstaker
  • tester
  • anitta
  • osvaldo12
  • megavids
  • provamag3
  • lostlight
  • All magazines