Skip to content
  1. Dec 17, 2022
  2. Aug 19, 2021
  3. May 23, 2021
  4. May 18, 2021
    • Steve Losh's avatar
      Fix control flow when the loop contains NIL blocks · e0cc021a
      Steve Losh authored and Robert Goldman's avatar Robert Goldman committed
      Control flow clauses that return from an iterate form without executing
      the epilogue code (e.g. `never` and `leave`) currently do so by
      expanding into `(return-from ,*block-name*)`.  For iterate forms without
      a user-provided name, the block will be named `nil`.  This causes
      problems when used with other Common Lisp looping constructs such as
      `dolist`:
      
          (iterate
            (for i :from 0 :below 10)
            (dolist (x '(5 10 15))
              (never (= i x))))
          ; => T, but should be NIL
      
      This patch adds a separate `*loop-name*` variable that will be bound to
      a gensym for `NIL`-named blocks and makes the various epilogue-skipping
      code refer to that instead of `*block-name*`.  Iterate forms *without*
      an explicit user-provided name will still have a separate `(block nil
      ...)` wrapping so users can still `(return ...)` as before.
      
      Before (simplified):
      
          (iterate (leave))
          ; ==> (block nil (return-from nil))
      
          (iterate foo (leave))
          ; ==> (block foo (return-from nil))
      
      After:
      
          (iterate (leave))
          ; ==> (block nil (block #:ITERATE123 (return-from #:ITERATE123)))
      
          (iterate foo (leave))
          ; ==> (block foo (return-from foo))
      e0cc021a
  5. May 17, 2021
  6. Feb 03, 2021
  7. May 11, 2020
  8. Jan 25, 2020
  9. Jan 23, 2018
  10. Jan 16, 2018
  11. Aug 03, 2017
    • Attila Lendvai's avatar
      tests: add *tests-expected-to-fail* to document which tests are expected to fail · c6659c94
      Attila Lendvai authored
      Ignore-this: 7d072a9ffe694700e1dc52ef3c653f94
      
      darcs-hash:79473b46ee0df4304125a8727b0691cfb05bbdd7
      c6659c94
    • Attila Lendvai's avatar
      Added 3 failing tests: always.finally, never.finally, and thereis.finally · ba12cb99
      Attila Lendvai authored
      Ignore-this: f3e9d3983567eb04ce2429b310bee837
      
      I'm not sure about what is their contract, but it was surprising to me
      that the FINALLY block is not executed.
      
      Arguably if you're expected to avoid sideffects in a FINALLY block,
      then you cannot/shouldn't change the return value, so the entire
      FINALLY block can be skipped then.
      
      Either way, this behavior should be documented with the tests, so
      if the current behavior is expected, then change the tests
      accordingly (as opposed to deleting them).
      
      darcs-hash:c0b172b51bc40943946c86d8ab76297807d26594
      ba12cb99
  12. Jan 29, 2014
  13. Dec 18, 2012
  14. Jun 03, 2010
    • Attila Lendvai's avatar
      added bug/walk.2 · 8bedb3c3
      Attila Lendvai authored
      Ignore-this: faa1bd48d0450e76652552bb47bcff02
      
      darcs-hash:3014735c0464ffdf47d05a0f8dd5ad6fc1f0db9b
      8bedb3c3
  15. May 25, 2007
  16. May 03, 2007
  17. Oct 25, 2006
  18. Mar 31, 2006