Commit Graph

42958 Commits

Author SHA1 Message Date
Matthew Flatt
7438586cf0 cs & thread: fix atomic timeouts
Commit 9a3eb15d8b broke atomic-timeout handling. As aresult, for
example, using the scroll thumb on Mac OS could freeze DrRacket as
long as something is running for a canvas refresh.
2021-01-02 08:22:14 -07:00
shhyou
db9c06aff1 Install local package catalog in Windows CI 2020-12-31 17:23:39 -05:00
Matthew Flatt
f299c4304d Chez Scheme: save an instruction on record predicates
Combine separate subtraction and comparison instructions into one in
the case of non-sealed record types.
2020-12-31 07:43:46 -07:00
Matthew Flatt
30eb35b99c cs & schemify: improve folding of procedure? and procedure-arity-includes? 2020-12-30 17:14:43 -07:00
Matthew Flatt
23300fd18d cs: use nongenerative records in core 2020-12-30 15:34:46 -07:00
Matthew Flatt
e604c2deb9 Chez Scheme: change record-type predicate to constant-time
Change the representation of records to keep an ancestor vector
instead of just a parent, so a record-type predicate (for a non-sealed
type) can be constant-time.
2020-12-30 14:02:38 -07:00
Matthew Flatt
a8819af26a cs & schemify: further refinments to left-to-right and letrec
More cases where the code can be mostly left alone, and then cp0 and
company can make further improvements.
2020-12-30 09:23:29 -07:00
Bogdan Popa
62e8f27bf7
inside: note necessary entitlement to embed CS using hardened runtime 2020-12-30 05:50:37 -07:00
David Van Horn
001ad13297
Check numeric argument to real->decimal-string
Closes #3565
2020-12-30 05:09:14 -07:00
Matthew Flatt
15bda57d77 cs & io: fix UDP receive poller registration
Closes #3590
2020-12-30 05:05:28 -07:00
Matthew Flatt
dbe36162ac cs: fix some predefined struct-operation procedure names
Closes #3592
2020-12-30 04:54:06 -07:00
Matthew Flatt
c7ca4414ca cs & io: small clean-ups to seconds->date
Streamline some things that probably needed to be different along the
way.
2020-12-30 04:49:48 -07:00
Matthew Flatt
4b7b1872dc version bump for seconds->date change 2020-12-30 03:44:14 -07:00
shuhung
4b4ed24c65
Implement seconds->date in the io layer 2020-12-30 03:41:33 -07:00
shhyou
9842dd6216 Send notification if the repo is racket 2020-12-29 22:55:36 -06:00
Matthew Flatt
4936977c56 cs & schemify: prevent reorder of allocation and continuation capture 2020-12-29 16:23:47 -07:00
Matthew Flatt
95e5acdb0d Chez Scheme: enable more let lifting
For example, allow
  (cdr (let ([x (f)]) (cons x x)))
to be turned into
  (let ([x (f)]) (cdr (cons x x)))
and then just
  ($value (f))
2020-12-29 14:07:43 -07:00
Matthew Flatt
ea96e2d304 add unsafe-set-immutable-{car,cdr}!
Reluctantly, with intentionally oxymoronic names, and with the key
caveat: using these requires making correct assumptions about Racket's
implementation.

With BC, a related assumption was that `unsafe-set-mcar!` and
`unsafe-set-mcdr!` mutate pairs, but that's not the case with CS. So,
adding these functions supports a kind of portability between BC and
CS.
2020-12-29 08:55:40 -07:00
Matthew Flatt
becf34a79b expander: fix check on syntax-local-lift-provide
Closes #3589
2020-12-28 14:07:10 -07:00
Matthew Flatt
471f18c02d Revert "makefile: clone single pb branch"
This reverts commit 250f5ca661.

The `--single-branch` flag requires Git 1.7.10 or later.
2020-12-28 09:53:31 -07:00
Matthew Flatt
70a600e1b5 build-instruction typos and clarifications 2020-12-27 19:08:19 -07:00
Matthew Flatt
8f05958ba2 Revert "makefile: add fake-installers target"
This reverts commit 2110b3c753.

Adding a `#:fake-installer?` site-confoguration option is better.
2020-12-27 19:06:20 -07:00
Matthew Flatt
2110b3c753 makefile: add fake-installers target
The `fake-installers[-from-built]` target drives a distribution build
like `installers[-from-built]`, but instead of building on clients,
just copies a "README" as an installer.
2020-12-27 15:46:08 -07:00
Matthew Flatt
250f5ca661 makefile: clone single pb branch 2020-12-27 09:21:55 -07:00
Matthew Flatt
8869f0eb9e Chez Scheme: remove a debugging leftover
A do-nothing loop, which was probably a debugging check at some point,
wasn't correct and could break vfasl loading.
2020-12-26 10:14:57 -07:00
Matthew Flatt
4d7f52e7dd expose WTF-8 converters on all platforms 2020-12-25 08:00:32 -07:00
Matthew Flatt
dd1061f069 cs & io: fix conversion from UTF-8-ish
The UTF-8-ish decoder incorrectly allowed a surrogate pair encoded as
two unpaired surrogates, and it treated an unpaired surrogate at the
of a stream as complete instead of a potential error.

Related to #3578
2020-12-24 15:43:59 -07:00
shhyou
6e58310176 Use foreign function from MSVCRT on Windows 2020-12-24 10:14:41 -07:00
shhyou
f6b7f93895 Fix JSON test 2020-12-23 13:25:35 -06:00
Bogdan Popa
f4cd7ab8a0 pkg: improve CI template for new packages
Related to #1500.

This improves the following aspects of the CI config:

* The config now tracks the current stable version of Racket so
package authors don't have to remember to upgrade the config on new
releases.  This is a double-edged sword, because it makes it easy to
use features of new Racket version and potentially break
backwards-compatibility by accident.  Running CI against a set of
static Racket versions doesn't have this problem since any such change
would end up failing.  Maybe a better change here would be to
interpolate the current `(version)` into the CI file instead.

* The job is now set to fail on the first error it encounters on the
assumption that most packages fail due to internal issues and not due
to mismatches between Racket versions.  The intent with this change is
to use fewer resources overall when possible.  Additionally, the
packages' dependencies are now validated during the setup step.

* Lastly, the install step now avoids building documentation for
dependencies, which can shave off significant amounts of time.
2020-12-23 10:25:24 -05:00
Stephen De Gabrielle
1ad448e19e added links with #:url 2020-12-23 08:21:45 -07:00
David Van Horn
c93837c2ce Fix rationalize with +nan.0 tolerance
Calling `rationalize` with `+nan.0` as the second argument was causing
a "no exact representation error."  This commit changes it to produce
`+nan.0`.

There was an unexercised set of tests for `rationalize` in the test
suite which, once called, demonstrate the bug.

Those tests also specify that `rationalize` should produce an exact
result when the first argument is exact and the second is an infinity.
That's not what the implementation does; it coerces the result to
inexact.  I changed the test cases to match the implementation, which
is consistent with other Schemes (Chez, MIT) and standards (R6RS).
2020-12-23 08:20:31 -07:00
Stefan Schwarzer
4fa48182c0 docs: fix upper ASCII limit for control characters
Character 32 is space, which isn't a control character.
2020-12-23 08:02:23 -07:00
Sam Tobin-Hochstadt
6369646116 Order keys when writing JSON output.
More significant on Racket CS because ordering is often different
than creation order.

Closes #3537.
2020-12-23 10:01:08 -05:00
Matthew Flatt
3577cb0e4d ffi/vector: more complete tests 2020-12-23 07:58:34 -07:00
David Van Horn
72a852ca43 cs: fix {u,s}16vector-{ref,set!} when memory is not bytes?
When a {u,s}16vector points to memory that's not bytes (e.g. from ffi)
then referencing or setting the memory results in a Chez error:

```
foreign-set!: unrecognized type 'int16
```

The fix is to change the type argument to `'integer-16` and
`'unsigned-16`.
2020-12-23 07:49:23 -07:00
Matthias Felleisen
bff1a3c012 test for ordered jsexpr->string 2020-12-23 09:45:09 -05:00
Matthew Flatt
cc9fc20a07 raco dist: signing repairs for ARM Mac OS 2020-12-22 15:55:47 -07:00
Matthew Flatt
d7e9628caf clean up some debugging leftovers 2020-12-22 13:07:15 -07:00
Matthew Flatt
a450246ee7 mach-o: infer machine type instead of depending on cross information
Directly inferring the machine type works more easily for some Racket
CS build steps.
2020-12-22 12:58:17 -07:00
Matthew Flatt
15ab674ef8 ffi/unsafe/objc: repair use of objc_msgSendSuper_stret
TTo keep stack alignment correct, the `objc_msgSendSuper_stret`
function needs to be used with a structure return type on i386,
instead of making the implicit return-pointer argument explicit.
(For BC, libffi apparently makes the wrong style work anyway.)
2020-12-22 10:51:54 -07:00
Matthew Flatt
b8f0c96756 Chez Scheme: repair i386 Mac OS __collect_safe ABI
A wrapper to align the stack during activation was dropped if the
return type was `void` for a foreign callable, and a callee-popped
argument was not handled right for a foreign call.
2020-12-22 10:51:45 -07:00
yjqww6
153569894c fix a contract test 2020-12-22 06:51:02 -05:00
Matthew Flatt
33fd201947 Chez Scheme: revert incorrect cp0 simplification
It's not necessarily ok to inline a function wrapper by
`make-wrapper-procedure`, because the wrapper might get mutated. We
could add immutable wrapper procedures, but we can also just revert to
a previous approach for code that needed the optimization.
2020-12-21 16:46:21 -07:00
shhyou
50f373f4d6 Fixes of the core tests for testing on Windows
* Initialize the environment variables with paths to
  MSVC toolchain before running the racket-test-core,
  since the foreign library tests need a C compiler.

* Fix a bug in foreign-test.rktl that deletes the existing
  content of environment variables (PATH, INCLUDE, LIB, etc)

* Let a test in date.rktl fail more gracefully.
2020-12-21 15:18:07 -06:00
Matthew Flatt
0041354e1f fix some uses of peek-bytes-avail! that do not expect specials
Closes #3572
2020-12-21 08:06:43 -07:00
Matthew Flatt
c93e4f1328 cs: repair ctype alignment
Currently, this repair matters only for PPC32 Mac OS, which is the
only place where alignment of some primitive atomic type is not the
same as its size.
2020-12-21 07:31:09 -07:00
Matthew Flatt
8cd96ec5df bc: repair for foreign callbacks
Fix an array whose size needs to be connected to the number of
arguments to `ffi-callback-maker`.
2020-12-20 20:35:49 -07:00
shhyou
344f2c9713 Split the testing steps in the Windows CI workflow
* cmd.exe only returns the error level of the last
  executed command and does not support fail-fast.
  So testing should be done in individual steps.

  See <https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-syntax-for-github-actions> for more information.

* Also installs db-test dependencies.
2020-12-20 22:11:10 -05:00
Matthew Flatt
763c5465f6 revert argument change in #%foreign exports
The changed functions are documented and turn out to be used by the
`gui` package.
2020-12-20 16:51:22 -07:00