Commit Graph

228 Commits (875357c1bf16981fb85e7bfadeac74de09dd1b51)

Author SHA1 Message Date
Doug Coleman 671f19d70f Remove all non-core uses of (scan-token)
Add scan-datum
Add scan-number
Document more words
Fixes #225.
2011-10-02 12:00:08 -07:00
Doug Coleman 76580da5d5 Refactor the lexer/parser to expose friendlier words for scanning tokens. The preferred top-level words now throw an exception on EOF.
CREATE -> scan-new
CREATE-CLASS -> scan-new-class
CREATE-WORD -> scan-new-word
CREATE-GENERIC -> scan-new-generic
scan -> (scan-token)
scan-token now throws on eof
(scan-word) returns word/number/f
scan-word now throws on eof
scan-word-name expects a non-number
Fixes #183.
Fixes #209.
2011-09-29 11:28:28 -07:00
Joe Groff d711824c10 command-line, parser, syntax: move the MAIN: invocation from run-file to run-script to minimize the potential impact on internal machinery that uses run-file 2011-08-17 21:29:02 -07:00
Joe Groff e1390875ca parser, source-files, syntax: have MAIN: store the main entry point in the source-file record in addition to the vocabulary. Have run-file execute the MAIN: word for a file if present after evaluating its contents. 2011-08-17 20:58:09 -07:00
Keita Haga 65de18993b syntax: add stack effect declaration to <color> word definition in usage example of C: syntax 2011-02-07 23:00:30 +09:00
Keita Haga 16d524802a syntax: trim trailing whitespace to $syntax section in the HOOK:'s help page 2011-02-04 15:56:02 +09:00
Keita Haga dcb387630b sequences, syntax, vocabs.parser: remove useless whitespace in docs 2010-12-23 03:42:41 +09:00
Keita Haga 34a9b93458 syntax: slightly to fix examples of QUALIFIED: and QUALIFIED-WITH: 2010-12-19 01:16:54 +09:00
Slava Pestov 8a0525e5ce Add a scan-token word which is like scan, except throws an error on EOF; document scan-object word; mention that scan-token/scan-object are preferred over scan/scan-word 2010-07-06 16:20:08 -04:00
Joe Groff 65e220b645 syntax: correct documentation for ratio syntax 2010-05-18 18:59:54 -07:00
Slava Pestov 627295f094 Language change: tuple slot setter words with stack effect ( value object -- ) are now named FOO<< instead of (>>FOO) 2010-05-06 17:21:02 -04:00
Joe Groff c3f8f5067e catch merge conflicts in source and report them as such 2010-04-06 13:34:26 -07:00
Slava Pestov a566d8cc6b lexer: each-token and map-tokens did not handle EOF properly 2010-03-26 03:42:07 -04:00
Daniel Ehrenberg 7364608417 Merge branch 'master' of git://factorcode.org/git/factor into bags 2010-03-02 17:04:45 -05:00
Joe Groff 9bf5c76771 lexer: add "each-token" and "map-tokens", which are equivalent to "parse-token _ each/map" but incremental. update a smattering of parsing words (such as USING:, SYMBOLS:, etc.) to use each-token/map-tokens 2010-02-28 22:19:43 -08:00
Daniel Ehrenberg 7ad324837b Updated documentation for sets 2010-02-27 00:27:40 -05:00
Daniel Ehrenberg e43312d780 Moving new-sets and hash-sets to core 2010-02-26 11:01:57 -05:00
Slava Pestov c5259f2e2c classes.tuple: document final class declaration 2010-02-18 04:13:34 +13:00
Slava Pestov 01824d41be Add support for final tuple classes which cannot be subclassed: TUPLE: foo ... ; final 2010-02-18 02:19:57 +13:00
Joe Groff a8e771c28f update syntax-floats for changes to math.parser. clarify docs on hex float literals 2010-02-08 10:42:04 -08:00
Slava Pestov fbf078d4b3 words: undefined error now contains the word in question 2010-02-03 23:11:23 +13:00
Slava Pestov e32d5fd0ac Minor updates to string documentation 2010-02-03 23:07:53 +13:00
Brad Christensen 9b9322ea1e A number of documentation fixes and cleanup. 2010-02-03 00:05:03 -07:00
Joe Groff 2f90b13160 touch up quotation documentation 2009-10-31 16:40:10 -05:00
Doug Coleman 7ce4b746e5 parsed -> suffix!, add append! 2009-10-28 13:38:27 -05:00
Slava Pestov 4ed91ff5ee syntax: fix docs for : 2009-10-16 23:45:10 -05:00
Doug Coleman 4cec00f209 improve io.pathnames docs 2009-10-16 05:48:37 -05:00
Keith Lazuka 405e5d015b docs: change $subsection to $subsections 2009-10-02 12:15:48 -04:00
Slava Pestov 1788957e1d syntax: fix typos in " docs 2009-09-23 17:50:00 -05:00
Doug Coleman 545f7f11bb document """ 2009-09-23 10:33:40 -05:00
Doug Coleman 5cb34724b7 Merge branch 'master' of git://factorcode.org/git/factor
Conflicts:
	basis/classes/struct/struct-tests.factor
	basis/functors/functors-tests.factor
	basis/specialized-arrays/specialized-arrays-tests.factor
2009-09-20 23:02:49 -05:00
Doug Coleman dc4a544a92 add multiline string support 2009-09-19 01:55:05 -07:00
Joe Groff 238f600da2 document number-base prettyprinter variable. add more docs about hex float syntax 2009-09-18 15:11:01 -05:00
Slava Pestov aad68418d2 math, syntax: document hexadecimal float literal syntax 2009-09-12 21:18:17 -05:00
Slava Pestov 018677319c math, syntax: fix help lint 2009-09-12 21:07:31 -04:00
Slava Pestov 3c55e7fe0c Add NAN: literal syntax for NANs with a payload 2009-09-12 15:06:15 -05:00
Slava Pestov d9ebfe5f48 syntax: improve T{ docs 2009-09-10 15:53:14 -05:00
Slava Pestov ab45402d04 Minor doc improvements 2009-08-31 05:46:57 -05:00
Joe Groff cb54ca6402 clarify 'deprecated' docs 2009-08-20 18:36:34 -05:00
Joe Groff 6089251574 move deprecation to tools.deprecation; load with bootstrap.tools 2009-08-20 16:17:36 -05:00
Joe Groff 400c89daf0 "deprecated" declaration, "deprecation" vocab to track deprecations in the error log 2009-08-20 15:10:42 -05:00
Slava Pestov bf54aebcc1 Fix QUALIFIED: docs. Reported by ex_rzr in #concatenative 2009-07-14 12:07:08 -05:00
Slava Pestov 29327a787c Remove initial-quot feature 2009-06-15 13:07:15 -05:00
Doug Coleman 059eb399f0 add initial-quot: syntax for tuples 2009-06-11 19:48:14 -05:00
Slava Pestov a0eb60906d Fix even more usings 2009-05-16 10:45:17 -05:00
Slava Pestov 66a9416473 Update documentation for stricter vocabulary search path semantics 2009-05-16 00:29:21 -05:00
Slava Pestov b31fe9b8f2 Implement stricter vocab search path semantics, with a new API for vocabs.parser. Add map-find-last to sequences vocab 2009-05-14 22:31:29 -05:00
Slava Pestov 0c1e519dcb Rename use+ to add-use, move search to vocabs.parser, EXCLUDE: bombs out if word doesn't exist 2009-05-13 22:15:48 -05:00
Slava Pestov b4088373b7 Merge branch 'master' of git://factorcode.org/git/factor 2009-05-04 05:16:47 -05:00
Slava Pestov a63ad6a7a5 Remove cruddy string encoding/decoding code from VM 2009-05-02 13:45:38 -05:00
Doug Coleman 0ad6d1fb7b add a few usages of iota, remove most 1+ and 1- from core 2009-05-01 19:58:24 -05:00
Slava Pestov 3dc9fdf9db Fleshed out new dispatch code 2009-04-24 20:43:01 -05:00
Slava Pestov c2fe2a4fea Improve stack checker documentation 2009-04-23 03:48:32 -05:00
Slava Pestov 8432c30ed1 Fix docs 2009-04-22 21:20:36 -05:00
Slava Pestov bcd0533794 Improve example in syntax vocab 2009-04-20 01:42:54 -05:00
Alex Chapman c2a35ecf33 Fix an example in syntax docs 2009-04-17 19:07:45 +10:00
Slava Pestov 1c68b389cc Document special float values 2009-04-14 15:05:10 -05:00
Slava Pestov 3752c706da Add M\ syntax for method literals 2009-04-06 02:57:39 -05:00
Slava Pestov 5a903d7bcd Fix a bug in CONSTANT: -- it wasn't calling reset-word 2009-03-29 22:46:27 -05:00
Slava Pestov 4e260ff000 Fix syntax docs 2009-03-28 04:25:07 -05:00
Slava Pestov b51ed8559e Update GENERIC# docs now that stack effect is mandatory 2009-03-26 21:26:06 -05:00
Slava Pestov 8385e9d9f5 Fixing compile errors, test failures and help lint failures 2009-03-23 17:12:41 -05:00
Slava Pestov 4fc2182ac8 define-generic and define-simple-generic now take stack effect parameters; math-combination is a singleton instead of a tuple 2009-03-22 18:00:26 -05:00
Slava Pestov c0154c1391 Change (:) to parse effect immediately, and remove ( parsing word 2009-03-21 03:17:35 -05:00
Slava Pestov ea60f8ae93 Changing : foo ; parsing to SYNTAX: foo ; 2009-03-21 01:27:50 -05:00
Slava Pestov 786475102d Make more code infer 2009-03-17 02:19:50 -05:00
Slava Pestov be4fb1e7d9 Move call( and execute( to core 2009-03-16 20:11:36 -05:00
Slava Pestov bfb6b4642a Consultations now implement the definition protocol; removing one from a source file forgets consulted methods 2009-03-07 00:42:43 -06:00
Slava Pestov e4a0396550 Add parse-quotation hook to parser which locals overrides. '[ and [ use this hook. Fixes locals bug reported by erg 2009-03-06 19:48:04 -06:00
Slava Pestov 846687fde8 Fix documentation 2009-03-05 13:40:19 -06:00
Slava Pestov 664e9b75de Improve " docs 2009-02-17 14:26:25 -06:00
Nicholas Seckar 25d20c6000 Update docs for GENERIC: GENERIC# and HOOK to show stack effect decl 2009-02-08 23:45:59 -08:00
Slava Pestov 4de41f94e9 Fixing wrappers with locals 2009-01-28 17:07:31 -06:00
Slava Pestov 9b57ff6540 Fix typo in GENERIC# docs 2009-01-28 12:16:00 -06:00
Slava Pestov 298fdecf32 Fixing eval unit test, and help lint failures from stricter help lint 2009-01-27 15:38:01 -06:00
Slava Pestov a9ef525aed Help lint fixes for stricter help lint 2009-01-27 04:12:37 -06:00
Slava Pestov 56260087ae Merge branch 'master' of git://factorcode.org/git/factor 2009-01-26 23:20:45 -06:00
Slava Pestov 92f9338978 Smart quotes 2009-01-26 23:20:27 -06:00
Joe Groff 3a38cb5a8c Typo in INSTANCE: doc 2008-12-18 14:02:35 -08:00
Slava Pestov 5fdb474c76 Fixing various test failures and updating some more vocabs for >r/r> removal 2008-12-17 22:29:32 -06:00
Slava Pestov c5160d76e9 Merge qualified, alias, symbols, constants into core 2008-12-17 18:10:01 -06:00
Slava Pestov 425c70caa9 Remove empty tags file 2008-12-16 02:03:35 -06:00
Slava Pestov daf2857d7b define-inline now takes an effect parameter
C: now sets the stack effect of the new word to slot names
add new basis/constants vocab; CONSTANT: foo bar is equivalent to : foo bar ; inline
(going to fold CONSTANT:, ALIAS: and qualified into core soon perhaps)
tighten the screws: inline words now need a stack declaration too
update some usages of inline words
2008-12-15 19:44:56 -06:00
Slava Pestov 5cb18d51b3 Fixing test-all and help-lint-all failures 2008-12-15 03:33:04 -06:00
Slava Pestov 50e214c152 io.files split up and general refactoring work in progress 2008-12-14 20:03:00 -06:00
Slava Pestov 4f0a9f311e Untangling some dependencies 2008-12-08 14:58:00 -06:00
Slava Pestov e8a69a3aea Fix conflict 2008-11-29 05:14:49 -06:00
Slava Pestov a4d9cdfeb3 Refactor all usages of >r/r> in core to use dip, 2dip, 3dip
Non-optimizing compiler now special-cases dip, 2dip, 3dip following a
literal quotation: this allows us to break the dip/slip meta-circle
without explicit calls to >r/r>
2008-11-23 02:44:56 -06:00
Slava Pestov 51787c2022 Add some error checking to CHAR: 2008-11-23 00:25:01 -06:00
Slava Pestov 3e7afcac29 (call-next-method) now takes a method instead of a class and a generic 2008-11-22 19:57:25 -06:00
Slava Pestov 2fe364a7bb Specialized arrays work in progress 2008-11-14 20:18:16 -06:00
Slava Pestov c19f2257f4 Fix permission bits 2008-10-02 08:34:49 -05:00
Slava Pestov e84dec38ef Doc fixes 2008-09-29 22:39:53 -05:00
Slava Pestov f91b8ead3b Fix typo 2008-09-25 05:35:48 -05:00
Doug Coleman 4be6611a81 oops, revert B change 2008-09-17 08:03:40 -05:00
Doug Coleman 165e5b7ff8 document B 2008-09-17 00:52:50 -05:00
Slava Pestov 18cc66f64e Update docs 2008-09-05 20:50:07 -05:00
Slava Pestov 57ca685e26 New tuple syntax 2008-09-05 20:39:45 -05:00
Slava Pestov e1716d92b3 Remove delegation slot 2008-09-03 03:46:56 -05:00
Doug Coleman 99f442c2c7 fix docs 2008-09-02 15:19:32 -05:00