00:16:07 | * | darkf joined #nimrod |
00:43:17 | * | kshlm joined #nimrod |
00:58:42 | * | brson quit (Ping timeout: 246 seconds) |
01:02:21 | * | jhc76 quit (Quit: Leaving) |
01:17:47 | * | kshlm quit (Ping timeout: 272 seconds) |
01:32:27 | * | johnsoft quit (Ping timeout: 255 seconds) |
01:32:46 | * | johnsoft joined #nimrod |
01:48:02 | * | saml_ joined #nimrod |
02:02:20 | * | EXetoC quit (Quit: WeeChat 1.0.1) |
02:43:10 | * | xenagi quit (Read error: Connection reset by peer) |
02:43:27 | * | xenagi joined #nimrod |
02:44:02 | * | will quit (Ping timeout: 245 seconds) |
02:46:23 | * | noam_ joined #nimrod |
02:47:48 | * | rpag quit (Quit: Leaving) |
02:49:13 | * | CARAM_ joined #nimrod |
02:49:44 | * | milosn_ joined #nimrod |
02:54:00 | * | noam quit (*.net *.split) |
02:54:01 | * | milosn quit (*.net *.split) |
02:54:01 | * | CARAM quit (*.net *.split) |
02:54:02 | * | vissborg quit (*.net *.split) |
02:54:03 | * | phI||Ip_ quit (*.net *.split) |
02:54:03 | * | Amrykid quit (*.net *.split) |
02:54:03 | * | EastByte quit (*.net *.split) |
02:54:28 | * | Amrykid joined #nimrod |
02:54:40 | * | phI||Ip joined #nimrod |
02:58:06 | * | CARAM_ is now known as CARAM |
02:58:26 | * | darkf quit (Read error: Connection reset by peer) |
03:00:03 | * | darkf joined #nimrod |
03:04:25 | * | EastByte joined #nimrod |
03:06:19 | * | vissborg joined #nimrod |
03:35:43 | * | bjz joined #nimrod |
03:52:57 | * | gokr quit (Ping timeout: 272 seconds) |
04:11:27 | * | xenagi quit (Quit: Leaving) |
04:20:26 | * | gokr joined #nimrod |
04:42:20 | * | nande quit (Remote host closed the connection) |
05:06:06 | * | saml_ quit (Ping timeout: 240 seconds) |
05:15:40 | * | bjz quit (Ping timeout: 250 seconds) |
05:40:38 | * | MyMind quit (*.net *.split) |
05:40:39 | * | comex quit (*.net *.split) |
05:44:26 | * | johnsoft quit (Ping timeout: 255 seconds) |
05:45:10 | * | johnsoft joined #nimrod |
05:46:09 | * | MyMind joined #nimrod |
05:46:09 | * | comex joined #nimrod |
05:46:38 | * | MyMind quit (Max SendQ exceeded) |
05:48:05 | * | MyMind joined #nimrod |
06:04:44 | Varriount | gokr: Very well written article. I like your 'conversational' writing style - it really brings personality to the article, and makes it interesting to read. |
06:05:39 | Varriount | gokr: I'd like to make some clarifications though - the nimrod code you show is written in something of a nontypical style. |
06:09:34 | * | darkf_ joined #nimrod |
06:09:57 | * | darkf quit (Ping timeout: 260 seconds) |
06:11:24 | Varriount | gokr: Procedure arguments without explicit types are implicitly given the 'expr' type, making them something like compile time templates/generics. Using procedures this way *might* lead to some odd behavior - I don't know any specifics, as untyped parameters are rarely used. |
06:13:51 | Varriount | This actually brings up a question that should be covered in the style guide - when should implicitly typed parameters be used? (Style guide is at https://github.com/Araq/Nimrod/wiki/NEP-1-:-Style-Guide-for-Nimrod-Code if you want to have a look) |
06:16:29 | Araq | Varriount: they shouldn't be used unless you're hacking something together |
06:16:57 | Varriount | Araq: Why? |
06:17:47 | Araq | because I wanna change their semantics |
06:18:17 | Varriount | Araq: How do you want to change their semantics? |
06:18:34 | Araq | so that the type is inferred instead of generalized |
06:19:27 | Varriount | Araq: Inferred from the procedure body? |
06:21:33 | Araq | yup |
06:21:42 | * | darkf_ is now known as darkf |
06:22:28 | Varriount | Araq: That sounds rather complex. Whats the reason behind the change? |
06:23:39 | Araq | it's more intuitive and I think excessive generics lead to code bloat |
06:26:00 | Varriount | Araq: But from a user's point of view, the use of implicitly typed parameters - to construct code without verbose typing - hasn't changed. |
06:26:53 | Araq | that's not true once you consider auto-complete |
06:27:17 | Araq | auto-complete works much better when not in a generic |
06:28:23 | Varriount | That rather relies on auto-complete (as well as the whole CaaS functionality) working well. :3 |
06:28:29 | Varriount | I also don't understand how one way leads to code bloat while the other doesn't. |
06:31:13 | Araq | proc foo(x, y: generic) |
06:31:19 | Araq | foo(3, 2) |
06:31:31 | Araq | foo(3.0, 2.9) # 2 instantations |
06:31:43 | Araq | proc bar(x, y: inferred) |
06:31:56 | Araq | bar(3,4) # calls float version |
06:32:20 | Araq | bar(3.0, 2.9) # calls float version, 1 "instantiation" |
06:32:37 | Araq | well it's rather unrealistic |
06:32:51 | Araq | most procs are only called once anyway |
06:33:24 | Varriount | I wonder how this works out according to type theory. |
06:34:02 | Varriount | Anyway, I have to go to sleep. Goodnight. |
06:36:35 | Araq | ok thanks for the minimal mingw |
07:01:10 | gokr | Varriount: Ah, thanks! Yeah, its the first lines of Nim I have written :) |
07:03:04 | gokr | Araq: Ah, more type inference? Nice |
07:05:30 | gokr | I did wonder about some small details - like why I get away with "timeToRun(() => benchmark(10000))" but using proc syntax it ended up as "timeToRun(proc():int64 = benchmark(10000))" IIRC. |
07:10:58 | Araq | => uses 'auto' as return type, i think |
07:11:22 | gokr | Ok, I need to read up more in the manual :) |
07:12:15 | gokr | I experimented just now a bit... so ideally I would like timeToRun to be typed as say "timeToRun(bench: proc) :float" |
07:12:27 | gokr | Since it uses discard anyway (it doesn't care what the proc returns). |
07:13:37 | gokr | And then call it like say "timeToRun(proc() = discard benchmark(10))" |
07:14:46 | gokr | But that doesn't fly. I get "expression 'bench()' has no type (or is ambiguous)" even though that line says "discard bench()" |
07:15:00 | gokr | So clearly I need to read the manual more ;) |
07:15:44 | gokr | Araq: Very interesting language, I am a die hard Smalltalker and almost immune to getting excited about statically typed languages. But Nim has gotten my interest. |
07:17:05 | * | Trustable joined #nimrod |
07:17:22 | gokr | And I am amazed I didn't find it when I wrote my "summary of new langs since 2000" article. |
07:17:33 | gokr | Given that its been around since at least 2008, right? |
07:23:38 | Araq | yeah |
07:24:09 | * | BlaXpirit joined #nimrod |
07:25:54 | Araq | Nim is the underdog |
07:26:55 | Araq | the underdog that prevents deadlocks at compile time, ... Rust cannot do this ... but *shrug* we have no one for marketing |
07:27:35 | gokr | Well, a bit of blogging can go a long way. |
07:27:51 | gokr | Btw, I asked if there was a planet nim, is there? |
07:28:07 | Araq | no idea what that even means ;-) |
07:28:09 | Triplefox | planet nim...what aliens live there |
07:28:20 | gokr | And oh, I am probably the millionth asking - why no regular mailing list? |
07:28:24 | gokr | I do hate web forums :) |
07:28:49 | gokr | Oh, so a "planet" is typically a site called planet.nim-lang.org - which runs an RSS aggregator. |
07:28:53 | Triplefox | oh i remember haxe going through that one...some people want an ml, some want forums...there is no agreement |
07:29:37 | gokr | I am 45 and... I dunno, we old dogs are like on ... 10-20 mailing lists and its IMHO a much more effective way to track. |
07:30:10 | gokr | But no biggie, just curious. |
07:30:44 | gokr | Example of planet (mono): http://www.go-mono.com/monologue/ |
07:31:46 | gokr | Or http://planet.smalltalk.org (which I just spammed with the Nim article apparently) |
07:33:54 | gokr | Further, if one would like to spice up documentation - readthedocs.org seems to be quite popular in many open source projects these days. Uses Sphinx AFAICT. |
07:34:07 | gokr | (I recall someone asked about pdf manual) |
07:35:07 | Araq | there is a pdf version of the manual |
07:35:13 | Araq | but it currenly doesn't build anymore |
07:35:48 | Araq | we don't need sphinx, we have our own docgen also based on RST |
07:36:58 | gokr | reStructuredText? |
07:38:11 | gokr | Duh, sorry, I ... thought Sphinx was something different - it also uses rST, ok, nice. |
07:47:36 | gokr | Araq: So much fun stuff to explore - just want to say thanks, I can see the amount of work and love put into this. |
07:48:04 | Araq | you're welcome |
07:48:12 | Araq | btw we REALLY need more coredevs |
07:48:31 | Araq | in fact, the situation got worse instead of better |
07:48:37 | gokr | Really? |
07:49:39 | gokr | How so? |
07:51:20 | Araq | because both zahary and dom96 have no free time anymore these days |
07:51:39 | gokr | Ah, got through school and got jobs? ;) |
07:51:50 | Araq | something like that |
07:52:25 | gokr | I have been active for a long time in the squeak community (and some ohters) and I recognize the pattern. |
07:52:48 | gokr | So you got your own company going now or? |
07:52:56 | Araq | ha, I wish |
07:53:14 | gokr | So you got a day job not Nim-ish? |
07:53:26 | Araq | yeah |
09:03:10 | * | Ven joined #nimrod |
09:12:21 | * | dirkk0 joined #nimrod |
09:18:29 | * | Ven quit (Ping timeout: 272 seconds) |
09:27:16 | * | Ven joined #nimrod |
09:30:26 | * | Ven quit (Client Quit) |
09:43:48 | * | bjz joined #nimrod |
10:10:52 | * | EXetoC joined #nimrod |
10:24:39 | * | dirkk0 quit (Quit: Leaving) |
10:56:24 | * | kuzy000 joined #nimrod |
11:04:53 | * | xcombelle joined #nimrod |
11:11:29 | * | Lorxu quit (Ping timeout: 260 seconds) |
11:25:44 | * | kuzy000 quit (Remote host closed the connection) |
11:41:53 | * | BitPuffin joined #nimrod |
11:43:56 | * | BlaXpirit-UA joined #nimrod |
11:45:41 | * | BlaXpirit quit (Ping timeout: 244 seconds) |
11:48:16 | gokr | So I installed Nimrod devel branch. Built fine and installed. |
11:48:40 | gokr | Now I wonder a) How do I generate all the docs? and b) How can I build c2nim? It fails finding llstream |
11:58:51 | Trustable | gokr: a) execute "koch web" |
11:59:13 | gokr | Aaah |
12:06:16 | gokr | Kinda fails on it though. |
12:07:44 | * | noam_ is now known as noam |
12:16:16 | * | will joined #nimrod |
12:16:20 | * | gokr quit (Quit: Leaving.) |
12:18:41 | Trustable | gokr: For me koch web works. What error do you get? |
12:21:38 | * | wan quit (Quit: WeeChat 1.0.1) |
12:32:31 | * | io2 joined #nimrod |
12:45:40 | * | darkf quit (Quit: Leaving) |
12:54:27 | * | jasondotstar quit (Quit: Leaving) |
13:04:14 | * | xcombelle quit (Quit: Quitte) |
13:04:24 | * | xcombelle joined #nimrod |
13:13:31 | * | bjz quit (Ping timeout: 244 seconds) |
13:24:26 | * | bjz joined #nimrod |
13:29:59 | * | jasondotstar joined #nimrod |
13:31:06 | * | untitaker quit (Ping timeout: 255 seconds) |
13:37:03 | * | untitaker joined #nimrod |
14:20:49 | * | saml joined #nimrod |
14:23:35 | * | gokr joined #nimrod |
14:26:28 | * | Matthias247 joined #nimrod |
14:38:55 | * | brson joined #nimrod |
14:52:24 | * | brson quit (Quit: leaving) |
14:52:31 | * | brson joined #nimrod |
14:53:25 | * | brson quit (Client Quit) |
14:53:32 | * | brson joined #nimrod |
14:54:20 | * | brson quit (Client Quit) |
14:54:29 | * | brson joined #nimrod |
14:55:18 | * | brson quit (Client Quit) |
14:55:25 | * | brson joined #nimrod |
15:18:32 | * | gokr_ joined #nimrod |
15:22:05 | * | gokr quit (Ping timeout: 260 seconds) |
15:23:24 | * | asterite joined #nimrod |
15:24:10 | asterite | Hi! I'm trying to use the json module. I copied the sample from here: http://nimrod-lang.org/json.html#parseJson,PStream,string with an `import json` at the top but I get `Error: undeclared identifier: 'parseJson'`… what am I doing wrong? |
15:24:54 | asterite | Sorry, the sample at the top of: http://nimrod-lang.org/json.html |
15:27:51 | Trustable | Hi asterite |
15:28:09 | asterite | Hi Trustable |
15:32:27 | Trustable | asterite, I don't know what the problem could be, check your code for any typos |
15:33:18 | asterite | Can you try it on your machine and see if it works? |
15:42:08 | * | nande joined #nimrod |
15:47:30 | Trustable | asterite: That's what I have done at first, after I read your message. |
15:49:08 | asterite | Hm, the file was named json.nim, I guess that was the problem… sorry |
15:53:58 | * | asterite quit (Quit: Leaving.) |
15:55:34 | Trustable | asterite: You found an issue. Good :) |
15:59:46 | * | kshlm joined #nimrod |
16:00:56 | * | xcombelle quit (Remote host closed the connection) |
16:11:01 | * | wan joined #nimrod |
16:15:31 | * | mko joined #nimrod |
16:19:54 | * | Keluri joined #nimrod |
16:20:18 | * | vendethiel joined #nimrod |
16:22:15 | NimBot | nimrod-code/nimforum new_async 3af3de2 Dominik Picheta [+1 ±1 -1]: Fix createdb and config filename. |
16:33:02 | * | jhc76 joined #nimrod |
16:37:24 | * | Matthias247 quit (Quit: Matthias247) |
16:54:27 | * | kshlm quit (Ping timeout: 245 seconds) |
16:58:23 | Araq | hi dom96 |
17:02:26 | Trustable | Hi Araq |
17:03:25 | Trustable | Araq: When a module imports itself, no error is thrown. Is this ok? |
17:03:37 | Araq | no, it's not |
17:03:52 | Araq | please make a bug report |
17:03:57 | Trustable | ok |
17:04:36 | Trustable | Do you think I should try to fix it? |
17:09:15 | Trustable | New issue created: https://github.com/Araq/Nimrod/issues/1572 |
17:09:32 | Araq | sure you can try |
17:09:44 | Araq | importer.nim seems to be a starting point |
17:10:24 | Araq | more important would be if you fix JS codegen bugs |
17:10:31 | Trustable | thx, I already took a look into the compiler source, but didn't found the place |
17:11:00 | Trustable | For what is JS output needed? |
17:11:32 | * | asterite joined #nimrod |
17:13:41 | * | gokr joined #nimrod |
17:15:23 | Araq | for people who like to compile Nim to JS |
17:15:33 | Araq | it's in compiler/jsgen.nim |
17:16:08 | Trustable | ok |
17:16:29 | Araq | there is even a comment that explains how it works |
17:16:32 | Araq | :P |
17:16:34 | gokr | Trustable: On master from github, running "./koch web" I get: Error: cannot open '../doc/exception_hierarchy_fragment.txt' |
17:17:09 | * | Jehan_ joined #nimrod |
17:17:33 | Araq | oh so master is broken again? :-/ |
17:17:43 | gokr | Trustable: And on devel branch I get another error :) - then I see "Error: undeclared identifier: 'useSysAssert'" on processing system.nim |
17:18:03 | Trustable | gork: I have tested it only on devel. |
17:18:19 | Trustable | *gokr |
17:18:34 | Araq | gokr: if you have already Nim installed, the git version uses the installed version of the stdlib |
17:18:43 | Araq | I'm looking into this right now |
17:18:44 | gokr | gokr is short for Goran Krampe btw, might be easier to recall it :) |
17:18:56 | gokr | Göran in fact. |
17:19:06 | Araq | it is a common problem |
17:19:07 | gokr | But I am not picky about those dots. |
17:19:16 | gokr | Araq: aha |
17:19:35 | gokr | I think I uninstalled and installed devel instead. |
17:19:51 | gokr | Hmmm, is there a "learn the ropes" article somewhere? :) |
17:19:55 | Araq | well the compiler tells you where it looks for the stdlib |
17:20:02 | gokr | I am a bit lost on all the tools etc. |
17:20:14 | gokr | But I am learning. |
17:21:23 | gokr | Btw, I ran c2nim on a header file and it created something - but it put a "bug" marker in it. |
17:21:30 | * | Francisco quit (Ping timeout: 246 seconds) |
17:21:51 | gokr | "This should never happen..." etc :) |
17:22:32 | Araq | er what? |
17:22:45 | gokr | "This should never happen. It indicates a bug" |
17:22:51 | Araq | if it fails, how come it produces ouput? |
17:23:04 | gokr | Hehe, let me check the header... perhaps its from there. |
17:23:24 | gokr | Ah! |
17:23:27 | gokr | Sorry, false alarm |
17:23:36 | gokr | It was actually a comment in the header, sneaky. |
17:24:52 | gokr | So... silly question time... I cloned out c2nim since it now lives in its own repo. Then... I just did "nimrod c c2nim" and... it failed to find llstream etc |
17:25:01 | gokr | Which I later found in the compiler |
17:26:02 | * | Francisco joined #nimrod |
17:26:14 | gokr | So I simply did "nimrod c -p:../Nimrod.devel/compiler/ c c2nim" and then it worked. |
17:26:37 | Araq | well it depends onto how the compiler resolves $nimrod |
17:26:58 | Araq | the config file for c2nim contains something like --path:$nimrod/compiler |
17:27:07 | Araq | so that c2nim can use the compiler's source code |
17:27:16 | Araq | but for some reason it's fragile |
17:27:16 | gokr | And is that en ENV var? |
17:27:31 | Araq | no, the compiler knows how to resolve $nimrod |
17:27:35 | gokr | ok |
17:27:56 | gokr | Can this be seen in "nimrod dump"? |
17:28:28 | gokr | Because... it lists /usr/local/compiler which seems... wrong. |
17:28:31 | gokr | To say the least. |
17:29:32 | gokr | All the other paths start with "/usr/local/lib/nimrod/" |
17:29:47 | Araq | well |
17:30:03 | Araq | if the binary is in /usr/local where are the compiler's sources? |
17:30:07 | Araq | nobody knows |
17:30:22 | Araq | so it has no chance of resolving this properly |
17:30:45 | gokr | So did I do something wrong or is this something in flux? |
17:31:06 | gokr | nimrod is in /usr/local/bin btw |
17:31:12 | Araq | yeah whatever |
17:31:31 | gokr | So I need to tell it ... via some cfg file where the sources are? |
17:32:15 | Araq | your way of providing it via --path is just fine |
17:32:25 | Araq | dunno how we can solve it in general |
17:32:51 | Araq | I guess we can't. nobody says the compiler's sources are even installed somewhere |
17:33:02 | gokr | Hmmm, I am not sure I grok this. Is the problem that we don't install the compiler sources? |
17:33:08 | gokr | Ah, ok. |
17:33:10 | Araq | yes |
17:33:26 | gokr | So... make them a babel package? :) |
17:33:53 | gokr | Btw, nimble and babel... relation? |
17:33:59 | Araq | that's one solution I guess except that people frequently build babel from source |
17:34:31 | Araq | which requires a working Nim installation, but not the compiler's sources so it should be fine |
17:34:41 | EXetoC | gokr: babel is now nimble |
17:34:52 | gokr | I mainly meant that... c2nim obviously uses parts of the compiler modules - so those modules could be separately installable as a babel package, so c2nim can depend on them. |
17:34:59 | gokr | EXetoC: aha. |
17:35:21 | Araq | yeah sounds like a good solution, gokr |
17:36:04 | gokr | Ok, gotta go pick up my daughter from her practice... later |
17:40:53 | * | asterite1 joined #nimrod |
17:41:26 | * | asterite1 left #nimrod (#nimrod) |
17:42:03 | * | Keluri quit (Quit: Page closed) |
17:43:21 | Araq | Varriount: looks like http://nsis.sourceforge.net/ is our best solution to get a web installer |
17:43:25 | * | asterite quit (Ping timeout: 260 seconds) |
17:47:04 | * | Matthias247 joined #nimrod |
17:58:15 | * | gokr_ quit (Ping timeout: 246 seconds) |
17:58:41 | * | gokr_ joined #nimrod |
18:12:53 | * | gokr_ quit (Ping timeout: 258 seconds) |
18:13:24 | * | gokr_ joined #nimrod |
18:14:29 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
18:30:14 | * | gokr_ quit (Ping timeout: 244 seconds) |
18:31:28 | * | gokr_ joined #nimrod |
18:42:52 | dom96 | Web installer? |
18:43:04 | dom96 | Araq: What do you have in mind? |
18:43:08 | dom96 | I do like NSIS though. |
18:51:35 | Araq | dom96: installer that lets you select what to download |
18:51:44 | Araq | and puts the packages in the right dirs |
18:52:17 | dom96 | That sounds great. |
18:53:27 | dom96 | Araq: I did some coding during a Java lecture today :P |
19:01:11 | * | gokr_ quit (Ping timeout: 258 seconds) |
19:01:27 | * | gokr_ joined #nimrod |
19:03:44 | * | gokr_ quit (Read error: Connection reset by peer) |
19:04:06 | * | gokr_ joined #nimrod |
19:09:56 | * | io2 joined #nimrod |
19:17:32 | * | zahary joined #nimrod |
19:21:59 | Jehan_ | dom96: Let me go out on a limb here and guess that you weren't coding in Java. :) |
19:22:13 | EXetoC | php I think |
19:22:56 | dom96 | Jehan_: haha you are correct. |
19:24:06 | Jehan_ | I'm still trying to figure out whether it's good or bad that Java has become an introductory language in CS. |
19:24:18 | Araq | it's bad |
19:24:24 | Araq | in fact: it's even worse |
19:24:32 | Araq | so here you go. now you know ;-) |
19:24:35 | dom96 | Python would be far better IMO. |
19:24:43 | dom96 | Nim even better. |
19:25:24 | dom96 | There is so much crap in Java that they are teaching us which you do not have to worry about in Nim. |
19:25:25 | gokr | I have used NSIS a long time ago, it was very nice. |
19:25:33 | Jehan_ | Araq: Well, I've seen C as an introductory language, so ... |
19:25:40 | dom96 | "You must make sure that 'public' is all lower case" |
19:25:52 | Jehan_ | The thing is, Java has at least most of the basics of a modern programming language. |
19:25:54 | dom96 | "You must make sure you have a main method" |
19:26:10 | gokr | When I started CS back in 1990 we started out with Scheme. Great course. |
19:26:16 | Jehan_ | But yeah, public static void main is crazy. |
19:26:35 | EXetoC | introduction with C++. win |
19:26:41 | Araq | "modern" is relative. I would argue that C++ is more modern |
19:27:13 | Jehan_ | Araq: I'd argue against that. :) |
19:27:18 | gokr | The problem with Java and C++ and... well, several languages, is that they have too much noise. |
19:27:32 | Jehan_ | No module system, not even an option for automatic memory management. |
19:27:34 | gokr | So for that only reason they kinda suck at teaching. |
19:27:35 | Araq | well I'm not sure if I'm serious here |
19:28:15 | Jehan_ | gokr: I don't disagree. |
19:28:16 | gokr | And for a very long time Java didn't even have closures. It does now... right? |
19:28:31 | gokr | It was a while since I coded Java - though I have done a lot of it. |
19:28:38 | Jehan_ | I like Python as an introductory language for non-computer scientists. Ruby probably, too. |
19:28:59 | Jehan_ | gokr: Java8 does. |
19:29:10 | gokr | Right, I read about that somewhere. |
19:29:19 | gokr | It took a while to shoe horn them in though :) |
19:29:35 | Jehan_ | You can kinda sorta use anonymous inner classes as a substitute. With limits. |
19:30:02 | Jehan_ | I'm still not sure what my preferred introductory language for CS students would be. |
19:30:19 | Jehan_ | Well, CS students need to be able to learn more than one and pick up additional languages on demand. |
19:30:25 | Jehan_ | But you have to start with something. |
19:30:29 | EXetoC | scheme? |
19:30:49 | Jehan_ | I know a friend of mine put her foot down and got to use Scala for her undergraduate CS course. |
19:31:06 | dom96 | Question is should CS students start with something nice and easy or something difficult. |
19:31:11 | dom96 | i.e. Python or C? |
19:31:22 | Jehan_ | Her rationale was that as a multi-paradigm language it allowed her to teach all the basic concepts without juggling languages. |
19:31:24 | dom96 | Actually I should say high level vs. low level. |
19:31:28 | dom96 | Not hard vs easy. |
19:31:37 | Jehan_ | dom96: High level. |
19:31:46 | Jehan_ | They'll get plenty of low-level stuff later on. |
19:31:49 | gokr | Scheme was a very good language for us. |
19:32:02 | gokr | That MIT course... don't remember its name, great one. Is online now. |
19:32:06 | Jehan_ | But there are plenty of first semester students who struggle with concepts such as assignment. |
19:32:32 | Jehan_ | gokr: Structure and Interpretation of Computer Programs? |
19:32:47 | gokr | The nice part with that course was not the language itself - it was the fact that it focused on techniques. You know, recursion etc |
19:32:49 | gokr | Exactly. |
19:32:58 | Araq | I think they should start with F#, Ocaml or Nim :-) |
19:32:59 | gokr | So the language was just a "vessel". |
19:33:12 | Jehan_ | My problem with scheme as an introductory language is that in many ways it's too limited. |
19:33:32 | gokr | Another really good thing with it was that noone was ahead. |
19:33:37 | gokr | More or less. |
19:33:44 | Jehan_ | Araq: Yeah, OCaml would work. I don't think I'd use Nim as an introductory language (no offense, that's not what it seems to be designed for). |
19:34:15 | Araq | the problem with Java is IMHO that it is too simple so you end up teaching APIs instead of constructs |
19:34:18 | gokr | IMHO the problems arise when you "fight the language" instead of learning concepts. |
19:34:22 | Jehan_ | gokr: Yeah, that's a common concern. Plus, people don't incorrectly think "I know all that already". |
19:34:40 | Araq | but APIs are really boring and frequently become outdated |
19:35:04 | gokr | There is a multi paradigm lang called... hmmm. It was used here in Sweden... argh... Mozart I think. |
19:35:04 | Jehan_ | Araq: I'm generally not a fan of teaching specific technologies in undergraduate CS. |
19:35:16 | Araq | well I guess you teach them algorithms in Java |
19:35:22 | Jehan_ | No matter what the technology is. The language should be a vehicle for teaching more general concepts. |
19:35:31 | EXetoC | code monkey training |
19:35:31 | gokr | exactly. |
19:35:33 | Jehan_ | gokr: Oz. |
19:35:40 | Araq | Jehan_: exactly. |
19:35:44 | gokr | Hmmm, was it Oz? Perhaps it was. |
19:36:15 | Jehan_ | gokr: Mozart is the reference implementation of Oz. |
19:36:29 | gokr | Ah |
19:36:54 | Jehan_ | There's also Ozma, which is Scala + Oz concepts on the Mozart VM. |
19:38:21 | gokr | Anyway, SICP was superb. |
19:38:50 | gokr | Although it was ... 24 years ago. Ehrm... shit I am old. |
19:38:56 | Jehan_ | gokr: It's really good for a certain type of student, but doesn't work so well for others. |
19:39:09 | gokr | Yeah, probably true. |
19:39:31 | gokr | But this was after all the 4.5 years CS engineering education. |
19:39:37 | gokr | Not a 1-2 years CS thing. |
19:39:42 | Jehan_ | I know because I had to help a few students who were struggling with the approach. :) |
19:39:43 | EXetoC | 25 are you? |
19:39:48 | gokr | Hehe |
19:39:48 | EXetoC | no you must be slightly older then |
19:39:57 | gokr | Slightly older than 25. :) |
19:40:41 | gokr | I am 45. Two daughters, both asleep now. ;) |
19:41:15 | gokr | So... Nim was born in 2008 |
19:41:19 | gokr | --ish? |
19:41:50 | gokr | Just a bit curious how I managed to miss it all these years. Even in my article about languages after 2000. |
19:41:50 | Araq | it's hard to say but official year is 2006 |
19:41:55 | gokr | Ok |
19:42:11 | gokr | I am a language fetishist. |
19:42:26 | gokr | Although since a very long time a Smalltalk diehard. |
19:43:16 | Jehan_ | Speaking about OCaml, I still think a syntax for generic modules would make a nice addition to Nim. :) |
19:43:17 | gokr | But Nim did catch my interest the other day, although I tend to be draw to minimalistic languages - and Nim... doesn't really land there ;) |
19:43:35 | Jehan_ | gokr: I adore Smalltalk, except for the image thing. |
19:44:06 | gokr | Well, after a bunch of years the "image thing" ... you start realizing the effects it has. |
19:44:13 | Araq | I used to date it back to 2004 but that's only what the lexer is from |
19:44:45 | Jehan_ | gokr: Yeah, it requires me to learn duplicates for all the tools I normally use. For each implementation. :( |
19:45:05 | Araq | well I always had compiler-related modules lying around ... |
19:45:24 | gokr | I always wonder why so few other languages don't try to be reflective like Smalltalk. The environment creates such an immense productivity. |
19:46:02 | Araq | funny I don't like smalltalk really but I like the "image thing" idea |
19:46:19 | Jehan_ | Araq: I like the idea, just not the actual experience. |
19:46:21 | gokr | Jehan_: Well, if you really use the Smalltalk environment for live interactive coding - then you start wondering why everyone else is sitting in their "dead files". |
19:46:30 | Jehan_ | Starting with not being able to use the editor I'm accustomed to. |
19:46:59 | Jehan_ | gokr: Been there, done that. It just … doesn't have the appeal. |
19:47:07 | Jehan_ | Different things work for different people. |
19:47:09 | gokr | The editor thing is of course "solvable", but for Smalltalk specifically the methods tend to be 20 lines max. Browsers and cross reference tools etc is what you really use. |
19:47:20 | gokr | Jehan_: Yeah, sure. |
19:47:48 | Jehan_ | gokr: That's a convention that I prefer to stick to with any language. It's not about the length of methods. |
19:47:49 | gokr | But I think most people "dismissing" it - does it for the wrong reasons. Typically because they didn't feel comfortable - due to other habits. |
19:48:17 | Jehan_ | I think that lack of comfort is a perfectly good reason. |
19:48:19 | gokr | Most Smalltalkers know lots of programming languages - and don't share this sentiment. |
19:48:36 | gokr | Then of course, you can always go GNU Smalltalk :) |
19:48:48 | Jehan_ | gokr: I've tried it. :) |
19:49:02 | Jehan_ | It's actually pretty nice, but it's another one-person project. |
19:49:07 | gokr | Yeah |
19:49:16 | gokr | The current strongest open source Smalltalk is Pharo. |
19:49:21 | gokr | Derivative from Squeak. |
19:49:32 | Jehan_ | Ruby is my command line Smalltalk derivative of choice. |
19:49:42 | Jehan_ | I have Pharo sitting here on my machine, I know. |
19:50:04 | gokr | Ruby mostly just pisses me off ;) |
19:50:18 | gokr | But that's because I am a Smalltalker. |
19:51:29 | gokr | Jehan_: Where are you from? |
19:51:52 | Jehan_ | My main problem with Pharo is that text input is too sluggish. At least on a Mac. |
19:52:21 | Jehan_ | gokr: Germany. Though I lived about 15 years of my life abroad. |
19:52:23 | gokr | Yeah, the Morphic UI framework has kinda clogged up completely. IIRC Igor and some others are reimplementing it all. |
19:52:35 | gokr | The text stuff I mean. |
19:53:05 | Jehan_ | gokr: Yeah, but the thing is, when typing a single character is close to breaking the .1 second reponsiveness threshold by itself, that's too slow for editing. |
19:53:20 | gokr | Really? That sounds a bit odd. |
19:53:48 | Jehan_ | Okay, it's not quite .1 seconds, but it's not instant, either. |
19:54:27 | gokr | Hmmm, not really something I recognize. |
19:54:34 | Jehan_ | Atom has (or at least had) the same issue. |
19:54:37 | gokr | Slightly off topic for this channel though :) |
19:55:03 | Jehan_ | I think any channel has a bit of off-topic chatter. As long as nothing else is going on ... |
19:55:14 | gokr | I am working with Squeak and Pharo btw. Our system is written fully in Squeak. |
19:55:28 | gokr | And I have been very active in that community since... like forever. |
19:56:04 | Jehan_ | gokr: What I really like about Pharo and Squeak is the direct UI integration. Even if Morphic is not my preferred UI. |
19:56:39 | gokr | Yeah, it dates back to the original ideas around Smalltalk. Single individual mastery etc. |
19:56:43 | Jehan_ | But it means that UI stuff is a whole less of a lot of a pain than anywhere else. |
19:57:05 | Jehan_ | Hmm, I think I scrambled that sentence, but you get the idea. |
19:57:13 | gokr | Yes, and another neat effect is that the tools you build - all run bit identical on all platforms. |
19:57:22 | gokr | Which is a huge benefit for a small community. |
19:57:27 | gokr | Sure. |
19:57:42 | Jehan_ | gokr: That's not actually a benefit in my world. UIs are different on different platforms. |
19:57:58 | gokr | They are - for apps. But for dev tools they don't need to be. |
19:58:36 | gokr | So much history in the UI world dating back to Smalltalk. |
19:59:24 | gokr | You know - it was Smalltalk that was demoed to Steve Jobs at Xerox PARC back in 198... 1983 I think. |
19:59:37 | Jehan_ | Yeah, I'm very familiar with the history. |
19:59:40 | Araq | yes. we know. ;-) |
19:59:45 | gokr | Sorry :) |
19:59:56 | Jehan_ | Lots of programming language nerds in this channel. :) |
20:00:02 | gokr | Did you also know that Steve was obsessed with smooth scrolling back then even? |
20:00:33 | gokr | He asked Dan Ingalls (who was demoing) if he could make the scrolling smooth (it was line by line) - and Dan hacked it right during the demo to be smooth. |
20:00:55 | Jehan_ | I once did a list and figured out that I've used somewhere between 30-40 different programming languages in anger (i.e. for serious work) at one point or another. If you count different assembly languages and substantially different LISP dialects. |
20:01:28 | gokr | Yeah, similar count here, perhaps a tad less, around 25 I think. |
20:02:15 | gokr | But its very interesting IMHO to cross boundaries. |
20:02:21 | Jehan_ | Oh, agreed. |
20:02:47 | Jehan_ | These days, I'm strongly gravitating towards multiparadigm languages myself. |
20:02:53 | gokr | Personally I would love something like Nim - but with the interactive power environment and productivity of Smalltalk. |
20:03:04 | Jehan_ | I blame Jim Coplien for that. :) |
20:03:20 | gokr | Although I always get nervous with languages with too many mechanisms. |
20:03:39 | gokr | I truly hate having to fight the language. |
20:04:06 | Jehan_ | gokr: Yeah, I don't mean to imply that I want the whole kitchen sink. |
20:04:22 | Araq | yeah but I fight languages because of missing features |
20:04:30 | gokr | No, I was actually thinking about Smalltalk vs Nim. |
20:04:37 | Jehan_ | But in my experience, every single-paradigm language does about 80% great and 20% horribly. |
20:04:49 | gokr | Smalltalk code I can always read and understand more or less immediately. |
20:05:15 | gokr | When a language has multiple mechanisms like generics, macros and god knows - that intersect - it can get insane pretty quickly. |
20:05:18 | Jehan_ | The thing I always loved about Smalltalk were the (syntactically) light-weight closures. |
20:05:37 | gokr | Yeah, and having them from the start - so that they are everywhere in the libs. |
20:05:40 | Jehan_ | Smalltalk is really one of the first multiparadigm languages (OO + higher order functions). |
20:05:58 | gokr | Adding them afterwards isn't really that rewarding if the libs are already set in a style not using them. |
20:06:07 | Jehan_ | Yeah. |
20:06:26 | gokr | And funny enough - in Smalltalk they are so natural - most Smalltalkers don't even know what a closure is. |
20:06:32 | Araq | gokr well that's a fair criticism of Nim and also the reason it takes so long to get stable |
20:06:35 | gokr | Well, many don't. |
20:06:44 | Jehan_ | That's one of my main beefs with Ruby, too: That the syntax becomes cumbersome if you have more than one closure per call. |
20:07:06 | gokr | Nim has naked lambdas now - why naked? |
20:07:34 | gokr | Perhaps its a logical choice when you don't have the "naked" keyword syntax as Smalltalk as. |
20:07:36 | gokr | has. |
20:08:35 | Araq | not sure what you mean but 'do' exists exactly for the reason to be able to pass multiple blocks to a macro |
20:09:05 | Jehan_ | gokr: Not familiar with the term "naked lambda"? |
20:09:06 | gokr | What I mean, or Jehan? |
20:09:34 | gokr | Ok, so... In Nim I can do fun( (x) => x*x) |
20:09:39 | Araq | and saying that Smalltalk is much simpler kind of misses the point. Smalltalk is dynamically typed. |
20:09:50 | gokr | So the "(x) => x * x" is naked. |
20:09:57 | Araq | it's easy to be simple when you go the dynamic typing route |
20:09:57 | gokr | It doesn't have anything around it. |
20:10:07 | Araq | => is a macro |
20:10:09 | Jehan_ | Oh, what I call "syntactically lightweight". |
20:10:16 | Araq | not a builtin syntax |
20:10:40 | gokr | I didn't come up with the term - and to be frank - I am not sure I use it correctly. I saw it in C# first I think. |
20:11:04 | Jehan_ | Speaking of which, this syntax still has issues with closures that don't return a value, I think. |
20:11:22 | Jehan_ | You have to add -> void explicitly. |
20:11:30 | Araq | it's not a syntax. it's simply a binary operator implemented as a macro. |
20:11:38 | Jehan_ | Araq: I know. |
20:11:45 | Jehan_ | Same difference. |
20:11:53 | Araq | it's not even in system.nim |
20:11:58 | Jehan_ | I still have to explicitly specify the return type for the case where there's no return type. |
20:12:06 | Jehan_ | I think it's auto inference going awry. |
20:12:10 | gokr | Well, "easy" it may be - but Smalltalk was refined over 10 years I think. Alan didn't really like the result though. |
20:12:33 | gokr | Araq: ok |
20:13:25 | gokr | Anyway, a light syntax for closures is very important IMHO. So that they are natural to use. Although I suspect the Nim libraries don't use much of them or? |
20:13:49 | gokr | Sorry, I need to study more Nim. ;) |
20:14:11 | Jehan_ | gokr: Actually, it's pretty lightweight if there's one closure that doesn't have parameters. |
20:14:29 | Jehan_ | And is not too bad otherwise, too. |
20:16:32 | Jehan_ | See https://bitbucket.org/behrends/nimr/src/d33ec14d7f3687e2fda5e73786e5620d3fc48279/nimr.nim -- namely, the lock procedure in line 42 and how it's used in line 76. |
20:23:04 | * | io2 quit (Ping timeout: 250 seconds) |
20:27:45 | EXetoC | no 'do' needed? |
20:28:05 | EXetoC | guess not |
20:29:23 | Jehan_ | EXetoC: No. Not if the procedure doesn't have parameters. |
20:30:30 | Jehan_ | Mind you, I only found that out a couple of months ago myself. :) |
20:54:53 | * | bjz_ joined #nimrod |
20:55:27 | * | bjz quit (Read error: Connection reset by peer) |
20:55:55 | Trustable | Araq and all: Suggestion for new compiler error: errSelfImport: "Import of itself is not allowed" OK? |
20:56:22 | Jehan_ | The message sounds a bit confusing to me. |
20:56:43 | Jehan_ | I'd suggest something like: "A module cannot import itself." |
20:57:05 | Trustable | thx. great. |
20:58:05 | Jehan_ | Perhaps even: "A module is trying to import itself", which would describe what's going on rather than what is forbidden. Not sure which is better. |
20:58:42 | Trustable | I like your first one better |
20:58:58 | EXetoC | and the name of said module |
20:59:01 | Araq | Trustable: no |
20:59:11 | Araq | just use errGenerated |
20:59:24 | EXetoC | though you have a line number already |
20:59:28 | Araq | these other err* messages are deprecated |
20:59:34 | Trustable | Araq: ok |
21:01:22 | Trustable | File and line number is also shown |
21:05:06 | Trustable | How can I split a PR? |
21:06:22 | Trustable | https://github.com/Araq/Nimrod/pull/1571 contains 2 different fixes, I don't know how to split them |
21:13:21 | * | Matthias247 quit (Read error: Connection reset by peer) |
21:16:08 | Jehan_ | I'd say, "git reset --soft HEAD^", commit the changes individually again, push the branch again. |
21:17:21 | Jehan_ | "git reset --soft HEAD^" is how you "uncommit" changes in git. |
21:18:43 | Trustable | Jehan_: But github merged my 2 commits automatically to one PR. How can I avoid this? |
21:19:04 | Jehan_ | Oh, I see. So you want two different pull requests? |
21:19:07 | EXetoC | by using separate branches |
21:19:07 | Trustable | yes |
21:19:13 | Jehan_ | What EXetoC said. |
21:19:17 | Trustable | ok |
21:19:42 | Jehan_ | First, do git reset --soft HEAD^ to uncommit, then commit the first set of changes. |
21:19:56 | Jehan_ | Then … ugh, let me think about that (sigh, git). |
21:20:54 | Jehan_ | Problem is that you then want to do git checkout to go back, but that will also reset the checkout. |
21:21:11 | Jehan_ | I think you'd need to stash the remaining changes, use git checkout, then unstash them. |
21:21:37 | Jehan_ | "Why I'm not a huge fan of Git", chapter XXVII. |
21:21:41 | * | io2 joined #nimrod |
21:27:58 | EXetoC | what would you do with some other VC software? |
21:28:23 | * | johnsoft quit (Ping timeout: 240 seconds) |
21:29:10 | * | johnsoft joined #nimrod |
21:29:33 | Jehan_ | Depends? Which one? Bazaar? Mercurial? Fossil? |
21:30:41 | Jehan_ | Bzr: bzr branch to fork, bzr uncommit in both branches, selectively commit one or the other set of changes in each branch. |
21:31:24 | EXetoC | are there fewer steps or is it more intuitive? |
21:31:33 | Jehan_ | More intuitive. |
21:32:27 | Jehan_ | Basically, you duplicate the branch (does not actually duplicate any repo data), then adjust each branch individually. |
21:32:51 | EXetoC | ok |
21:33:17 | Jehan_ | I'm still miffed at Canonical for neglecting Bzr, which still has the sanest conceptual model of any DVCS I know. |
21:33:57 | Jehan_ | But because they're not even keeping up with bug and performance fixes, it's not really an option except for personal projects. |
21:35:14 | Jehan_ | Mercurial: "hg uncommit", "hg commit <whatever you need for part 1>", "hg update .^", "hg commit <whatever you need for part 2>" |
21:36:58 | Trustable | oh bad, another time merged |
21:38:12 | Jehan_ | Git is superior when you want to hack your repository, of course. But it often doesn't allow you to do the straightforward stuff in a straightforward fashion. |
21:38:23 | * | BlaXpirit-UA quit (Quit: Quit Konversation) |
21:39:57 | Trustable | PR problem solved :) 2 PRs now ready |
21:43:24 | * | will quit (Read error: Connection reset by peer) |
21:44:16 | * | melgen joined #nimrod |
21:44:53 | Trustable | dom96: please merge https://github.com/nimrod-code/Aporia/pull/59 |
21:55:55 | * | BitPuffin quit (Ping timeout: 255 seconds) |
22:09:40 | Araq | Trustable: meh, string comparison? use the fileIndexes instead |
22:09:51 | Araq | that's what they are for |
22:10:05 | Trustable | ok, I can try |
22:21:04 | Trustable | Araq: done |
22:21:24 | Araq | added a test case to the test suite too? |
22:23:14 | Trustable | Araq: I don't know how to. But I added an example program in the issue https://github.com/Araq/Nimrod/issues/1572. It's only 2 lines. |
22:23:50 | Araq | well it's not hard |
22:25:09 | Araq | tests/misc/tinvalidnewseq.nim |
22:25:14 | Trustable | Araq: ok, I will look |
22:25:17 | Araq | take this as an example |
22:25:31 | Araq | but put your test in tests/modules |
22:25:58 | Araq | it's literally just adding a file with some special discard header |
22:28:57 | Trustable | Araq: file is added, how can I test it? |
22:30:20 | Araq | nim c -r tests/testament/tester cat modules |
22:30:51 | Araq | iirc you can also run a single test instead of a whole category but I never do that so I forgot how |
22:32:42 | Trustable | Araq: PR updated with test case |
22:36:43 | * | Lorxu joined #nimrod |
23:00:41 | Trustable | 4 PRs done for today :) |
23:02:20 | Araq | fixed a JS bug? |
23:02:41 | Araq | but great work! |
23:02:56 | Araq | I will merge later 0.9.6 is actually frozen |
23:04:56 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
23:14:16 | * | bjz_ quit (Ping timeout: 260 seconds) |
23:20:21 | * | quasinoxen quit (Ping timeout: 260 seconds) |
23:21:48 | Araq | Varriount: some more research shows that inno setup might also be up for the task |
23:38:35 | * | sdw quit (Read error: Connection reset by peer) |
23:40:55 | * | quasinoxen joined #nimrod |
23:41:23 | Varriount | Araq: Or we could write the installer in Nim... |
23:54:22 | * | darkf joined #nimrod |
23:55:10 | Araq | Varriount: nah |
23:55:30 | Araq | we won't produce a professional installer that people are used to |
23:56:03 | * | Jehan_ eagerly awaits the first C compiler written entirely in NIm. :) |
23:57:19 | Araq | oh yeah ... where is mat3? |
23:57:42 | EXetoC | and then a nim compiler written in C |
23:59:17 | Varriount | Araq: Regarding your earlier remark about core developers, I'm surprised I still count. :3 |
23:59:44 | Araq | Varriount: I used the console installer of SmartEiffel back in the days |
23:59:57 | Araq | trust me, you don't want that |