[BLACKBOX] Trap 0 when compiling LSH and ROT

From: [at]} <CFB>
Date: Thu, 3 Jan 2008 14:32:36 +1030

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

The following sample code results in a trap 0 when attempting to compile
with BB 1.6rc5:

MODULE TestShift;

IMPORT
  SYSTEM;
        
VAR
  int: INTEGER;
  long: LONGINT;
        
BEGIN
  int := 1;
  long := 2;
  int := SYSTEM.LSH(int, long)
END TestShift.

(The same problem occurs with SYSTEM.ROT)

I acknowledge that the code is invalid (the second parameter should not be a
LONGINT). However, a trap rather than a compiler error message makes it
difficult to locate the problem as it is not immediately obvious which line
of your own source code is causing the problem.

Regards,

Chris Burrows
CFB Software
http://www.cfbsoftware.com/gpcp


----
To unsubscribe, send a message with body "SIGNOFF BLACKBOX" to LISTSERV{([at]})nowhere.xy----boundary-LibPST-iamunique-1591395116_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"
e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZmYwe1xmb250dGJsDQp7XGYwXGZz
d2lzcyBBcmlhbDt9DQp7XGYxXGZtb2Rlcm4gQ291cmllciBOZXc7fQ0Ke1xmMlxmbmlsXGZjaGFy
c2V0MiBTeW1ib2w7fQ0Ke1xmM1xmbW9kZXJuXGZjaGFyc2V0MCBDb3VyaWVyIE5ldzt9fQ0Ke1xj
b2xvcnRibFxyZWQwXGdyZWVuMFxibHVlMDtccmVkMFxncmVlbjBcYmx1ZTI1NTt9DQpcdWMxXHBh
cmRccGxhaW5cZGVmdGFiMzYwIFxmMFxmczIwIFRoZSBmb2xsb3dpbmcgc2FtcGxlIGNvZGUgcmVz
dWx0cyBpbiBhIHRyYXAgMCB3aGVuIGF0dGVtcHRpbmcgdG8gY29tcGlsZVxwYXINCndpdGggQkIg
MS42cmM1OlxwYXINClxwYXINCk1PRFVMRSBUZXN0U2hpZnQ7XHBhcg0KXHBhcg0KSU1QT1JUIFx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2008 - 05:02:36 UTC

This archive was generated by hypermail 2.3.0 : Thu Sep 26 2013 - 06:31:11 UTC