IRC Logs for #io Friday, 2014-10-10

*** hashmal has quit IRC01:25
*** hashmal has joined #io01:26
*** hashmal has quit IRC01:30
*** gatesphere has quit IRC02:44
*** chadkouse has joined #io02:51
*** chadkouse has quit IRC03:59
*** AKASkip has joined #io05:47
*** AKASkip has quit IRC06:10
*** AKASkip has joined #io07:03
*** pchalupa has joined #io07:08
*** hashmal has joined #io07:35
*** hashmal has quit IRC08:24
*** TheMonkey has joined #io08:35
*** ElMonkey has quit IRC08:39
*** bjz has joined #io09:27
*** ijon_ has joined #io11:14
*** hashmal has joined #io11:41
*** fxbert has joined #io11:49
*** bjz has quit IRC11:53
*** bjz has joined #io12:01
*** AKASkip has quit IRC13:14
fxberti can’t seem to find a documentation of the message(…) method. does anyone know where its behavior is documented?13:35
bomma_http://iolanguage.org/scm/io/docs/reference/index.html#/Core/Core/Object/message13:42
fxbertthanks bomma13:46
fxbertwhat i dont understand is, how message can be called in the lobby but lobby does not have Object as a prototype … and message is a method of Object13:47
fxbertnevermind it indirectly does13:47
*** fredreichbier has joined #io14:15
*** AKASkip has joined #io15:26
*** fredreichbier has quit IRC15:30
*** fredreichbier has joined #io15:36
jerfredreichbier, but Lobby does have object as a prototype, eventually =]16:30
jerLobby's proto is a system level object that holds all the classes, and its proto is Object16:30
jerthis is commonly referred to as the chicken-egg problem and we break it by setting this up at compile time of the interpreter16:30
jerso Lobby's proto is Protos, Protos is Object16:31
fredreichbierfredreichbier, think you mis-tabbed me here :)16:31
jererr16:31
fredreichbier(but interesting nonetheless!)16:31
jeryeah i did16:31
jerfxbert, ^^^^16:31
jeri usually only poke my head in here about once a day, but if you have these kinds of internal questions and can't get other satisfactory responses, just hang around =]16:34
*** fredreichbier has quit IRC16:47
fxbertokay jer :)16:53
fxbertty16:53
fxberti’ve also been looking for documentation on where linebreaks are allowed in an io program … seems as if can be problematic if there is one between an object an a message16:55
*** AKASkip has quit IRC17:09
jeryes it can17:21
jerin general, don't do that =]17:21
jerit's a failure of the syntax17:21
jernewlines and semicolons denote the end of a message tree, and while you can use \ in strings, outside, it just doesn't work17:22
*** ijon_ has quit IRC17:22
jeryou however, might be able to use do()17:22
jeri.e.,17:22
jerfoo do(17:22
jer  msg1 msg217:23
jer)17:23
jerinstead of: foo msg1 msg217:23
jerbearing in mind that do() returns the receiver after executing the messages17:23
jerso depending on how you're using it, may not work for you17:23
fxberthmm ic17:24
fxberthow do you know newline mark the end of a message tree? i was searching all around but couldnt find it in the docs … 17:25
*** ijon_ has joined #io17:31
fxberti like io, but sometimes it drives me nuts17:31
jerit's not in the docs17:32
jer=]17:32
fxbertfor example when executing: 2 + 3 println17:32
fxberti see17:32
jerit's burried in the internals17:32
fxberti was poking around in the source code but couldn’t make much sense of it17:32
jerio's syntax could be simplified and cleaned up quite a bit17:32
jerjust nobody has the desire to do it17:32
fxbertalso when changeing the operatorTable in interactive mode it works but not when running the script from file17:33
fxberti guess thats because the syntax tree is build before the operatorprecedences are set by the program17:34
jeroh yes17:36
jerok so that's easier to explain17:36
jerwhen parsing a file, we do a pass over it to build the AST before we execute anything, since we're a tree walking vm we need the AST to execute17:36
fxberti see17:36
fxbertare you on the dev team of io?17:36
jerwhich means, we have to parse the whole file, since our AST is mutable, if we did it incrementally, a user could manipulate the AST at some point in the file invalidating what we have already executed17:36
jerio doesn't time travel17:37
jerfxbert, used to be17:37
fxberti see :D17:37
jerinteractively, we doMessage() everything basically17:37
jerbasically, parse your input into a message, then pass it ot doMessage on the lobby 17:37
fxbertright, because the AST cant be build before the command is known17:37
jerhow we load files basically is a doFile()17:37
fxbertcool17:37
jerworks the same way on a different resource (string vs file)17:37
jerfxbert, to clarify a bit more on your statement17:38
jerAST can't be executed until all of it is known17:38
fxberti see17:38
jersince we allow first class access to the AST at runtime and let you mutate17:38
jertradeoffs =]17:38
fxbertwith power comes great responsibility17:39
jerso consider: adder := method(a, b, a + b); getSlot("adder") message next setName("-"); adder(1, 2) == -117:39
jeri effectively changed adder, after its definition, from a + b, to a - b17:40
jerthis example is contrived of course, you can think of better ways to use this (macro expansion, for instance) but yeah generally discouraged, but permitted17:40
fxbertio is fun, love the fact that you can kill yourself by removing all slots from Object :D17:41
jeroh yes17:41
jerC may let you shoot yourself in the foot, C++ blow your leg off, but io lets you erase yourself from history17:41
jer=]17:41
fxbertxD17:41
fxberti am just starting to learn io (from the 7 weeks book) so far it has been really refreshing17:42
jerah ok17:43
jermy example in that book (I'm Jeremy Tregunna) is horrible horrible horrible =]17:43
jeri wish i hadn't have given it to bruce17:43
jer=]17:43
fxbertwhich example?17:43
jerday 3 17:43
jerthe phone book17:43
fxbertah hehe :D17:43
fxbertim at day 2 ;)17:44
jerah17:44
jerwell my example is neat conceptually, but if i were doing it all over again, i'd give a different example17:44
fxbertlike how?17:44
jerlike a proper message patcher17:44
jerinstead17:44
fxberthm k17:44
jerwhich could be used as a piece of a macro expander17:44
jerbasically, what it'd do is walk any arbitrary message you passed in, and replace known patterns, with some other message and link everything up17:45
jerso if you had a message tree like this: a b XXX d and you wanted to replace XXX with: + then you'd get a b + d17:45
fxbertokay17:45
jeranyway, the patcher would walk the AST< find a supplied pattern, rip it out, and splice in your message tree17:47
jerjust like you'd expect to occur in macro expansion17:47
fxberti love this17:47
fxberti was wondering17:48
fxbertwhen the AST ist build wouldn’t it be possible to make io take into account how the operator precedences are changed in the program? or is there a technical problem preventing this?17:49
jersorry was away for a bit19:11
fxbertnp, im on air @ radio right now19:12
jerio's operator precedence rules are only known after the whole AST is built19:12
jerbecause it does message rewriting19:12
jerbased on those rules19:12
jerso it has to know everything ahead of time19:12
jerif it didn't, it couldn't do operator precedence with varying levels of precedence19:12
jerconsider: 1 + 2 * 3 / 4 % 1019:13
jer3 different precedence rules there; if it did it incrementally, you'd get: 1 +(2 *(3)) /(4 %(10))19:13
jerwhich would give you the wrong result19:13
jerthat's actually the best it could do19:14
jerbut if we can look at whole message trees, then we can see how to parse it properly19:14
jer1 +(2 *(3) /(4)) %(10)19:14
fxbertbut a subtree of the AST could be build using different precedence rules … in theory at least19:15
jerit could be19:17
jersince we get our tree after parsing like this:19:18
jer1 +(2) *(3) /(4) %(10)19:18
jerwe have to rewrite parts of it19:18
jeri.e., the middle chunk, has to go in the argument to +19:18
fxbertyea19:18
jeroh also one caveat with manipulating the AST, it won't recalculate precedence rules =]19:19
jerso if you change + to *, you still get +'s precedence rules19:19
fxberttrue19:19
fxbertan assembler does two sourcecode scans .. one to build the symbol table and one to translate the code to machine instructions 19:20
fxbertwhat if one would scan for operatortable changes before building the AST  so that one knows where in the AST operators change19:21
jerinteresting thought19:22
jerthat would require semantic analytsis though in an io-like langauge19:23
jersince all our calls are dynamically bound, the receiver of any given method may change the semantics of a method, you can't reason about this ahead of time19:23
fxbertthats right19:23
jerthis is also the hardest part about io to optimize19:24
fxbertkind of an hen and egg problem19:24
jerwe have no constraints on side effects19:24
fxbertthats a great quote :D19:24
jerso even if you did spawn up a new IoState to run this code in, sandbox style, if that code launches missiles, you're fucked19:24
fxbertpretty much yea 19:25
jeri want to build another language sometime19:25
jera simply typed lambda calclus language based on a linear type system =]19:25
fxbertlike what kind of lang?19:25
jerpretty much the exact opposite of io19:26
fxberthave you heard of Omega?19:26
jeri have19:26
jeri'd just want to build a toy to explore the idea of linear types more19:26
jererr, Omega no, i read that as "Clean"19:26
jer=p19:26
fxberthehe19:26
fxbertthe idea is intriguing: http://lambda-the-ultimate.org/node/408819:27
fxberta program is a proof of its own correctness19:27
jerooo neat19:27
fxbertwhat exactly does linear types mean?19:27
jerwell, basically you can think of linear type systems enforcing that there can only ever be one reference of some value19:27
fxbertok19:28
jerand it also enforces that a program cannot alias some type to some other type19:28
fxbertso you cant cast types?19:28
jerClean uses a similar type system19:28
jernope19:28
fxbertah ic19:28
jerbut yeah, one day i'm figuring i'll write a little toy language to explore this idea19:29
fxbertthats alot of work, interesting work though19:29
jerwell, dev tooling is what i like to work on19:30
jerlanguages, debuggers, ides, ...19:30
fxberti figured :)19:30
jerin my day to day i write ios apps though =/19:30
jerso any chance i get where i think i can dedicate enough time to toying with some new-to-me technology, i take it19:30
fxbertswift is another thing on my backlog of things to try :D19:30
fxbertyea i have the same problem19:31
jerif not for my visa situation, i'd probably be on campus right now interviewing for swift -- phone screens went awesome, they wanted to continue but didn't have the time to go through a visa process, position was immediate need19:31
jer=[19:31
jerswift is a language i'd have loved to work on19:31
fxbertwhre are you based? eu?19:32
fxberti hear there are many interesting tech jobs in the uk19:33
fxbertmy brother is moving there right now19:33
jeri'm in Costa Rica right now, but i'm Canadian19:33
jermoved here a few years ago19:33
jerdon't hold an H1 class visa, could go TN route too, which is quicker, but apparently not quick enough19:33
fxbertnice19:33
fxberti keep reading about the rediculous visa and work permit process in the us19:34
jeri'm not inclined to leave costa rica, given i make a NYC wage on a Costa Rican cost of living =]19:34
fxbertalot of companys dont want to go through the process19:34
jerunless of course, it's for something i can't say no to19:34
fxbert:)19:34
jerso when i was asked if i'd apply for the swift team, jumped on it19:34
fxbertwho wouldn’t19:35
fxberta friend of mine just turned down google19:35
fxbertif it was me i’d look into it at least :o19:35
jeri've narrowly avoided going to google in 2 aquisitions, and 2 separate intense recruiter efforts19:35
jergoogle couldn't offer me anything (public at least) to make me go19:35
jerlast time i avoided joining google, was 1 day before the deal closed when Google acquired PostRank19:36
jerwe were made aware 4 days earlier, and i had already decided that i was going to move to Costa Rica with my wife19:36
jer=]19:36
fxbertthats a pretty good situation to be in, im in college right now, i hope to be as successful :D19:36
jeri've been lucky19:37
jerright place, right time kinda thing19:37
jernot to make it seem like i suffer from imposter syndrome, i am well aware and happy with what i've accomplished in my life19:37
jerbut so much more to do19:37
fxbertluck is one thing, but i guess your skills did bring you in that situation in the first place19:38
jerwell, being able to get shit done, learn, and be interested in things helps19:39
jersure19:39
jerthat's "lasting power"19:39
jer=]19:39
fxbert^^19:39
jerluck gets you the opportunity in the first place19:39
jerwell, luck and timing19:40
jer=D19:40
fxbertand skill!19:40
fxbert:p19:40
*** pchalupa has quit IRC20:19
*** AKASkip has joined #io20:36
*** ElMonkey_ has joined #io21:02
*** TheMonkey has quit IRC21:06
*** ijon_ has quit IRC21:16
*** fxbert has quit IRC21:17
*** fxbert has joined #io21:18
*** fxbert has quit IRC21:18
*** AKASkip has quit IRC21:36
*** gatesphere has joined #io21:49
*** Stalkr_ has joined #io21:54
*** lym has joined #io21:58
*** lym has left #io ()21:58
*** petr has quit IRC22:11
*** petr has joined #io22:14
*** ijon_ has joined #io22:20
*** Stalkr_ has quit IRC23:01
*** ret2libc has joined #io23:10
*** ret2libc has quit IRC23:12
*** ret2libc has joined #io23:13
*** ret2libc has quit IRC23:20
*** bjz has quit IRC23:45

Generated by irclog2html.py 2.11.0 by Marius Gedminas - find it at mg.pov.lt!