Commit log

243b66a Add unit test for rope with all 4-byte chars

Max Brunsfeld created

e860cac Get randomized tests passing in the presence of multibyte chars

Max Brunsfeld created

beaa35f Merge pull request #61 from zed-industries/ropes-2

Click to expand commit body
Store buffer's visible and deleted text using ropes

Max Brunsfeld created

614e96b Clarify how the ropes are kept consistent with the fragments

Max Brunsfeld created

fc25335 Remove inline assertions about RopeBuilder invariants

Max Brunsfeld created

79c91de Get tests passing with RopeBuilder

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

cba8603 WIP

Nathan Sobo created

2cdf315 WIP: Replace ropey with our own Rope

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra and Nathan Sobo created

2f5754d Implement a `Cursor` for `Rope`

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra and Nathan Sobo created

580fc4f Clarify variable and method names

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra and Nathan Sobo created

0d50c74 :lipstick:

Antonio Scandurra created

9f9f339 :memo:

Antonio Scandurra created

e2c19d3 Add `Rope::chunks`

Antonio Scandurra created

6e30fdb Better balancing of chunks on `push`

Antonio Scandurra created

f303a1d Implement `::chars`, `::to_point` and `::to_offset` for Rope

Antonio Scandurra created

ff235e6 Increase leaf occupation for rope

Antonio Scandurra created

d7cde9f Don't underflow Rope chunks on append

Antonio Scandurra created

e48973f Start on a SumTree-based Rope implementation

Antonio Scandurra created

9aeb35b Get tests passing using a slow rightmost_point impl

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Max Brunsfeld and Nathan Sobo created

d8f7b35 Fix concurrent editing in buffer after using ropes

Click to expand commit body
Co-Authored-By: Max Brunsfeld <max@zed.dev>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra , Max Brunsfeld , and Nathan Sobo created

39c56b7 Get local buffer usage working with ropes

Click to expand commit body
Randomized tests for remote edits are still not passing.

Co-Authored-By: Max Brunsfeld <max@zed.dev>

Antonio Scandurra and Max Brunsfeld created

7b98fb3 WIP: Get the type checker passing...

Click to expand commit body
...but not the borrow checker!

Co-Authored-By: Max Brunsfeld <max@zed.dev>

Antonio Scandurra and Max Brunsfeld created

0e9441e WIP

Click to expand commit body
Co-Authored-By: Nathan Sobo <nathan@zed.dev>

Antonio Scandurra and Nathan Sobo created

b348276 Merge pull request #60 from zed-industries/fix-failures

Click to expand commit body
Fix more test flakiness

Antonio Scandurra created

37f0ba9 Increase timeout for fs-dependent conditions

Antonio Scandurra created

4884a05 Change buffer atomically when reloading from disk

Antonio Scandurra created

19f51bc Rely more on conditions for state derived after worktree changes

Antonio Scandurra created

2c43066 Merge pull request #59 from zed-industries/more-resilient-fs-events

Click to expand commit body
Use `flush_fs_events` more after performing synchronous fs mutations

Antonio Scandurra created

eea9cb4 Use `flush_fs_events` more after performing synchronous fs mutations

Click to expand commit body
I am not sure I have caught all the examples of this, but in general
I think we always want to perform a `flush_fs_events` as opposed to
`next_scan_complete` when doing synchronous I/O. Indeed, the file
system may inform us about the events caused by the just-performed
I/O over multiple batches, and `next_scan_complete` may return
before seeing all of them.

Note that this also removes a few assertions which were ensuring
that, on start, a worktree's file handle wouldn't know its deleted
status, even if the file didn't exist for sure on disk. However,
now that `file` is an async API, it's possible that by the time the
`FileHandle` is resolved, `Worktree` has already completed scanning.
We test a similar behavior further along in the test where those
assertions were removed, so it felt okay to proceed without them.

Antonio Scandurra created

0187b6d Merge pull request #54 from zed-industries/file-changed-on-disk

Click to expand commit body
Handle buffers' files changing on disk from outside of Zed

Max Brunsfeld created

520cbfb Read file's mtime in background when getting a FileHandle

Click to expand commit body
Co-Authored-By: Antonio Scandurra <me@as-cii.com>

Max Brunsfeld and Antonio Scandurra created

d76d532 Merge branch 'master' into file-changed-on-disk

Max Brunsfeld created

d0b7377 Merge pull request #57 from zed-industries/dropped-entities

Click to expand commit body
Fix panic when an entity's ref count is decremented to 0 and then is incremented again

Max Brunsfeld created

493643c Remove dropped entities even if there are no effects to flush

Max Brunsfeld created

9dac491 Don't remove entities whose ref count has become positive again

Nathan Sobo created

e81a28e Remove dropped entities after every effect

Nathan Sobo created

c757b3f Allow a longer timeout in buffer conflict test

Max Brunsfeld created

4910bc5 Merge branch 'master' into file-changed-on-disk

Max Brunsfeld created

36163f7 Merge pull request #56 from zed-industries/async-ctx

Click to expand commit body
Simplify spawning and asynchronous code

Max Brunsfeld created

d6c8952 Remove commented-out tests for spawn and spawn_stream

Max Brunsfeld created

a3be559 Pass a handle to the current view model when spawning

Click to expand commit body
Most of the time, we'll want a way to get a reference back to the current view or model, so this facilitates that common case.

Nathan Sobo created

fa6bd1f Introduce AsyncAppContext and simplify spawning

Click to expand commit body
Now when you call spawn in various context, you pass an FnOnce that is called with an AsyncAppContext and returns a static future. This allows you to write async code similar to how our tests work, borrowing the guts of the AsyncAppContext when needed to interact, but using normal async await semantics instead of callbacks.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>

Nathan Sobo and Max Brunsfeld created

d0f69c7 Merge pull request #55 from zed-industries/test-macros

Click to expand commit body
Introduce a `gpui::test` macro for less ceremony when writing tests

Max Brunsfeld created

2326ac3 Use `gpui::test` for tests in gpui

Click to expand commit body
Co-Authored-By: Max Brunsfeld <max@zed.dev>

Antonio Scandurra and Max Brunsfeld created

ab04d71 Use `gpui::test` in async tests in zed

Click to expand commit body
Co-Authored-By: Max Brunsfeld <max@zed.dev>

Antonio Scandurra and Max Brunsfeld created

1c2b381 Use `gpui::test` macro for synchronous tests in zed

Antonio Scandurra created

c7d97ad Introduce a `gpui::test` macro

Antonio Scandurra created

048bbc9 Test prompting when saving while there's a conflict

Antonio Scandurra created

ac2168f Update `mtime` and `is_deleted` when saving/loading a file

Antonio Scandurra created

2eff936 Make `MutableAppContext::prompt` private

Click to expand commit body
...as we're supposed to call this method only via ViewContext.

Antonio Scandurra created