[M3devel] Text processing

Mika Nystrom mika at async.caltech.edu
Tue Apr 28 18:26:24 CEST 2009


Hmm cm3ide has its own Wx.  It doesn't use that?  It looks different
from the standard one in cm3.

In the *standard* one, that is, m3-libs/libbuf/src/Wx.m3,
the fix is the following:

PROCEDURE ToText (t: T): TEXT =
  VAR txt := Text8.Create(t.nFull * ChunkSize + t.next);
      c := t.head;   n := 0;
  BEGIN

There used to be a "+ 1" in the call to Text8.Create.  It's crud
from converting from the old array TEXTs.

I've already checked this in to the cm3 distribution.

     Mika

"Randy Coleburn" writes:
>This is a MIME message. If you are reading this text, you may want to 
>consider changing to a mail reader or gateway that understands how to 
>properly handle MIME multipart messages.
>
>--=__Part6C44DF9F.0__=
>Content-Type: text/plain; charset=US-ASCII
>Content-Transfer-Encoding: quoted-printable
>
>There is a bug in CM3IDE that may be the result of this problem.  I'll =
>need to get your fix and try it.
>--Randy
>
>>>> Mika Nystrom <mika at async.caltech.edu> 4/28/2009 11:36 AM >>>
>
>Speaking of text processing, I was very surprised at the bug I found
>in Wx the other day (and checked in a fix for).  I'm 99% certain my
>fix is correct, but I'm very surprised no one found this bug before.
>
>Wx was inserting spurious nulls at the end of every generated TEXT.
>
>Is it possible someone is using this interface and depending on the
>buggy behavior?  m3ide and m3browser import it.
>
>     Mika
>
>
>CONFIDENTIALITY NOTICE:  This email and any attachments are intended =
>solely for the use of the named recipient(s). This e-mail may contain =
>confidential and/or proprietary information of Scientific Research =
>Corporation.  If you are not a named recipient, you are prohibited from =
>making any use of the information in the email and attachments.  If you =
>believe you have received this email in error, please notify the sender =
>immediately and permanently delete the email, any attachments, and all =
>copies thereof from any drives or storage media and destroy any printouts =
>of the email or attachments.
>
>EXPORT COMPLIANCE NOTICE:  This email and any attachments may contain =
>technical data subject to U.S export restrictions under the International =
>Traffic in Arms Regulations (ITAR) or the Export Administration Regulations=
> (EAR).  Export or transfer of this technical data and/or related =
>information to any foreign person(s) or entity(ies), either within the =
>U.S. or outside of the U.S., may require export authorization by the =
>appropriate U.S. Government agency prior to export or transfer.  In =
>addition, technical data may not be exported or transferred to certain =
>countries or specified designated nationals identified by U.S. embargo =
>controls without prior export authorization.  By accepting this email and =
>any attachments, all recipients confirm that they understand and will =
>comply with all applicable ITAR, EAR and embargo compliance requirements.
>
>
>--=__Part6C44DF9F.0__=
>Content-Type: text/html; charset=US-ASCII
>Content-Transfer-Encoding: quoted-printable
>Content-Description: HTML
>
><HTML><HEAD>
><META http-equiv=3DContent-Type content=3D"text/html; charset=3Diso-8859-15=
>">
><META content=3D"MSHTML 6.00.6000.16825" name=3DGENERATOR></HEAD>
><BODY style=3D"MARGIN: 4px 4px 1px">
><DIV>There is a bug in CM3IDE that may be the result of this problem. =
> I'll need to get your fix and try it.</DIV>
><DIV>--Randy<BR><BR>>>> Mika Nystrom <mika at async.caltech.edu&gt=
>; 4/28/2009 11:36 AM >>><BR><BR>Speaking of text processing, I =
>was very surprised at the bug I found<BR>in Wx the other day (and checked =
>in a fix for).  I'm 99% certain my<BR>fix is correct, but I'm very =
>surprised no one found this bug before.<BR><BR>Wx was inserting spurious =
>nulls at the end of every generated TEXT.<BR><BR>Is it possible someone is =
>using this interface and depending on the<BR>buggy behavior?  m3ide =
>and m3browser import it.<BR><BR>     Mika<BR><BR></DIV>=
></BODY></HTML>
>
>--=__Part6C44DF9F.0__=--



More information about the M3devel mailing list