diff --git a/collects/typed-scheme/minimal.ss b/collects/typed-scheme/minimal.ss index 40bcc4c9..f3b6d039 100644 --- a/collects/typed-scheme/minimal.ss +++ b/collects/typed-scheme/minimal.ss @@ -1,9 +1,9 @@ #lang scheme/base (provide #%module-begin provide require rename-in rename-out prefix-in only-in all-from-out except-out except-in - providing begin) + providing begin subtract-in) -(require (for-syntax scheme/base)) +(require (for-syntax scheme/base) scheme/require) (define-for-syntax ts-mod 'typed-scheme/typed-scheme) diff --git a/collects/typed-scheme/private/base-env.ss b/collects/typed-scheme/private/base-env.ss index 39c1c2cf..2f60de6a 100644 --- a/collects/typed-scheme/private/base-env.ss +++ b/collects/typed-scheme/private/base-env.ss @@ -8,7 +8,7 @@ '#%paramz "extra-procs.ss" (only-in '#%kernel [apply kernel:apply]) - scheme/promise + scheme/promise scheme/system (only-in string-constants/private/only-once maybe-print-message) (only-in scheme/match/runtime match:error matchable? match-equality-test) (for-syntax (only-in (types abbrev) [-Number N] [-Boolean B] [-Symbol Sym]))) @@ -830,3 +830,9 @@ [vector-split-at-right (-poly (a) ((list (-vec a)) -Integer . ->* . (-values (list (-vec a) (-vec a)))))] + +;; scheme/system +[system (-String . -> . -Boolean)] +[system* ((list -Pathlike) -String . ->* . -Boolean)] +[system/exit-code (-String . -> . -Integer)] +[system*/exit-code ((list -Pathlike) -String . ->* . -Integer)] diff --git a/collects/typed/private/wrap.ss b/collects/typed/private/wrap.ss new file mode 100644 index 00000000..8f2bb87b --- /dev/null +++ b/collects/typed/private/wrap.ss @@ -0,0 +1,10 @@ +#lang scheme + +(define-syntax (mb stx) + (syntax-case stx () + [(_ id) + #'(#%plain-module-begin + (require id) + (provide (all-from-out id)))])) + +(provide (rename-out [mb #%module-begin])) \ No newline at end of file diff --git a/collects/typed/scheme.ss b/collects/typed/scheme.ss new file mode 100644 index 00000000..37e8e2ad --- /dev/null +++ b/collects/typed/scheme.ss @@ -0,0 +1,4 @@ +#lang s-exp typed-scheme/minimal + +(require typed/scheme/base (subtract-in scheme typed/scheme/base scheme/contract)) +(provide (all-from-out typed/scheme/base scheme)) \ No newline at end of file diff --git a/collects/typed/scheme/base.ss b/collects/typed/scheme/base.ss new file mode 100644 index 00000000..8798e922 --- /dev/null +++ b/collects/typed/scheme/base.ss @@ -0,0 +1,16 @@ +#lang s-exp typed-scheme/minimal + + + +(providing (libs (except scheme/base #%module-begin #%top-interaction with-handlers lambda #%app) + (except typed-scheme/private/prims) + (except typed-scheme/private/base-types) + (except typed-scheme/private/base-types-extra)) + (basics #%module-begin + #%top-interaction + lambda + #%app)) +(require typed-scheme/private/base-env typed-scheme/private/base-special-env + (for-syntax typed-scheme/private/base-types-extra)) +(provide (rename-out [with-handlers: with-handlers]) + (for-syntax (all-from-out typed-scheme/private/base-types-extra))) diff --git a/collects/typed/scheme/base/lang/reader.ss b/collects/typed/scheme/base/lang/reader.ss new file mode 100644 index 00000000..009b1f17 --- /dev/null +++ b/collects/typed/scheme/base/lang/reader.ss @@ -0,0 +1,8 @@ +#lang s-exp syntax/module-reader + +typed-scheme + +#:read r:read +#:read-syntax r:read-syntax + +(require (prefix-in r: typed-scheme/typed-reader)) diff --git a/collects/typed/scheme/lang/reader.ss b/collects/typed/scheme/lang/reader.ss new file mode 100644 index 00000000..009b1f17 --- /dev/null +++ b/collects/typed/scheme/lang/reader.ss @@ -0,0 +1,8 @@ +#lang s-exp syntax/module-reader + +typed-scheme + +#:read r:read +#:read-syntax r:read-syntax + +(require (prefix-in r: typed-scheme/typed-reader)) diff --git a/collects/typed/scheme/system.ss b/collects/typed/scheme/system.ss index f10fe2e2..61bc8bc1 100644 --- a/collects/typed/scheme/system.ss +++ b/collects/typed/scheme/system.ss @@ -1,10 +1 @@ -#lang typed-scheme - -(require typed/private/utils) - -(require/typed/provide - scheme/system - [system (String -> Boolean)] - [system* (Path-String String * -> Boolean)] - [system/exit-code (String -> Integer)] - [system*/exit-code (Path-String String * -> Integer)]) +#lang s-exp typed/private/wrap scheme/system \ No newline at end of file