prettyprint: rename so it doesn't look so much like print-error.
							parent
							
								
									e42144e9ea
								
							
						
					
					
						commit
						24b116be1c
					
				| 
						 | 
				
			
			@ -35,7 +35,7 @@ IN: prettyprint
 | 
			
		|||
 | 
			
		||||
: short. ( obj -- ) pprint-short nl ;
 | 
			
		||||
 | 
			
		||||
: pprint-error ( obj -- str )
 | 
			
		||||
: error-in-pprint ( obj -- str )
 | 
			
		||||
    class-of name>> "~pprint error: " "~" surround ;
 | 
			
		||||
 | 
			
		||||
: .b ( n -- ) >bin print ;
 | 
			
		||||
| 
						 | 
				
			
			@ -45,7 +45,7 @@ IN: prettyprint
 | 
			
		|||
: stack. ( seq -- )
 | 
			
		||||
    [
 | 
			
		||||
        [ short. ] [
 | 
			
		||||
            drop [ pprint-error ] keep write-object nl
 | 
			
		||||
            drop [ error-in-pprint ] keep write-object nl
 | 
			
		||||
        ] recover
 | 
			
		||||
    ] each ;
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -12,7 +12,7 @@ IN: ui.tools.traceback
 | 
			
		|||
TUPLE: stack-entry object string ;
 | 
			
		||||
 | 
			
		||||
: <stack-entry> ( object -- stack-entry )
 | 
			
		||||
    dup [ unparse-short ] [ drop pprint-error ] recover
 | 
			
		||||
    dup [ unparse-short ] [ drop error-in-pprint ] recover
 | 
			
		||||
    stack-entry boa ;
 | 
			
		||||
 | 
			
		||||
SINGLETON: stack-entry-renderer
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue