[Oberon] Username which contains the "@" char ...

shark at gulfnet.sd64.bc.ca shark at gulfnet.sd64.bc.ca
Thu Jan 5 21:49:01 CET 2006


Chris,

Greetings for the New Year.

Monday 08 August 2005 you mentioned,
" ... Username which contains the "@" char 
I've torn my guts out patching n-o ..."

pe.RFC2396.Mod is now available.
HyperDocTools.Fetch 
"http://carnot.pathology.ubc.ca/pe.RFC2396.Mod" => pe.RFC2396.Mod ~ 

It is based upon parts of HyperDocs.Mod.  I've 
changed ESC and UnESC in consideration of these 
factors.
1. HyperDocs.ESC works "in place".  NetSystem 
must be able to keep distinct source and target 
strings to avoid UnESCing and ESCing whenever 
Show is invoked.  That is why I needed to ask a 
few months ago how to detect the identity of two 
variables.
2. I want to check for array overflow.  This can
happen when ESC adds characters.  Also can happen
when the target array is smaller than the source.
3. I want to check that a parameter is legitimate;
ie. that 0X terminates the string.
4. HyperDocs.ESC and UnESC shift downstream characters 
for each escapable character found.  Another way 
requires one shift at most; see ESC1 and UnESC.
5. With a temporary variable, shifting is avoided 
and the code is shorter; see ESC2.  Nevertheless
ESC1 seems better than ESC2.

Several test cases are at the end of the file.  
If you can find another which breaks my implementation 
please let me know.

Jan commented,
"I prefer longer code over C style functions."

My programming experience is too limited.  All 
criticisms are welcome and I'll try to make 
appropriate improvements.

Of course, RFC2396.Mod is no practical help until 
used in NetSystem.Mod.  I'll work on that when 
time is available.

While working here we can reflect that escaping 
could have been unnecessary with another syntax 
of the URI.

Regards,    ... Peter E.

Desktops.OpenDoc  http://carnot.pathology.ubc.ca/



More information about the Oberon mailing list