Added some tests.
Fixed some things I noticed when testing the tests.
This commit is contained in:
		
							parent
							
								
									524933d29f
								
							
						
					
					
						commit
						3908019bbc
					
				
					 4 changed files with 235 additions and 33 deletions
				
			
		|  | @ -40,13 +40,13 @@ | |||
| 
 | ||||
| (define-syntax in-list | ||||
|   (syntax-rules (:for) | ||||
|     ((in-list:for ((var) source) next . rest) | ||||
|     ((in-list :for ((var) source) next . rest) | ||||
|      (in-list :for ((var cursor) source) next . rest)) | ||||
|     ((in-list:for ((var cursor) source) next . rest) | ||||
|     ((in-list :for ((var cursor) source) next . rest) | ||||
|      (in-list :for ((var cursor succ) source) next . rest)) | ||||
|     ((in-list:for ((var cursor succ) (source)) next . rest) | ||||
|     ((in-list :for ((var cursor succ) (source)) next . rest) | ||||
|      (in-list :for ((var cursor succ) (source cdr)) next . rest)) | ||||
|     ((in-list:for ((var cursor succ) (source step)) next . rest) | ||||
|     ((in-list :for ((var cursor succ) (source step)) next . rest) | ||||
|      (next | ||||
|       ;; outer let bindings, bound outside the loop, unchanged during the loop | ||||
|       () | ||||
|  | @ -63,9 +63,9 @@ | |||
|       . rest)) | ||||
| 
 | ||||
|     ;; Generator-clauses | ||||
|     ((in-listlst) | ||||
|     ((in-list lst) | ||||
|      (gen-list lst)) | ||||
|     ((in-list(var) (expr step)) | ||||
|     ((in-list (var) (expr step)) | ||||
|      (gen-list lst step)))) | ||||
| 
 | ||||
| (define gen-list | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Linus
						Linus