00:01:14 | * | q66 quit (Remote host closed the connection) |
00:20:57 | * | comex quit (Ping timeout: 264 seconds) |
00:21:55 | * | comex joined #nimrod |
00:38:24 | * | Trixar_za is now known as Trix[a]r_za |
04:02:42 | * | OrionPK quit (Quit: Leaving) |
05:19:29 | * | ARCADIVS joined #nimrod |
06:34:43 | Araq | hi ARCADIVS |
06:34:46 | Araq | welcome |
06:48:12 | * | zahary quit (Quit: Leaving.) |
08:23:50 | * | ARCADIVS quit (Quit: WeeChat 0.3.8) |
09:12:05 | * | zahary_ joined #nimrod |
09:21:02 | * | Amrykid quit (*.net *.split) |
09:35:57 | * | xcombelle joined #nimrod |
10:16:29 | zahary_ | just FYI: another new language with similar goals (and design) to Nimrod: https://github.com/lycus/flect/wiki/Introduction#motivation |
10:16:29 | zahary_ | They are lagging behind in implementation tho |
10:28:42 | * | q66 joined #nimrod |
10:30:52 | * | Amrykid joined #nimrod |
10:33:40 | * | erlnoob joined #nimrod |
10:35:53 | erlnoob | hello, i'm using 0.9.0, subrange value validity doesn't seem to be enforced, e.g., TDay = range[0..6] <-- with a variable of type TDay, i can assign values outside 0 and 6. help? |
10:37:17 | zahary_ | hi erlnoob, this could be a bug. most people here use the latest version of the language from github and it's hard to tell when certain things got fixed |
10:37:59 | zahary_ | there will be a new release 0.9.2 coming out soon |
10:38:11 | erlnoob | nice |
10:38:30 | erlnoob | guess i should be using the one from github eh |
10:39:47 | zahary_ | if you enjoy nimrod so far, I definitely recommend that you stay current with the latest developments |
10:42:17 | erlnoob | i enjoy it a lot |
10:58:36 | erlnoob | ok, i compiled the one from github.. the instruction on the site tells me to compile and run koch (?), but it exits with FAILURE |
11:00:05 | zahary_ | at which step do you get the failure exactly? you extracted the sources, built a compiler with build.sh/bat, built koch with bin\nimrod koch.nim and then failed on koch boot -d:release? |
11:03:31 | erlnoob | yes, the part at ./koch boot -d:release exits with "FAILURE" and something about "lib/system.nim(2568, 32) Warning: unknown magic 'Locals' might crash the compiler" |
11:04:25 | erlnoob | anyways, i recompiled my test program to see if the subrange "bug" (?) is still there, and it is... |
11:04:39 | zahary_ | I think the problem is that you currently installed nimrod compiler is in your path |
11:05:14 | erlnoob | ah ok, may i ask what the koch program does? |
11:06:00 | zahary_ | .. so koch picks it up instead of using the one that you just build in the bin directory. |
11:07:23 | erlnoob | so.. i got 0.9.1 in my path.. but the bug is still there |
11:08:32 | erlnoob | anyways.. here's the output of koch boot -d:release (using nimrod 0.9.1): http://pastebin.com/DNR1EdXC |
11:18:30 | zahary_ | well. this is unexpected, but you could try some previous revision for the first bootstrap: git checkout 29bd96edb |
11:18:56 | zahary_ | then checkout master again and repeat koch boot -d:release |
11:20:34 | zahary_ | the error you are getting is about parsing the new object construction syntax. maybe we haven't rebuilt the sources after introducing it, Araq? |
11:21:51 | erlnoob | 0.9.1 still accepts values outside the defined subranges btw |
11:22:23 | zahary_ | you are still not on the head revision before a successful bootstrap. |
11:22:29 | erlnoob | is the koch thing really necessary? i installed the 0.9.0 from the website, just compile and start using... no koch |
11:23:51 | zahary_ | koch uses the latest C sources we have exported to build a recent compiler that it then uses to build the most up-to-date sources |
11:24:01 | zahary_ | ... up-to-date nim sources that is |
11:48:29 | * | zahary_ left #nimrod (#nimrod) |
11:49:00 | * | zahary_ joined #nimrod |
12:35:12 | Araq | erlnoob: you can get uptodate C sources for boostrapping from here: http://build.nimrod-code.org/commits/linux-x86/nimrod_9130ad264e2c_csources.zip |
12:42:13 | erlnoob | Araq: ok, downloading.. is an instruction included inside? what do i do with it? |
12:50:10 | * | Trix[a]r_za is now known as Trixar_za |
12:54:00 | Araq | erlnoob: https://github.com/Araq/Nimrod#compiling |
12:54:05 | dom96 | hello |
12:54:24 | Araq | you need to overwrite the csources.zip file and then it should work |
12:54:26 | Araq | hi dom96 |
13:00:36 | dom96 | Points to flect for mentioning Nimrod in their motivation. |
13:01:50 | erlnoob | Araq: it says linux-x86 but i'm on macosx.. should work right? |
13:02:28 | dom96 | erlnoob: yes, the zip contains C sources for all platforms. |
13:03:53 | erlnoob | failed building with: "clang: error: no such file or directory: 'build/3_2/ecmasgen.c'" |
13:04:14 | erlnoob | it's missing.. |
13:11:29 | dom96 | works fine here. |
13:11:39 | dom96 | (With the exception of having to create a bin directory) |
13:11:40 | Araq | erlnoob: you also need an up to date build.sh script ... sorry |
13:11:59 | dom96 | The C source zip contains the corresponding build.sh |
13:12:08 | erlnoob | oh i see |
13:18:40 | erlnoob | ok so using the latest git + the csources.zip from Araq, i'm able to compile nimrod 0.9.1 (2013-05-07) BUT now doing >bin/nimrod c koch gives the following: http://pastebin.com/LcQnzCQG |
13:21:41 | Araq | hmm dunno the clang compiler tends to cause problems |
13:22:23 | Araq | which reminds me ... I wanted to test it here on my machine |
13:25:00 | Araq | works here with Debian clang version 3.0-6 |
13:27:51 | erlnoob | so if i wait for the official release.. i won't have to deal with the koch thing right? |
13:28:15 | Araq | right |
13:28:27 | Araq | but I wonder why you got a stack trace |
13:28:36 | Araq | the C sources should be in release mode |
13:29:03 | erlnoob | beats me man, i just type the commands to a t |
13:31:28 | Araq | nimbuild produces a debug version ... :-/ |
13:33:20 | Araq | Zor: "I dislike the second approach because it complicates the parsing stage rather significantly." <-- this is false |
13:34:04 | dom96 | hrm, my bad then? |
13:34:12 | Araq | dom96: yeah :P |
13:35:23 | dom96 | I'll generate some release C sources manually for erlnoob then. |
13:36:41 | dom96 | Araq: Just a matter of executing 'koch csource -d:release' right? |
13:37:08 | Araq | yes |
13:40:26 | * | Endy joined #nimrod |
13:49:37 | NimBot | Araq/Nimrod 228b511 Araq [+0 ±4 -0]: pegs/re =~ warns about scope rule change; improved docs |
13:59:39 | * | Trixar_za is now known as Trix[a]r_za |
14:11:42 | * | Amrykid quit (Ping timeout: 245 seconds) |
14:14:18 | * | Amrykid joined #nimrod |
14:33:44 | dom96 | erlnoob: Try these: http://picheta.me/csources_05_08.zip |
14:33:53 | dom96 | Sorry it took so long |
14:34:10 | erlnoob | dom96: ok, downloading.. don't worry, i really appreciate the effort |
14:36:26 | Zor | Araq: what? |
14:38:34 | Araq | Zor: it's from your blog I think |
14:39:04 | Araq | nimrod supports 'when' as a statement and in object declarations |
14:39:15 | Araq | that's 2 places not everywhere and works good enough |
14:39:17 | Zor | oh you are talking about the conditional compilation post |
14:39:31 | Araq | and it doesn't complicate the grammar |
14:39:52 | Araq | well not for nimrod at least as nimrod can be parsed without any symbol table whatsoever |
14:40:49 | Zor | Araq: in flect, I would have to support when in many places: at the top level, inside module decls, inside struct decls, inside union decls, inside union case decls, inside trait/impls decls, inside function decls (i.e. expr level) and probably others I'm forgetting |
14:41:29 | Araq | no you don't have to do that |
14:42:16 | Zor | that's a matter of opinion |
14:42:48 | Araq | not really, it's either part of the grammar and thus as constrained as any other syntactic construct |
14:42:57 | Araq | or you really want a preprocessor in the first place |
14:43:17 | Zor | ? |
14:43:21 | Zor | aren't you digressing here? |
14:43:51 | Zor | at least I don't see what that has to do with the many places I want to support conditional compilation in |
14:45:03 | Araq | well you can easily do: |
14:45:11 | Araq | when x: type T = int |
14:45:14 | Araq | else: type T = float |
14:45:26 | Araq | you want |
14:45:34 | Araq | type T = when x: int else: float |
14:45:40 | Araq | desparately and I dunno why |
14:46:41 | zahary_ | Zor is building a language too? post a link to the blog url please |
14:47:28 | Araq | zahary_: zor is the guy behind flect |
14:47:52 | zahary_ | yeah, I figured after reading the messages |
14:49:35 | dom96 | http://blog.alexrp.com/ |
14:50:52 | Zor | mind you, it's very much still in a research/design state :) |
14:51:41 | Zor | Araq: no, but what I do want is the ability to e.g. have a different set of functions in an 'impl' body depending on some condition |
14:52:02 | Zor | or have different fields in a union case |
14:52:20 | Zor | it's also no unreasonable to want to only declare a module if the platform is e.g. posix or whatever |
14:52:24 | Zor | s/no/not/ |
14:55:30 | dom96 | Zor: I read your motivation behind Flect and still wonder: why not simply use Nimrod? |
14:57:01 | erlnoob | dom96: Araq: thank you both, it compiles successfully now.. and the subrange bug is gone in 0.9.1 (2013-05-08) |
14:57:18 | dom96 | erlnoob: Brilliant, glad to help :) |
14:57:23 | erlnoob | top notch support :) |
14:57:26 | erlnoob | hehe |
14:57:32 | Araq | there are still subranges bugs left :P |
14:57:51 | Araq | var r: range[1..3] # initialized with 0 |
14:58:09 | erlnoob | oh well, at least i'm on the same page now |
14:58:33 | erlnoob | it's a beautiful language |
15:02:09 | Araq | thanks |
15:19:07 | Araq | Zor: I still can't follow; just design your grammar flexible enough and you don't have to special case 'when' all the time |
15:19:53 | Zor | Araq: at that point it gets so flexible that I think a preprocessor would work just as well |
15:33:39 | zahary_ | imo the best way is if the whole grammar is just built out of expressions (point 3 in your blog) - then "when" is just another expression |
15:35:32 | zahary_ | with the white space sensitivity for operators and few more bits that we've discussed here before it's possible to define a very visually appealing grammar like that |
15:36:00 | Zor | my grammar is not purely expressions |
15:36:06 | Zor | everything is an expression inside functions |
15:36:14 | Zor | outside functions, there are just declarations |
15:37:41 | zahary_ | what is the benefit of special forms in the syntax in declarations? I have argued before that executable blocks are the best declarative mechanism |
15:38:32 | zahary_ | e.g. the way ruby class definitions work for example |
15:53:23 | * | erlnoob quit (Ping timeout: 245 seconds) |
15:53:41 | * | erlnoob joined #nimrod |
16:05:11 | Araq | Zor: a preprocessor has many disadvantages for refactoring tools ... |
16:05:45 | Araq | and a 3 level grammar lexer/preprocessor/parser is meh ... |
16:06:06 | Araq | arguably even the lexer/parser distinction is old fashioned |
16:06:26 | Araq | stemming from a time where cpus where much slower |
16:06:28 | zahary_ | the big problem with preprocessors in my book is that you lose any access to semantic information |
16:08:13 | Araq | the first version of nimrod had a preprocessor btw ... I'm glad I got rid of it early on |
16:08:32 | zahary_ | the point of macros and the other meta-programming facilities is that you expose all of knowledge the compiler has for the code structure and underlying types to the user |
16:08:33 | Araq | you can still see it in the configuration files: @if ... etc. |
16:10:59 | Zor | it isn't as if a preprocessor makes refactoring tools not work |
16:11:08 | Zor | see: every c# ide |
16:12:04 | Zor | the thing about refactoring in the presence of a preprocessor is just that you have to deal with unbalanced directives |
16:13:04 | Zor | most IDEs tend to choke on those (read: just delete them) which turns out to be fine in 99% of cases, because you should probably be shot if you write stuff like void foo () { \if ... } void bar () { \endif ... } |
16:15:16 | Araq | "yeah be shot" and yet people will do it and tools have to workaround it. It's just unnecessary complexity that helps nobody |
16:15:59 | zahary_ | C++ is a useful comparison point here. it has a preprocessor with similar capabilities, but people still need conditional compilation based on semantic information: |
16:16:00 | zahary_ | http://ecn.channel9.msdn.com/events/GoingNative12/GN12StaticIfIHadAHammer.pdf |
16:16:36 | * | fowl joined #nimrod |
16:17:50 | Zor | Araq: they do? we don't have any instances of such unbalanced directives anywhere in the entire mono tree, for instance |
16:18:02 | Zor | and we have an entire base class library in there, that needs to support tons of different targets |
16:18:21 | Araq | Zor: #ifdef __cpp: extern "C" { #endif |
16:19:01 | Zor | Araq: using C/C++ as a counter-example is just unfair considering they're both utterly insane |
16:19:35 | Zor | I'm talking about C#, a relatively sane language |
16:19:47 | Zor | (if you disregard the OOP) |
16:20:06 | fowl | Araq: did you want me to change the PR for hash(varargs[A]) |
16:20:15 | fowl | openarry* |
16:20:17 | zahary_ | It's common practice to bash C++, but semantics-wise it's much more interesting language to study than C# |
16:20:45 | Zor | you're missing the point here |
16:20:58 | Zor | we have a base class library that targets countless OSs and architectures, written in C# |
16:21:08 | Zor | and we don't need to write insane unbalanced preprocessor directives |
16:21:27 | Zor | that's kind of the point I'm trying to get across |
16:21:56 | zahary_ | alright, but you cannot do the tricks outlined in the document I linked (which were identified in places where the template system in C++ failed to deliver) |
16:22:26 | Zor | I don't contend that point |
16:22:58 | Zor | but I only have simple substitution-based generics, so it's not too relevant for me |
17:05:22 | Araq | fowl: that is correct, make it openarray; bad connection here, bbl |
17:06:22 | fowl | Araq: i did a couple days ago :) |
17:50:56 | * | fowl quit (Quit: Leaving) |
18:20:07 | * | erlnoob quit (Quit: erlnoob) |
18:29:20 | reactormonk | http://kripken.github.io/mloc_emscripten_talk/gindex.html#/20 hm. |
18:30:52 | Araq | reactormonk: asm.js is still a bad joke and unreal engine in the browser is sluggish as hell ... if it runs at all |
18:30:59 | Araq | 2x of native speed my ass |
18:39:26 | Araq | btw the new JS codegen is now in master, feel free to make it support asm.js. the codegen is now much more hackable imho |
18:48:53 | Araq | bbk |
18:48:56 | Araq | *bbl |
18:56:22 | * | xcombelle quit (Remote host closed the connection) |
19:11:03 | * | Endy quit (Ping timeout: 260 seconds) |
19:28:37 | * | Amrykid quit (Changing host) |
19:28:37 | * | Amrykid joined #nimrod |
19:40:33 | reactormonk | cool |
21:10:36 | * | fowl joined #nimrod |
21:16:56 | Araq | ping zahary_ |
21:52:36 | * | comex is now known as lycomthrope |
21:53:59 | * | lycomthrope is now known as comex |
22:23:56 | * | fowl_ joined #nimrod |
22:24:35 | * | fowl_ quit (Client Quit) |
22:55:48 | * | OrionPK joined #nimrod |
23:12:36 | NimBot | Araq/Nimrod 3905fe6 Billingsly Wetherfordshire [+0 ±1 -0]: add hashing for seqs |
23:12:36 | NimBot | Araq/Nimrod 036530c Billingsly Wetherfordshire [+0 ±1 -0]: Change hash[T](seq[A]) to take varargs[A] |
23:12:36 | NimBot | Araq/Nimrod 4171ff3 Billingsly Wetherfordshire [+0 ±1 -0]: Change varargs[T] to openarray[T] |
23:12:36 | NimBot | Araq/Nimrod 5949eab Araq [+0 ±1 -0]: Merge pull request #418 from fowlmouth/patch-5... 3 more lines |
23:21:12 | fowl | gettin my commit count up (: |
23:21:46 | Araq | I should review your macros_dsl for inclusion into the stdlib |
23:22:27 | Araq | but it's too late and I figured it's trivial to make the effect system much better so I'm doing this instead |
23:32:11 | fowl | is there a repos for nimrod project euler solutions |
23:33:16 | Araq | nimrod is on project euler, don't know who wrote the code |
23:33:20 | Araq | and I think it's pretty old |
23:35:00 | * | reactormonk quit (Ping timeout: 264 seconds) |