[M3commit] [modula3/cm3] fa9293: Fix "[m3devel] Another Word bug" reported by Peter...

GitHub noreply at github.com
Fri Feb 26 18:37:21 CET 2016


  Branch: refs/heads/master
  Home:   https://github.com/modula3/cm3
  Commit: fa9293aaaf5fb3b4933e38103e2c811bef957f4b
      https://github.com/modula3/cm3/commit/fa9293aaaf5fb3b4933e38103e2c811bef957f4b
  Author: Rodney Bates <rodney.m.bates at acm.org>
  Date:   2016-02-26 (Fri, 26 Feb 2016)

  Changed paths:
    M m3-sys/m3front/src/exprs/CallExpr.m3

  Log Message:
  -----------
  Fix "[m3devel] Another Word bug" reported by Peter McKinna

Fix the following:

Compiling this snippet with the typo & instead of ,

PROCEDURE T() =
VAR j : INTEGER;
BEGIN
  j := Word.And(1 & 3);
END T;

gives

"../src/Test.m3", line 7: illegal operand(s) for '&'

***
*** runtime error:
***    An array subscript was out of range.
***    file "../AMD64_LINUX/WordAnd.m3 => ../src/builtinWord/And.mg", line 44
***

Aborted (core dumped)




More information about the M3commit mailing list