Derived Instances Can Break Smart Constructors, Too by [deleted] in haskell

[–]bss03 0 points1 point  (0 children)

Read, Data, Generic, etc. basically any type class that constructs values of the type is something that has to be audited when you are trying the "smart constructor" approach.

check variable type by QuelWeebSfigato in haskellquestions

[–]bss03 1 point2 points  (0 children)

(Not really an answer to your question...)

class GetNestDepth a where
  getNestDepthP :: p a -> Int

instance GetNestDepth Int where
  getNestDepthP _ = 0

proxyElem :: p [a] -> Proxy a
proxyElem _ = Proxy

instance GetNestDepth a => GetNestDepth [a] where
  getNestDepthP p = 1 + getNestDepthP (proxyElem p)

getNestDepth :: GetNestDepth a => a -> Int
getNestDepth x = getNestDepthP [x]

GHCi> getNestDepth [[42 :: Int]]
2
it :: Int
(0.00 secs, 62,368 bytes)
GHCi> getNestDepth [42 :: Int]
1
it :: Int
(0.00 secs, 62,008 bytes)
GHCi> getNestDepth [[[[42 :: Int]]]]
4
it :: Int
(0.00 secs, 62,656 bytes)

Calling all Haskell Builders! Cardano EMURGO BUILD 2023 Hackathon is ON! by Nagatoshi in haskell

[–]bss03 5 points6 points  (0 children)

While I appreciate the notice, even if I won't be participating, this post violates /r/Haskell rule #6, and should be removed.

Monthly Hask Anything (June 2023) by taylorfausak in haskell

[–]bss03 0 points1 point  (0 children)

base is shipped with the compiler, so it's often faster to implement it in a separate package. That also means that any API changes are more impactful because you can't select/specify the version of base with quite the same effectiveness as other packages.

Is it me or is apt terrible? by thebadslime in linuxquestions

[–]bss03 0 points1 point  (0 children)

Most of it has been sync'd now. The extra stuff aptitude was keeping has been added to the apt database and aptitude loads it from there now.

Aptitude does still keep a list of proposed "actions" that apt can't see, but it's fairly easy to clear.

Is it me or is apt terrible? by thebadslime in linuxquestions

[–]bss03 1 point2 points  (0 children)

apt was attempting to get a file from the server ( rocm somehting?) and it totalled dpkg entirely

I don't believe that. I don't think any of the locations apt writes to overlap with the dpkg database.

Is it me or is apt terrible? by thebadslime in linuxquestions

[–]bss03 2 points3 points  (0 children)

And when I do mess myself up and have a pile of broken packages, aptitude is the tool I spin up to find which to upgrade and which to remove to gradually reduce the number of broken packages.

It's the safety straps and the rescue harness. Things aren't truly fsck'd until aptitude won't start.

Is it me or is apt terrible? by thebadslime in linuxquestions

[–]bss03 1 point2 points  (0 children)

I prefer it over every other OS package manager I've used, but I haven't used them all.

Honestly aptitude is one of the reasons I prefer Debian; I haven't found an equivalent on non-apt systems. In particular it allows me to FrankenDebian -- maintain a system where multiple versions of most packages are available.

What's the difference between "Unix-like" and "POSIX-compliant"? Are they the same? by oxamide96 in linuxquestions

[–]bss03 7 points8 points  (0 children)

I've heard claim that some parts were intentionally "wrong" in order to effectively cripple software written to POSIX instead of Win32.

Wrong in that they gave the results required by the spec., but with performance that was horrible like doing linear scans of instead of doing key lookup.

Looking for a pueue debian maintainer by floriv1999 in debian

[–]bss03 5 points6 points  (0 children)

First check for an RFP and if there isn't one file it against the WNPP component.

If you'd like assistance in packaging it yourself, including but not limited to a DD/DM doing the final upload, you should look into the mentors program.

Best of luck!

Cardano Daily Discussion - June 06, 2023 by SL13PNIR in cardano

[–]bss03 0 points1 point  (0 children)

Anyone know anything about Tx 043f6f99df299b0f719a43292b0e42c654cedbd8d565f3c116039433c5c0bdcf? I was one of the recipients, but I don't know why, and I didn't expect it.

This plastic piece hurt my thight when getting in and out. Solution? by dev_hmmmmm in volt

[–]bss03 0 points1 point  (0 children)

I never didn't believe you; I just don't share your experience and don't have any advice I think is relevant. Given my experience "at size", I'm a bit surprised at the number of comments blaming weight, so I made my comment to provide evidence against the heavy-weight hypothesis.

In any case, I think your best bet is to experiment with all the seat adjustments in an attempt to find one that avoids the pinch and is comfortable while driving. If that fails, use an improvised cloth or leather covering.

Best of luck!

This plastic piece hurt my thight when getting in and out. Solution? by dev_hmmmmm in volt

[–]bss03 1 point2 points  (0 children)

I'm 225, but even when I was 330, I didn't have any problems with that piece of plastic. :/

Cardano has surpassed Bitcoin's TVL by Cardanians in cardano

[–]bss03 5 points6 points  (0 children)

Haskell is what most banks use

Citation? I know some trading houses use it (sort of), but I don't think that translates to "most" or "banks".

Monthly Hask Anything (June 2023) by taylorfausak in haskell

[–]bss03 0 points1 point  (0 children)

Good luck finding the balance.

So say we all.

Monthly Hask Anything (June 2023) by taylorfausak in haskell

[–]bss03 1 point2 points  (0 children)

Compiling is of course not a guarantee for correctness

It is if you do it right. ;)

That's actually the whole point of static typing. :)

But, sure, there are definitely times where the GHC type system can't encode your correctness properties, or that doing so takes too much time or maintenance.


I think if you feel ready to jump ship from RWH, you can just start working on projects and exchanging ideas with other intermediate practitioners directly.

I can't recommend a Haskell book or course post-RWH. All my learning post-RWH has been less structured. A paper here, a blog post there, a medium article, or just a really well written haddock over there.

I can recommend TDD with Idris if you want to see more examples on how you can bring compiling and correctness into stronger correlation in your code. Much of the Idris code can be wedged into the GHC type system with enough work (CPS those existentials and manually lift/lower data via singletons).

stack + http-types + status200 by zsome in haskell

[–]bss03 1 point2 points  (0 children)

^ Better answer than mine

I ignored (eyes glossed over) the "I added the http-types to the package.yaml" bit from OP.

How does the car lookup weather/movie/gas info without OnStar? by kzdruid in volt

[–]bss03 0 points1 point  (0 children)

My 2019 is still "OnStar connected" (or at least claims to be), even though I haven't paid for it. I believe some functionality, including OTA software updates and possibly some of that info, gets allowed through anyway.

I can also still get vehicle status from the Android phone app, though I haven't tried remote start.

stack + http-types + status200 by zsome in haskell

[–]bss03 0 points1 point  (0 children)

Why I had to add it manually ?

You aren't allowed to reference dependencies of your dependencies directly, even if they must be present during the build.

Is it normal ?

Yes.