Commit Graph

102 Commits (c9664e746b0f4b51e5fde48284e01cc7c3243c76)

Author SHA1 Message Date
John Benediktsson 43f334de3e core-foundation.strings: prevent creating CFString from characters in range 0xd800-0xdfff. 2012-06-01 17:56:34 -07:00
Joe Groff eee483654a use radix literals 2011-11-23 19:03:40 -08:00
Doug Coleman 4dce315490 Add core-foundation.launch-services for finding the path of a bundle. Add a new standard-paths vocabulary for finding files. 2011-10-30 16:11:18 -07:00
John Benediktsson 0d2bccdba7 core-foundation.timers: allow interval to be specified in the constructor. 2011-10-19 15:30:55 -07:00
John Benediktsson f2741b34a4 Eliminate duplicate syntax for stack effects "(" no longer drops and is identical to the old "((", which is now removed. 2011-10-18 13:19:39 -07:00
Doug Coleman 1152bab4d7 Cleanups found with lint tool 2011-10-14 10:15:13 -07:00
Doug Coleman 300138eb4d 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
Doug Coleman 4c3418b3ee Trim down a few using lists 2011-09-26 13:42:46 -07:00
John Benediktsson 0e3d598e69 specialized-arrays: performed some cleanup.
Specifically,
    •   Created >c-array to be replacement for >T-array.
    •   Created cast-array to be generic replacement for all T-array-cast words.
    •   Created c-array@ to be generic replacement for T-array@ words.
    •   Replaced usages of <T-array> with T <c-array>
    •   Replaced usages of <direct-T-array> with T <c-direct-array>
    •   Replaced usages of >T-array with T >c-array
    •   Replaced usages of T-array-cast with T cast-array
    •   Replaced usages of malloc-T-array with T malloc-array.
    •   Removed malloc-T-array.
    •   Removed T-array-cast.
    •   Removed T-array@.
    •   Removed >T-array.

I also added (but didn't change any code to use):
    •   T c-array-type, returns T-array
    •   T c-array?, returns T-array?
    •   c-array{ T ... }, returns T-array{ ... }

Bootstraps just find on Mac OS X.  Also `load-all test-all` works for me.
2011-09-26 11:37:51 -07:00
Joe Groff 571ef865e6 slots: pre-create the "at", "nth", and "global" slots to make deterministic the currently nondeterministic ambiguity between accessors:change-* and assocs:change-at, sequences:change-nth, and namespaces:change-global 2011-09-19 10:03:43 -07:00
Joe Groff 689511f316 game.input.iokit: deal with Lion's breakage of the IOHID* API 2011-07-29 13:24:10 -07:00
Slava Pestov 25f8796b0a core-foundation.run-loop bug fix for Doug's bug fix 2011-04-16 19:11:43 -07:00
Doug Coleman de2651f0f6 Bugfix: Only reset-timer on mac if sleep-time returns an integer. If it returns f, don't divide by 1000 and error. 2011-04-15 00:11:15 -05:00
Slava Pestov ae11aa08db Change do-callback to register the current thread with the callback, instead of busy waiting for the current callback to become the right one before returning. Fixes 100% CPU usage issue with system-alert. Thanks to Blei and ex-rzr for doing preliminary analysis of the issue 2011-04-12 21:48:54 -04:00
Slava Pestov 55fd15c45a Move <ref>, deref and little-endian? from alien.c-types to alien.data, remove <c-object> 2010-12-25 16:55:36 -08:00
Doug Coleman 40bdadcac4 Remove many uses of <int> and *int etc 2010-10-25 12:49:12 -05:00
Slava Pestov cf6b910c9f alien.data: remove second quotation parameter from with-out-parameters, now all values are copied properly and calling 'clone' on structs in this quotation is not necessary 2010-07-16 17:32:05 -04:00
Doug Coleman b197f4e755 Remove more system-micros stuff 2010-06-22 02:04:31 -05:00
Doug Coleman 8174abe287 remove system-micros word from factor src tree 2010-06-22 01:49:11 -05:00
Slava Pestov 5d9993d46f Updating code to use with-out-parameters 2010-05-23 03:07:47 -04:00
Joe Groff ca9614e746 Merge branch 'master' into abi-symbols 2010-04-01 15:28:36 -07:00
Doug Coleman 636f2ed2e5 Use flags{ instead of flags all over the place 2010-04-01 14:44:03 -05:00
Joe Groff d951be1832 "cdecl" -> cdecl 2010-03-31 19:20:35 -07:00
Slava Pestov d07a2bd326 core-foundation.run-loop: remove unnecessary yields. This fixes a thread starvation issue with game.input 2010-03-15 19:25:57 +13:00
Slava Pestov b8f3e0bc56 core-foundation.run-loop: clean up and speed up some code to fix starvation issue exposed by game.loop (reported by Joe Groff) 2010-03-01 12:22:18 +13:00
Slava Pestov 3c7f3f3886 core-foundation.run-loop: cleanup 2010-02-24 21:18:29 +13:00
Joe Groff eb93f68302 ui.backend.cocoa: invalidate run loop timers before raising an NSAlert and add them back when runModal returns to avoid run loop callbacks reentering Factor 2010-02-23 23:52:03 -08:00
Joe Groff 886b9c9dd2 change back other char/uchar* parameters that don't look like actual string types 2010-02-23 13:15:16 -08:00
Joe Groff 127f178b91 cairo.ffi, core-foundation.strings: change some functions that don't really expect strings to use char* instead of c-string (reported by Blei) 2010-02-23 12:53:09 -08:00
Joe Groff 96ab4492d2 rename current string-mangling "char*" to "c-string". char* is now just a boring old pointer to char 2010-02-23 11:42:02 -08:00
Joe Groff 43c5969490 core-foundation.fsevents: use CALLBACK: type to define master-event-source-callback 2010-02-21 11:17:25 -08:00
Slava Pestov 0aad3e6e12 vocabs.metadata: replace unportable tag with a platforms.txt file for more fine-grained control. Rename unportable tag to untested for remaining cases 2010-02-20 13:30:49 +13:00
Slava Pestov 81827c420a core-foundation.arrays: forgot to check in unit tests 2010-02-15 01:03:40 +13:00
Slava Pestov e645913ca5 core-foundation.arrays: CF>array word was broken ever since integer sequences were removed 2010-02-10 11:46:44 +13:00
Slava Pestov 08b6ebc7fa Factor source files should not be executable 2009-11-21 17:50:43 -06:00
Slava Pestov b8987749f7 Move nano-count>timestamp word to core-foundation.run-loop since its pretty specialized 2009-11-20 00:12:16 -06:00
Doug Coleman 80240c82f0 use nanoseconds in the core-foundation run-loop 2009-11-19 19:22:36 -06:00
Doug Coleman 4d6bae9a21 update run-loop multiplexer 2009-11-19 14:18:27 -06:00
Doug Coleman 3323072613 Merge branch 'master' into startup
Conflicts:
	core/bootstrap/primitives.factor
	vm/run.hpp
2009-11-15 02:52:50 -06:00
Joe Groff cee5862b69 update a bunch of alien-callbacks and alien-indirects to use c-type words 2009-10-21 21:10:11 -05:00
Doug Coleman 6fa23d7ea4 change add-init-hook to add-startup-hook, new add-shutdown-hook word 2009-10-19 22:17:02 -04:00
Joe Groff dd67afe581 replace all TYPEDEF: void* XXX* with C-TYPE: XXX 2009-09-27 22:21:24 -05:00
Joe Groff e5d406693e add USING:s and rearrange definitions so macosx can compile without parsing c-type strings 2009-09-26 23:14:57 -05:00
Joe Groff 334e93bbbf get things to a point where they bootstrap again 2009-09-15 21:43:18 -05:00
Slava Pestov a36c377dc0 core-foundation.strings: fix load error 2009-09-13 00:17:24 -05:00
Joe Groff 16ba9bd8b8 add full complement of [SU]Int[0-9]+ typedefs to core-foundation 2009-09-12 19:43:57 -05:00
Joe Groff adee149870 CFSTRING: syntax for defining CF/Cocoa string constants. update core-foundation.run-loop to use CFSTRING: 2009-09-12 19:43:23 -05:00
Slava Pestov 527db8995a Specialized array overhaul
- Replace hand-written specialized-arrays.* subvocabularies with new system; instead of USE:ing specialized-arrays.T, do SPECIALIZED-ARRAY: T
- Ditto for specialized-vectors; use SPECIALIZED-VECTOR:
- io.mmap.functor: removed entirely, use <mapped-array> instead
- struct-arrays and struct-vectors have been removed because specialized arrays and vectors subsume them entirely
2009-09-09 22:33:34 -05:00
Slava Pestov 430f4a83f9 specialized-arrays.direct is no more; instead, every specialized-array.<foo> vocabulary has a <direct-T-array> constructor 2009-09-04 22:01:55 -05:00
Joe Groff ee4735eec9 update cocoa and core-foundation stuff to use classes.struct and boxed malloc-arrays 2009-08-29 12:22:55 -05:00