This reduces compilation time by removing a dependency on syn and other
dependencies of ouroboros_macros. In addition it saves a lot of unused
codegened methods.
On my laptop (2 core + HT) this reduces compilation time by ~20%. On a
many core system this doesn't help much though as the critical path path
consists of both ttf-parser -> rustybuzz and swash. Further gains will
likely need to be made by reducing compilation time for these crates.
Benchmark 1: cargo build
Time (mean ± σ): 25.150 s ± 0.167 s [User: 84.414 s, System: 7.335 s]
Range (min … max): 24.909 s … 25.444 s 10 runs
Benchmark 1: cargo build
Time (mean ± σ): 19.819 s ± 0.226 s [User: 67.754 s, System: 5.592 s]
Range (min … max): 19.492 s … 20.140 s 10 runs
The code is based on an expansion of the ouroboros macro, cleaned up to
remove all unused methods and inline most functions that are only called
once.
There was a problem in the upstream `sys-locale` crate where it assumed
that every WebAssembly target can use `wasm-bindgen` just fine. This
however is not the case, as `wasm-bindgen` and the ecosystem around it
are specifically to target the web. In reality there however are at
least the following 4 "targets" (with possibly more in the future):
- WebAssembly on the web
- Freestanding WebAssembly
- WebAssembly with WASI
- WebAssembly with Emscripten
These are all supported properly through `sys-locale` 0.3.0 now. However
because "WebAssembly on the web" unfortunately is not its own target and
instead uses `wasm32-unknown-unknown`, just like freestanding
WebAssembly, the only way to differentiate between them is through a
feature. This is the best practice and is done throughout the ecosystem.
Here the feature `wasm-web` is introduced that properly forwards it to
`sys-locale` and possibly other crates in the future.
* WIP VI wrapper for editor
* WIP: block cursor
* Create Edit trait, run CI on all feature options
* Add prints describing build steps to ci.sh
* Custom rendering for Vi editor
* Clippy fixes
* More clippy fixes
* Show clippy results in CI
* Fix for Redox
* Fix clippy lint
* Add vi feature to enable vi-style editor
* Add escape to libcosmic text box