Niko Matsakis
2e9b418bbb
rework book a little bit
...
- extend some of the empty sections, add a new common pattern
- also, show how to use anchors and include so we can test the sources
for common patterns
2019-09-24 06:13:51 -04:00
Niko Matsakis
1a8c97899e
Merge pull request #194 from matklad/on-demand
...
On demand input queries
2019-09-24 05:18:10 -04:00
Aleksey Kladov
3616014391
Apply suggestions from code review
...
Co-Authored-By: Niko Matsakis <niko@alum.mit.edu>
2019-09-24 12:08:13 +03:00
Aleksey Kladov
a798f1d918
Update src/runtime.rs
...
Co-Authored-By: bjorn3 <bjorn3@users.noreply.github.com>
2019-09-22 18:31:38 +03:00
Aleksey Kladov
ec5b92ea20
tests and docs for on-demand input pattern
2019-09-20 12:25:12 +03:00
Aleksey Kladov
60a475202a
add add_synthetic_read method to allow tweaking of the durability
2019-09-20 12:24:46 +03:00
Aleksey Kladov
95d0392f9c
add invalidate method to queries
2019-09-20 10:40:26 +03:00
Niko Matsakis
a9860bf37f
Merge pull request #147 from Marwes/cycles
...
feat: Allow queries to avoid panics on cycles
2019-09-19 05:56:39 -04:00
Aleksey Kladov
b3d3e8f944
Merge pull request #192 from guanqun/typo-fix
...
some random typo fixes
2019-08-22 20:15:03 +03:00
Guanqun Lu
5eb6c6f0bd
some random typo fixes
2019-08-23 00:54:29 +08:00
Aleksey Kladov
9fa6c57d3c
Merge pull request #191 from matklad/updates
...
⬆️ syn, quote, proc_macro2
2019-08-22 16:34:43 +03:00
Aleksey Kladov
04ecedd6ec
⬆️ syn, quote, proc_macro2
2019-08-22 16:21:46 +03:00
Markus Westerlind
360c78397b
nits
2019-08-21 10:18:01 +02:00
Markus Westerlind
897ee5f3d2
cargo fmt
2019-08-21 10:13:08 +02:00
Markus Westerlind
0e01067d55
feat: Allow queries to avoid panics on cycles
...
Quickest POC I could create to get some potentially cyclic queries to
not panic and instead return a result I could act on. (gluon's module
importing need to error on cycles).
```
// Causes `db.query()` to actually return `Result<V, CycleError>`
fn query(&self, key: K, key2: K2) -> V;
```
A proper implementation of this would likely return
`Result<V, CycleError<(K, K2)>>` or maybe larger changes are needed.
cc #6
2019-08-16 20:37:54 +02:00
Niko Matsakis
4815e14796
Merge pull request #190 from nikomatsakis/0.13.0
...
publish 0.13.0
2019-08-15 08:08:52 -04:00
Niko Matsakis
6fbce09585
highlight breaking changes
2019-08-15 08:08:00 -04:00
Niko Matsakis
a1bd7106a2
publish 0.13.0
...
also, create a release notes file for future reference
2019-08-15 07:59:05 -04:00
Aleksey Kladov
dd2b6669cc
Merge pull request #182 from matklad/runtime_id
...
use AtomicU64 for RuntimeId
2019-08-15 14:38:34 +03:00
Aleksey Kladov
efa92fdc23
use AtomicU64 for RuntimeId
...
We don't use `RuntimeId` to index memory, so using usize is
not the best fit semantically
2019-08-15 14:06:26 +03:00
Niko Matsakis
89dcc0ca57
Merge pull request #181 from matklad/ptr
...
use ptr::eq/hash for readability
2019-08-15 07:04:07 -04:00
Niko Matsakis
c80f5ead1c
Merge pull request #185 from matklad/pl
...
⬆️ parking_lot
2019-08-15 07:02:30 -04:00
Niko Matsakis
ae9ab75384
Merge pull request #183 from matklad/no-clone
...
remove needless clone
2019-08-15 07:01:34 -04:00
Niko Matsakis
b272cc1321
Merge pull request #180 from nikomatsakis/durability
...
Durability
2019-08-15 07:01:00 -04:00
Niko Matsakis
b26a690ff3
remove an unnecessary &mut
2019-08-15 06:50:10 -04:00
Niko Matsakis
969a9c2fc8
re-use the database-key instead of recreating it
2019-08-15 06:39:17 -04:00
Niko Matsakis
4cae741768
inline probe_memoized_value
2019-08-15 06:36:37 -04:00
Aleksey Kladov
5c27b734cf
⬆️ parking_lot
2019-07-15 19:43:39 +03:00
Aleksey Kladov
4c09786285
Merge pull request #184 from matklad/or_default
...
tiny simplification
2019-07-05 17:49:28 +03:00
Niko Matsakis
485df37e6f
make durability helper panic on an undefined key
2019-07-05 06:06:29 -04:00
Niko Matsakis
d4f7e4b2b4
improve comment
2019-07-05 06:05:18 -04:00
Niko Matsakis
346ce6bc16
remove set_common
helper and merge into set
2019-07-05 06:01:55 -04:00
Niko Matsakis
06ad8c7930
merge set and set_with_durability in plumbing trait
2019-07-05 06:01:17 -04:00
Niko Matsakis
8d30df0a0f
log durability
2019-07-05 06:00:21 -04:00
Niko Matsakis
e4b822cca4
s/verify_value/mark_value_as_verified/
2019-07-05 05:59:21 -04:00
Niko Matsakis
87f8517d75
remove max_durability
in favor of Durability::MAX
2019-07-05 05:58:23 -04:00
Niko Matsakis
e4cca9b8ff
disallow (and remove) dead-code
2019-07-05 05:58:10 -04:00
Niko Matsakis
6252430a91
Update src/input.rs
...
Co-Authored-By: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-07-05 05:52:36 -04:00
Aleksey Kladov
519bde621c
tiny simplification
2019-07-05 10:39:59 +03:00
Aleksey Kladov
1faa9d6016
remove needless clone
2019-07-04 15:20:27 +03:00
Niko Matsakis
5221e95ac4
correct out of date comments and typos
2019-07-04 06:32:08 -04:00
Aleksey Kladov
a7a8309c95
use ptr::eq/hash for readability
2019-07-03 22:24:11 +03:00
Niko Matsakis
e190a291f5
Update src/debug.rs
2019-07-03 06:28:09 -04:00
Niko Matsakis
ac93c950be
make interned keys have durability high
2019-07-02 08:22:25 -04:00
Aleksey Kladov
76f153e35e
Merge pull request #179 from matklad/bump-rand
...
⬆️ rand
2019-07-02 15:21:09 +03:00
Niko Matsakis
9d474363fc
s/next_revision/synthetic_write/
...
Also write some docs explaining its side-effects.
2019-07-02 07:49:01 -04:00
Niko Matsakis
a0a6bac5af
modify public API to set_foo_with_durability
2019-07-02 07:49:01 -04:00
Niko Matsakis
09c9bd9761
adjust public api from is_constant
to durability
2019-07-02 07:49:01 -04:00
Niko Matsakis
880b29a640
move durability
to its own module and make part of public API
2019-07-02 07:49:01 -04:00
Niko Matsakis
8b7808c6ae
eliminate a built-in notion of constant durability
2019-07-02 07:49:01 -04:00