Jonathan Tang

I'm JustaStudent, a physics major at Amherst College, going into my senior year. Spend most of my time reading/thinking about various computer stuff though, as my physics grades quite obviously show.

I've been programming on-and-off since I was 12, though I only started doing non-toy-programs after high school. Worked for a year between then and college at a now-defunct startup called TraxitTechnologies?, where the business plan shifted every month or so. I did mostly JavaLanguage work (wrote the UI for the product, allow with a couple database-interface tools), with some PerlLanguage and some CeePlusPlus projects too. Learned a lot, but the business failed utterly, mostly because they had no development process whatsoever.

Current projects include a new database system for and a programming language I've been designing. I'm also tempted to join the LiveJournal development team, but there're only so many hours in the day.

I've been learning a lot of programming languages recently. Last year was mostly all CommonLisp, then I learned DylanLanguage over the summer, some of HaskellLanguage when I got back to school, then a little ErlangLanguage and RebolLanguage over the course of the semester. I've also recently discovered the theoretical aspects of programming... being self-taught, I'd pretty much ignored them before recently. I'm also interested in EmergentBehavior - it seems like a lot of future developments may come from that area, because software systems are getting complex enough that we can't grok all the interactions that might arise from stringing pieces together.

Feel free to contact me for whatever reason at:
 AIM/YM: Nostrademons

Some pages I've originated: Probably a few more that I've forgotten and didn't sign, too. :)

Major refactoring jobs: (personally, I think this is much more important than originating pages)

This paper looks like it would be of interest to you. Hopefully you've run across Peano Axioms for defining arithmetic in terms of set theory? If so, the paper is an easy read: TypeArithmeticsPaper

The Zermelo-Frankel (ZF and ZFC) axioms are more commonly used these days, but the Peano are earlier, better known outside of pure math, and more intuitively concrete.

But the point is about types; arithmetic is secondary. -- dm

Thanks, just downloaded it for reading offline. Are Peano Axioms like Von Neumann numbers, defining the integers in terms of sets-containing-sets, and arithmetic in terms of...geesh, I forgot, I think it was set membership? I'm familiar with that, if there's any connection. -- jt

Yes, exactly. Peano was the original approach, long before ZFC and von Neumann. If you are trying to upload to Y!Photos from a camera phone then, boy, do I have the inside help for you on that...lemme know... -- dm

Links to articles on Rebol. Haven't read 'em yet. -- dm

Of possible interest: company that does Lisp, founded by famous MIT Lisper, located next to MIT. LL1 posting last year said they were then looking for someone junior to do Lisp and not having much luck.
-- dm

Hrmm, I should try them. I was pursuing a job in another AI-lab spinoff (started by a friend of my mother's from high school), but I dunno if that'll pan out.

BTW (and completely unrelated), have you seen the PLEAC ( project? It's an attempt to implement the Perl Cookbook in a wide variety of languages, to provide a practical comparison. It unfortunately doesn't say much about the large-scale abstraction capabilities of the language, since Perl's not designed for that, but it'll sniff out areas where you've unwittingly made things harder for the programmer than they need to be. I've found it to be a good way to find hidden "gotchas" in language design, since the best way to evaluate a language is to write lots of programs in it.

And I assume you're familiar with the GreatComputerLanguageShootout. That's another source of example programs, and'll let you benchmark your language against all the other popular ones. -- jt

Thanks. You've probably seen this, but I dunno if you thought much about it or not: cparse for Lisp parses C headers. Steal idea/code to help interface a new language to the OS and to the large number of existing C libraries.

Seems like a popular idea these days; I've seen similar things for some other languages too. -- dm

GwydionDylan also has a C parser: Melange. But the Dylan one still has several bugs, so the Cliki source is probably better reference material.

I also downloaded the source and technical papers for ElkHound?, a GLR parser generator that's only about 10-30% slower than Bison (it hybridizes GLR and LR parsing so that it uses the LR algorithm when there's no ambiguity in the grammar). Was planning to implement something like that, and use it for both the surface syntax(es) and the C/C++ FFI. Elkhound comes with a grammar for C++ (it was initially designed to write a C++ parser called Elsa, which can parse Mozilla successfully), so I could just copy that. -- jt

Don't forget that you need a C preprocessor as well, and they are not trivial to write (I've done it several times). Possibly just run an existing one, like GNU's? Parsing C/C++ header files can be a tarpit if you're not careful. -- dm

Oh, that's right. I'll probably use a preexisting one if possible; I'm compiling to C anyway, so it'll require gcc or equivalent on the system anyway. GCC has a command-line switch to output the preprocessed C, right? I don't suppose there's any way to emit an easily-parsable AST from the front-end, is there? -- jt

The -E flag does that. Also it is traditional to have the preprocessor run as a separate executable, and GNU honors that tradition: /usr/bin/cpp. This is either better or worse than gcc -E depending on what you want/don't want in the way of command line options automatically provided in the case of -E.

Easily-parsable AST? Hmm...I have in fact hacked GCC, but I'm a good 5 years out of date, so I can't say for sure. If you did want to use their code generator, though, it's set up to take many front-ends via intermediate language. Since this has been done fairly often, and the code refactored to assist in that multiple times, this no doubt would be much easier to do than writing your own code generator, and it would then automatically be multi-platform. I never did this myself, though, so I'm not sure how much work that takes.

Oh, whoops, I must be getting're still talking about cparse-like stuff, I was thinking about a backend for your language. Strike that, reverse it, go on again...

Right then, as to your actual question, that's much easier to answer: I don't really know. :-) But apparently GCC 3.4 will support precompiled headers, which is kind of suggestive.

But I think you've got a great idea; maybe if you suggest that to all the relevant folks (cparse, Dylan, whomever), they'll go off and implement it within GCC? Or maybe it's already there and I just don't know. -- dm

RegularExpressions is indeed something that people will accidentally type, so having no page there is not a great idea. Could you respond to the following: Not trying to be rude, but I tried to break down the problem into simple questions. Would you mind providing simple answers? Especially, I believe the last question is the most important point'' In many cases (not all) both pages are necessities.

Also, noticing your change on MasteringRegularExpressions - the page no longer links to RegularExpression or RegularExpressions. I don't believe that that's the best situation. -- DanielSheppard Which do you prefer, the one in the title of the book, the one specifying a singular occurrence of the collection, or both?

I'm going to replace the content of the RegularExpressions page with "See RegularExpression". If you feel that there is information that applies only to groups of expressions and not to singular expressions, feel free to factor it out. Having two pages with duplicated information is pointless. My reasoning for choosing the singular form over the plural form is that it is possible to link to the singular page when referring to the plural, but the reverse is not possible. Because of this I would prefer a link to the RegularExpression page to exist on the MasteringRegularExpressions page

(by the way all the comments made here have been from me, not Jonathan) -- DanielSheppard

Jonathan probably has better things to do. Could you please remove the content from one of the two pages and replace with a pointer? Having duplicate content will make it a nightmare if anybody starts adding more content to either of the pages. (Note that the RegularExpressions page is currently incorrectly formatted)

Wow, long discussion on my homepage while I was at class. I'll try to respond to some of the relevant points: It looks like a refactoring is in progress on the whole RegularExpression family of pages, so I'll let that quiet and see how it comes out before touching anything. -- JonathanTang

Returned to sender -> Please see WikiNamePluralProblem, SolutionOfTheWikiNamePluralProblem, SixSingleQuotes, and RefactorByMerging before reverting de-pluralized pages. If you have a problem with the accepted practice as described on SolutionOfTheWikiNamePluralProblem, discuss it there and the community can come to consensus again. I'll hold off on making further edits (I need to go home and cook dinner anyway) until you've had a chance to comment. JonathanTang - I see what you mean. I don't agree. But you are free to do what you want, after all this is wiki. I may check back in the fall to see the improvements and enhancements you have created.

March 10, 2006: I don't know how old the above block of discussion is, but I just fixed all the links to RegularExpressions with SixSingleQuotes and deleted it. Just to let you know. -- EarleMartin

Jonathan, regarding ReplaceDontRespond?, you might want to take a look at RefactorByCondensingQuestionAnswerPair (part of the RefactoringWikiPages pattern language) and ReplaceQuestionWithAnswer (on Meatball), and consider merging them. -- JohannesGijsbers

Am merging them and deleting ReplaceDontRespond?... -- jt

BTW my reply to you on CarlosNsRodrigues technically should have been about "adpositions" rather than about "prepositions" per se, but English only has a couple of postpositions... -- dm

Message you are welcome to delete BozMo? and TransparentNamesPlease? when you wish


I deleted BozMo? and TransparentNamesPlease?. Perhaps you know how much of OneNamePlease is "cooked" and suitable for refactoring/deletion. -- ElizabethWiethoff
You deleted your dream from FutureOfProgrammingLanguages; what's up with that? Disillusioned on the subject?? -- dm

Heh, not at all. I just think it wasn't called for on a Wiki page.

And, for a more selfish reason, I've noticed that the success of a language depends on its ability to draw a community that's willing to invest their time in it. The success of that depends on the original creator's ability to stand aside and accept contributions from users, regardless of any ego-attachment to the language. I thought that a comment like that, even if joking, might give the impression that I'm more concerned with it being my language than it being a good language.

For now, it is "my" language. But my velocity on the interpreter seems to be picking up, so I could conceivably have something to put on SourceForge within the next couple months (it may be a bit longer, depending on whether I want to hold onto it until the parser and compiler are done). At that point I have to give up control and take it wherever its path leads. Which may very well be nowhere, but I wanna at least increase the chance that it could be popular, even if that chance is still miniscule. -- jt

Ah, ok. Say, you've alluded to writeups or short analysis papers or something that you do sometimes, and I've been curious about them; can you make any of them available online? Maybe with a banner "unfinished informal draft, please do not circulate in this form" at the top, if that's an issue. I feel like you have interesting thoughts and that only the tip of the iceberg shows up here from time to time. -- dm

Hah, I rather doubt anyone would be able to understand them. I tend to ramble on for a bit and then leave off just as it's starting to make sense. See, at that point, it's clear in my mind, so I don't see the need to write down the eventual conclusions.

If I do eventually start a SourceForge project page, I'll probably just toss them up there for history's sake, with a big disclaimer that these probably bear no relation to the actual design and might be quite difficult to follow. I'd throw 'em on a webspace, but I don't have FTP or SSH access from NZ, so it'd have to be after I get back to the U.S. -- JonathanTang

Well...if the rambling doesn't make sense, how about just a conclusion here or there? If you remain mostly opaque until you start a project web site, well, people usually don't ever quite get around to it, even if they do do the technology that was going to end up on the web site "one of these days". To share your thoughts, no time to get in the habit like the present, even if it's just one-liners because you're busy. -- dm

P.S. some free web sites allow HTTP upload, FWIW that at least gets around the protocol issue. -- dm
btw that chem site was actually spam, not just squatting

[comments moved to DeterministicResourceManagement]

Jonathan, perhaps we should refactor that part of my home page under a more appropriate heading. It is something I've been meaning to do, but haven't quite decided the best way to do it. Thoughts? -- ChrisHines

I was just about to copy it to another page, but was having trouble thinking of the new name -- the existing ResourceIsXYZ (e.g. ResourceAcquisitionIsInitialization) pages are close, but not necessarily exactly right. And then I was going to put a link to that on the page I created earlier today, IssuesForLanguageDesigners. So, yeah...suggestions? -- DougMerritt

My stance in the discussion is that memory, as a resource, should not be more privileged than other resources. So either don't have garbage collection, or find a way to put other resources on an equal footing (vis-a-vis GC) as memory. So, perhaps something along the lines of MemoryIsJustAnotherResource? or AllResourcesCanBecomeGarbage?, or perhaps we should just go with the name that Jonathan and I were using in the early part of the discussion: DeterministicCleanup? and have a DeterministicCleanupDiscussion? page for the thread. -- ChrisHines

I think an extra Discussion page is overkill at this point, but maybe if it keeps growing.

Ok, DeterministicResourceManagement strikes me as descriptive based on what you're saying...I'll do that now.

P.S. If memory serves, you may need to add a counterargument to hold up your side of things; I thought JT had an unanswered point in the discussion. Maybe I'm misremembering, though; I only skimmed it again tonight. -- dm

About your text adventure game, it doesn't make sense to put it where you've put it (CeeProgramsForBeginners). First of all there is not a single line of explanation which is against the very spirit of teaching and second of all it just does not fit in since the idea was to introduce notions of C progressively, gradually. With your program we're jumping 10 lessons ahead.

There was plenty of explanation as I originally posted it. The whole program was in the context of a LiterateProgramming tutorial, where it was worked through sequentially. I do understand the need for brevity, so I'm fine with having the condensed version of CeeProgramsForBeginners, as long as the explanation is somewhere accessible.

And I really don't care whether it's on "advanced" or "beginners", but you have to realize the huge range of experience we have on this site. Personally, I think it's appropriate as a "second level" beginner program; StructureAndInterpretationOfComputerPrograms uses far more difficult examples, and that's an introductory CS text. I don't think anyone here besides you would call it "advanced": it is still a toy example, and it took me maybe 2-3 hours to write the whole thing out, including tutorial, without compiler or reference manual. If it'd been just the program without the explanation, I probably could've had it working in about 20 minutes. -- JonathanTang

Which shows why LiterateProgramming isn't more popular. It's much harder and slower than simply programming! I do have reservations about throwing so much material at Susannah, though. I can't imagine how she'd be anything but overwhelmed by all this stuff. -- dm

For simple programs where you already know the answers, yes. I'm beginning to like it for a lot of the more difficult problems, though. For these problems, you're thinking-limited, not typing-limited. Writing all the thoughts down often helps clarify them, as in ConeOfAnswers. And including code with the prose helps clarify the explanations. From there, it's just a matter of expanding the code, and you've got LiterateProgramming.

This is a general shift on my thinking on literate programming. When I first heard about it, I was very much "Ugh, you've gotta write the documentation too? That's so slow! I'd never get anything done." Then I started thinking about programming as the process of knowledge acquisition. I've noticed that for many of my programs, I'll flounder around for 3-4 rewrites without getting much done. Then suddenly it'll fall into place, and the final program will emerge in very little time (often a couple days or so).

My explanation for this is that the rewrites are not useless; they're acquiring knowledge about the problem design. Prototyping, basically. Once the problem domain is understood, it's just a matter of typing, and that can go really fast. 1000 lines/night isn't horribly 10 seconds/line, that's only 3 hours.

This may account for the differing opinions on RewriteCodeFromScratch. It's bad to rewrite other people's code from scratch, because you don't fully understand it (though you may think you do, which is why you're rewriting it in the first place). But it's perfectly fine to rewrite your own code from scratch, because you have all the original understanding and moreso. -- jt
Hah, Doug, a CoRoutine would work well here. Maybe we should borrow some ContinuationsInCee. [Don't mind us, Susannah, I'm just joking around with some esoteric stuff that most of the pros don't use.] -- JonathanTang

Interesting point; coroutines would do this nicely. A closure would be better for the current adventure game, since there's no need to suspend each room rather than just reactivate it from scratch each time it's entered, but if there were state, such that it behaved differently each time it were entered (as in fancier adventure games), a coroutine could be best.

And, if each room does not have on-going state when it is occupied, then the only relevant state is the room occupied, which is 1-to-1 with a FiniteStateMachine, and...I don't know if you've heard this before, but FSMs are well-modelled by gotos!

The reason there's nothing wrong with it is that FSMs, by their nature, have arbitrary arcs between states, as determined by the final application. No matter how you implement them, whether data driven or control driven, these arbitrary state changes are equally confusing.

It doesn't tend to help to translate a goto-FSM into a data- driven FSM. And in fact it can be more complicated, because you have to do an enum or something to introduce meaningful labels for the states. This may be an argument against using FSMs in the first place, of course. But in the adventure game, the map of the world determines the connectivity, so an FSM is pretty natural, and if the linkages are confusing, that's presumably because it is supposed to be -- and unfortunately the programmer may be confused, too, not just the user.

Gotos have such a bad reputation that mostly only hardware engineers dared to continue doing this, but there's actually nothing wrong with it -- except that what you really want is FSM support in the high level language, which then generates the gotos automatically. Then again, there's very little difference between saying "enter_state(Forest)" vs "goto Forest". The main catch is that the app may expand to need data stack and/or recursion stack state suspension later, which invalidates the goto FSM model and requires switching to coroutines/closures/something.

But I thought it was worth mentioning this second useful application of gotos in languages (the first I mentioned before: when the high level language is auto-generated). -- dm

I always found FSMs easiest to comprehend when drawn out as a graph. In compiler design class, I found it really helpful that all the lexers were drawn out as an NFA first, then converted to a DFA, then translated to code (the prof recommended a table-based lexer, but we used JLex for the homework, which does a goto-based one). That's about the only way I can stand looking at a raw FSM in its entirety; I hate reading a mess of gotos on the printed page.

(Interestingly, my very first program was very like this one, an adventure game with inputs and such. But I wrote it in Apple IIe Basic, where I had to use GoTo. Then I had a helluva time converting to Pascal and C and forgetting about GoTo. Apparently I forgot too much, because break/continue seemed very weird to me when I ran across them, and understanding ContinuationPassingStyle was quite tricky.)

And it seems that most real FSMs don't require that you "grok" the whole thing at once. In this game, for one, you're only concerned about immediate connections. Ditto for MUDs, though when I tried writing one of those we drew out all the maps ahead of time before actually building them. For that matter, in most programming nowadays, you don't need or want to grok the whole thing. I think gotos tend to be okay when used locally (so that the target isn't outside of your immediate concerns). The big objection of GotoConsideredHarmful was that they were used to jump everywhere within the code, so you couldn't understand anything without dealing with a GoTo. -- jt

Could you look at the anonymous remarks left on my home page about setting up a WalledGarden? I assume they are from Doug M (who made the first comments) but they were logged out. I have no idea who to ask about a setting such up, and am not completely sure about what it might involve but you look to me to be a de facto deputy administrator (and I am too scared to try bothering Ward). Do you have a view on doing this? I guess the alternative is to ask Scott to do the same with AndStuff as Sunir did with MeatBall rather than shutting it down? -- AndrewCates

Hah, a de factor deputy administrator? I'm flattered, but no, I'm just a hopefully-helpful WikiGnome. Anyway, I'd recommend the same thing Doug and the AnonymousDonor suggested: go ahead and do, explain why you're doing, and be prepared to move the pages off if CommunityDoesNotAgree. We all act by community consensus here (well, ideally), but that doesn't mean you need to ask permission for everything. The anyone-can-edit-any-page system fulfills that function. If people don't agree, they'll edit or delete the page. Then it's up to you to either restore a toned-down version that's likely to be acceptable, or discuss until you can come to a consensus. -- JonathanTang

Thanks. Have done at AboutLettertoPeter?. Andrew
FYI someone moved your ProceduralCodeCritique? to FictionPublishingExample; just a heads-up in case you didn't notice. -- dm

Yep, that's me actually. Haven't gotten around to resetting my username cookie after moving to FireFox. -- jt

How can you keep track of whether you were the one that did something without a username cookie? :-) <-dm Thanks, but I am able to do that for myself.
Jonathan, I just figured You should get a warm fuzzy for the refactoring and WikiGnomeing you do on a regular basis. So ... WHUTE! -- JonathanArkell

Thanks, I try. :) There're many folks here that do a whole lot more WikiGnoming? than I do, though, and many of them remain anonymous. -- JonathanTang

Oh totally.. but i caught you in the act. ;)
Jonathan, re: BrufPredictsFailure

I think what PhlIp did (adding the reposting bit) was very good compromise. Agree with you the names made it better known who said what, but I would have put in SixSingleQuotes and add the word from before their names.

I think it is necessary to differentiate what a person said elsewhere and quoted here, vs what a person said in person with proper signature, vs the need to sometimes making a more casual comment.

So dl is my semi Casual identifier, will go more formal, or less formal depending on circumstances.

What do you think? -- dl

I also think what PhlIp did was a good compromise. Am a little worried about the "without permission" part, but copyright issues are for Ward to worry about.

And typically the initialed signature is used for further comments after you've already signed one on the page. I've gotten lazy too and sometimes signed with just initials, then had to go back and add the full signature because people didn't know who I was. WikiIsNotaSocialClub?. A signature of just -- dl or -- jt carries no information if someone stumbles onto a comment several years later, after the participants have long since become inactive. -- jt

ShortWikiSignaturesSmell for several reasons. -- MarkIrons?

Agreed, and I've been tending to move back towards RealNamesOnlyOrAnonymous lately. They should all be on pages where I've signed in full earlier, though Googling through it looks like a couple have been moved to their own pages, or the original signed comment has been edited out (yet another reason why they smell).

Most of the pages seem to be unredeemable ThreadMess anyway though. I'm not sure I like the general trend towards shorter, more off-the-cuff comments, though I've certainly participated in them too. BulletedThreadsSmell horribly. -- jt (hey, it's my HomePage)

Jonathan, in case your bright intelligence was not able to figure it out on its own, I choose to delete any AnonymousCoward signed (and not only those) idiocies that contain gratuitous insults. If you want to waste your time restoring such things, well be my guest. I shall have fun. -- Costin

If you're referring to BoysThatBitch?, go right ahead. I'm really just being pedantic, because I've found lots of people who toss terms like libel and slander around without knowing what they really mean ("plagiarism" is another oft-misunderstood term). Long as you've read my comment, go ahead and delete it again, or I can if you'd like. -- jt

EditText of this page (last edited April 21, 2006) or FindPage with title or text search