axiom-developer
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Axiom-developer] serveral bugs in codebase


From: Juergen Weiss
Subject: [Axiom-developer] serveral bugs in codebase
Date: 26 Jul 2003 18:13:30 +0200
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

Hi,

here is a list of bugs I found, with suggested fixes:

*** intint.lisp 2003/06/20 20:13:06     1.1
--- intint.lisp 2003/06/20 20:35:24
***************
*** 63,69 ****
  ;;   (|npProcessSynonym| str))
  
  (defun |SpadInterpretFile| (fn)
!       (|SpadInterpretStream| nil fn nil) )
  
  (defun |intNewFloat| ()
    (list '|Float|))
--- 63,69 ----
  ;;   (|npProcessSynonym| str))
  
  (defun |SpadInterpretFile| (fn)
!       (|SpadInterpretStream| 1 fn nil) )
  
  (defun |intNewFloat| ()
    (list '|Float|))


*** macros.lisp 2003/03/22 20:24:23     1.1
--- macros.lisp 2003/06/16 19:56:44
***************
*** 297,303 ****
   "Needed by spadCompileOrSetq" 1)
   
  (defun -REPEAT (BD SPL)
!   (let (u g g1 inc final xcl xv il rsl tll funPLUS funGT fun? funIdent)
      (DO ((X SPL (CDR X)))
          ((ATOM X)
           (LIST 'spadDO (NREVERSE IL) (LIST (MKPF (NREVERSE XCL) 'OR) XV)
--- 297,303 ----
   "Needed by spadCompileOrSetq" 1)
   
  (defun -REPEAT (BD SPL)
!   (let (u g g1 inc final xcl xv il rsl tll funPLUS funGT fun? funIdent 
funPLUSform funGTform)
      (DO ((X SPL (CDR X)))
          ((ATOM X)
           (LIST 'spadDO (NREVERSE IL) (LIST (MKPF (NREVERSE XCL) 'OR) XV)



in newaux.lisp, the binding powers of +-> should be:
         (+-\> 998 112) ; was 998 102 


the following error leads to undefined var error
if checked at runtime

*** define.boot 2003/03/22 20:24:23     1.1
--- define.boot 2003/06/21 21:16:46
***************
*** 1181,1187 ****
   
  compCapsuleItems(itemlist,$predl,$e) ==
    $TOP__LEVEL: local
!   $myFunctorBody :local := data    ---needed for translator
    $signatureOfForm: local
    $suffix: local:= 0
    for item in itemlist repeat $e:= compSingleCapsuleItem(item,$predl,$e)
--- 1172,1178 ----
   
  compCapsuleItems(itemlist,$predl,$e) ==
    $TOP__LEVEL: local
!   $myFunctorBody :local -- := data    ---needed for translator
    $signatureOfForm: local
    $suffix: local:= 0
    for item in itemlist repeat $e:= compSingleCapsuleItem(item,$predl,$e)

diff -c -r1.1 format.boot
*** format.boot 2003/03/22 20:24:23     1.1
--- format.boot 2003/06/20 23:04:52
***************
*** 703,716 ****
              if CAR next = 'dbN then dbN := CADR next
              else argL := next
              keyStuff  := IFCDR keyStuff
!             next      := IFCAR KeyStuff
          oneMsg  := returnStLFromKey(key,argL,dbN)
          allMsgs := ['" ", :NCONC (oneMsg,allMsgs)]
      allMsgs
--- 703,716 ----
              if CAR next = 'dbN then dbN := CADR next
              else argL := next
              keyStuff  := IFCDR keyStuff
!             next      := IFCAR keyStuff
          oneMsg  := returnStLFromKey(key,argL,dbN)
          allMsgs := ['" ", :NCONC (oneMsg,allMsgs)]
      allMsgs


wrong # of args
*** i-map.boot  2003/03/22 20:24:23     1.1
--- i-map.boot  2003/06/20 18:37:48
***************
*** 690,696 ****
  
    locals := SETDIFFERENCE(COPY $localVars, parms)
    if locals then
!     lets := [['LET, l, ''UNINITIALIZED__VARIABLE, op] for l in locals]
      body := ['PROGN, :lets, body]
  
    reportFunctionCompilation(op,fnName,parms,
--- 690,696 ----
  
    locals := SETDIFFERENCE(COPY $localVars, parms)
    if locals then
!     lets := [['LET, l, ''UNINITIALIZED__VARIABLE] for l in locals]
      body := ['PROGN, :lets, body]



I'm not really sure if this change is correct,
the original code for sure is incorrect.

*** i-spec1.boot        2003/03/22 20:24:23     1.1
--- i-spec1.boot        2003/06/20 21:13:15
***************
*** 897,914 ****
    -- for one index variable case for now.  may generalize later
    for iter in itrl repeat
      iter is ['WHILE,pred] =>
!       predVec := mkIterZippedFun($indexList,pred,zipType,$localVars)
        s := [mkAtreeNode 'swhile,predVec,s]
      iter is ['UNTIL,pred] =>
!       predVec := mkIterZippedFun($indexList,pred,zipType,$localVars)
        s := [mkAtreeNode 'suntil,predVec,s]
      iter is ['SUCHTHAT,pred] =>
        putTarget(pred,$Boolean)
!       predVec := mkIterZippedFun($indexList,pred,zipType,$localVars)
        s := [mkAtreeNode 'select,predVec,s]
    s
  
! mkIterZippedFun(indexList,funBody,zipType,$localVars) ==
    -- transform funBody into a lamda with $index as the parameter
    numVars:= #$indexVars
    for [var,:.] in $indexVars repeat
--- 897,914 ----
    -- for one index variable case for now.  may generalize later
    for iter in itrl repeat
      iter is ['WHILE,pred] =>
!       predVec := mkIterZippedFun($indexVars,pred,zipType,$localVars)
        s := [mkAtreeNode 'swhile,predVec,s]
      iter is ['UNTIL,pred] =>
!       predVec := mkIterZippedFun($indexVars,pred,zipType,$localVars)
        s := [mkAtreeNode 'suntil,predVec,s]
      iter is ['SUCHTHAT,pred] =>
        putTarget(pred,$Boolean)
!       predVec := mkIterZippedFun($indexVars,pred,zipType,$localVars)
        s := [mkAtreeNode 'select,predVec,s]
    s
  
! mkIterZippedFun($indexVars,funBody,zipType,$localVars) ==
    -- transform funBody into a lamda with $index as the parameter
    numVars:= #$indexVars
    for [var,:.] in $indexVars repeat

wrong # of args
*** i-spec2.boot        2003/03/22 20:24:23     1.1
--- i-spec2.boot        2003/06/20 18:46:33
***************
*** 550,556 ****
              compFailure ['"   The type of the local variable",
                :bright name,'"has changed in the computation."]
          if dm and isSubDomain(dm,om) then put(name,'mode,om,$env)
!         ['LET,name,objVal value,$mapName]
                 -- $mapName is set in analyzeMap
        om := objMode value
        dm := get(name, 'mode, $env) or objMode(get(name, 'value, $e))
--- 550,556 ----
              compFailure ['"   The type of the local variable",
                :bright name,'"has changed in the computation."]
          if dm and isSubDomain(dm,om) then put(name,'mode,om,$env)
!         ['LET,name,objVal value]
                 -- $mapName is set in analyzeMap
        om := objMode value
        dm := get(name, 'mode, $env) or objMode(get(name, 'value, $e))



avoid infinite loop, if autoload fails

*** lisplib.boot        2003/03/22 20:24:23     1.1
--- lisplib.boot        2003/06/29 17:10:24
***************
*** 216,222 ****
      SETF(SYMBOL_-FUNCTION cnam,mkAutoLoad(fn, cnam))
   
  autoLoad(abb,cname) ==
!   if not GET(cname,'LOADED) then loadLib cname
    SYMBOL_-FUNCTION cname
   
  setAutoLoadProperty(name) ==
--- 216,224 ----
      SETF(SYMBOL_-FUNCTION cnam,mkAutoLoad(fn, cnam))
   
  autoLoad(abb,cname) ==
!   if not GET(cname,'LOADED) then
!       FMAKUNBOUND cname
!       loadLib cname
    SYMBOL_-FUNCTION cname
   
  setAutoLoadProperty(name) ==


*** msg.boot    2003/06/20 20:13:07     1.1
--- msg.boot    2003/07/09 20:59:59
***************
*** 379,388 ****
  -------------------
  --%   a-list stuff
  desiredMsg (erMsgKey,:optCatFlag) ==
!     isKeyQualityP(erMsgKey,'show)   => TRUE
!     isKeyQualityP(erMsgKey,'stifle) => NIL
      not null optCatFlag  => CAR optCatFlag
!     TRUE
   
  isKeyQualityP (key,qual)  ==
      --returns pair if found, else NIL
--- 379,388 ----
  -------------------
  --%   a-list stuff
  desiredMsg (erMsgKey,:optCatFlag) ==
!     isKeyQualityP(erMsgKey,'show)   => true
!     isKeyQualityP(erMsgKey,'stifle) => false
      not null optCatFlag  => CAR optCatFlag
!     true
   
  isKeyQualityP (key,qual)  ==
      --returns pair if found, else NIL


Regards

Juergen Weiss

-- 
Juergen Weiss     | Universitaet Mainz, Zentrum fuer Datenverarbeitung,
address@hidden| 55099 Mainz, Tel: +49(6131)39-26361, FAX: +49(6131)39-26407




reply via email to

[Prev in Thread] Current Thread [Next in Thread]