Slava Pestov
d0dc6ba8af
slots, classes.tuple: make 'integer'-declared slots call >integer on the new value before storing it in, and remove code duplication between type checks in writer methods and boa constructors
2010-01-16 19:29:19 +13:00
Slava Pestov
0612bc6177
Factor source files should not be executable
2009-11-21 17:50:43 -06:00
Slava Pestov
e30d275e41
compiler.cfg: 'basic-block new hashcode' should not throw an exception; fixes tools.deploy.test.11
2009-11-16 02:01:36 -06:00
Slava Pestov
c693587018
classes.algebra: cleanup
2009-11-10 17:41:47 -06:00
Doug Coleman
1d12a6707d
sigma -> map-sum
2009-10-29 14:34:04 -05:00
Doug Coleman
bd13e018dd
memq? -> member-eq?, sorted-memq? -> sorted-member-eq?
2009-10-28 15:02:00 -05:00
Doug Coleman
50d4eb27bf
add missing usings
2009-10-10 14:04:22 -05:00
Doug Coleman
584cd44856
fix the tuple subclassing example docs
2009-10-10 14:02:35 -05:00
Keith Lazuka
405e5d015b
docs: change $subsection to $subsections
2009-10-02 12:15:48 -04:00
Joe Groff
92e864b019
fix stack effect of ERROR: words that inherit slots from a base class
2009-09-29 12:52:13 -05:00
Joe Groff
748ba4b833
give a better error message when an invalid slot name is used in a tuple/struct literal
2009-09-16 18:07:39 -05:00
Slava Pestov
d5bc1ceca2
classes.struct: fix some bugs
...
- STRUCT: foo<ENTER> in listener threw an error
- S{ did not throw an error when used with non-struct types
- attempting to subclass a struct class now fails
- forgetting a struct class now removes the corresponding C type
- 'see'ing a struct class now indents correctly
2009-09-10 15:59:27 -05:00
Slava Pestov
389f47086a
classes.tuple: don't run out of memory inside 'instances' quotation if optimizing compiler is off
2009-09-02 05:19:20 -05:00
Doug Coleman
26cc551049
fix another tuple definition bug
2009-09-01 11:36:06 -05:00
Doug Coleman
d46d063f5f
inheriting from itself would hang a tuple definition. only breaks if tuple is being redefined
2009-09-01 04:02:44 -05:00
Doug Coleman
f18aef2afb
Merge branch 'master' of git://factorcode.org/git/factor
2009-08-22 21:24:02 -04:00
Joe Groff
c898593983
decouple struct parsing/printing from tuple parsing/printing a bit
2009-08-19 18:53:44 -05:00
Joe Groff
15a7148de0
Merge branch 'master' of git://factorcode.org/git/factor
2009-08-19 15:48:07 -05:00
Doug Coleman
fadede137c
use iota
2009-08-19 08:27:28 -05:00
Doug Coleman
3313098936
use iota
2009-08-19 08:21:45 -05:00
Slava Pestov
030b1b816c
Add inline declarations for various assorted methods
2009-08-17 22:32:21 -05:00
Joe Groff
6fe7fe72c7
Merge branch 'master' of git://factorcode.org/git/factor
2009-08-14 10:55:05 -04:00
Doug Coleman
3f3d57032b
Delete empty unit tests files, remove 1- and 1+, reorder IN: lines in a lot of places, minor refactoring
2009-08-13 19:21:44 -05:00
Joe Groff
ca592b9654
extend T{ } syntax to build structs
2009-08-12 15:40:06 -04:00
Joe Groff
25c3434892
pprint structs with tuple syntax
2009-08-12 13:16:43 -04:00
Brad Christensen
f8405e9c55
A number of documentation fixes.
...
* Short-circuit combinators now show correct stack effect for quots
* Groups and Clumps unchecked examples corrected, made runnable in listener
* Class operations had duplicate link to class-types
* Protocol slots readability fixed
* Tuple word property for "tuple-layout" corrected to "layout"
* cond>quot sentence started in lowercase
* Method precedence code example missing stack effect for GENERIC:, M: integer explain changed to detail an integer
* Motivation for default streams readability
* Default input and output streams duplicate readln link removed from output stream words section
* Looping combinators do description clarified
* Make philosophy missing space
* Linear order protocol duplicate after? link removed
* Parsing words readability fix
* Copied note regarding with-compilation-unit from define to define-declared and define-inline
2009-08-10 23:34:25 -07:00
Slava Pestov
cf826d80b0
classes.tuple: eliminate generic arithmetic from M: tuple = and M: tuple hashcode*
2009-07-18 02:09:56 -05:00
Joe Groff
7a88c5ae8a
variants vocab for ADTs
2009-06-26 16:31:20 -05:00
Slava Pestov
29327a787c
Remove initial-quot feature
2009-06-15 13:07:15 -05:00
Slava Pestov
285c8cecc6
Add some failing unit tests exposing bugs in initial-quot: implementation
2009-06-13 18:34:27 -05:00
Doug Coleman
258abe31ab
add some unit tests for reshaping tuples with initial-quot: slots
2009-06-12 11:58:07 -05:00
Doug Coleman
99bfeb62c4
simplify implementation of initial-quot:
2009-06-12 11:45:53 -05:00
Doug Coleman
21a33419a7
initial-quot: works fully, need to make a couple simplifications
2009-06-12 09:21:51 -05:00
Doug Coleman
4bd06486fb
make a word not generic, remove unit test for unimplemented feature
2009-06-11 20:20:21 -05:00
Doug Coleman
059eb399f0
add initial-quot: syntax for tuples
2009-06-11 19:48:14 -05:00
Slava Pestov
9c239694bf
Update unit tests for parser note and lazy list changes
2009-05-16 13:41:11 -05:00
Slava Pestov
35ccf0231e
Factor out parser note code into parser.notes vocabulary, and print a note if a using list contains duplicates
2009-05-16 09:40:17 -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
bba30dc284
Fix conflict from master
2009-04-27 17:09:09 -05:00
Joe Groff
0d03dea74b
factor out tuple literal slot parsing from the rest of tuple literal parsing
2009-04-26 15:59:26 -05:00
Slava Pestov
7aa65b5b5f
Fixing new method dispatch implementation
2009-04-25 19:41:27 -05:00
Slava Pestov
48e70b65fa
Move cross-referencing stuff to tools.crossref since compiler doesn't depend on it anymore, and compute cross-referencing index as needed; reduces image size by ~4Mb
2009-04-22 04:20:38 -05:00
Slava Pestov
469c9ee21d
Debugging stack checking
2009-04-21 16:09:53 -05:00
Slava Pestov
05f3f9dcb9
Fixing unit tests for stack effect inference changes
2009-04-20 21:15:19 -05:00
Slava Pestov
8414693142
stack-checker: trust word declarations instead of recursively checking them
2009-04-20 18:44:45 -05:00
Doug Coleman
7a1841f59b
(( -- )) eval -> eval( -- )
2009-04-17 15:49:21 -05:00
Doug Coleman
aad6a3d504
fixing compiler error in core
2009-04-17 12:45:57 -05:00
Slava Pestov
a0ba66080d
Documentation updates suggested by dmpk2k
2009-04-10 03:52:53 -05:00
Slava Pestov
890553b776
Fixing tests for method-sec removal
2009-04-06 05:22:28 -05:00
Slava Pestov
7bf0a46d3d
Updating tests for method-spec removal
2009-04-06 04:16:39 -05:00
Slava Pestov
6080c6e734
Fix stack effect redefinition
2009-03-22 20:16:31 -05:00
Slava Pestov
38c6be94d4
Fixing some stack comments
2009-03-16 06:17:18 -05:00
Slava Pestov
bf41b187b0
Re-organize code so that with-compilation-unit can infer
...
Fix with-compilation-unit to work in deployed code
2009-03-13 19:39:32 -05:00
Slava Pestov
667eca9410
Fix unit tests and help lint for 'see' move
2009-03-11 17:33:54 -05:00
Slava Pestov
bf663e830a
Changing a method into a generated slot accessor would result in the generated accessor being forgotten
2009-03-06 20:02:31 -06:00
Slava Pestov
ca7a155b72
Merge branch 'master' into new_ui
2009-03-01 20:13:05 -06:00
Slava Pestov
03cb32ad9c
Make execute( faster, add execute-unsafe( and make effect tuple slots read only
2009-03-01 20:12:35 -06:00
Slava Pestov
b4a61114e1
Merge branch 'master' into new_ui
2009-02-19 13:36:32 -06:00
Slava Pestov
60134eeb98
Documentation fixes
2009-02-19 13:35:53 -06:00
Slava Pestov
421ee726b8
Merge branch 'master' into new_ui
2009-02-16 21:22:12 -06:00
Slava Pestov
6b25e99470
Add summary for heaps more vocabs
2009-02-16 21:05:13 -06:00
Slava Pestov
056e7aa442
Merge branch 'master' into new_ui
2009-02-13 18:12:35 -06:00
Doug Coleman
cdc5aa60b0
add a stack effect to tuple article
2009-02-13 10:48:11 -06:00
Slava Pestov
669548e62e
Clean up some usages of tuck, and add Joe's curried cleave/spread/apply combinators to kernel vocabulary
2009-02-02 13:43:54 -06:00
Doug Coleman
3c408342ef
renaming: contain? -> any?, deep-contains? -> deep-any?, pad-left -> pad-head, pad-right -> pad-tail, trim-left -> trim-head, trim-right -> trim-tail
2009-01-29 22:19:07 -06:00
Slava Pestov
87e0110ff1
O(1) equal? and hashcode* for ranges
2009-01-28 23:33:26 -06:00
Slava Pestov
92f9338978
Smart quotes
2009-01-26 23:20:27 -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
ea4feee886
Fix typo
2008-12-09 15:10:51 -06:00
Slava Pestov
7c1c97470f
tuple-class-unchanged? was bogusly returning f during bootstrap for classes without a superclass
2008-12-08 23:52:46 -06:00
Slava Pestov
a56d480aa6
Various optimizations leading to a 10% speedup on compiling empty EBNF parser:
...
- open-code getenv primitive
- inline tuple predicates in finalization
- faster partial dispatch
- faster built-in type predicates
- faster tuple predicates
- faster lo-tag dispatch
- compile V{ } clone and H{ } clone more efficiently
- add fixnum fast-path to =; avoid indirect branch if two fixnums not eq
- faster >alist on hashtables
2008-12-06 09:16:29 -06:00
Slava Pestov
c49cbe5d9c
Fix typo in the docs
2008-12-03 04:07:36 -06:00
Slava Pestov
52c5b53e27
Refactoring usages of >r, r>, -rot, rot
2008-11-30 22:21:37 -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
3e29a31493
Residual fixes for curry/compose change
2008-11-21 05:17:20 -06:00
Slava Pestov
a95bb533b5
Remove more redundant branches from tuple type predicates and generic words with methods on tuple classes
2008-11-06 09:08:17 -06:00
Slava Pestov
9160e667a7
Fix tuple>array and tuple reshaping
2008-11-06 01:10:56 -06:00
Slava Pestov
cc879fa9b7
Tuple layouts are now arrays, instead of built-in types. The superclass
...
array is now part of the tuple layout object itself, and class hashcodes
are stored alongside class words there. This removes 2 indirections when
reading a superclass, and 3 when reading a superclass hashcode.
2008-11-05 22:20:29 -06:00
Slava Pestov
b4d3473d5e
Tuple parsing didn't handle line breaks properly; if scan returns f, must throw unexpected-eof
2008-11-03 21:01:50 -06:00
Slava Pestov
94fa3929a8
Rice
2008-10-23 05:28:22 -05:00
Slava Pestov
325dbf3eef
Fix regression
2008-10-20 21:07:55 -05:00
Slava Pestov
ab61e5cd8c
Fix performance problem
2008-10-20 05:56:13 -05:00
Slava Pestov
d2dd7288b3
Fix parser bug with multi-line tuple literals
2008-10-08 23:43:37 -05:00
Slava Pestov
c19f2257f4
Fix permission bits
2008-10-02 08:34:49 -05:00
Slava Pestov
78881e1368
Better error message with invalid tuple literals
2008-09-24 21:23:26 -05:00
Slava Pestov
3d790d8ac8
Memory ricing to make deploy tests pass on Mac OS X/PowerPC
2008-09-19 00:26:27 -05:00
Slava Pestov
44f53de164
Move make to its own vocabulary, remove fry _ feature
2008-09-10 20:07:00 -05:00
Doug Coleman
b1d26e100a
use if/when/unless-empty, docs
2008-09-06 17:10:32 -05:00
Slava Pestov
32c2543571
Documentation fixes
2008-09-06 05:12:28 -05:00
Slava Pestov
57ca685e26
New tuple syntax
2008-09-05 20:39:45 -05:00
Slava Pestov
6b07c85fec
Minor fixes here and there for delegation slot removal
2008-09-03 06:05:50 -05:00
Slava Pestov
e1716d92b3
Remove delegation slot
2008-09-03 03:46:56 -05:00
Doug Coleman
1e8358eff5
Merge branch 'master' of git://factorcode.org/git/factor
2008-09-02 02:09:54 -05:00
Slava Pestov
110a5e5162
Change equality semantics
2008-09-02 02:02:05 -05:00
Doug Coleman
bef502adfc
ENABLE NEW ACCESSORS
2008-09-02 01:56:06 -05:00
Slava Pestov
f5fbd94a4c
New compiled crossref implementation
2008-08-31 01:34:00 -05:00
Slava Pestov
3cef7c9992
Smarter usage tracking system
2008-08-30 02:31:27 -05:00
Slava Pestov
85cdb1b767
Working on new compiled usage strategy; old one was wrong
2008-08-30 00:05:27 -05:00
Slava Pestov
74dccc7fbf
Debugging compiler
2008-08-28 22:28:34 -05:00
Slava Pestov
a4ac751605
Starting to remove delegation
2008-08-22 23:20:49 -05:00
Slava Pestov
2440fc1ceb
Fixing remaining issues
2008-08-22 17:38:23 -05:00
Slava Pestov
86f11713e3
Fixing some more bugs
2008-08-22 03:12:15 -05:00
Slava Pestov
95657e5742
Remove some funny retain stack usage
2008-08-18 20:13:24 -05:00
Slava Pestov
8b55b53269
Re-implement reverse to fix obscure problem
2008-08-18 16:40:50 -05:00
Slava Pestov
4cb64aaeb8
Fixing unit tests for eval word being moved
2008-07-29 00:05:01 -05:00
Slava Pestov
d66f887736
Create basis vocab root
2008-07-28 22:03:13 -05:00
Slava Pestov
c6915b1023
Working on tuple slot propagation
2008-07-25 02:07:45 -05:00
Slava Pestov
d0ae6bdb8f
Make array length foldable
2008-07-16 16:48:09 -05:00
Slava Pestov
817035099c
Fix erg's tuple definition bugs
2008-07-13 21:06:50 -05:00
Slava Pestov
966ef323bc
Expand allocations for simpler intrinsics
2008-07-13 03:53:34 -05:00
Slava Pestov
8160859c8b
Fixes
2008-07-12 13:12:45 -05:00
Slava Pestov
7ca3c2a878
Various minor compiler tweaks
2008-07-12 01:08:30 -05:00
Slava Pestov
2f560ffbe0
Fix typo
2008-07-11 17:46:57 -05:00
Slava Pestov
498986fe88
Fix tuple redefinition bug
2008-07-10 02:11:49 -05:00
Slava Pestov
5d9c1ea0a0
Documentation updates, rename unfold to produce
2008-07-10 01:00:27 -05:00
Slava Pestov
78d24d5a5d
Fix unit test failures
2008-07-05 23:08:30 -05:00
Slava Pestov
1c92b20a9a
Fix two bugs
2008-07-05 20:37:28 -05:00
slava
3dcc04675b
Merge branch 'master' of git://factorcode.org/git/factor
2008-07-05 03:07:48 -05:00
slava
8321a41db0
Tweak to reduce image size; don't produce prototypes for tuples with all slots set to f
2008-07-05 03:07:25 -05:00
Slava Pestov
44c1c1f679
Move tuple-class to classes.tuple where it belongs
2008-07-05 00:59:39 -05:00
Slava Pestov
091484de98
Fix ERROR:, erg's mixin bug
2008-07-04 01:32:11 -05:00
Slava Pestov
ef2fddb1ec
Fix conflict
2008-07-03 16:46:21 -05:00
Eduardo Cavazos
c38298f0b5
classes.tuple: use sigma
2008-07-03 13:45:32 -05:00
Slava Pestov
e876349c51
Fix tests
2008-07-03 02:50:45 -05:00
Slava Pestov
72d9c040b4
Improved ERROR:
2008-07-03 02:47:29 -05:00
Slava Pestov
2831cb8d9b
Tweaking docs, change stage2 to load less stuff
2008-07-03 01:39:45 -05:00
Slava Pestov
aeb2b9d701
Fixing unit test failures
2008-07-02 15:57:38 -05:00
Slava Pestov
f7eecc7893
Move bit-arrays and float-arrays to extra
2008-07-02 02:03:30 -05:00
Slava Pestov
537269447c
Move mirrors out of the boot image
2008-07-02 00:20:01 -05:00
Slava Pestov
f8fd065fc5
Initial value for alien slots is a BAD-ALIEN
2008-07-01 16:33:45 -05:00
Slava Pestov
664631aa23
Fixing reshaping to work with type declaration
2008-07-01 16:16:02 -05:00
Slava Pestov
fb8723bce1
Better optimizers for new, boa
2008-06-30 03:10:43 -05:00
Slava Pestov
f7b7001f39
BOA constructors now check types
2008-06-30 01:44:58 -05:00
Slava Pestov
3b41e31584
More tuple declaration work
2008-06-29 21:37:57 -05:00
Slava Pestov
0be00f03e6
Mirrors now check sot t slot types, support type coercion for setters, instance? now infers, better transform for 'new', more efficient 'case' where keys are all wrappers
2008-06-29 02:12:44 -05:00
Slava Pestov
b36e06d0d6
Builtinn types now use new slot accessors; tuple slot type declaration work in progress
2008-06-28 02:36:20 -05:00
Slava Pestov
3f520c3c79
Better error messages for when new or boa are applied to the wrong type
2008-06-26 20:47:36 -05:00
Slava Pestov
6e0d35e615
Split up huge parser vocabulary
2008-06-25 03:25:08 -05:00
Slava Pestov
80720cea0d
More redefinition fixes
2008-06-11 17:40:33 -05:00
Slava Pestov
ba8f1388ab
Fixing everything for mandatory stack effects
2008-06-09 02:14:14 -05:00
Slava Pestov
9dd5c9919f
Mandatory stack effect annotations
2008-06-08 15:32:55 -05:00
Slava Pestov
ec71ee0940
Bug fixes
2008-05-28 19:34:18 -05:00
Slava Pestov
315110eb09
Working on intersection classes
2008-05-10 18:09:05 -05:00
Slava Pestov
0a3429810c
Fix classes.tuple unit test failures
2008-05-10 16:28:02 -05:00
Doug Coleman
fd531c1a31
rename butlast to but-last
2008-05-07 01:38:34 -05:00
Slava Pestov
9fd7b12534
Merge branch 'master' of git://factorcode.org/git/factor
2008-05-07 00:40:17 -05:00
Doug Coleman
01f20cf32d
update core to use butlast, butlast-slice
2008-05-06 12:36:49 -05:00
Slava Pestov
53832ccd2f
Fix
2008-05-06 09:01:28 -05:00
Slava Pestov
5a29b2e273
Class linearization
2008-05-02 02:51:38 -05:00
Doug Coleman
e264537a1a
reverse the arguments of diff, assoc-diff
...
fix lots of usings
fix help-lint
2008-04-26 02:01:06 -05:00