01:41:10  * karterkjoined
01:45:43  * karterkquit (Ping timeout: 260 seconds)
15:43:36  * mmaleckijoined
15:43:36  * indutnyjoined
15:43:36  * kohaijoined
15:43:36  * creationixjoined
15:43:36  * ryahjoined
16:50:40  <indutny>whoa
16:51:01  <indutny>https://github.com/indutny/candor/commit/d3602c04dc4e2073ea3f4b3388a7778e92c12693
16:51:04  <indutny>stack trace support
16:51:07  <indutny>creationix: ^^
16:51:09  <indutny>I promised ya
16:53:01  * hij1nxjoined
16:54:12  <indutny>hij1nx: hey man! https://github.com/indutny/candor/commit/d3602c04dc4e2073ea3f4b3388a7778e92c12693 :)
16:54:49  <hij1nx>oh nice!
16:55:14  <hij1nx>source map
16:55:17  <indutny>hehe
16:55:28  <indutny>yes, that was very interesting thing to implement
16:55:32  <indutny>AVL trees, etc
16:55:37  * hij1nxlikes
16:56:16  <hij1nx>oh! so it looks like i could super easily just get the AST?
16:56:22  <hij1nx>from a candor script?
16:56:39  <indutny>hm... yes, but in C++
16:56:57  <indutny>source maps has nothing to do with AST
16:57:05  <hij1nx>hehe i moved on
16:57:08  <hij1nx>I'm still code reading
16:57:13  <hij1nx>im talking about getting the AST
16:57:42  <hij1nx>wouldn't need something like uglify
16:58:27  <indutny>hm... I've no candor interface to parser
16:58:34  <hij1nx>would be awesome like functionname.toAST();
16:58:48  <indutny>heh, it's possible
16:58:59  <indutny>I know function's offset and length in the source
16:59:01  <hij1nx>that would be bad ass
17:00:25  <hij1nx>I'm not sure how significant new lines prevent JS from doing function-keyword-less functions...
17:00:59  <hij1nx>./be says we can't have that in JS because of significant newlines.
17:00:59  <indutny>huh?
17:01:13  <indutny>well
17:01:14  <hij1nx>./be (brendan eich)
17:01:20  <indutny>yes, I know that
17:01:23  <hij1nx>;)
17:01:36  <indutny>function a
17:01:37  <indutny>()
17:01:38  <indutny>{
17:01:38  <indutny>}
17:01:41  <indutny>that's possible in es
17:02:03  <hij1nx>ASI rules are the problem?
17:02:15  <indutny>what ASI stands for?
17:02:23  <hij1nx>automatic semicolon insertion
17:02:33  <indutny>ah, yes then
17:02:36  <hij1nx>ahh
17:02:37  <indutny>it'll insert ; after a
17:02:40  <hij1nx>yep
17:02:52  <indutny>so function's syntax should be changed dramatically
17:02:53  * alejandromgjoined
17:03:46  <hij1nx>I'm not sure how he associates additional `significant new line` rules with the risk of delivering ES6
17:03:51  <indutny>btw, we should invite ./be here :)
17:03:57  <hij1nx>yea for sure
17:04:05  <indutny>do you know his IRC nickname?
17:04:42  <hij1nx>i can't remember, I've seen him in #node.js before though
17:04:55  <hij1nx>#moz maybe?
17:05:03  <hij1nx>nope
17:05:07  <hij1nx>#mozilla
17:05:15  <indutny>hm... we can still do it at twitter :)
17:05:27  <hij1nx>yep
17:05:30  <indutny>one sec, finishing "Hello world" email
17:08:12  <hij1nx>this is essentially a self-balancing tree yeah? like a splay tree? https://github.com/indutny/candor/commit/d3602c04dc4e2073ea3f4b3388a7778e92c12693#L14R356
17:08:21  <indutny>not like splay, but yes
17:08:24  <indutny>that's AVL tree
17:08:52  <hij1nx>I'm not familiar with AVLTree
17:09:02  <hij1nx>what is the primary difference?
17:09:12  <indutny>splay is changing tree on reads
17:09:13  * hij1nxlazy
17:09:31  <hij1nx>ok, I'm fumbling through reading it =)
17:10:25  <indutny>:)
17:10:31  <hij1nx>ok i see how this is working, cool
17:11:01  <hij1nx>i was doing this a while ago… https://github.com/hij1nx/forest/blob/master/lib/splayTree.js
17:11:15  <indutny>oh
17:11:16  <indutny>cool :)
17:11:23  <hij1nx>i wanted to put together a huge collections of trees
17:11:32  <indutny>what v8 is using it for?
17:11:39  <hij1nx>i got too busy =)
17:11:51  <indutny>hahah
17:11:53  <indutny>kk
17:12:10  <hij1nx>bench marks
17:12:22  <hij1nx>its in the trunk for benches
17:12:41  <indutny>interesting
17:12:52  <indutny>curious what they're using for sourcemaps
17:14:07  <hij1nx>i just saw paul irish talking about that
17:14:10  <hij1nx>looking for the article
17:14:23  <indutny>nono
17:14:28  <indutny>not that sourcemaps
17:14:32  <indutny>sorry, wrong term
17:14:36  <indutny>:)
17:15:03  <indutny>they should have some sort of assembly-address to js-offset mapping
17:15:09  <hij1nx>ahh =)
17:15:26  <hij1nx>i have too many conversations going at the same time...
17:15:48  <indutny>hehe
17:15:59  <indutny>multitasking doesn't really work well for humans
17:17:06  <hij1nx>I'm looking through trunk and I'm not really seeing that code =(
17:18:58  * alejandromgquit (Quit: leaving)
17:19:37  <hij1nx>ok… back to cloud sockets...
17:21:06  <indutny>hij1nx: ++
17:21:07  <kohai>hij1nx has 9 kohais
17:21:10  <mmalecki>hij1nx: ++
17:21:10  <kohai>hij1nx has 10 kohais
17:42:06  * alejandromgjoined
18:04:03  * hij1nxquit (Quit: hij1nx)
18:08:47  * alejandromgchanged nick to alejandromg_w
18:09:00  <creationix>hello everyone
18:09:28  <creationix>brenden is in the #jsapi room all the time, but it's not freenode, it's mozilla's own irc server
18:10:11  <creationix>I like the stack trace API
18:10:24  <creationix>I can add stack traces to my error messages in candor.io now
18:10:38  <indutny>hi
18:10:55  <creationix>btw, how persistent is this array?
18:11:02  <creationix>and is it mutable
18:11:05  <indutny>creationix: totally not persistent
18:11:08  <indutny>yes it's mutable
18:11:15  <indutny>it's generated on each __$trace() call
18:11:19  <indutny>I can implement an API for you
18:11:32  <creationix>the v8 stack trace API (JS facing) is persistent and mutable
18:11:47  <creationix>meaning if I insert random properties in a level of the stack, I can retrieve it later on
18:11:55  <indutny>that won't work
18:12:05  <creationix>ok
18:12:18  <creationix>if it did work, I could implement a try..catch like semantic in pure candor
18:12:28  <creationix>that's how I implement pure js domains in node
18:12:55  <creationix>it can even cross async calls if I control all the event sources
18:13:01  <creationix>chained stack traces
18:13:07  <creationix>and chained error handlers
18:14:15  <creationix>so, for example, you register an error handler at the start of an http request, and then when an uncaught exception happens, I can trace it down to the http request that it originates from and clean up resources and send that client a 500 response
18:15:14  <creationix>all I need from candor is a stack-local storage
18:15:30  <indutny>hm...
18:16:56  <indutny>so you want to store somethink in stack-trace array
18:17:05  <indutny>something*
18:27:29  <creationix>right
18:28:43  * alejandromg_wchanged nick to alejandromg
18:28:50  <creationix>my try(fn) function will store something in the stack and call fn, then remove it when fn returns, but it throw(err) is called later in the stack, it will look for any stored handlers
18:30:37  <indutny>oooh
18:30:39  <indutny>let me think
18:30:39  <creationix>it doesn't have to be in the stack exactly
18:30:46  <creationix>A single stack local variable is fine
18:31:03  <creationix>I can still nest try by creating my own list and storing it in that single slot
18:31:42  <creationix>I just use the v8 stack array because it's stack local and persistent
18:32:30  <indutny>can't that be managed in candor-land?
18:32:38  <creationix>I guess what I can't do is force the stack to unwind
18:32:58  <creationix>how would I store a stack local variable in pure candor?
18:33:03  <creationix>I don't control every function call
18:36:02  <creationix>my programming language professor always said exceptions were evil
18:36:05  <creationix>I don't understand why
18:36:30  <creationix>of course he was into provable languages and ml variants
18:37:16  <indutny>brb
18:58:20  <indutny>creationix: https://github.com/indutny/candor/commit/ea5ee4e8261216251c39410fa6ca3cb0fb132124
19:00:43  <creationix>cool
19:24:47  <indutny>exceptions are evil
19:24:55  <indutny>like a goto
19:32:46  <mmalecki>well, they are a bit like goto ;)
19:35:21  <indutny>not really :)
19:35:25  <indutny>but yes
19:35:26  <indutny>goto are just jumps
19:35:47  <indutny>exceptions are unwinding stack and sending some information to handler
19:41:51  * Raynosjoined
19:42:57  <indutny>creationix: I think pure candor exceptions won't behave well
19:43:13  <indutny>creationix: that works fine in functional languages, because they're using CPS
19:43:28  <indutny>creationix: and compiler transforms that stuff in optimized code
19:43:44  <indutny>optimizing such level of abstraction in non-functional language is quite hard
19:44:46  <indutny>so we should decide: either we need exceptions or not
19:46:26  <Raynos>Is there a plan for candor -> js compiler
19:46:48  <Raynos>or is the purpose of candor completely abstract from compliance with browsers / node / js environments
19:48:32  <Raynos>Ah I see candor.io
19:59:24  <indutny>Raynos: creationix was working on candor.js
19:59:45  <indutny>but it's far from something working now : https://github.com/creationix/candor.js
20:00:03  <indutny>though it shouldn't be really hard to implement (except non-string keys)
20:00:36  <Raynos>I see
20:00:53  <indutny>Raynos: candor itself is an abstract language which itself can't do any IO
20:01:00  <indutny>Raynos: and should have bindings like in candor.io
20:01:19  <Raynos>whats the purpose of it?
20:01:22  <Raynos>What problem does it solve?
20:01:25  <indutny>Raynos: of candor?
20:01:35  <Raynos>Alternatively is candor just an experiment for fun
20:01:54  <indutny>can't argue with that, developing candor is fun :)
20:02:21  <indutny>though, it's purpose is to provide simple language with js-like semantics, but with less features, and, therefore, better performance
20:02:56  <indutny>so I'm completely serious about it
20:06:25  <indutny>Raynos: btw, join candor's google group: https://groups.google.com/forum/?fromgroups#!forum/candorlang
20:07:04  <Raynos>I see
20:07:15  <Raynos>Looking at it as a js dev I wonder what I need
20:08:01  <indutny>Raynos: would be great if you'll put your ideas here: https://groups.google.com/forum/?fromgroups#!topic/candorlang/0ms6AvrQjYQ
20:08:37  <indutny>candor is not a replacement for js, but it should solve a lot of WAT that people feel about js (though, I love JS with all my heart)
20:10:58  * hij1nxjoined
20:12:01  <Raynos>One thing I like is a way to do modules
20:12:10  <Raynos>cross file development of some format
20:14:25  * hij1nxquit (Client Quit)
20:15:52  * hij1nxjoined
20:18:46  <indutny>Raynos: well, by default each compiled file has it's own global context
20:18:56  <indutny>implementing modules is up to IO bindings developer
20:19:05  <Raynos>I can see that
20:19:16  <Raynos>however you have an oppurtunity to do modules correctly at the syntax level
20:19:21  <Raynos>that might be worth exploring
20:19:24  <indutny>right
20:19:28  <indutny>what's your proposal
20:19:34  <indutny>can you send it to the group?
20:19:40  <Raynos>No clue what to propose
20:21:04  * hij1nxquit (Quit: hij1nx)
20:22:00  <Raynos>Are functions hoisted up like javascript is?
20:22:19  <indutny>no
20:22:28  <indutny>but they may be
20:22:37  <indutny>if there's a need for that
20:22:46  <indutny>a() { } <=> a = () {} now
20:22:47  <Raynos>I personally like that feature for code organization but thats opinionated
20:23:26  <Raynos>Is there anything equivelant to arguments?
20:23:59  <indutny>creationix proposed some sort of vargs via "...", but I haven't decided about that yet
20:29:18  * hij1nxjoined
20:34:25  <Raynos>I was thinking that
20:34:26  <Raynos>https://gist.github.com/b86ed871069c90a55bb7
20:34:33  <Raynos>I rewrote my pd js lib using candor (I think)
20:35:14  <indutny>hm... looks good!
20:35:26  <indutny>can I ask you to put that into group too?
20:36:11  <indutny>I like it, it's like in lua, but w/o vague "args" variable that poisons on-stack vars
20:38:29  <Raynos>I quite like ... as well
20:39:21  <indutny>Raynos: thanks
20:39:23  <indutny>going to sleep now
20:39:24  <indutny>ttyl
20:39:26  <Raynos>gn
20:39:27  * indutnychanged nick to indutny_sleeping
20:51:00  * hij1nxquit (Quit: hij1nx)
21:09:57  * hij1nxjoined
21:19:38  * hij1nxquit (Quit: hij1nx)
21:24:01  <creationix>did I really just say "if we has" on the mailing list?
21:24:07  * creationixhangs head in shame
21:31:07  <creationix>heh, stated goal of harmony rest arguments "Provide a better arguments so we can deprecate, obsolete, and some years hence burn with fire / salt the earth anything to do with arguments, foo.arguments, etc."
21:47:34  <Raynos>I quite like the rest arguments
21:47:47  <Raynos>Is there an equivelant to functionReference.length in candor?
21:48:11  <Raynos>For example express and async.js send different parameters based on the parameters the function accepts
21:50:44  * hij1nxjoined
22:30:29  <creationix>Raynos, still here
22:30:32  <creationix>?
22:31:30  <Raynos>yes
22:31:56  <Raynos>functions dont have properties :(
22:31:58  <Raynos>that is sad
22:34:38  <creationix>keeps things simple
22:34:38  * hij1nxquit (Ping timeout: 240 seconds)
22:34:51  <Raynos>But I like treating functions as objects
22:35:19  <creationix>as do I
22:35:22  <creationix>but it's not required
22:35:28  <creationix>and it does complicate things
22:35:41  <Raynos>I see your point
22:35:54  <creationix>anyway, function arity should be using sizeof
22:36:03  <creationix>I think that' fair to add if indutny_sleeping can implement it
22:37:48  <creationix>so I think destructuring is too much
22:37:52  <creationix>and it's just sugar
22:37:56  <creationix>but varargs is a primitive
22:38:06  <creationix>it really limits the language if it's not there somehow
22:39:18  <creationix>I want a way for people to add sugar to the language a'la coffeescript
22:39:24  <creationix>with sourcemap
22:39:37  <creationix>then candor can just provide the bare primitives and focus on being an awesome vm
22:40:55  <Raynos>:)
22:41:19  <Raynos>I think function arity with sizeof is useful and I would still push for functions to have properties because it gets annoying if they can't
22:41:57  <Raynos>and since candor has no exception
22:42:13  <Raynos>what would adding properties at run time to a function do?
23:03:46  * hij1nx_joined
23:13:33  * hij1nx_quit (Quit: hij1nx_)
23:19:26  <creationix>what does adding properties to a number do
23:19:43  <creationix>candor basically does nothing or returns nil when there is a problem