Re: CAP once more

From: H. v. L. <"H.>
Date: Fri, 17 Sep 2004 21:02:39 +0200

----boundary-LibPST-iamunique-760466341_-_-
Content-type: text/plain

On Fri, 17 Sep 2004 19:27:04 +0100, Bob Walkden <bob{([at]})nowhere.xy
wrote:

  snip

> CAP(CHR(247)) = CAP(÷) = ×
>
> There is no sense in which ÷ can be said to have a capital letter, as
> far as I know.
>
> Other Oberons do not have a character set as part of the specification of
> CAP, and none of them seems to specify the result of executing CAP on a
> character like ÷, for which there is no meaningful capital equivalent.
> Therefore, if you execute CAP with a non-letter character, all bets
> are off. This is rather unfortunate. It would have been better to
> define a result for the non-letter case. It should have returned
> either the same character that was input, or it should have returned a
> value such as 0X, indicating 'no corresponding capital'.

Thanks for writing. This my opinion as well.
And the other question I had in mind may not have shown clearly, as the
module I added was written in a little hurry. Here's a (hopefully) better
version:

MODULE PrivCapTest;

        IMPORT
                In, StdLog;

        PROCEDURE Do*;
                VAR
                        ch: CHAR;
                        i: INTEGER;
        BEGIN
                FOR i := ORD(MIN(CHAR)) TO ORD(MAX(SHORTCHAR)) DO
                        ch := CHR(i);
                        StdLog.Ln;
                        StdLog.String("CAP(CHR(");
                        StdLog.IntForm(i, 16, 0, 8FX, FALSE);
                        StdLog.String(")) = ");
                        StdLog.String("CAP(");
                        StdLog.Char(ch);
                        StdLog.String(") = ");
                        StdLog.Char(CAP(ch));
                        IF ch # CAP(ch) THEN
                                StdLog.String(" = ");
                                StdLog.String("CHR(");
                                StdLog.IntForm(ORD(CAP(CHR(i))), 16, 0, 8FX, FALSE);
                                StdLog.String(") ");
                        END;
                END;
                StdLog.Ln;
        END Do;

END PrivCapTest.

This one shows the mappings of CAP in Hex-numbers. And on inspection it
really shows some logic. The blocks 00X to 1FX, 40X to 5FX, 80X to 9FX and
C0X to DFX are unchanged by CAP whereas the others are mapped on their
preceding blocks respectivly (e. g. 60X -> 40X and so on).
Whatever the implementation of this (non-) mapping may be, I can't imagine
that it really is a problem to change in the sense that blocks 20X to 3FX
and A0X to BFX stay unmapped as well.
I admit this will not solve the problem of having CAP(÷) = ×, but this
really is a matter of the unicode gang (or their predecessors) not one OMS
can solve. On the other side I believe OMS should be able to change CAP
the way I sugest without loss of efficiency as the action to be taken
still isn't anything else but bit-shifting. Or am I wrong?

Regards

Harro von Lavergne
--------------------------------------------

To unsubscribe from this mailing list, send a message containing the word "unsubscribe" to:
   blackbox-request{([at]})nowhere.xy

To get a list of valid e-mail commands and instructions on their usage, send a message containing the word "help" to the above address.

Send any problem reports or questions related to this email list to the list owner at
   owner-blackbox{([at]})nowhere.xy

Current posting policy:

a) To post you should use the same address by which you are subscribed to the mailing list. That way, the list server will recognize you as subscriber and forward your posting immediately, without creating any overhead.

b) If, for some reason, you cannot post from the address, by which you are subscribed, your message will be moderated to avoid spam. Please understand that moderation will often cause some delay, in particular over weekends or holydays.


----boundary-LibPST-iamunique-760466341_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"

e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZmYwe1xmb250dGJsDQp7XGYwXGZz
d2lzc1xmY2hhcnNldDAgQXJpYWw7fQ0Ke1xmMVxmbW9kZXJuIENvdXJpZXIgTmV3O30NCntcZjJc
Zm5pbFxmY2hhcnNldDIgU3ltYm9sO30NCntcZjNcZm1vZGVyblxmY2hhcnNldDAgQ291cmllciBO
ZXc7fX0NCntcY29sb3J0YmxccmVkMFxncmVlbjBcYmx1ZTA7XHJlZDBcZ3JlZW4wXGJsdWUyNTU7
fQ0KXHVjMVxwYXJkXHBsYWluXGRlZnRhYjM2MCBcZjBcZnMyMCBPbiBGcmksIDE3IFNlcCAyMDA0
IDE5OjI3OjA0ICswMTAwLCBCb2IgV2Fsa2RlbiA8Ym9iQHdlYi1vcHRpb25zLmNvbT4gIFxwYXIN
Cndyb3RlOlxwYXINClxwYXINCiAgc25pcFxwYXINClxwYXINCj4gIENBUChDSFIoMjQ3KSkgPSBD
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