diff --git a/basis/db/tuples/tuples-docs.factor b/basis/db/tuples/tuples-docs.factor index 3d2971bf9c..bd88c56431 100644 --- a/basis/db/tuples/tuples-docs.factor +++ b/basis/db/tuples/tuples-docs.factor @@ -1,9 +1,13 @@ ! Copyright (C) 2008 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. USING: classes help.markup help.syntax io.streams.string kernel -quotations sequences strings multiline math db.types db ; +quotations sequences strings multiline math db.types +db.tuples.private db ; IN: db.tuples +HELP: random-id-generator +{ $description "Used to tell " { $link eval-generator } " to generate a random number for use as a key." } ; + HELP: create-sql-statement { $values { "class" class } diff --git a/basis/db/types/types-docs.factor b/basis/db/types/types-docs.factor index 4d3be1d592..60d92717e8 100644 --- a/basis/db/types/types-docs.factor +++ b/basis/db/types/types-docs.factor @@ -1,7 +1,7 @@ ! Copyright (C) 2008 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. USING: classes hashtables help.markup help.syntax io.streams.string -kernel sequences strings math db.tuples db.tuples.private ; +kernel sequences strings math ; IN: db.types HELP: +db-assigned-id+ @@ -89,31 +89,31 @@ HELP: VARCHAR HELP: user-assigned-id-spec? { $values - { "specs" "a sequence of sql specs" } + { "specs" "a sequence of SQL specs" } { "?" "a boolean" } } -{ $description "Tests if any of the sql specs has the type " { $link +user-assigned-id+ } "." } ; +{ $description "Tests if any of the SQL specs has the type " { $link +user-assigned-id+ } "." } ; HELP: bind# { $values - { "spec" "a sql spec" } { "obj" object } } + { "spec" "a SQL spec" } { "obj" object } } { $description "A generic word that lets a database construct a literal binding." } ; HELP: bind% { $values - { "spec" "a sql spec" } } + { "spec" "a SQL spec" } } { $description "A generic word that lets a database output a binding." } ; HELP: db-assigned-id-spec? { $values - { "specs" "a sequence of sql specs" } + { "specs" "a sequence of SQL specs" } { "?" "a boolean" } } -{ $description "Tests if any of the sql specs has the type " { $link +db-assigned-id+ } "." } ; +{ $description "Tests if any of the SQL specs has the type " { $link +db-assigned-id+ } "." } ; HELP: find-primary-key { $values - { "specs" "a sequence of sql-specs" } - { "seq" "a sequence of sql-specs" } } -{ $description "Returns the rows from the sql-specs array that are part of the primary key. Composite primary keys are supported, so this word must return a sequence." } + { "specs" "a sequence of SQL specs" } + { "seq" "a sequence of SQL specs" } } +{ $description "Returns the rows from the SQL specs array that are part of the primary key. Composite primary keys are supported, so this word must return a sequence." } { $notes "This is a low-level word." } ; HELP: get-slot-named @@ -124,13 +124,13 @@ HELP: get-slot-named HELP: no-sql-type { $values - { "type" "a sql type" } } -{ $description "Throws an error containing a sql type that is unsupported or the result of a typo." } ; + { "type" "a SQL type" } } +{ $description "Throws an error containing a SQL type that is unsupported or the result of a typo." } ; HELP: normalize-spec { $values - { "spec" "a sql spec" } } -{ $description "Normalizes a sql spec." } ; + { "spec" "a SQL spec" } } +{ $description "Normalizes a SQL spec." } ; HELP: offset-of-slot { $values @@ -140,22 +140,19 @@ HELP: offset-of-slot HELP: primary-key? { $values - { "spec" "a sql spec" } + { "spec" "a SQL spec" } { "?" "a boolean" } } -{ $description "Returns true if a sql spec is a primary key." } ; - -HELP: random-id-generator -{ $description "Used to tell " { $link eval-generator } " to generate a random number for use as a key." } ; +{ $description "Returns true if a SQL spec is a primary key." } ; HELP: relation? { $values - { "spec" "a sql spec" } + { "spec" "a SQL spec" } { "?" "a boolean" } } -{ $description "Returns true if a sql spec is a relation." } ; +{ $description "Returns true if a SQL spec is a relation." } ; HELP: unknown-modifier { $values { "modifier" string } } -{ $description "Throws an error containing an unknown sql modifier." } ; +{ $description "Throws an error containing an unknown SQL modifier." } ; ARTICLE: "db.types" "Database types" "The " { $vocab-link "db.types" } " vocabulary maps Factor types to database types." $nl diff --git a/basis/farkup/farkup.factor b/basis/farkup/farkup.factor index a752694764..bad41296ee 100755 --- a/basis/farkup/farkup.factor +++ b/basis/farkup/farkup.factor @@ -1,6 +1,6 @@ ! Copyright (C) 2008 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. -USING: accessors arrays combinators html.elements io +USING: accessors arrays combinators io io.streams.string kernel math namespaces peg peg.ebnf sequences sequences.deep strings xml.entities xml.literals vectors splitting xmode.code2html urls.encoding xml.data diff --git a/basis/furnace/actions/actions.factor b/basis/furnace/actions/actions.factor index 72a7b76d23..97cb73c9cb 100644 --- a/basis/furnace/actions/actions.factor +++ b/basis/furnace/actions/actions.factor @@ -10,7 +10,6 @@ furnace.utilities furnace.redirection furnace.conversations html.forms -html.elements html.components html.components html.templates.chloe diff --git a/basis/furnace/auth/auth-docs.factor b/basis/furnace/auth/auth-docs.factor index f1f68c975d..3f1bcb6085 100644 --- a/basis/furnace/auth/auth-docs.factor +++ b/basis/furnace/auth/auth-docs.factor @@ -105,9 +105,8 @@ ARTICLE: "furnace.auth.realm-config" "Authentication realm configuration" "Instances of subclasses of " { $link realm } " have the following slots which may be set:" { $table { { $slot "name" } "A string identifying the realm for user interface purposes" } - { { $slot "users" } { "An authentication provider (see " { $link "furnace.auth.providers" } ". By default, the " { $link users-in-db } " provider is used." } } + { { $slot "users" } { "An authentication provider (see " { $link "furnace.auth.providers" } "). By default, the " { $link users-in-db } " provider is used." } } { { $slot "checksum" } { "An implementation of the checksum protocol used for verifying passwords (see " { $link "checksums" } "). The " { $link sha-256 } " checksum is used by default." } } - { { $slot "users" } { "An authentication provider (see " { $link "furnace.auth.providers" } } } { { $slot "secure" } { "A boolean, that when set to a true value, forces the client to access the authentication realm via HTTPS. An attempt to access the realm via HTTP results in a redirect to the corresponding HTTPS URL. On by default." } } } ; diff --git a/basis/furnace/chloe-tags/chloe-tags.factor b/basis/furnace/chloe-tags/chloe-tags.factor index 1c320182bf..dd24d8dcde 100644 --- a/basis/furnace/chloe-tags/chloe-tags.factor +++ b/basis/furnace/chloe-tags/chloe-tags.factor @@ -8,6 +8,7 @@ xml.data xml.entities xml.writer xml.utilities +xml.literals html.components html.elements html.forms @@ -20,7 +21,6 @@ http.server http.server.redirection http.server.responses furnace.utilities ; -QUALIFIED-WITH: assocs a IN: furnace.chloe-tags ! Chloe tags @@ -56,11 +56,11 @@ CHLOE: write-atom drop [ write-atom-feeds ] [code] ; : compile-link-attrs ( tag -- ) #! Side-effects current namespace. - attrs>> '[ [ [ _ ] dip link-attr ] each-responder ] [code] ; + '[ [ [ _ ] dip link-attr ] each-responder ] [code] ; : a-start-tag ( tag -- ) [ > non-chloe-attrs-only compile-attrs ] [ compile-link-attrs ] [ compile-a-url ] tri @@ -116,17 +116,18 @@ CHLOE: form } cleave ] compile-with-scope ; -STRING: button-tag-markup - -
-
-; +: button-tag-markup ( -- xml ) + +
+ + XML> ; : add-tag-attrs ( attrs tag -- ) attrs>> swap update ; CHLOE: button - button-tag-markup string>xml body>> + button-tag-markup body>> { [ [ attrs>> chloe-attrs-only ] dip add-tag-attrs ] [ [ attrs>> non-chloe-attrs-only ] dip "button" deep-tag-named add-tag-attrs ] diff --git a/basis/help/html/html.factor b/basis/help/html/html.factor index ec52264643..820261dd32 100644 --- a/basis/help/html/html.factor +++ b/basis/help/html/html.factor @@ -1,11 +1,11 @@ ! Copyright (C) 2008 Slava Pestov. ! See http://factorcode.org/license.txt for BSD license. USING: io.encodings.utf8 io.encodings.ascii io.encodings.binary -io.files io.files.temp io.directories html.streams html.elements help kernel +io.files io.files.temp io.directories html.streams help kernel assocs sequences make words accessors arrays help.topics vocabs tools.vocabs tools.vocabs.browser namespaces prettyprint io vocabs.loader serialize fry memoize unicode.case math.order -sorting debugger ; +sorting debugger html.elements html ; IN: help.html : escape-char ( ch -- ) diff --git a/basis/html/components/components.factor b/basis/html/components/components.factor index eec7508c5e..be197d10e6 100644 --- a/basis/html/components/components.factor +++ b/basis/html/components/components.factor @@ -6,7 +6,7 @@ hashtables combinators continuations math strings inspector fry locals calendar calendar.format xml.entities xml.data validators urls present xml.writer xml.literals xml xmode.code2html lcs.diff2html farkup io.streams.string -html.elements html.streams html.forms ; +html html.streams html.forms ; IN: html.components GENERIC: render* ( value name renderer -- xml ) diff --git a/basis/html/elements/elements-docs.factor b/basis/html/elements/elements-docs.factor index dab9376413..05b202e08e 100644 --- a/basis/html/elements/elements-docs.factor +++ b/basis/html/elements/elements-docs.factor @@ -1,5 +1,5 @@ +USING: help.markup help.syntax io present html ; IN: html.elements -USING: help.markup help.syntax io present ; ARTICLE: "html.elements" "HTML elements" "The " { $vocab-link "html.elements" } " vocabulary provides words for writing HTML tags to the " { $link output-stream } " with a familiar look and feel in the code." diff --git a/basis/html/elements/elements.factor b/basis/html/elements/elements.factor index 005d67f221..b0e46984d7 100644 --- a/basis/html/elements/elements.factor +++ b/basis/html/elements/elements.factor @@ -3,18 +3,9 @@ USING: io io.styles kernel namespaces prettyprint quotations sequences strings words xml.entities compiler.units effects xml.data xml.literals urls math math.parser combinators -present fry io.streams.string xml.writer ; - +present fry io.streams.string xml.writer html ; IN: html.elements -SYMBOL: html - -: write-html ( str -- ) - H{ { html t } } format ; - -: print-html ( str -- ) - write-html "\n" write-html ; - << : elements-vocab ( -- vocab-name ) "html.elements" ; @@ -127,24 +118,3 @@ SYMBOL: html ] [ define-attribute-word ] each >> - -: xhtml-preamble ( -- ) - "" write-html - "" write-html ; - -: simple-page ( title head-quot body-quot -- ) - [ with-string-writer ] bi@ - - - - - <-> - <-> - - <-> - - XML> write-xml ; inline - -: render-error ( message -- ) - [XML <-> XML] write-xml ; diff --git a/basis/html/forms/forms.factor b/basis/html/forms/forms.factor index f92f8d0764..0a69e2ed70 100644 --- a/basis/html/forms/forms.factor +++ b/basis/html/forms/forms.factor @@ -1,8 +1,8 @@ ! Copyright (C) 2008 Slava Pestov ! See http://factorcode.org/license.txt for BSD license. USING: kernel accessors strings namespaces assocs hashtables io -mirrors math fry sequences words continuations html.elements -xml.entities ; +mirrors math fry sequences words continuations +xml.entities xml.writer xml.literals ; IN: html.forms TUPLE: form errors values validation-failed ; @@ -109,7 +109,6 @@ C: validation-error : render-validation-errors ( -- ) form get errors>> [ -
    - [
  • escape-string write
  • ] each -
+ [ [XML
  • <->
  • XML] ] map + [XML
      <->
    XML] write-xml ] unless-empty ; diff --git a/basis/html/html.factor b/basis/html/html.factor new file mode 100644 index 0000000000..5469941972 --- /dev/null +++ b/basis/html/html.factor @@ -0,0 +1,34 @@ +! Copyright (C) 2004, 2009 Chris Double, Daniel Ehrenberg. +! See http://factorcode.org/license.txt for BSD license. +USING: io kernel xml.data xml.writer io.streams.string +xml.literals io.styles ; +IN: html + +SYMBOL: html + +: write-html ( str -- ) + H{ { html t } } format ; + +: print-html ( str -- ) + write-html "\n" write-html ; + +: xhtml-preamble ( -- ) + "" write-html + "" write-html ; + +: simple-page ( title head-quot body-quot -- ) + [ with-string-writer ] bi@ + + + + + <-> + <-> + + <-> + + XML> write-xml ; inline + +: render-error ( message -- ) + [XML <-> XML] write-xml ; diff --git a/basis/html/streams/streams.factor b/basis/html/streams/streams.factor index 43fa8bda85..51eb37b83d 100644 --- a/basis/html/streams/streams.factor +++ b/basis/html/streams/streams.factor @@ -4,7 +4,7 @@ USING: combinators generic assocs io io.styles io.files continuations io.streams.string kernel math math.order math.parser namespaces make quotations assocs sequences strings words html.elements xml.entities sbufs continuations destructors -accessors arrays urls.encoding ; +accessors arrays urls.encoding html ; IN: html.streams GENERIC: browser-link-href ( presented -- href ) diff --git a/basis/html/templates/chloe/chloe.factor b/basis/html/templates/chloe/chloe.factor index c3c1ec2b9e..e5b40fcfaa 100644 --- a/basis/html/templates/chloe/chloe.factor +++ b/basis/html/templates/chloe/chloe.factor @@ -5,8 +5,9 @@ namespaces make classes.tuple assocs splitting words arrays io io.files io.files.info io.encodings.utf8 io.streams.string unicode.case mirrors math urls present multiline quotations xml logging continuations -xml.data +xml.data xml.writer xml.literals strings html.forms +html html.elements html.components html.templates @@ -15,7 +16,6 @@ html.templates.chloe.components html.templates.chloe.syntax ; IN: html.templates.chloe -! Chloe is Ed's favorite web designer TUPLE: chloe path ; C: chloe diff --git a/basis/html/templates/chloe/compiler/compiler.factor b/basis/html/templates/chloe/compiler/compiler.factor index 4034b67d45..7180e8cdbc 100644 --- a/basis/html/templates/chloe/compiler/compiler.factor +++ b/basis/html/templates/chloe/compiler/compiler.factor @@ -73,8 +73,8 @@ DEFER: compile-element [ compile-start-tag ] [ compile-children ] [ compile-end-tag ] - [ drop tag-stack get pop* ] - } cleave ; + } cleave + tag-stack get pop* ; ERROR: unknown-chloe-tag tag ; @@ -116,7 +116,7 @@ ERROR: unknown-chloe-tag tag ; [ [ compile-children ] compile-quot ] [ % ] bi* ; inline : compile-children>string ( tag -- ) - [ with-string-writer ] process-children ; + [ with-string-writer ] process-children ; : compile-with-scope ( quot -- ) compile-quot [ with-scope ] [code] ; inline diff --git a/basis/html/templates/chloe/components/components.factor b/basis/html/templates/chloe/components/components.factor index 3041120d43..19f2019266 100644 --- a/basis/html/templates/chloe/components/components.factor +++ b/basis/html/templates/chloe/components/components.factor @@ -21,7 +21,8 @@ M: singleton-class component-tag ( tag class -- ) bi ; M: tuple-class component-tag ( tag class -- ) - [ drop "name" required-attr compile-attr ] [ compile-component-attrs ] 2bi + [ drop "name" required-attr compile-attr ] + [ compile-component-attrs ] 2bi [ render ] [code] ; : COMPONENT: diff --git a/basis/html/templates/chloe/syntax/syntax.factor b/basis/html/templates/chloe/syntax/syntax.factor index fb457ff1df..c2ecd4506b 100644 --- a/basis/html/templates/chloe/syntax/syntax.factor +++ b/basis/html/templates/chloe/syntax/syntax.factor @@ -6,7 +6,6 @@ classes.tuple assocs splitting words arrays memoize parser lexer io io.files io.encodings.utf8 io.streams.string unicode.case mirrors fry math urls multiline xml xml.data xml.writer xml.utilities -html.elements html.components html.templates ; diff --git a/basis/html/templates/fhtml/fhtml.factor b/basis/html/templates/fhtml/fhtml.factor index 992b660070..23bb469627 100644 --- a/basis/html/templates/fhtml/fhtml.factor +++ b/basis/html/templates/fhtml/fhtml.factor @@ -5,7 +5,7 @@ USING: continuations sequences kernel namespaces debugger combinators math quotations generic strings splitting accessors assocs fry vocabs.parser parser lexer io io.files io.streams.string io.encodings.utf8 -html.elements +html html.templates ; IN: html.templates.fhtml diff --git a/basis/html/templates/templates.factor b/basis/html/templates/templates.factor index 57418a3e02..6951f09efe 100644 --- a/basis/html/templates/templates.factor +++ b/basis/html/templates/templates.factor @@ -2,8 +2,8 @@ ! See http://factorcode.org/license.txt for BSD license. USING: accessors kernel fry io io.encodings.utf8 io.files debugger prettyprint continuations namespaces boxes sequences -arrays strings html.elements io.streams.string -quotations xml.data xml.writer ; +arrays strings html io.streams.string +quotations xml.data xml.writer xml.literals ; IN: html.templates MIXIN: template @@ -53,9 +53,13 @@ SYMBOL: atom-feeds : write-atom-feeds ( -- ) atom-feeds get [ - + first2 [XML + + href=<->/> + XML] write-xml ] each ; SYMBOL: nested-template? diff --git a/basis/http/server/responses/responses.factor b/basis/http/server/responses/responses.factor index 4056f0c7f0..c9b4600ac8 100644 --- a/basis/http/server/responses/responses.factor +++ b/basis/http/server/responses/responses.factor @@ -1,6 +1,6 @@ ! Copyright (C) 2008 Slava Pestov. ! See http://factorcode.org/license.txt for BSD license. -USING: html.elements math.parser http accessors kernel +USING: math.parser http accessors kernel xml.literals xml.writer io io.streams.string io.encodings.utf8 ; IN: http.server.responses @@ -13,11 +13,13 @@ IN: http.server.responses swap >>body ; : trivial-response-body ( code message -- ) - - -

    [ number>string write bl ] [ write ] bi*

    - - ; + + +

    <-> <->

    + + + XML> write-xml ; : ( code message -- response ) 2dup [ trivial-response-body ] with-string-writer diff --git a/basis/http/server/server.factor b/basis/http/server/server.factor index a886d7bae7..90a8ddb51a 100755 --- a/basis/http/server/server.factor +++ b/basis/http/server/server.factor @@ -24,7 +24,7 @@ http.parsers http.server.responses http.server.remapping html.templates -html.elements +html html.streams ; IN: http.server @@ -174,8 +174,9 @@ main-responder global [ <404> or ] change-at [ add-responder-nesting ] [ call-responder* ] 2bi ; : http-error. ( error -- ) - "Internal server error" [ ] [ - [ print-error nl :c ] with-html-writer + ! TODO: get rid of rot + "Internal server error" [ ] rot '[ + [ _ print-error nl :c ] with-html-writer ] simple-page ; : <500> ( error -- response ) diff --git a/basis/http/server/static/static.factor b/basis/http/server/static/static.factor index c910529d73..67ce0237a4 100644 --- a/basis/http/server/static/static.factor +++ b/basis/http/server/static/static.factor @@ -4,9 +4,9 @@ USING: calendar kernel math math.order math.parser namespaces parser sequences strings assocs hashtables debugger mime.types sorting logging calendar.format accessors splitting io io.files io.files.info io.directories io.pathnames io.encodings.binary -fry xml.entities destructors urls html.elements +fry xml.entities destructors urls html xml.literals html.templates.fhtml http http.server http.server.responses -http.server.redirection ; +http.server.redirection xml.writer ; IN: http.server.static TUPLE: file-responder root hook special allow-listings ; @@ -56,18 +56,14 @@ TUPLE: file-responder root hook special allow-listings ; \ serve-file NOTICE add-input-logging -: file. ( name -- ) +: file. ( name -- xml ) dup link-info directory? [ "/" append ] when - dup
    escape-string write ; + dup [XML
  • ><->
  • XML] ; : directory. ( path -- ) dup file-name [ ] [ - [

    file-name escape-string write

    ] - [ - - ] bi + [ file-name ] [ directory-files [ file. ] map ] bi + [XML

    <->

    XML] write-xml ] simple-page ; : list-directory ( directory -- response ) diff --git a/basis/math/blas/cblas/cblas.factor b/basis/math/blas/cblas/cblas.factor index f14c6cfd43..2a2e9e3a72 100644 --- a/basis/math/blas/cblas/cblas.factor +++ b/basis/math/blas/cblas/cblas.factor @@ -1,20 +1,24 @@ USING: alien alien.c-types alien.syntax kernel system -combinators combinators.short-circuit ; +combinators ; IN: math.blas.cblas << : load-atlas ( -- ) "atlas" "libatlas.so" "cdecl" add-library ; +: load-fortran ( -- ) + "I77" "libI77.so" "cdecl" add-library + "F77" "libF77.so" "cdecl" add-library ; : load-blas ( -- ) "blas" "libblas.so" "cdecl" add-library ; "cblas" { { [ os macosx? ] [ "libblas.dylib" "cdecl" add-library ] } { [ os windows? ] [ "blas.dll" "cdecl" add-library ] } - { - [ os { [ openbsd? ] [ netbsd? ] } 1|| ] - [ "libcblas.so" "cdecl" add-library load-blas ] - } + { [ os openbsd? ] [ "libcblas.so" "cdecl" add-library load-blas ] } + { [ os netbsd? ] [ + load-fortran load-blas + "/usr/local/lib/libcblas.so" "cdecl" add-library + ] } { [ os freebsd? ] [ "libcblas.so" "cdecl" add-library load-atlas ] } [ "libblas.so" "cdecl" add-library ] } cond diff --git a/basis/unix/stat/netbsd/netbsd.factor b/basis/unix/stat/netbsd/netbsd.factor index 6fccd570e3..0bcb886417 100644 --- a/basis/unix/stat/netbsd/netbsd.factor +++ b/basis/unix/stat/netbsd/netbsd.factor @@ -5,3 +5,34 @@ cell-bits { { 32 [ "unix.stat.netbsd.32" require ] } { 64 [ "unix.stat.netbsd.64" require ] } } case + +: _VFS_NAMELEN 32 ; inline +: _VFS_MNAMELEN 1024 ; inline + +C-STRUCT: statvfs + { "ulong" "f_flag" } + { "ulong" "f_bsize" } + { "ulong" "f_frsize" } + { "ulong" "f_iosize" } + { "fsblkcnt_t" "f_blocks" } + { "fsblkcnt_t" "f_bfree" } + { "fsblkcnt_t" "f_bavail" } + { "fsblkcnt_t" "f_bresvd" } + { "fsfilcnt_t" "f_files" } + { "fsfilcnt_t" "f_ffree" } + { "fsfilcnt_t" "f_favail" } + { "fsfilcnt_t" "f_fresvd" } + { "uint64_t" "f_syncreads" } + { "uint64_t" "f_syncwrites" } + { "uint64_t" "f_asyncreads" } + { "uint64_t" "f_asyncwrites" } + { "fsid_t" "f_fsidx" } + { "ulong" "f_fsid" } + { "ulong" "f_namemax" } + { "uid_t" "f_owner" } + { { "uint32_t" 4 } "f_spare" } + { { "char" _VFS_NAMELEN } "f_fstypename" } + { { "char" _VFS_NAMELEN } "f_mntonname" } + { { "char" _VFS_NAMELEN } "f_mntfromname" } ; + +FUNCTION: int statvfs ( char* path, statvfs* buf ) ; diff --git a/basis/xmode/code2html/code2html.factor b/basis/xmode/code2html/code2html.factor index 22ffc04824..2f35cd6d76 100644 --- a/basis/xmode/code2html/code2html.factor +++ b/basis/xmode/code2html/code2html.factor @@ -1,5 +1,5 @@ USING: xmode.tokens xmode.marker xmode.catalog kernel locals -html.elements io io.files sequences words io.encodings.utf8 +io io.files sequences words io.encodings.utf8 namespaces xml.entities accessors xml.literals locals xml.writer ; IN: xmode.code2html @@ -15,7 +15,8 @@ IN: xmode.code2html tokenize-line htmlize-tokens ; : htmlize-lines ( lines mode -- xml ) - [ f ] 2dip load-mode [ htmlize-line "\n" suffix ] curry map nip ; + [ f ] 2dip load-mode [ htmlize-line ] curry map nip + { "\n" } join ; : default-stylesheet ( -- xml ) "resource:basis/xmode/code2html/stylesheet.css" diff --git a/basis/xmode/marker/marker.factor b/basis/xmode/marker/marker.factor index 4fdde60976..cff0af2a98 100755 --- a/basis/xmode/marker/marker.factor +++ b/basis/xmode/marker/marker.factor @@ -157,7 +157,7 @@ M: seq-rule handle-rule-start mark-token add-remaining-token tuck body-token>> next-token, - get-delegate [ push-context ] when* ; + delegate>> [ push-context ] when* ; UNION: abstract-span-rule span-rule eol-span-rule ; @@ -168,7 +168,7 @@ M: abstract-span-rule handle-rule-start tuck rule-match-token* next-token, ! ... end subst ... dup context get (>>in-rule) - get-delegate push-context ; + delegate>> push-context ; M: span-rule handle-rule-end 2drop ; diff --git a/core/strings/strings-docs.factor b/core/strings/strings-docs.factor index 3a519e143b..d40cd982d8 100644 --- a/core/strings/strings-docs.factor +++ b/core/strings/strings-docs.factor @@ -4,7 +4,7 @@ sbufs math ; IN: strings ARTICLE: "strings" "Strings" -"A string is a fixed-size mutable sequence of Unicode 5.0 code points." +"A string is a fixed-size mutable sequence of Unicode 5.1 code points." $nl "Characters are not a first-class type; they are simply represented as integers between 0 and 16777216 (2^24). Only characters up to 2097152 (2^21) have a defined meaning in Unicode." $nl diff --git a/extra/lint/lint.factor b/extra/lint/lint.factor index 998f2d42d7..60e3332ee4 100755 --- a/extra/lint/lint.factor +++ b/extra/lint/lint.factor @@ -1,7 +1,7 @@ ! Copyright (C) 2007, 2008 Doug Coleman. ! See http://factorcode.org/license.txt for BSD license. USING: accessors alien alien.accessors arrays assocs -combinators.short-circuit fry hashtables html.elements io +combinators.short-circuit fry hashtables html io kernel math namespaces prettyprint quotations sequences sequences.deep sets slots.private vectors vocabs words kernel.private ; diff --git a/extra/websites/concatenative/concatenative.factor b/extra/websites/concatenative/concatenative.factor index 302967969f..c1d62c6cda 100644 --- a/extra/websites/concatenative/concatenative.factor +++ b/extra/websites/concatenative/concatenative.factor @@ -55,8 +55,6 @@ TUPLE: factor-website < dispatcher ; : ( -- responder ) factor-website new-dispatcher - "wiki" add-responder - "user-admin" add-responder URL" /wiki/view/Front Page" "" add-responder ; SYMBOL: key-password @@ -76,8 +74,10 @@ SYMBOL: dh-file "password" key-password set-global common-configuration - "pastebin" add-responder - "planet" add-responder + "wiki" add-responder + "user-admin" add-responder + "pastebin" add-responder + "planet" add-responder "/tmp/docs/" "docs" add-responder test-db main-responder set-global ; @@ -90,7 +90,7 @@ SYMBOL: dh-file : init-production ( -- ) common-configuration - test-db "concatenative.org" add-responder + "wiki" add-responder test-db "concatenative.org" add-responder test-db "paste.factorcode.org" add-responder test-db "planet.factorcode.org" add-responder home "docs" append-path test-db "docs.factorcode.org" add-responder