From 2b35edb595aa35e87dfaf6c2626646095adbb8ce Mon Sep 17 00:00:00 2001 From: Doug Coleman Date: Wed, 20 Jun 2012 22:33:47 -0700 Subject: [PATCH] issue #358: Make a word lookup-article so that article is just a tuple. --- basis/help/definitions/definitions.factor | 4 ++-- basis/help/help-docs.factor | 2 +- basis/help/lint/lint.factor | 2 +- basis/help/topics/topics-docs.factor | 2 +- basis/help/topics/topics.factor | 6 +++--- extra/fuel/fuel.factor | 2 +- extra/fuel/xref/xref.factor | 2 +- 7 files changed, 10 insertions(+), 10 deletions(-) diff --git a/basis/help/definitions/definitions.factor b/basis/help/definitions/definitions.factor index 076fa59352..f8162d6235 100644 --- a/basis/help/definitions/definitions.factor +++ b/basis/help/definitions/definitions.factor @@ -9,9 +9,9 @@ IN: help.definitions M: link definer drop \ ARTICLE: \ ; ; -M: link where name>> article loc>> ; +M: link where name>> lookup-article loc>> ; -M: link set-where name>> article loc<< ; +M: link set-where name>> lookup-article loc<< ; M: link forget* name>> remove-article ; diff --git a/basis/help/help-docs.factor b/basis/help/help-docs.factor index bce44ca8e8..bc1cbd7f64 100644 --- a/basis/help/help-docs.factor +++ b/basis/help/help-docs.factor @@ -131,7 +131,7 @@ ARTICLE: "help-impl" "Help system implementation" } "Help article implementation:" { $subsections - article + lookup-article articles } "Links:" diff --git a/basis/help/lint/lint.factor b/basis/help/lint/lint.factor index 2172500ebe..73decf2d74 100644 --- a/basis/help/lint/lint.factor +++ b/basis/help/lint/lint.factor @@ -68,7 +68,7 @@ PRIVATE> : check-about ( vocab -- ) vocab-link boa dup - '[ _ vocab-help [ article drop ] when* ] check-something ; + '[ _ vocab-help [ lookup-article drop ] when* ] check-something ; : check-vocab ( vocab -- ) "Checking " write dup write "..." print flush diff --git a/basis/help/topics/topics-docs.factor b/basis/help/topics/topics-docs.factor index 720991a609..82cf78e70d 100644 --- a/basis/help/topics/topics-docs.factor +++ b/basis/help/topics/topics-docs.factor @@ -10,7 +10,7 @@ HELP: no-article { $description "Throws a " { $link no-article } " error." } { $error-description "Thrown by " { $link help } " if the given help topic does not exist, or if the help topic being displayed links to a help topic which does not exist." } ; -HELP: article +HELP: lookup-article { $values { "name" "an article name" } { "article" "an " { $link article } " object" } } { $description "Outputs a named " { $link article } " object." } ; diff --git a/basis/help/topics/topics.factor b/basis/help/topics/topics.factor index d12138ea3e..fafbf14274 100644 --- a/basis/help/topics/topics.factor +++ b/basis/help/topics/topics.factor @@ -61,12 +61,12 @@ ERROR: no-article name ; M: no-article summary drop "Help article does not exist" ; -: article ( name -- article ) +: lookup-article ( name -- article ) articles get ?at [ no-article ] unless ; M: object valid-article? articles get key? ; -M: object article-title article article-title ; -M: object article-content article article-content ; +M: object article-title lookup-article article-title ; +M: object article-content lookup-article article-content ; M: object article-parent article-xref get at ; M: object set-article-parent article-xref get set-at ; diff --git a/extra/fuel/fuel.factor b/extra/fuel/fuel.factor index 7673b96a69..b60f837707 100644 --- a/extra/fuel/fuel.factor +++ b/extra/fuel/fuel.factor @@ -107,7 +107,7 @@ PRIVATE> ! Help support -: fuel-get-article ( name -- ) article fuel-eval-set-result ; +: fuel-get-article ( name -- ) lookup-article fuel-eval-set-result ; : fuel-get-article-title ( name -- ) articles get at [ article-title ] [ f ] if* fuel-eval-set-result ; diff --git a/extra/fuel/xref/xref.factor b/extra/fuel/xref/xref.factor index 649081ff03..eeec3b260c 100644 --- a/extra/fuel/xref/xref.factor +++ b/extra/fuel/xref/xref.factor @@ -62,7 +62,7 @@ PRIVATE> : doc-location ( word -- loc ) props>> "help-loc" swap at get-loc ; -: article-location ( name -- loc ) article loc>> get-loc ; +: article-location ( name -- loc ) lookup-article loc>> get-loc ; : get-vocabs ( -- seq ) all-vocab-names ;