Changeset 8448
- Timestamp:
- Feb 9, 2008, 9:16:45 AM (17 years ago)
- Location:
- branches/gz-working/cocoa-ide
- Files:
-
- 2 edited
-
cocoa-editor.lisp (modified) (1 diff)
-
cocoa-utils.lisp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/gz-working/cocoa-ide/cocoa-editor.lisp
r8428 r8448 1810 1810 (hemlock-view pane)))) 1811 1811 1812 (defun double-%-in (string)1813 ;; Replace any % characters in string with %%, to keep them from1814 ;; being treated as printf directives.1815 (let* ((%pos (position #\% string)))1816 (if %pos1817 (concatenate 'string (subseq string 0 %pos) "%%" (double-%-in (subseq string (1+ %pos))))1818 string)))1819 1820 (defun nsstring-for-lisp-condition (cond)1821 (%make-nsstring (double-%-in (or (ignore-errors (princ-to-string cond))1822 "#<error printing error message>"))))1823 1824 1812 (objc:defmethod (#/runErrorSheet: :void) ((self hemlock-frame) message) 1825 1813 #+debug (#_NSLog #@"runErrorSheet: signal = %@" :id signal) -
branches/gz-working/cocoa-ide/cocoa-utils.lisp
r8428 r8448 235 235 ;; debugging 236 236 237 (defun double-%-in (string) 238 ;; Replace any % characters in string with %%, to keep them from 239 ;; being treated as printf directives. 240 (let* ((%pos (position #\% string))) 241 (if %pos 242 (concatenate 'string (subseq string 0 %pos) "%%" (double-%-in (subseq string (1+ %pos)))) 243 string))) 244 237 245 (defun log-debug (format-string &rest args) 238 (#_NSLog (ccl::%make-nsstring (apply #'format nil format-string args)))) 246 (let ((string (apply #'format nil format-string args))) 247 (#_NSLog (ccl::%make-nsstring (double-%-in string))))) 239 248 240 249 (defun nslog-condition (c) … … 244 253 (#_NSLog #@"Error in event loop: %@" :address nsstr))))) 245 254 255 (defun nsstring-for-lisp-condition (cond) 256 (%make-nsstring (double-%-in (or (ignore-errors (princ-to-string cond)) 257 "#<error printing error message>")))) 258 246 259 247 260
Note:
See TracChangeset
for help on using the changeset viewer.
