logoalt Hacker News

tomcamyesterday at 10:23 PM1 replyview on HN

Seems to be strongly influenced by HyperTalk... or is it the other way around?


Replies

zahlmanyesterday at 11:41 PM

Both date to 1987. Aside from the use of whitespace, I don't really see the same influence. HyperTalk loops looked like `repeat with i = 1 to ...`; it didn't have the same concept of iterating over a container directly, even though it could treat strings as containers (not just of "characters", but also space-separated "words" or comma-separated "items").

On the other hand, it had explicit syntax sugar that was specific to the HyperCard environment (thus actions like `ask` and `answer` for simple modal dialog prompts), along with phrasing intended to make things read in English and even avoiding basic operators (thus, `put ... into ...` as an assignment syntax, `the number of` as a length operator, `it` referring to the result of the previous line in some contexts, ...). And of course, the HyperCard environment was event-driven; you could write explicitly callable functions, but your entry point was only ever some GUI interaction, not top-level code or a "main" function.

Perhaps you could say that they both came from a similar philosophy about how to make a programming language "natural-language-like". Which IMO was a big step up from COBOL at least ;)