--- Log opened Sun Mar 15 00:00:07 2015 |
00:15 | | Turaiel is now known as Turaiel[Offline] |
01:29 | | thalass [thalass@Nightstar-h1qmno.eastlink.ca] has joined #code |
01:29 | | mode/#code [+o thalass] by ChanServ |
01:32 | | PinkFreud [WhyNot@Pinkfreud.is.really.fuckin.lame.nightstar.net] has joined #code |
01:32 | | mode/#code [+o PinkFreud] by ChanServ |
01:59 | | * Derakon debugs some code for work via the built-in scripting panel, eyes this line. |
01:59 | <&Derakon> | org.micromanager.MMStudio.getInstance().frame_.metadataPanel_.contrastPanel_.cur rentHistograms_.ccpList_.get(0).cache_.getSummaryMetadata().getJSONArray("ChName s"); |
01:59 | <&Derakon> | (I'd previously overridden Java's normal public/private system; normally none of these fields would be directly available) |
02:55 | | VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has quit [Connection closed] |
03:10 | | Turaiel[Offline] is now known as Turaiel |
03:48 | <@celticminstrel> | Eh? |
03:50 | <&Derakon> | CM: that's just me descending through the object heirarchy of our program. I have to start from MMStudio, and my end point is some of the metadata for a dataset. |
03:55 | | thalass [thalass@Nightstar-h1qmno.eastlink.ca] has quit [Operation timed out] |
03:56 | | thalass [thalass@Nightstar-h1qmno.eastlink.ca] has joined #code |
03:56 | | mode/#code [+o thalass] by ChanServ |
03:58 | | macdjord|slep [macdjord@Nightstar-r9vt2h.mc.videotron.ca] has quit [[NS] Quit: Tekeli-li! Tekeli-li!] |
04:03 | | Derakon is now known as Derakon[AFK] |
04:12 | <@froztbyte> | Derakon[AFK]: such private namespace access!~ |
04:12 | <@froztbyte> | what's with the _ suffix on some? |
04:12 | <@froztbyte> | oh, they're on all |
04:12 | <@froztbyte> | my eyes just don't work |
04:42 | | Orthia [orthianz@Nightstar-5r9l9s.callplus.net.nz] has quit [[NS] Quit: Going dooooown...] |
04:55 | | Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has quit [Connection reset by peer] |
05:04 | | macdjord [macdjord@Nightstar-r9vt2h.mc.videotron.ca] has joined #code |
05:04 | | mode/#code [+o macdjord] by ChanServ |
05:05 | | Orthia [orthianz@Nightstar-5r9l9s.callplus.net.nz] has joined #code |
05:06 | | mode/#code [+o Orthia] by ChanServ |
05:27 | | thalass [thalass@Nightstar-h1qmno.eastlink.ca] has quit [[NS] Quit: Leaving] |
05:33 | | celticminstrel [celticminst@Nightstar-gmujup.dsl.bell.ca] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] |
06:25 | | Alek [omegaboot@Nightstar-03ja8q.il.comcast.net] has quit [Ping timeout: 121 seconds] |
06:28 | | Alek [omegaboot@Nightstar-03ja8q.il.comcast.net] has joined #code |
06:28 | | mode/#code [+o Alek] by ChanServ |
06:49 | | Kindamoody[zZz] is now known as Kindamoody |
07:09 | | Checkmate [Z@Nightstar-484uip.cust.comxnet.dk] has joined #code |
07:09 | | mode/#code [+o Checkmate] by ChanServ |
07:11 | | Syka_ [the@Nightstar-c409v3.vividwireless.net.au] has quit [Connection closed] |
07:11 | | Syka [the@Nightstar-c409v3.vividwireless.net.au] has joined #code |
07:54 | | Checkmate [Z@Nightstar-484uip.cust.comxnet.dk] has quit [Ping timeout: 121 seconds] |
07:57 | | macdjord [macdjord@Nightstar-r9vt2h.mc.videotron.ca] has quit [Ping timeout: 121 seconds] |
08:04 | | Turaiel is now known as Turaiel[Offline] |
08:47 | | kourbou|sleep is now known as kourbou |
09:02 | < kourbou> | I miss pi day already :( Yesterday was 3/1415 |
09:17 | | AverageJoe [evil1@Nightstar-2ofrtr.ph.cox.net] has joined #code |
09:28 | | macdjord [macdjord@Nightstar-r9vt2h.mc.videotron.ca] has joined #code |
09:28 | | mode/#code [+o macdjord] by ChanServ |
09:37 | | kourbou_ [kourbou@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
09:39 | | kourbou_ is now known as recover |
09:40 | | kourbou [holoirc@Nightstar-deqg8j.fbx.proxad.net] has quit [NickServ (RECOVER command used by recover)] |
09:40 | | recover is now known as kourbou |
09:40 | | kourbou|phone [holoirc@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
10:11 | | AverageJoe [evil1@Nightstar-2ofrtr.ph.cox.net] has quit [Ping timeout: 121 seconds] |
10:27 | | VirusJTG [VirusJTG@Nightstar-6i5vf7.sta.comporium.net] has joined #code |
12:22 | | Kindamoody is now known as Kindamoody|afk |
13:49 | | kourbou|phone [holoirc@Nightstar-deqg8j.fbx.proxad.net] has quit [Connection closed] |
13:50 | | kourbou|phone [holoirc@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
13:54 | | kourbou|phone [holoirc@Nightstar-deqg8j.fbx.proxad.net] has quit [Connection closed] |
14:13 | | kourbou|phone [holoirc@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
16:02 | | Turaiel[Offline] is now known as Turaiel |
16:10 | | celticminstrel [celticminst@Nightstar-gmujup.dsl.bell.ca] has joined #code |
16:10 | | mode/#code [+o celticminstrel] by ChanServ |
16:55 | | kourbou [kourbou@Nightstar-deqg8j.fbx.proxad.net] has quit [Ping timeout: 121 seconds] |
17:14 | | Turaiel is now known as Turaiel[Offline] |
17:41 | | kourbou [kourbou@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
18:02 | | Turaiel[Offline] is now known as Turaiel |
18:11 | | Derakon[AFK] is now known as Derakon |
18:19 | | Turaiel is now known as Turaiel[Offline] |
18:24 | | Vash [Vash@Nightstar-uhn82m.ct.comcast.net] has joined #code |
18:24 | | mode/#code [+o Vash] by ChanServ |
18:25 | | Turaiel[Offline] is now known as Turaiel |
18:50 | | kourbou is now known as kourbou|food |
18:51 | | Kindamoody|afk is now known as Kindamoody |
19:16 | | kourbou|food is now known as kourbou |
19:53 | | Harlow [harlow@Nightstar-oteu2h.il.comcast.net] has joined #code |
20:09 | | Harlow [harlow@Nightstar-oteu2h.il.comcast.net] has quit [[NS] Quit: sleep] |
20:10 | | kourbou [kourbou@Nightstar-deqg8j.fbx.proxad.net] has quit [[NS] Quit: Got to go. Bye.] |
20:18 | | kourbou|phone is now known as kourbou |
20:26 | | himi [fow035@Nightstar-v37cpe.internode.on.net] has quit [Ping timeout: 121 seconds] |
20:28 | | Harlow [harlow@Nightstar-oteu2h.il.comcast.net] has joined #code |
20:33 | < Harlow> | Raw sockets from javascript are impossible :( |
20:33 | | Kindamoody is now known as Kindamoody[zZz] |
20:41 | < kourbou> | That's why you use Socket.io :) |
20:47 | < [R]> | Harlow: Browser-JS? Yes. |
20:53 | < Harlow> | socket io is just web sockets though |
20:53 | < Harlow> | I just want to use nectar |
20:53 | < Harlow> | netcat* |
20:53 | < Harlow> | on the server side |
20:57 | | Checkmate [Z@Nightstar-484uip.cust.comxnet.dk] has joined #code |
20:57 | | mode/#code [+o Checkmate] by ChanServ |
21:01 | < kourbou> | Ah OK. |
21:02 | < Harlow> | [R] what do you mean? |
21:03 | < [R]> | Harlow: not all JS is run in a browser. |
21:03 | < Harlow> | i know |
21:03 | < Harlow> | yeah i was talking an in browser js |
21:04 | < [R]> | No browser provides raw sockets to their JS interpreter. I really was hoping Websockets would have fixed that, but it didn't. |
21:04 | <@Shiz> | that is not something that should be fixed. |
21:14 | < Harlow> | Shiz, there should be some way some how to do raw sockets, even if its stupid complex. |
21:15 | <@Shiz> | no, there really shouldn't |
21:15 | <@Shiz> | not in browsers at least |
21:15 | <@Shiz> | you're opening up for more abuse potential than an unpatched windows xp install |
21:18 | | kourbou is now known as kouby |
21:19 | | kouby is now known as kourbou |
21:55 | <&McMartin> | If I want to write a system in Javascript and have it be on a web page and stuff, can I have a master whatever.js file included by one script tag, and then have whatever.js load/include the remaining JS files? |
21:59 | < kourbou> | No idea. |
22:02 | <@Shiz> | yes. |
22:02 | <@Shiz> | http://requirejs.org/ |
22:03 | <@Shiz> | commonjs is another approach i believe |
22:03 | <&McMartin> | OK, this is not worth the effort for the specific use case |
22:03 | <&McMartin> | But it's good to know it exists |
22:04 | <&McMartin> | The solution in my case this time is literally cat |
22:05 | <@Shiz> | :) |
22:05 | <&McMartin> | I recognize the impulse to say "I want to include one script tag instead of like three or four when used" |
22:06 | <&McMartin> | "I will pull in massive new chunks of infrastructure and rearchitect the entire project!" |
22:06 | <&McMartin> | "Orrrrr I could cat the files all together at the end and include that." |
22:14 | <&McMartin> | Some of my JS books also claim that for (index in array) isn't guaranteed to return the indices in order. Is this actually true? |
22:14 | <&McMartin> | in-browser tests imply "no" but they also imply that maps preserve order and I *know* the spec doesn't guarantee that. |
22:15 | < [R]> | If you're being retarded and doing array.something = x... |
22:15 | < [R]> | Otherwise yeah, arrays keep their order. |
22:16 | <&McMartin> | Technically, your "being retarded" case is the only reason to ever bother with "everything is an object" semantics~ |
22:17 | < [R]> | Arrays are slightly special in that regard |
22:17 | < [R]> | Not all implementations handle that case well. |
22:17 | <&McMartin> | I recall that varargs are also special-cased, but I'm not really using those |
22:18 | <&McMartin> | I'm mostly iterating through a shitload of reconfigurable data, some of which needs to be ordered, some of which doesn't |
22:18 | < [R]> | Oh, I also finally understood your query. |
22:19 | < [R]> | for (index in array) will also get you any functions that were added to the array prototype. |
22:19 | < [R]> | Certain libraries (ExtJS) will do this. |
22:19 | <&McMartin> | By experimentation it looks like the length property however does not show up |
22:19 | < [R]> | Yes, length is made uniterable. |
22:19 | <&McMartin> | I've mostly been being careful about checking iterate-over-object-used-as-map with hasOwnProperty |
22:21 | <@Shiz> | JS: even iteration has to be hard |
22:21 | <&McMartin> | To be fair, still fewer keystrokes than C++ |
22:22 | <&McMartin> | There's only two aspects of JS I'd consider Unambiguously Wrong as opposed to Consistent But Probably Not What You Were Expecting |
22:23 | <@Shiz> | i really hope weak typing is one of them |
22:24 | <&McMartin> | No, that's Ambiguously Wrong |
22:24 | <&McMartin> | Also depending on where you came from, it may be What You Were Expecting |
22:24 | <&McMartin> | function scope for variables and automatic creation of globals on defining undeclared variables. |
22:24 | <@Shiz> | don't many people praise JS's scope because it took it from scheme or something |
22:25 | < [R]> | Autoglobals sucks yeah |
22:25 | <&McMartin> | Shiz: getting to that |
22:25 | <&McMartin> | Replace "globals" with "locals" and "function" with "block" and then you are straddling Python and Scheme, and several of the really ugly bits that burn people in JS also evaporate |
22:26 | <@Shiz> | python has no block scope |
22:26 | <@Shiz> | only function scope |
22:26 | <@Shiz> | :P |
22:26 | <&McMartin> | I did say "straddling" |
22:26 | <&McMartin> | Python does not have the full Scheme semantics for its internal functions either |
22:27 | <&McMartin> | JS does, which is why you can use function definitions to trivially implement private object memebers. |
22:27 | <@Shiz> | like globals() and locals()? |
22:27 | <@Shiz> | ;p |
22:27 | <&McMartin> | "block" here means "like C", if this isn't clear. |
22:27 | <@Shiz> | no, i understand what a block means |
22:27 | <&McMartin> | Except with the necessary variation from C that lets returning an internally defined function work |
22:28 | <&McMartin> | C assumes that stack frames all live on, well, a stack, and that once you return from a function you don't need that stack frame anymore |
22:28 | <&McMartin> | That's not true for JS for the same reason it's not true for Lisp (or Haskell or F# or) |
22:28 | <@Shiz> | obviously |
22:29 | <@Shiz> | or any languages that has closures |
22:29 | <&McMartin> | The part where JS burns people is basically that loop variables get reassigned instead of rebound |
22:29 | <&McMartin> | So the infamous thing where you do something like for (i = 0; ...) { a[i] = function() { something referring to i; } } |
22:29 | <&McMartin> | And then all your functions after the loop return the same wrong value |
22:29 | <@Shiz> | oh, fun |
22:30 | <&McMartin> | You can make that happen in Lisp too, but the natural way to write stuff in Lisp means it ends up not happening when you write it the natural way |
22:30 | <&McMartin> | Not so for JS and it's because of the "function scope for all variables" rules, in effect. |
22:31 | <&McMartin> | As with all Lisp descended things, the solution is to add Another Function Call~ |
22:34 | <&ToxicFrog> | McMartin: re: dynamic loading of JS: the approach ss1map uses is just to dynamically create a <script> element and it works ok: https://github.com/ToxicFrog/ss1edit/blob/master/maps/init.js#L22 |
22:35 | <&McMartin> | TF: Yeah, there are some disadvantages there for my case specifically, though |
22:35 | <&McMartin> | (Those elements are loaded asynchronously) |
22:48 | | himi [fow035@Nightstar-dm0.2ni.203.150.IP] has joined #code |
22:48 | | mode/#code [+o himi] by ChanServ |
23:08 | | kourbou [holoirc@Nightstar-deqg8j.fbx.proxad.net] has quit [Connection closed] |
23:08 | | kourbou [holoirc@Nightstar-deqg8j.fbx.proxad.net] has joined #code |
23:20 | | kourbou is now known as kourbou|zzz |
--- Log closed Mon Mar 16 00:00:23 2015 |