code logs -> 2012 -> Thu, 17 May 2012< code.20120516.log - code.20120518.log >
--- Log opened Thu May 17 00:00:25 2012
00:20
< RichyB>
This is fun. http://blog.ezyang.com/2012/05/what-happens-when-you-mix-three-research-programm ing-languages-together/
00:20
< RichyB>
I am especially amused by Maxim 4: "The less interesting a problem is to the academic, the more likely it is youll be able to fix it yourself."
00:31 You're now known as TheWatcher[T-2]
00:32
<@TheWatcher[T-2]>
froztbyte: http://quotes.nightstar.net/? ;)
00:34 You're now known as TheWatcher[zZzZ]
00:38
<&McMartin>
That is a fun article, indeed
01:00 Derakon[AFK] is now known as Derakon
01:01
< Rhamphoryncus>
Welp, I now understand the purpose of taking only one or two provinces at a time. Even with colonial conquest it's 9.6 infamy to annex the inca
01:53
< Rhamphoryncus>
wrong channel :P
02:15 Noah [nbarr@490720.C448F4.6334E9.5D6C06] has joined #code
02:19
< Noah>
jerith: Is there anything particularly wrong with the way jokbot handles plugins?
02:20 Attilla [Obsolete@Nightstar-d5b5a5fc.as43234.net] has quit [Ping timeout: 121 seconds]
02:31 Kindamoody[zZz] is now known as Kindamoody
02:34
<&McMartin>
Oh hey, 0 is true.
02:34
<&McMartin>
\o/
02:35
<~Vornicus>
um
02:35
<&Derakon>
Language?
02:37
<&McMartin>
Clojure
02:38
<&McMartin>
This means I can use if-let without having to do any special-case jackassery.
02:40
< Noah>
if 0: punch( McMartin )
02:40
< Noah>
Now, since I code in python, you're safe
02:41
< Noah>
However, you're coding in Clojure, so quit hitting yourself, quit hitting yourself~
02:41 * Derakon sighs at the #angband-dev channel, where, when he asked for some feedback on his terrain representation woes, he got from user A hopelessly uninformed suggestions ("use a map!"), and from user B "lol premature optimization just throw something in there".
02:42
< Noah>
Go code for DCSS instead
02:42
<&McMartin>
Noah: No, see, zero being true is good.
02:43
< Noah>
Is 1 also true?
02:44
<&McMartin>
Yes.
02:44
<&McMartin>
Everything that isn't nil is true.
02:44
<&McMartin>
That means that you don't need an explicit Maybe type.
02:44
< Noah>
Hmm, I can see that being pretty useful
02:44
< RichyB>
* cough*
02:44
< RichyB>
You do need an explicit Maybe type, sometimes.
02:45
<&Derakon>
There's no boolean type, McM?
02:45
< Noah>
What else does that, some other language but I forget which
02:45
<&McMartin>
Derakon: As a Lisp, nil is also false.
02:45
< Noah>
RichyB: That sounds ironic, just saying
02:45
< RichyB>
Specifically, there are plenty of situations where you want to distinguish Nothing (Just Nil).
02:45
<&McMartin>
Lisps disagree on what "true" is.
02:45
<&Derakon>
McM: so evaluating "1 > 2" returns nil, then?
02:45
< RichyB>
Derakon, yes.
02:46
< Noah>
Why not just call it false
02:46
< RichyB>
Because it's also used in a few other places, like as a linked-list terminator.
02:46
< RichyB>
Also, less wear-and-tear on keyboards.
02:46
<&McMartin>
And because Lisp started out as an extremely strange assembly language.
02:46
< RichyB>
It's also kind of a traditional name in Lisp, going back to days of yore.
02:46
< Noah>
Ah huh
02:46
< RichyB>
Like "cons" "car" and "cdr".
02:47
<&McMartin>
Also, Lisp dialects do vary as to this: in Scheme, for instance, #f and '() are not in fact the same thing.
02:47
< RichyB>
McMartin, I forgot that.
02:47
<&McMartin>
car/cdr, incidentally, are straight out of Strange Assembly.
02:47
<&McMartin>
Contents of Address/Decrement Register.
02:47
< RichyB>
Literally "Contents of Address Register" on some specific IBM machine.
02:47
< RichyB>
^- yes.
02:48
< RichyB>
One great upside though.
02:48
< RichyB>
Good bumper sticker.
02:48
< RichyB>
"My other car is a cdr."
02:48
<&McMartin>
\o/
02:48
<&McMartin>
Clojure is one of the worst Lisps I've ever used, tbh, but toll-free bridging with JVM, .NET, and JS is pretty boss.
02:48
<&McMartin>
(only one at a time, ofc)
02:48
< RichyB>
Did you seriously say "JS"?
02:49
<&McMartin>
I did. Clojure has a JavaScript backend and can be used to do dynamic web content.
02:50
< RichyB>
Damn.
03:00
<&McMartin>
Although I also seem unable to get it to work.
03:00
<@ToxicFrog>
<Noah> What else does that, some other language but I forget which -- Lua also has 'nil and false are false and everything else is true'; pretty sure it took that from Lisp, though.
03:01
< Noah>
Ah, maybe that's what it is
03:01
<&McMartin>
Clojure actually does have true and false
03:01 * Vornicus should at some point make a table of languages and what they consider false.
03:01
<&McMartin>
(> 1 2) returns false
03:01
<&McMartin>
(= nil false) *also* returns false
03:01
<@ToxicFrog>
(lua also has a distinct boolean type, though; 'nil' and 'false' are not the same thing although they are both boolean false)
03:02
<&Derakon>
Vorn: you'll have fun when you get to Perl!
03:02
<&Derakon>
Where "0" is false.
03:02
<&McMartin>
(if nil 'x 'y) returns y
03:02
<&McMartin>
(if 0 'x 'y) returns x
03:02
<&McMartin>
"0 but true" ftw
03:02
<@ToxicFrog>
Derakon: is == at least commutative in Perl?
03:02
<~Vornicus>
Der: yeah, really weakly-typed languages really blow
03:02
<&Derakon>
But "00" is true!
03:02
<&Derakon>
TF: not sure.
03:03
<~Vornicus>
but you've got ones like empty collections, empty strings, 0, null pointers, false itself, strings that would cast to 0 or false, uh...
03:04
<@ToxicFrog>
Also, as for Maybe types - AIUI those are primarily useful in statically typed languages when you don't want to worry about null
03:06
<&McMartin>
TF: Well, here, it's (if-let [x init-value] stuff-with-x stuff-when-x-was-nil)
03:06
<@ToxicFrog>
(and when you want "this function maybe returns a T or maybe returns nothing" encoded in the signature)
03:07
<@ToxicFrog>
That binds x to init-value, then does stuff-with-x if x and stuff-when-x-was-nil otherwise, in both cases with the binding active?
03:08
<&McMartin>
Definitely in the first, unsure about the second
03:08
<&McMartin>
Let's see~
03:09
<&McMartin>
x is unbound in the second clause
03:09
<@ToxicFrog>
Aah
03:09
<&McMartin>
So if you want a nil there you have to constant-prop it by hand =P
03:23
<&McMartin>
Oh jeeze
03:23
<&McMartin>
wtf
03:23
<&McMartin>
Fedora's version of JDK doesn't include jar >_<
03:28
<@ToxicFrog>
;.;
03:30
<&McMartin>
Oh, wait, do I only have the JRE here...
03:31 * McMartin tries installing the *actual* JDK.
03:32
<&McMartin>
OK, there it is. -_-
03:32 maoranma [nbarr@Nightstar-65ece756.pools.spcsdns.net] has joined #code
03:35 Noah [nbarr@490720.C448F4.6334E9.5D6C06] has quit [Ping timeout: 121 seconds]
03:37 * gnolam reads the backscroll, goes AHAHAHAHAHA
03:37
< gnolam>
If you're depending on "Any patches written made it into upstream, improving the situation of the software for future developers, and"
03:37
< gnolam>
... you're pre-fucked.
03:38
<&McMartin>
Nah
03:38
<&McMartin>
That's "it would be nice if"
03:38
<&McMartin>
You've got your own patches already, you are required to give zero fucks
03:38
<&McMartin>
But it's nice if they take them =P
03:39
< gnolam>
And if you've got your own patches, towards which the devs give zero fucks... you're better off buying something where the devs are contractually obliged to give fucks.
03:39
<&McMartin>
I, um
03:39
<&McMartin>
That doesn't comport with my time as a grad student at all, I need this pretending to work in three days and can't afford that level of support from anyone
03:40
< gnolam>
As long as you're writing a toy whatever, eh.
03:41
< RichyB>
uh
03:41
< gnolam>
It just needs to work for as long as it takes to demonstrate it.
03:41
< RichyB>
If upstream gives zero fucks and you're doing commercial software development, you abandon upstream.
03:41
<&McMartin>
Yes, that is exactly what a research project is.
03:41
< gnolam>
Otherwise: see AHAHAHAHAHA
03:41
< RichyB>
Either fork it or migrate elsewhere.
03:41
< gnolam>
=> take on an additional dev cost that is far, far from zero
03:42
<&McMartin>
Well, you're going to have to anyway in that situation.
03:42
<&McMartin>
If you could buy it, it's not a research project, now is it
03:42
< RichyB>
You have dev cost either way, from the fallout of "upstream gives zero fucks."
03:43
< RichyB>
"Upstream gives zero fucks" means that you made a mistake when you picked your upstream. You should not expect there to be any way of getting out of that situation that doesn't cost.
03:44
<&McMartin>
Pretty much, unless upstream is pure infrastructure and you don't have to care either.
03:44
<&McMartin>
The Linux kernel developers cared very little for my research, for instance, and I didn't have to care. =P
03:46
< gnolam>
"If you're writing a toy whatever, it just needs to work for as long as it takes to demonstrate it"
03:46
<&McMartin>
Yeah, but if you aren't, and you're an academic, you're in a full-bore NIH situation anyhow.
03:47
<&McMartin>
In fact, you probably *aren't* an academic at that point, you're support staff for the researchers, and you *are* the upstream.
03:48
< gnolam>
Or you are an academic, and you're actually concerned that whatever you're writing should be usable. Beyond the "see, your grant wasn't wasted" point.
03:48
<&McMartin>
If upstream gives zero fucks, you've already failed on that point - your code isn't part of the currently active ecosystem.
03:50
<&McMartin>
If you want people to actually use your stuff you won't be able to fund the usability parts with the grant, at least not the kinds I seemed to end up with.
03:50
<&McMartin>
Of course, the old stuff I did now relies on binary formats that are no longer valid, so its direct applicability is limited at best, so this is, aha, academic for me.
03:52
<&McMartin>
None of this changes the problem with your original statement, though, which gets the causality backwards.
03:54
<&McMartin>
(Though to the digression, this is IME the distinction between Masters and Doctoral students; the Masters are usually set on infrastructure-style things and the Doctoral students are set to justifying the grants)
04:20 Reiv [reiverta@5B433A.3CF6C7.E4E702.379023] has joined #code
04:21
< maoranma>
blablablabla
04:21 maoranma is now known as Noah
04:26 * Vornicus pipes maoranma through the rubbish lister.
04:34 * Noah pipes Vornicus through cowsay
04:45
<&Derakon>
How is the rubbish Lister any different from the normal Lister? Less of a curry fixation?
04:48
< Noah>
mmm, curry
04:53
<~Vornicus>
Perhaps
04:53
<~Vornicus>
(I had curry for dinner.)
05:04
<&McMartin>
Yay cowsay
05:06
<&McMartin>
(Another fine product of the Berkeley CSUA)
05:10 celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has quit [[NS] Quit: And lo! The computer falls into a deep sleep, to awake again some other day!]
05:27
<&McMartin>
\o/
05:28 * McMartin gets a ClojureScript hello-world working.
05:33 himi [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
05:33 mode/#code [+o himi] by ChanServ
06:23 himi [fow035@Nightstar-5d05bada.internode.on.net] has quit [Ping timeout: 121 seconds]
06:42 Reiv [reiverta@5B433A.3CF6C7.E4E702.379023] has quit [Client closed the connection]
06:47 Derakon is now known as Derakon[AFK]
06:58 Kindamoody is now known as Kindamoody|afk
07:02 ErikMesoy|sleep is now known as ErikMesoy
07:23 eckse [eckse@Nightstar-3b021371.dsl.sentex.ca] has quit [Client closed the connection]
07:29 himi [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
07:29 mode/#code [+o himi] by ChanServ
07:48
< froztbyte>
TheWatcher[zZzZ]: usually I go to http://qdb.slipgate.za.net but that should work as well :)
08:26 Kindamoody|afk is now known as Kindamoody
09:06 You're now known as TheWatcher
09:58 Reiv [reiverta@5B433A.F67240.A2CD37.A51D38] has joined #code
10:02 himi [fow035@Nightstar-5d05bada.internode.on.net] has quit [Client closed the connection]
10:09 himi [fow035@Nightstar-5d05bada.internode.on.net] has joined #code
10:09 mode/#code [+o himi] by ChanServ
10:52 Attilla [Obsolete@Nightstar-d5b5a5fc.as43234.net] has joined #code
12:07
<@TheWatcher>
Ugh, I hate circular dependencies
12:53 Kindamoody is now known as Kindamoody|out
13:01 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has quit [Client exited]
13:49 Kindamoody|out is now known as Kindamoody
15:18 Reiv [reiverta@5B433A.F67240.A2CD37.A51D38] has quit [Client closed the connection]
16:02 Kindamoody is now known as Kindamoody|P2
16:33
<&jerith>
03:19 < Noah> jerith: Is there anything particularly wrong with the way jokbot handles plugins?
16:35
<&jerith>
Noah: Not really, but the Twisted plugin stuff already finds and loads the appropriate modules and is well tested.
16:36
<&jerith>
Since you're using Twisted anyway, there's not real reason not to use it there, and it saves complexity and potential bugs in your code.
16:39 ErikMesoy [Erik_Mesoy@A08927.B4421D.B81A91.464BAB] has quit [Ping timeout: 121 seconds]
16:40 ErikMesoy [Erik_Mesoy@Nightstar-bd2f5f93.80-203-16.nextgentel.com] has joined #code
16:43 Attilla [Obsolete@Nightstar-d5b5a5fc.as43234.net] has quit [Ping timeout: 121 seconds]
16:49 Attilla [Obsolete@Nightstar-b6853f84.as43234.net] has joined #code
17:06 Janus [NSwebIRC@Nightstar-afc5b963.res.rr.com] has joined #code
17:06 eckse [eckse@Nightstar-3b021371.dsl.sentex.ca] has joined #code
17:06 mode/#code [+o eckse] by ChanServ
17:47 * ToxicFrog learns horrible things about MATLAB, like the fact that you crash its garbage collector with a stack overflow by freeing a linked list
17:49
<@ToxicFrog>
"I can't think of a single language I've used, other than MATLAB, and maybe exercises in school where you write out longhand all the state transitions for a Turing machine, that doesn't. The 1977 version of FORTRAN, maybe doesn't. I suppose this tells you that MATLAB met its original late-seventies design goal of being easier to use than FORTRAN. It is now 2009."
17:52
< RichyB>
Doesn't what?
17:56
<~Vornicus>
http://abandonmatlab.wordpress.com/2009/07/28/no-lists/ provide lists.
18:00 ShellNinja is now known as Number3
18:02
< Noah>
jerith: Maybe I'm just having issues groking Twisted's plugin system, I'll take another look at it now that I've had close to something that one would call a nights sleep
18:06 Tarinaky is now known as Atreus
18:31 * Janus pops in to the World Peace Summit. Has a more pressing problem; the ring broke off this can of vienna sausages and it won't open?
18:34 * Vornicus patpats janus
18:36
< Janus>
I just wanted to write a water pressure thingy. To find out the drawing order sorting thing won't work for an isometric view. It was kind of a rube goldberg machine anyway though.
18:37
< gnolam>
..?
18:40
< Janus>
I figured I could just draw each tile, farthest to closest, kinda like this http://dl.dropbox.com/u/3108480/waterthing.png But it breaks down once you put units or other things on the tiles.
18:42
<~Vornicus>
how does it break down?
18:42
<~Vornicus>
Can't you just, I don't know, draw the units at the same time as the tiles?
18:44
< Janus>
Since the ground itself is counted as one object. I got drawing order jerry rigged so that every class that needs drawn inherits a 'Drawable' class. This registers it into an array higher up, that sorts it based on it's positioning. As it is like this though, each tile would need to be it's own Drawable object. Which seems kinda wonky
18:44
<@ToxicFrog>
Yeah, Z-order is easy here - something standing on a tile is closer than the tile itself but further away than everything else that is further away than the tile.
18:47
< Janus>
They're not shown, but multiple tile wide entities might throw a wrench into it too. I'm just not sure how yet!
18:47
<~Vornicus>
ottd does this by having such entities broken up into many individual tiles.
18:48 RichyB [MyCatVerbs@Nightstar-3b2c2db2.bethere.co.uk] has quit [Ping timeout: 121 seconds]
18:48
< Janus>
... that. Would work.
18:49
<~Vornicus>
note: it is possible for some of this to cause problems for things transitioning between tiles.
18:50
< Janus>
Aha, actually. Treating each tile as an entity just like characters doesn't seem that bad now either. I was just worried it'd make it harder to determine shadows, or how much of the vertical face to draw. I guess it wouldn't be bad if the tiles could see what their neighbors were though.
18:55 * Janus has his vienna sausages!
19:00
< Janus>
(Transitions... At least the 1x1 tile wide units would be easy. I guess the 2x1 ones could just... be stylized in how they're split (e.g. wrong and mis-justified)
19:14 Kindamoody|P2 is now known as Kindamoody
19:14
<~Vornicus>
note that using openGL and an appropriate camera (typical "isometric" cameras are yaw 45 pitch -30
19:14
<~Vornicus>
makes your z calculations simple.
19:14
<~Vornicus>
or rather, trivial
19:15
<~Vornicus>
but then you need to use 3d art or impostors, both of which can be painful
19:24 ErikMesoy [Erik_Mesoy@Nightstar-bd2f5f93.80-203-16.nextgentel.com] has quit [Connection reset by peer]
19:25
< Janus>
Yeah... At least height doesn't affect much though, it's mostly X and Y. Which isn't hard! The only time height factors in, seems to be when a character moves north-east/west behind a high cliff
19:26 ErikMesoy [Erik_Mesoy@Nightstar-bd2f5f93.80-203-16.nextgentel.com] has joined #code
19:26 Kindamoody is now known as Kindamoody[zZz]
19:26
< Janus>
And they briefly have to be behind the tall tile, while on top of the tile they were just on, both the same distance away in terms of x and y. That's easily fixed though
20:47 Attilla_ [Obsolete@Nightstar-2b8bafce.threembb.co.uk] has joined #code
20:48 Attilla [Obsolete@Nightstar-b6853f84.as43234.net] has quit [Ping timeout: 121 seconds]
20:48
< ErikMesoy>
What's the ctcp command to check someone's client?
20:48 Attilla_ is now known as Attilla
20:49
< Namegduf>
VERSION.
20:51
< ErikMesoy>
Thanks.
20:57 Rhamphoryncus [rhamph@Nightstar-5697f7e2.abhsia.telus.net] has joined #code
21:12 * TheWatcher grumbles at neither markdown or doxygen including a 'simpler' table syntax, is having to include html table markup in his comments
21:15
<@TheWatcher>
... wait, it does
21:16
<@TheWatcher>
(there's a deep irony in missing something in the documentation when writing documentation...)
21:42 Attilla [Obsolete@Nightstar-2b8bafce.threembb.co.uk] has quit [Ping timeout: 121 seconds]
21:42 Attilla [Obsolete@Nightstar-2b8bafce.threembb.co.uk] has joined #code
21:44 ErikMesoy is now known as ErikMesoy|sleep
21:49 Attilla [Obsolete@Nightstar-2b8bafce.threembb.co.uk] has quit [Ping timeout: 121 seconds]
22:05
<@ToxicFrog>
"Donald is the best. Someone the other day said they felt he was a bit on the arrogant side. Well, (a) I've never noticed that myself, although I haven't finished his The Art of Computer Programming yet (I got it twice for Christmas, if you can believe that. I'm so predictable!), and (b) regardless, I think Donald has a right to be arrogant. When you obsolete the printing press, you earn that right, fair and square. You're even allowe
22:05
<@ToxicFrog>
d to wear a t-shirt that reads: "I'm Donald Knuth and You're Not". It's in the Rules."
22:09
<&McMartin>
Heee
22:10
<&McMartin>
His full academic regalia is also ridiculous because it's a mishmash of heraldry from every place that's given him honorary degrees
22:10
<&McMartin>
Which is a lot of them.
22:12 Attilla [Obsolete@Nightstar-674cce85.threembb.co.uk] has joined #code
22:16 * ToxicFrog ponders giving SICP another go using Clojure
22:17
<&McMartin>
Clojure is weak in various important ways =(
22:17
<&McMartin>
Though I forget how much SICP relies on those
22:17
<&McMartin>
I can't really do *any* of my horrible Scheme stunts I did in Gambit in Clojure
22:29
<@ToxicFrog>
Like what?
22:31
<&McMartin>
Continuations for exceptions, non-recursive tail-calls
22:31
<&McMartin>
Of course, clojure does have recur, an equivalent to named-let for escape continuations, and direct exception support, so.
22:31
<&McMartin>
Also, Clojure-CLR is being somewhat recalcitrant
22:34
<&McMartin>
And it doesn't have a remotely complete set of binaries for distribution.
22:36
<&McMartin>
Though I guess I'm being overly picky given that Clojure 1.4 is less than a month old.
22:36
<@ToxicFrog>
Clojure also has trampoline for non-recursive tail calls, although it's not as convenient as just, well, calling
22:37
<&McMartin>
I'm of two minds about whether or not "recur" is something the compiler should handle for me.
22:37
<&McMartin>
Oh hey, I was unaware of trampoline
22:37
<&McMartin>
OK, state machine based objection withdrawn
22:38
<&McMartin>
Nobody does Continuation Madness like Scheme though.
22:39
<&McMartin>
(Well, Racket. But Racket is the current state of the art for Scheme.)
22:42
<&McMartin>
Snerk
22:43
<&McMartin>
Scala/Clojure interop
22:43
<&McMartin>
I guess why not
22:45
<&McMartin>
I still don't have a good feel for -> and ..
22:46
<@ToxicFrog>
Oh, also
22:46
<@ToxicFrog>
What did you mean by "complete set of binaries for distribution"?
22:47
<&McMartin>
It turns out it's that the link is stale on clojure.org
22:48
<&McMartin>
But there aren't 1.4 Clojure-CLR binaries, and no release binaries at all
22:48
<&McMartin>
I couldn't even find 1.3 ones, but those are on the non-stale link
22:48
<&McMartin>
(The clojure account on github instead of Rich Hickey's?)
22:51
<@ToxicFrog>
clojure-clr 1.4 is still in beta
22:51
<@ToxicFrog>
Given that, as you noted, clojure-1.4 is less than a month old
22:52
<@ToxicFrog>
That said I am displeased by the total lack of documentation for clojure.compile.exe
22:55 Attilla [Obsolete@Nightstar-674cce85.threembb.co.uk] has quit [Ping timeout: 121 seconds]
22:57
<&McMartin>
Also, lein run doesn't work the way I'd want.
22:57 Attilla [Obsolete@Nightstar-674cce85.threembb.co.uk] has joined #code
22:57 * McMartin is porting an old GW-BASIC game to Clojure here. >_>
22:57
<@ToxicFrog>
Blargh
22:58
<&McMartin>
The eventual plan is to make it ClojureScript-capable so it can run on a webpage
22:58
<@ToxicFrog>
Clojure.Compile does not appear to work for me; it says 'compiling to .', thinks for a bit, then runs the program I am trying to compile and then vomits up a 30-line stack trace
23:00
<&McMartin>
Elch
23:00
<&McMartin>
Yeah, I'm sticking to Java for now
23:02
<@ToxicFrog>
Also I seem to have problems with the REPL randomly hanging on me :/
23:03
<&McMartin>
Hey, my pretty-printer works
23:03
<&McMartin>
That will be useless in the final code.
23:38 celticminstrel [celticminst@Nightstar-5d22ab1d.cable.rogers.com] has joined #code
23:45 Noah [nbarr@Nightstar-65ece756.pools.spcsdns.net] has quit [Ping timeout: 121 seconds]
--- Log closed Fri May 18 00:00:41 2012
code logs -> 2012 -> Thu, 17 May 2012< code.20120516.log - code.20120518.log >

[ Latest log file ]