Commit Graph

33550 Commits

Author SHA1 Message Date
Eric Dobson
3c179e0217 Move logic of numbering rest/drest arg to abstract results. 2014-06-24 21:52:21 -07:00
Eric Dobson
db02f2198e Remove unused kw field in lam-result. 2014-06-24 21:52:21 -07:00
Eric Dobson
2f7cb68aea Fix infer dotted cases when there are constraints on the dbound.
Closes PR 14593.
2014-06-24 21:35:18 -07:00
Eric Dobson
8fb166d67f Make interning work on Rep-seq for Reps with complicated fields.
This gives ~3% improvement in new-metrics.rkt
2014-06-24 21:28:21 -07:00
Stephen Chang
500745f41b add typed/racket/async-channel 2014-06-24 18:16:14 -04:00
Gustavo Massaccesi
49ff6d3c84 optimizer: test use of virtual clock in branches
Test that the optimizer don't move some expressions inside if branches.
2014-06-24 17:47:43 +01:00
Matthew Flatt
f4be105ab6 inside: modernize overview to discourage extensions and embedding
The beginning of the "Inside" documentation was still geared toward
writing extensions or embedding Racket, which almost no one does any
more. Shuffle and change the beginning to orient it around the
foreign-function interface, instead.
2014-06-24 17:47:43 +01:00
Eric Dobson
5cf65e28fc Add equality operations for Reps.
This speeds up microbenchmarks by 50%, and new-metrics.rkt by 30%.
2014-06-24 08:19:06 -07:00
Matthew Flatt
d3e008af50 racket/tcp: use %E instead of %e for socket error reporting
Using "%E" is right for WinSock errors, instead of "%e".
2014-06-24 11:40:21 +01:00
Matthew Flatt
2134dbf952 scribble: 'border and '{left,right,top,bottom}-border properties for cells 2014-06-24 11:30:14 +01:00
Eric Dobson
fd3d01d822 Use (listof tc-result?) instead of tc-results? when inferring types.
tc-results? does not represent Bottom in a way that maintains the number
of values that generated the Bottom.
2014-06-23 21:49:53 -07:00
Eric Dobson
7701e8af51 Do not rebuild the environment made by check-non-recursive-clauses. 2014-06-23 21:46:03 -07:00
Eric Dobson
203311e993 Make with-lexical-env/extend-props not execute its body if its dead. 2014-06-23 21:46:02 -07:00
Eric Dobson
e8c14839e1 Simplify and document compact. 2014-06-23 21:38:27 -07:00
Eric Dobson
c66d0286cf Change type<? to rep<?.
Also moves type-equal and rep<? to rep-utils.
2014-06-23 21:07:59 -07:00
Eric Dobson
7f721ef5d8 In -and move the NotTypeFilters to the begining as well. 2014-06-23 21:07:59 -07:00
Sam Tobin-Hochstadt
dcb5b09a14 Optimize match patterns of the form (list x ...).
This also applies to `(mlist x ...)`, even though
that involves two traversals when only one is
required by the old method. Timing suggests that
the new code is nonetheless faster.
2014-06-23 15:27:19 -04:00
Matthew Flatt
133d7a3c41 distro-build: add "versionless" option
Versionless mode avoids putting a version number in an installer's
name or in installation paths.
2014-06-23 18:42:46 +01:00
Asumu Takikawa
1e67fb16e6 Fix type for syntax-local-phase-level 2014-06-23 11:48:39 -04:00
Matthew Flatt
58eab92dc3 Fix reading of badly encoded symbols from bytecode
This is the third try to fix the bug exposed by "fuzz.rkt". Previous
repairs addressed a symptom at the point of printing bad symbols,
instead of the cause at a failure to validate a symbol's encoding
when reading bytecode. This one fixes reading.
2014-06-23 16:21:48 +01:00
Matthew Flatt
408d6bb773 Fix UTF-8 symbol repair
Commit 6a5a3037b4 was not quite right, because it used sightly the
wrong variant among a dozen decoding functions.  The test suite caught
the problem, but I forgot to run it before pushing.

Also, repair the "Inside" documentation on the function that was
incorrectly used, and document the new variant.
2014-06-23 15:35:25 +01:00
Matthew Flatt
6a5a3037b4 avoid getting stuck on non-UTF-8 symbol encodings in bytecode
Found by fuzz tester, and this bug seems to be a common reason for
the fuzz test to time out.
2014-06-23 13:27:52 +01:00
Matthew Flatt
431321f2cb fix use of wrong comparsion macro
The wrong comparison could possibly (though not likely) cause an
operation-skipping optimization to be missed.
2014-06-23 10:44:56 +01:00
Matthew Flatt
d970d5aaea Scribble: improve Unicode handling for Latex/PDF output
Normalize strings to composed form before splitting a
string into characters to handle individually.
2014-06-23 06:28:50 +01:00
Matthew Flatt
93fdbdc79c optimizer: refine virtual clock, more precise shift-fuel tracking
Allow an effect-free `if` to not increment the effect-tracking
virtual clock (but increment the clock during branches, to avoid
moving computation into a branch).

Spend empty-`let`-elimination fuel more precisely, so that more
empty `let`s can be removed while still avoiding quadratic
compile times.
2014-06-23 06:28:50 +01:00
Robby Findler
25cf0ea610 add crop/align 2014-06-22 23:41:58 -05:00
Robby Findler
ff8708b311 add color-frame 2014-06-22 23:41:58 -05:00
Robby Findler
43c1ddbf5f Rackety: bring down below 102 columns 2014-06-22 23:41:57 -05:00
Eric Dobson
1271c11781 Add contracts to filter-ops. 2014-06-22 19:43:45 -07:00
Robby Findler
b234e22413 in text mode, don't do "The Racket Language"-specific things
closes PR 14590
2014-06-22 08:39:46 -05:00
Mike Sperber
95ccac8a5c Synch German string constants with latest. 2014-06-21 13:01:19 +02:00
Eric Dobson
7acc9eaf0a Make combine-results work with tc-result/c. 2014-06-20 23:52:09 -07:00
Robby Findler
06061758b7 update the expected results for the redex bitmap tests 2014-06-21 01:33:31 -05:00
Eric Dobson
fc649c6b99 Fix subtype for filters in AnyValues. 2014-06-20 23:11:38 -07:00
Eric Dobson
b199527ec2 Add test cases for subtyping of -Bottom. 2014-06-20 21:46:23 -07:00
Eric Dobson
30809eb841 Add match expander for functions and arities together. 2014-06-20 21:30:25 -07:00
Eric Dobson
11e19caa02 Add bottom as a special case in multiple value context. 2014-06-20 21:30:25 -07:00
Eric Dobson
5af90e65e9 Make funapp take a Type/c instead of a tc-results?. 2014-06-20 21:30:25 -07:00
Eric Dobson
cb243606ab Only match on f-type in tc/funapp. 2014-06-20 21:30:25 -07:00
Eric Dobson
919e03b9f7 Remove extraneous patterns in tc/funapp.
Also improves error messages on cases which return AnyValues/ValuesDots.
2014-06-20 21:30:25 -07:00
Robby Findler
82d8094d1a adjust the 'Skip to Next Misspelled Word' menu key shortcut to try to avoid conflicts 2014-06-20 19:25:09 -05:00
Robby Findler
74831b41cc add abbreviate-given-names
This changes the behavior of make-cite and authors, but it would
probably be better to change the behavior of generate-bibliography
2014-06-20 19:23:14 -05:00
J. Ian Johnson
bacbafad9f Closes PR14589. 2014-06-20 14:08:25 -04:00
Asumu Takikawa
8b53d32f52 Give more information for kw errors in TR
Tells the user which missing keywords were mandatory and
which were optional (which is useful if, e.g., the expected type
says mandatory but the function had it optional).
2014-06-20 12:21:45 -04:00
Asumu Takikawa
8755e62556 Check kw functions with optional arguments better
In particular, allow the optional kws to be left out in the
expected type (a function type with fewer optional kws is
a supertype).

Closes PR 14583
2014-06-20 12:14:43 -04:00
Matthew Flatt
22b7cc6a5e optimizer: improvements mostly for splitting of multiple-value bindings
Convert

 (let-values ([(<id> ...) (if <id-t>
                              (values <e1> ...)
                              (values <e2> ...))])
    ....)

to

 (let ([<id> (if <id-t> <e1> <e2>)]
       ...)
    ....)

which duplicates the `(if <id-t> ....)` test, but that's likely to
be worthwhile to avoid multiple-values shuffling and enable more
constant and copy propagation.

A related improvement is to more eagerly discard `let` wrappers
with unused bindings during optimization, which could enable
further optimization, and allow moving conditionals relative
to other expressions to avoid intermediate binding.

Eagerly discarding `let` wrappers exposed a bug in the optimizer's
shifting of variable locations by exercising the relavant shifting
operation in shift_closure_compilation().

Closes PR 14588
2014-06-20 11:05:07 +01:00
Matthew Flatt
16a0727231 optimizer: fix reordering in let+values+values splitting
While the commit comment in 3150b31eb7 still seems right, the changed
overlooked the fact that the arguments to a split `values` might get
reordered (due to the way binding positions are calculated). Fix the
optimizer to make sure that reordering is allowed.

The change touches a lot of code, because we want to use
"omittable" to implement "movable", and it's not ok to
reorder access of mutable variables (in case some other thread is
mutating them). We have to fix all the calls to "omittable"
to support the slight generalization.
2014-06-20 08:08:17 +01:00
Matthew Flatt
da979b6c8d optimizer: fix with-continuation-mark optimization
Misuse of the function to optimize applications constrained the
body of a `with-continuation-mark` form to a single result
value.
2014-06-20 06:41:39 +01:00
Robby Findler
0c5239fb51 improve check syntax so opening the context-sensitive menu is faster
in certain situations

Specifically, don't compute the identifiers-hash before opening the
menu but, when it does need to be computed, avoid consider the same
arrows over and over. This makes an especially big difference when a
region of text is selected that contains lots of arrow heads that all
point to a place that has lots of arrows.

Specifically, the time to compute the identifers hash for the example in
the PR is now about 200x faster (altho this still takes 200 msec, which
is why it isn't computed at all in that sequence of steps any more).

closes PR 14586
2014-06-19 20:01:12 -05:00
Asumu Takikawa
4aa438937a Rework how keyword methods are handled by TR
Override the `define/foo` forms for racket/class to
allow type annotations and to use TR's keyword property.
2014-06-19 17:12:54 -04:00