哪种语言用于设计1990年的Photoshop?

时间:2013-02-15 04:50:05

标签: pascal

http://news.cnet.com/8301-1023_3-57569533-93/adobe-releases-source-code-for-1990-version-of-photoshop/

http://www.computerhistory.org/atchm/photoshop-license-agreement/

问题>这是帕斯卡吗?

PROCEDURE AddCode (node: PNode; code: INTEGER; VAR word: Str255);

VAR
    branch: INTEGER;

BEGIN

IF LENGTH (word) = 0 THEN
    BEGIN

    IF node^.leaf OR (node^.branch [0] <> NIL) OR
                     (node^.branch [1] <> NIL) THEN
        BEGIN
        WRITELN ('? Conflict for code ', code:1);
        EXIT (PROGRAM)
        END;

    node^.leaf := TRUE;
    node^.code := code

    END

ELSE
    BEGIN

    IF word [1] = '0' THEN
        branch := 0
    ELSE IF word [1] = '1' THEN
        branch := 1
    ELSE
        BEGIN
        WRITELN ('? Invalid word for code ', code:1);
        EXIT (PROGRAM)
        END;

    DELETE (word, 1, 1);

    IF node^.branch [branch] = NIL THEN
        BEGIN

        NEW (node^.branch [branch]);

        node^.branch [branch]^.leaf := FALSE;
        node^.branch [branch]^.branch [0] := NIL;
        node^.branch [branch]^.branch [1] := NIL

        END;

    AddCode (node^.branch [branch], code, word)

    END

END;

1 个答案:

答案 0 :(得分:2)

Cnet文章链接到a blog post from the Computer History Museum宣布代码的发布,它告诉你答案:

  

按行数计算,大约75%的代码使用Pascal,大约15%使用68000汇编语言,其余的是各种类型的数据。

问题中引用的特定代码确实是Pascal。