Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→
Page 1 .. 541 542 543 544 545 546 547 548 549 550 551 .. 5022
502,152 events total
2020-10-09 19:10:23 <koz_> And in this case, it's 100% possible.
2020-10-09 19:10:41 crossw1nd joins (~crosswind@188.73.195.239)
2020-10-09 19:11:30 × whiteline quits (~whiteline@unaffiliated/whiteline) (Remote host closed the connection)
2020-10-09 19:11:47 whiteline joins (~whiteline@unaffiliated/whiteline)
2020-10-09 19:11:55 <Guest18> Well, it's not error prone, because i am guaranteed that depth will never return Nothing in my list comprehension
2020-10-09 19:12:07 <Guest18> but i see why it isn't efficient
2020-10-09 19:12:20 <dsal> dwts: I really like haskellbook.com -- it's easier if you pretend that you're new to programming
2020-10-09 19:12:59 <Guest18> I am going to get back to you with a better solution
2020-10-09 19:13:19 × nbloomf quits (~nbloomf@2600:1700:83e0:1f40:c588:f17e:f3e:2fb3) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-10-09 19:13:26 <Cale> Guest18: It's often error prone in that while your code might satisfy the precondition to not have fromJust crash when you write the fromJust, future changes to the code often result in fromJust being applied to Nothing, and they're a total pain to deal with
2020-10-09 19:13:26 × cr0ssw1nd quits (~crosswind@adsl-174.176.58.193.tellas.gr) (Ping timeout: 256 seconds)
2020-10-09 19:13:38 <Cale> > fromJust Nothing
2020-10-09 19:13:41 <lambdabot> *Exception: Maybe.fromJust: Nothing
2020-10-09 19:13:44 <Cale> ^^ this is all you get at runtime
2020-10-09 19:13:54 <Cale> Note the lack of a source location to help you
2020-10-09 19:14:06 <Cale> I would actually usually prefer to write (\(Just x) -> x)
2020-10-09 19:14:10 <Cale> just because...
2020-10-09 19:14:18 <Cale> > (\(Just x) -> x) Nothing
2020-10-09 19:14:20 <lambdabot> *Exception: <interactive>:3:2-15: Non-exhaustive patterns in lambda
2020-10-09 19:14:37 <Cale> ^^ that will include the file and line number of the lambda which failed to match
2020-10-09 19:14:50 nbloomf joins (~nbloomf@2600:1700:83e0:1f40:744e:3fd6:7740:f62b)
2020-10-09 19:14:56 <Guest18> Although, I must say, I was getting errors non-stop when i started with haskell, but now, i kinda get some things and i start to understand where the ghc has a problem and know how to fix it. It is really satisfying to write haskell :))
2020-10-09 19:15:23 <Guest18> Cale: I see, good to know! Thanks!
2020-10-09 19:15:32 <Cale> Yeah, generally the type system makes refactors a lot more manageable -- you learn to rely on the errors that the compiler is going to give you
2020-10-09 19:15:52 <Cale> You can just change something and let the compiler figure out most of the consequences
2020-10-09 19:15:58 <ski> dsal : i suspect they didn't want to pretend that. (especially since they come from Scheme)
2020-10-09 19:16:42 <dsal> Yeah, scheme might be a more gentle approach vector.
2020-10-09 19:16:58 <Guest18> Cale: yees, i so love it. I dread working with normal, idiomatic C# now, I much favor using functional constructs in it now
2020-10-09 19:17:40 <Guest18> One of these days, I am gonna suggest to my boss to maybe let me work in F#
2020-10-09 19:18:15 thir joins (~thir@p200300f27f02580060eb7dde324e54c8.dip0.t-ipconnect.de)
2020-10-09 19:19:04 × ashbreeze quits (~mark@72-161-255-112.dyn.centurytel.net) (Ping timeout: 272 seconds)
2020-10-09 19:19:05 <Guest18> I heard F# is pretty good actually, what do you think?
2020-10-09 19:19:43 _ashbreeze_ joins (~mark@72-161-255-112.dyn.centurytel.net)
2020-10-09 19:20:41 <koz_> As far as I am aware, F# is basically .NET's Scala.
2020-10-09 19:20:59 <dsal> Isn't F# ocaml?
2020-10-09 19:21:20 <dsal> I don't know much about microsoft.
2020-10-09 19:21:25 <dolio> It's more like ocaml than scala, I think.
2020-10-09 19:21:26 <Guest18> dsal: that's what i heard, and seeing it, yeah, it is very similar to ocaml
2020-10-09 19:21:39 <koz_> dolio: Yeah, that's a fair call.
2020-10-09 19:22:27 × thir quits (~thir@p200300f27f02580060eb7dde324e54c8.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-10-09 19:22:36 <dolio> It's missing a lot of ML stuff, though.
2020-10-09 19:22:58 <dolio> Or maybe not a lot, but what it's missing is significant.
2020-10-09 19:23:04 <Guest18> like what?
2020-10-09 19:23:11 <dolio> The module system.
2020-10-09 19:23:49 <Guest18> it does have modules though
2020-10-09 19:24:32 <dolio> It doesn't have ML style modules.
2020-10-09 19:25:26 <aldum> anyone know about F*?
2020-10-09 19:26:01 <aldum> allegedly it's an even more advanced functional lang from MS, but there's not much out there about it
2020-10-09 19:26:14 <Guest18> never heard of it
2020-10-09 19:26:17 <monochrom> Oh, if you already have a Scheme background, then "a gentle introduction to haskell" ought to do.
2020-10-09 19:26:22 GyroW joins (~GyroW@d54C03E98.access.telenet.be)
2020-10-09 19:26:22 × GyroW quits (~GyroW@d54C03E98.access.telenet.be) (Changing host)
2020-10-09 19:26:22 GyroW joins (~GyroW@unaffiliated/gyrow)
2020-10-09 19:27:49 × GyroW_ quits (~GyroW@unaffiliated/gyrow) (Ping timeout: 264 seconds)
2020-10-09 19:29:27 <dminuoso> It's very gentle.
2020-10-09 19:29:31 <dminuoso> The name isn't totally misleading.
2020-10-09 19:29:39 <monochrom> \∩/ "In the rest of the paper we will often say “more polymorphic than” instead of the more precise but clumsier “at least as polymorphic as”." I have always wanted to do that.
2020-10-09 19:29:42 dminuoso stops with the tongue-in-cheek
2020-10-09 19:30:05 ashbreeze joins (~mark@72-161-253-2.dyn.centurytel.net)
2020-10-09 19:30:18 <monochrom> It is gentle if you're OK with Scheme or ML or ...
2020-10-09 19:30:21 wroathe_ joins (~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-10-09 19:30:30 <dminuoso> It's still not, really.
2020-10-09 19:31:27 <dminuoso> I'd say the type system, lack-of-IO-purity and lazyness make for a pretty wild experience, even from Scheme.
2020-10-09 19:31:27 × chenshen quits (~chenshen@2620:10d:c090:400::5:7709) (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
2020-10-09 19:32:01 × wroathe quits (~wroathe@c-73-24-27-54.hsd1.mn.comcast.net) (Ping timeout: 264 seconds)
2020-10-09 19:32:07 × bifunc2 quits (bifunc2@gateway/vpn/protonvpn/bifunc2) (Quit: -)
2020-10-09 19:32:35 <dminuoso> The gentle introduction is just a very brief rush over Haskell that works well enough for someone who comes from say Idris.
2020-10-09 19:32:52 <dminuoso> It doesn't teach the language at all
2020-10-09 19:32:56 <dolio> I read it after learning Scheme.
2020-10-09 19:33:03 × _ashbreeze_ quits (~mark@72-161-255-112.dyn.centurytel.net) (Ping timeout: 260 seconds)
2020-10-09 19:33:06 <monochrom> It worked very well for me, and Idris didn't exist when it worked for me.
2020-10-09 19:33:42 <dsal> I played with haskell for years and even had some useful not-completely-trivial programs, but it wasn't until I suspended prior knowledge that understanding got a lot easier.
2020-10-09 19:34:49 <dminuoso> monochrom: Says the professor in comp sci.
2020-10-09 19:34:51 <dminuoso> ;)
2020-10-09 19:34:54 <monochrom> nor Agda. Coq existed but I wasn't patient with it, I gave up after a few simple propositions.
2020-10-09 19:35:10 × cole-h quits (~cole-h@c-73-48-197-220.hsd1.ca.comcast.net) (Quit: Goodbye)
2020-10-09 19:35:36 <monochrom> For the type system you could point towards me having done ML before I ran into Haskell.
2020-10-09 19:36:01 <monochrom> But how the hell did I grok ML's type system in the first place, after only Scheme and Pascal?
2020-10-09 19:36:14 <monochrom> Well I guess I also met Ada.
2020-10-09 19:36:32 <dolio> I didn't do ML first.
2020-10-09 19:36:35 <monochrom> and C++ templates
2020-10-09 19:37:48 <ski> monochrom : with Ada generics ?
2020-10-09 19:38:02 <monochrom> My feeling is that, eg, Hutton's and Bird's are only more wordy, and more examples, than the gentle introduction. But not gentler.
2020-10-09 19:38:06 <monochrom> Yeah
2020-10-09 19:38:25 × darjeeling_ quits (~darjeelin@122.245.210.138) (Ping timeout: 240 seconds)
2020-10-09 19:39:15 <monochrom> Those books feel gentler because the wordy fillers forces you to spend 500 pages of time over what could be said in 10 pages such is in the gentle introduction.
2020-10-09 19:39:45 × jollygood2 quits (~bc8165ab@217.29.117.252) (Ping timeout: 240 seconds)
2020-10-09 19:40:02 <monochrom> This means if you consume the gentle introduction at the slow rate of, like, one afternoon per paragraph, then it's gentle.
2020-10-09 19:40:09 <monochrom> And I think I did exactly that.
2020-10-09 19:40:41 darjeeling_ joins (~darjeelin@122.245.210.138)
2020-10-09 19:40:47 <dminuoso> I think its highly situational
2020-10-09 19:40:54 <dwts> dsal: let me check that - thanks
2020-10-09 19:41:33 <dolio> If you already know how to write scheme programs, it seems like enough to start messing around.
2020-10-09 19:41:44 <dolio> It won't teach you everthing about every situation, obviously.
2020-10-09 19:41:47 × geekosaur quits (82659a05@host154-005.vpn.uakron.edu) (Remote host closed the connection)
2020-10-09 19:43:19 <dsal> dwts: When I started learning Haskell for real, I had production code in c, c++, objective c, ocaml, java, scheme, perl, tcl, erlang, ruby, r, and probably something else I forgot. Tossing another language on seemed like no big deal.
2020-10-09 19:43:49 <dsal> Haskell isn't hard fundamentally. People build a lot of seemingly complex things in Haskell, but that's because it's easy. :)
2020-10-09 19:44:48 leungbk joins (~user@2605:e000:1315:706:ec37:30e1:3998:1459)
2020-10-09 19:44:52 <dsal> I realized I never had any production Eiffel. I built a postgres replication system in it, but clearly I never made anything I thought was useful enough.
2020-10-09 19:46:11 <dwts> dsal: I can't yet have an opinion if it's hard or not, but I need to get a better understanding on the function definitions (and how to read them e.g. when reading the haskell docs). Functional programming is not new to me as I've played with scheme before, but I tend to find the parentheses much more readable (so far)

All times are in UTC.