--- Log opened Fri Jan 28 00:00:07 2011 |
00:14 | | AnnoDomini [annodomini@Nightstar-c64d12a1.adsl.tpnet.pl] has quit [[NS] Quit: leaving] |
01:01 | | gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has quit [[NS] Quit: Z?] |
01:30 | < celticminstrel> | Hehe, 'ls; cd .; ls' gave two different lists. |
01:34 | < Vornicus> | ...how. |
01:35 | <@McMartin> | One treated as to console, one treated as to pipe? |
01:36 | | Derakon[AFK] is now known as Derakon |
01:47 | < celticminstrel> | The directory had been moved and replaced by another with the same name. Something like that. |
01:59 | | kwsn [kwsn@Nightstar-7426b23f.dyn.centurytel.net] has joined #code |
02:05 | | Kimo|workhome is now known as Kindamoody |
02:39 | | Kindamoody is now known as Kindamoody[zZz] |
03:22 | | Derakon is now known as Derakon[kitchenslave] |
04:12 | | Derakon[kitchenslave] is now known as Derakon |
05:38 | | cpux is now known as shade_of_cpux |
05:56 | | celticminstrel [celticminstre@Nightstar-f8b608eb.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!] |
05:58 | | Tarinaky [Tarinaky@Nightstar-f349ca6d.plus.com] has joined #code |
06:30 | | Derakon is now known as Derakon[AFK] |
07:33 | | AnnoDomini [annodomini@Nightstar-c64d12a1.adsl.tpnet.pl] has joined #code |
07:33 | | mode/#code [+o AnnoDomini] by Reiver |
08:19 | | Vornicus is now known as Vornicus-Latens |
08:52 | | kwsn [kwsn@Nightstar-7426b23f.dyn.centurytel.net] has quit [[NS] Quit: ] |
09:15 | | Tarinaky [Tarinaky@Nightstar-f349ca6d.plus.com] has quit [Client closed the connection] |
09:28 | | You're now known as TheWatcher |
10:03 | | AnnoDomini [annodomini@Nightstar-c64d12a1.adsl.tpnet.pl] has quit [[NS] Quit: Going elsewhere.] |
10:13 | | Kindamoody[zZz] is now known as Kindamoody |
10:32 | | Kindamoody is now known as Kimo|out |
11:51 | | * TheWatcher flails at HTTP::Cookie |
11:52 | <@TheWatcher> | ffs, if you're going to provide a function to export cookies as a string, provide a bloody function to take that string and import it again. |
13:06 | | AnnoDomini [annodomini@Nightstar-c64d12a1.adsl.tpnet.pl] has joined #code |
13:06 | | mode/#code [+o AnnoDomini] by Reiver |
13:19 | | gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has joined #code |
15:02 | | * TheWatcher eyes this code, facepalms, realises that he's actually been going in entirely the wrong direction for the last day |
15:13 | | Tarinaky [Tarinaky@Nightstar-f349ca6d.plus.com] has joined #code |
16:04 | | celticminstrel [celticminst@Nightstar-f8b608eb.cable.rogers.com] has joined #code |
16:05 | | Reiv [orthianz@ServerAdministrator.Nightstar.Net] has quit [Connection reset by peer] |
16:05 | | Reiv [orthianz@3CF3A5.E1CD01.36D449.95F5A5] has joined #code |
16:15 | | Reiv [orthianz@3CF3A5.E1CD01.36D449.95F5A5] has quit [Ping timeout: 121 seconds] |
16:30 | | Ortiha [orthianz@3CF3A5.E1CD01.36D449.95F5A5] has joined #code |
16:32 | | Kimo|out is now known as Kindamoody |
17:01 | | outpost[college] [NSwebIRC@Nightstar-fb34d99e.temple.edu] has joined #code |
17:01 | < outpost[college]> | I need help on java with something really stupid that I've brainfarted. |
17:02 | < outpost[college]> | I have an object called item, containing int predecessors, and an arraylist of items called Successors. |
17:02 | < outpost[college]> | public static class item{ public int pred; //number of predecessors ArrayList<item> succ = new ArrayList(); } |
17:02 | < outpost[college]> | Specifically. |
17:02 | < outpost[college]> | And now I need to create an item object called A, containing no predecessors, and an empty arraylist of items. |
17:03 | < outpost[college]> | But for some odd reason I can't recall HOW. |
17:04 | <@ToxicFrog> | Just pass 0 as pred? |
17:05 | <@ToxicFrog> | Or do you mean you don't recall the invocation syntax for new? |
17:05 | <@ToxicFrog> | (also, by convention Java types are capitalized; Item, not item.) |
17:12 | | * ToxicFrog pokes outpost[college] |
17:15 | < celticminstrel> | Bah, who cares about convention. :P |
17:17 | <@ToxicFrog> | Anyone who has to understand your code, including but not limited to your prof, TA, classmakes, co-workers, and yourself next semester when you need to refer back to this. |
17:17 | < Namegduf> | This presumes you like your prof, TA, classmates, coworkers, or yourself. |
17:17 | < Namegduf> | But if you do, yes. |
17:18 | < celticminstrel> | Hehe. |
17:18 | < celticminstrel> | If it's only yourself, though, you can invent your own convention. |
17:18 | < outpost[college]> | back, sorry, had a student to help. |
17:18 | < outpost[college]> | TF - I got the pred, it's the succ that's throwing errors. |
17:18 | < Namegduf> | You could also make your own custom changes to the language. |
17:19 | < Namegduf> | And write comments in a form of shorthand that doubles as encryption. |
17:19 | <@ToxicFrog> | outpost[college]: what sort of errors? How are you creating it? |
17:19 | <@ToxicFrog> | Something like: new Item(0, new ArrayList<Item>(0)) should work, I think. |
17:20 | <@TheWatcher> | Better yet, show us the code. |
17:20 | < outpost[college]> | That throws a 'cannot find symbol error' "constructor Item(int,java.util.ArrayList<topological2.Main.Item>)" |
17:20 | < outpost[college]> | Honestly, that *is* all the code. |
17:21 | <@ToxicFrog> | Sorry, 'item', not 'Item'. Read things carefully :P |
17:22 | <@ToxicFrog> | ...can you put initializers inline to field declarations like that in Java? |
17:23 | < outpost[college]> | I fixed the Item bit, so it's not that. And I'm not sure, I haven't done Java is some 4-5 years. |
17:26 | <@ToxicFrog> | Hmm. Looks like you can. Interesting. |
17:27 | <@ToxicFrog> | Ok, so pastebin all of your code exactly as written + the error you get. |
17:27 | < outpost[college]> | I know it's something very silly I'm forgetting |
17:28 | < outpost[college]> | http://pastebin.com/dCTmhcNE |
17:29 | <@ToxicFrog> | Oh |
17:29 | <@ToxicFrog> | Ok, the problem is that you don't have a constructor for Item |
17:29 | < outpost[college]> | ... |
17:29 | <@ToxicFrog> | So obviously trying to use constructor-new won't work. |
17:29 | < outpost[college]> | Well fuck me! and I'm supposed to be a TA/ |
17:30 | <@ToxicFrog> | Oh god, you're TAing a Java course? |
17:30 | <@ToxicFrog> | I'm so sorry. |
17:30 | < outpost[college]> | Thank god no, although I need to tutor in it. |
17:30 | < outpost[college]> | It's even worse. .net and asp.net scripting. |
17:30 | <@ToxicFrog> | ;.; |
17:30 | < outpost[college]> | I really wish I could do C++ tutoring, I *know* that. |
17:33 | <@ToxicFrog> | Even if I enjoyed C++ (I really don't) I'm not sure I could ever do C++ tutoring. |
17:33 | <@ToxicFrog> | It has even more pitfalls and an even steeper learning curve than C or Java, and trying to teach it to people would gradually drive me insane. |
17:35 | | Ortiha [orthianz@3CF3A5.E1CD01.36D449.95F5A5] has quit [Client closed the connection] |
17:35 | | Ortiha [orthianz@3CF3A5.E1CD01.36D449.95F5A5] has joined #code |
17:36 | <@ToxicFrog> | ...ahahahahahaaaa |
17:36 | <@ToxicFrog> | http://double-chinned.mirror.waffleimages.com/data/8e/8edea457d3f6ed047693e15ca2 f7b608f96916dd.jpg |
17:37 | < gnolam> | :) |
18:00 | | AnnoDomini is now known as Ed |
18:10 | | Tarinaky is now known as Caeldir |
19:44 | | AbuDhabi [annodomini@Nightstar-ba468114.adsl.tpnet.pl] has joined #code |
19:44 | | AbuDhabi is now known as Edd |
19:47 | | Ed [annodomini@Nightstar-c64d12a1.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds] |
20:20 | | SmithKurosaki [smith@Nightstar-7820a96a.dsl.teksavvy.com] has joined #code |
20:29 | | outpost[college] [NSwebIRC@Nightstar-fb34d99e.temple.edu] has quit [[NS] Quit: Page closed] |
20:49 | | Derakon [chriswei@Nightstar-cfae48c3.ca.comcast.net] has joined #code |
20:49 | | mode/#code [+o Derakon] by Reiver |
20:49 | <@Derakon> | A good sign your refactoring is on the right track: the new module you've created to hold the refactored code is 204 lines long when you hit the first code review. |
20:50 | <@Derakon> | (Another good sign: you're taking a global that's used in 45 different places and turning it into a module-scoped variable that's used in 9) |
21:07 | <@Derakon> | Down to 26 globals~! |
21:13 | <@TheWatcher> | Dear lord, that guy should be shot~ |
21:13 | <@Derakon> | It was over 100 when I started. |
21:13 | <@TheWatcher> | Preferably out of a cannon. Into the sun. |
21:14 | <@McMartin> | There's a sharp minimum on globals well above 0, given that you're using wx, though |
21:14 | <@Derakon> | Some of them were global even though they were only used within a single function. As far as I can tell the reason was to make debugging with the in-program console easier -- he just imported the module that was used to store globals and checked the value. |
21:14 | <@Derakon> | McM: how do you figure? |
21:14 | <@Derakon> | (Though yes, I don't plan to push the globals all the way down to 0) |
21:14 | <@McMartin> | I think wxApp is required by the API to be global |
21:15 | <@Derakon> | Ah. |
21:15 | <@McMartin> | Most GUI libraries generally have some global whose value is "the global event loop" or "this value represents the application as a whole" or whatnot |
21:15 | <@Derakon> | Yeah, I wouldn't be surprised. |
21:15 | <@Derakon> | That doesn't really count though, IMO; it's imposed from the outside, so there's nothing we can do about it and little point worrying about it. |
21:16 | <@Derakon> | (On the flipside, when I started we also had millions of magic-number IDs for various UI widgets which were looked up by said IDs all over the place; I've now eliminated almost all of those) |
21:18 | <@Derakon> | I'll admit that a lot of my global-removing is actually just moving variables from being in the "seb" module to being in modules more closely related to the global's function, and then doing a mass search-and-replace throughout the codebase. |
21:19 | <@Derakon> | There's been relatively little refactoring going on beyond that, so modules are still reaching into each others' bits and tweaking them. |
21:19 | <@Derakon> | But this should at least help clarify the dependency relationships. |
21:36 | <@Derakon> | 23 globals! I now no longer need 'less' to view the list! |
21:40 | < celticminstrel> | Yay! |
21:41 | <@Derakon> | Of those, 9 are from crufty old code that's not currently being used, but I'm keeping around because I may need to model new code on it later. |
21:45 | < celticminstrel> | Sounds familiar. |
21:59 | | Edd is now known as AnnoDomini |
22:13 | | Kindamoody [Kindamoody@Nightstar-4764665d.tbcn.telia.com] has quit [Client closed the connection] |
22:15 | | Kindamoody [Kindamoody@Nightstar-4764665d.tbcn.telia.com] has joined #code |
22:35 | < Alek> | "Instead of an iPhone, he bought a Roomba. Installed Linux on it. Plans to put in a GSM module and use it to place calls." |
22:43 | | Vornicus-Latens is now known as Vornicus |
22:43 | | * Derakon drops 19 global variables on Vorn. |
22:44 | | Caeldir [Tarinaky@Nightstar-f349ca6d.plus.com] has quit [Connection closed] |
22:46 | <@Derakon> | Hunh. "It is estimated that 0.4% of current cancers in the United States are due to CTs performed in the past and that this may increase to as high as 1.5-2% with 2007 rates of CT usage." |
22:46 | <@Derakon> | (CT = X-Ray Computed Tomography) |
22:47 | | * TheWatcher eyebrows |
22:53 | | AnnoDomini [annodomini@Nightstar-ba468114.adsl.tpnet.pl] has quit [[NS] Quit: Sleep.] |
22:54 | | * Derakon eyes his laptop's CD/DVD drive. |
22:54 | <@Derakon> | I insert a disc. It spins up, I can read stuff. CD spins down. I try to copy something. CD never spins up again... |
22:56 | < gnolam> | Derakon: Sounds a bit high to me, even if a CT scan can give you several years worth of background. |
22:56 | <@Derakon> | Gnolam: well, consider that people who get scans are likely to get several scans of the same location. |
22:57 | < gnolam> | Then again, you 'mercans seem to go in for a lot of unnecessary scans. And medical checkups in general. ;) |
22:57 | < gnolam> | Also: cancer estimates from external radiation are notoriously unreliable. |
22:57 | < gnolam> | Most of them use the LNT model, FFS. |
22:58 | <@Derakon> | Yeah, no error bars on that estimate. |
22:58 | <@Derakon> | Linear no-threshold model? |
22:58 | < gnolam> | Yep. |
22:58 | <@Derakon> | "Risk is directly proportional to dose at all dose levels." |
22:58 | <@Derakon> | Yeah, I can see how that could be inaccurate. |
22:58 | <@McMartin> | I'm in my 30s - the competing "Radiation in the quantities our devices produce is good for you!" model sets off a few red flags even if it turns out to be true. |
22:58 | < gnolam> | Easy to use, but it's so incredibly disconnected from reality that I consider it /pseudoscience/. |
22:59 | <@McMartin> | ALARA is still the standard protocol, and if ALARA is zero, the answer is zero. =P |
23:01 | | * Derakon mutters, tries to figure out what the different dimensions in a sinogram actually are. |
23:02 | <@Derakon> | (Sinograms being slightly modified raw data from X-Ray CT scanners) |
23:02 | < gnolam> | Except that since we don't live in a zero-radiation environment, it's very far from zero. |
23:03 | <@McMartin> | Well, yes. zero being 'zero added' |
23:06 | < gnolam> | And if the LNT model is correct, Sweden should have a 25% higher cancer rate than, say, Spain. |
23:06 | <@Derakon> | What makes Sweden so radioactive? |
23:07 | <@McMartin> | My understanding was that LNT wasn't considered viable as a predictive tool, only as a regulatory one |
23:07 | <@McMartin> | Erring in maximally conservative ways for hazards is not a particularly uncommon way to go about doing this, because AFAIK there is no consensus on where the non-linearity threshold *is*. |
23:07 | < gnolam> | Lots of uranium, higher latitude. |
23:08 | <@Derakon> | Ah. |
23:08 | < gnolam> | (=> increase in radon and cosmogenic radiation, respectively) |
23:08 | <@Derakon> | Right. |
23:09 | | * Vornicus is apparently buried in variables |
23:58 | | Derakon [chriswei@Nightstar-cfae48c3.ca.comcast.net] has quit [[NS] Quit: Lost terminal] |
--- Log closed Sat Jan 29 00:00:08 2011 |