| 22:41:47 | * | NimBot joined #nimrod | 
| 22:41:57 | dom96 | !ping | 
| 22:41:57 | NimBot | pong | 
| 22:42:08 | dom96 | Alright, everything works now :) | 
| 22:44:10 | filwit | Araq: I kinda agree with you that 'else' should be indented after 'case' statements | 
| 22:44:32 | Araq | good | 
| 22:44:38 | Araq | !lag | 
| 22:44:38 | NimBot | 51ms between me and the server. | 
| 22:54:43 | filwit | so a variant object is like a union with runtime checks? | 
| 22:57:16 | Araq | yes | 
| 22:57:31 | Araq | or like a 'sum' type if you're into FP | 
| 22:58:17 | Araq | in fact FP languages tend to "prove" the correct usage but this doesn't work well with nimrod's mutability of objects | 
| 22:58:21 | filwit | are these runtime checks removed with release builds btw? | 
| 22:58:29 | Araq | yes | 
| 22:58:33 | filwit | great | 
| 22:58:40 | Araq | no ... ;-) | 
| 22:58:51 | filwit | damn... ;0 | 
| 22:59:02 | Araq | but good enough for now | 
| 22:59:35 | Araq | filwit: you will always be able to turn them off don't worry | 
| 23:00:00 | Araq | but I'd prefer more efficient checks instead of none | 
| 23:00:54 | Araq | it depends on your use case, but I feel a bit uneasy to deploy server software without all these safety checks | 
| 23:01:12 | filwit | well I'd love effecient checks as well. But I like the idea of checks-at-debug, fast-as-possible at release | 
| 23:01:22 | Araq | sure | 
| 23:01:55 | filwit | so I'm totally find if the checks are there with -d:release, as long as I can pass another flag that turns them off | 
| 23:02:26 | Araq | I'll see how clang's hot/cold code distinction helps | 
| 23:02:29 | filwit | but all that's not so pressing right now | 
| 23:02:33 | Araq | for the runtime checks | 
| 23:03:02 | Araq | in general it's hard because we don't control the backend | 
| 23:03:45 | Araq | otherwise we could easily keep the overhead of these checks to a minimum | 
| 23:05:07 | filwit | I see, well you know a whole lot more about that stuff than I do, so I'm sure you'll make the right choices :) | 
| 23:12:46 | Araq | in fact, the situation is already very good as you can turn the checks on and off for specific sections of code :-) | 
| 23:13:07 | Araq | so turn them on, profile and turn off for the bottlenecks :D | 
| 23:13:09 | filwit | {.push checks.} you mean? | 
| 23:13:14 | Araq | yes | 
| 23:13:30 | filwit | ya I liked that {.push.} when I saw it | 
| 23:14:18 | filwit | is there a syntax to pass procs around cleanly? | 
| 23:14:20 | filwit | meaning: | 
| 23:14:40 | filwit | proc foo(callback:proc()): | 
| 23:14:44 | filwit |   callback() | 
| 23:14:48 | filwit | then... | 
| 23:15:02 | filwit | foo((){ | 
| 23:15:06 | Araq | foo(proc () = echo "hi") | 
| 23:15:07 | filwit |   doSomethign() | 
| 23:15:10 | filwit | }) | 
| 23:15:31 | filwit | right, great | 
| 23:15:34 | filwit | let me try | 
| 23:17:27 | filwit | that's awesome, and very clean | 
| 23:17:45 | Araq | thanks | 
| 23:17:49 | filwit | are proc var's subject to inlining at all? | 
| 23:17:56 | filwit | i'm asuming no | 
| 23:18:00 | filwit | assuming* | 
| 23:18:00 | Araq | not yet | 
| 23:18:07 | filwit | so it's possible? | 
| 23:18:09 | Araq | but it's simple to implement | 
| 23:18:18 | filwit | nice | 
| 23:19:00 | filwit | I was telling you before about my jQuery-style game engine idea, being able to supply functions to procedures like this may be a key component | 
| 23:19:20 | filwit | also, I noticed that there's JSON style syntax somewhere... | 
| 23:19:25 | filwit | which is another | 
| 23:19:35 | Araq | there is a json module yes | 
| 23:19:40 | Araq | heavily used in fact | 
| 23:20:09 | filwit | i mean the: var data = {"name":"Philip", "age":24} thing | 
| 23:20:32 | filwit | that's also very good for MongoDB support I'm sure | 
| 23:20:46 | Araq | it's just sugar for an array of tuples | 
| 23:21:13 | Araq | [("name", "Philip"), ("age", "24")] | 
| 23:21:21 | filwit | yes, but the syntax is clean enough to use for things like MongoDB in the same way you use it with Javascript | 
| 23:21:29 | Araq | note the need for consistent types | 
| 23:21:31 | Araq | however | 
| 23:21:39 | Araq | you can pass it to a macro :-) | 
| 23:21:43 | filwit | ah, I see | 
| 23:22:03 | filwit | yes, macros make that very useful | 
| 23:23:07 | Araq | you can also do: | 
| 23:23:24 | Araq | template `<=` (a, b: expr): expr = (a, b) | 
| 23:23:24 | filwit | damn, man. Isn't it like 1:30 over there? | 
| 23:23:45 | Araq | ["key" <= "value", "key2" <= "value3"] | 
| 23:23:48 | Araq | etc. | 
| 23:23:52 | Araq | ugh | 
| 23:23:55 | Araq | you're right | 
| 23:24:25 | filwit | ya, I always end up staying up to late and paying for it in the morning :) | 
| 23:24:56 | Araq | yeah good night | 
| 23:25:01 | filwit | night |