Fix prettyprinting of URLs

db4
Slava Pestov 2009-04-05 20:44:12 -05:00
parent 75dd35179b
commit 87121c1468
2 changed files with 8 additions and 3 deletions

View File

@ -1,6 +1,9 @@
! Copyright (C) 2008 Slava Pestov.
! See http://factorcode.org/license.txt for BSD license.
USING: kernel present prettyprint.custom prettyprint.backend urls ;
USING: kernel present prettyprint.custom prettyprint.sections
prettyprint.backend urls ;
IN: urls.prettyprint
M: url pprint* dup present "URL\" " "\"" pprint-string ;
M: url pprint*
\ URL" record-vocab
dup present "URL\" " "\"" pprint-string ;

View File

@ -1,5 +1,5 @@
IN: urls.tests
USING: urls urls.private tools.test
USING: urls urls.private tools.test prettyprint
arrays kernel assocs present accessors ;
CONSTANT: urls
@ -227,3 +227,5 @@ urls [
[ "http://localhost/?foo=bar" >url ] unit-test
[ "/" ] [ "http://www.jedit.org" >url path>> ] unit-test
[ "USING: urls ;\nURL\" foo\"" ] [ URL" foo" unparse-use ] unit-test