Seibel: Big Brother Database?

Zawinski: Yeah. And it was slow so I started digging into why it wasslow and I realized, oh, it’s slow because the compiler sucks. So Irewrote the compiler, which was my first run-in with the intransigenceof Stallman. So I knew a lot about Emacs.

Seibel: So the change to the byte compiler, did it change the bytecodeformat or did it just change the compiler?

Zawinski: It actually had a few options—I made some changes at theC layer, the byte-code interpreter, added a few new instructions thatsped things up. But the compiler could be configured to emit eitherold-style byte-code or ones that took advantage of the new codes.

So I write a new compiler and Stallman’s response is, “I see no needfor this change.” And I’m like, “What are you talking about? Itgenerates way faster code.” Then his next response is, “Okay, uh,send me a diff and explain each line you changed.” “Well, I didn’t dothat—I rewrote it because the old one was crap.” That was not OK.The only reason it ever got folded in was because I released it andthousands of people started using it and they loved it and they naggedhim for two years and finally he put it in because he was tired of beingnagged about it.

Seibel: Did you sign the papers assigning the copyright to the FreeSoftware Foundation?

Zawinski: Oh yeah, I did that right away. I think that was probablythe first thing in the email. It was like, send me a diff for each line andsign this. So I signed and said, “I can’t do the rest; can’t send you a diff;that’s ridiculous. It’s well documented; go take a look.” I don’t think heever did.

There’s this myth that there was some legal issue between Lucid andFSF and that’s absolutely not true—we assigned copyrights foreverything we did to them. It was convenient for them to pretend wehadn’t at certain times. Like, we actually submitted the paperworkmultiple times because they’d be like, “Oh, oh, we seem to have lostit.” I think there was some kind of brouhaha with assignments andXEmacs much later, but that was way after my time.

Seibel: So you started with Lisp. But you obviously didn’t stick with itfor your whole career. What came next?

Zawinski: Well, the next language I did any serious programming in afterLisp was C, which was kind of like going back to the assembly I programmed onan Apple II. It’s the PDP-11 assembler that thinks it’s a language. Which was,you know, unpleasant. I’d tried to avoid it for as long as possible. AndC++ is just an abomination. Everything is wrong with it in every way.So I really tried to avoid using that as much as I could and do everything in Cat Netscape. Which was pretty easy because we were targeting pretty smallmachines that didn’t run C++ programs well because C++ tends tobloat like crazy as soon as you start using any libraries. Plus the C++compilers were all in flux—there were lots of incompatibility problems. So wejust settled on ANSI C from the beginning and that served us pretty well. Afterthat Java felt like going back to Lisp a bit in that there were concepts thatthe language wasn’t bending over backwards trying to make you avoid—that werecomfortable again.

Seibel: Like what?

Zawinski: Memory management. That functions felt more likefunctions than subroutines. There was much more enforcedmodularity to it. It’s always tempting to throw in a goto in C code justbecause it’s easy.

Seibel: So these days it seems like you’re mostly doing C and Perl.

Zawinski: Well, I don’t really program very much anymore. Mostly I writestupid little Perl scripts to keep my servers running. I end up writing a lotof goofy things for getting album art for MP3s I have—that kind of thing. Justtiny brute-force throw-away programs.

Seibel: Do you like Perl or is it just handy?

Zawinski: Oh, I despise it. It’s a horrible language. But it is installedabsolutely everywhere. Any computer you sit down on, you’re nevergoing to have to talk someone through installing Perl to run yourscript. Perl is there already. That’s really the one and only thing thatrecommends it.

It has an OK collection of libraries. There’s often a library for doingthe thing you want. And often it doesn’t work very well, but at leastthere’s something. The experience of writing something in Java andthen trying to figure out—I myself have trouble installing Java on mycomputer—it’s horrible. I think Perl is a despicable language. If you uselittle enough of it, you can make it kind of look like C—or I guessmore like JavaScript than like C. Its syntax is crazy, if you use it. Itsdata structures are a mess. There’s not a lot good about it.

Seibel: But not as bad as C++.

Zawinski: No, absolutely not. It’s for different things. There’s stuff thatwould be so much easier to write in Perl or any language like Perl than in Cjust because they’re text-oriented—all these so-called “scripting languages”.Which is a distinction I don’t really buy—“programming” versus “scripting”. Ithink that’s nonsense. But if what you’re doing is fundamentally manipulatingtext or launching programs, like running wget and pulling some HTML out andpattern-matching it, it’s going to be easier to do that in Perl than even EmacsLisp.

Seibel: To say nothing of, Emacs Lisp is not going to be very suitablefor command-line utilities.

Zawinski: Yeah, though I used to write just random little utilities inEmacs all the time. There was actually a point, early on in Netscape,where part of our build process involved running “emacs -batch” tomanipulate some file. No one really appreciated that.

Seibel: No. I imagine they wouldn’t. What about XScreenSaver—doyou still work on that?

Zawinski: I still write new screen savers every now and then just forkicks, and that’s all C.

Seibel: Do you use some kind of IDE for that?

Zawinski: I just use Emacs, mostly. Though recently, I portedXScreenSaver to OS X. The way I did that was I reimplemented Xlibin terms of Cocoa, the Mac graphics substrate, so I wouldn’t have tochange the source code of all the screen savers. They’re still making Xcalls but I implemented the back end for each of those. And that wasin Objective C, which actually is a pretty nice language. I enjoyed doingthat. It definitely feels Java-like in the good ways but it also feels like C.Because it’s essentially C, you can still link directly with C code andjust call the functions and not have to bend over backwards.

Seibel: At Lucid, leaving aside the politics of Emacs development,what technical stuff did you learn?

Zawinski: I definitely became a better programmer while I was there.Largely because that was really the smartest group of people I’ve beenaround. Everyone who worked there was brilliant. And it was just niceto be in that kind of environment where when someone says, “That’snonsense,” or “We should do it this way,” you can just take theirword for it, believe that they know what they were talking about. Thatwas really nice. Not that I hadn’t been around smart people before.But it was just such a high-quality group of people there, consistently.

Seibel: And how big was the development team?

Zawinski: I think there were like 70 people at the company soprobably; I don’t know, 40 or so on the development team. TheEnergize team was maybe 25 people, 20. It was divided up into prettydistinct areas. There were the folks working on the compiler side ofthings and the back-end database side of things. The GUI stuff thatwasn’t Emacs. And then there was, at one point, me and two or threeother people working on integrating Emacs with the environment.That eventually turned into mostly me working on mostly Emacs stuff,trying to make our Emacs 19 be usable, be an editor that doesn’t crashall the time, and actually runs all the Emacs packages that you expect itto run.


Перейти на страницу:
Изменить размер шрифта: