ionide-vscode-fsharp
smartstring
Our great sponsors
ionide-vscode-fsharp | smartstring | |
---|---|---|
16 | 7 | |
841 | 480 | |
1.0% | - | |
8.7 | 0.0 | |
14 days ago | 7 months ago | |
F# | Rust | |
MIT License | Mozilla Public License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
ionide-vscode-fsharp
- Ask HN: Why do you think F# is not more popular, even within the .NET ecosystem?
-
Is there a modern IDE with good support for OCaml?
I'd love to see something similar to Microsoft's Ionide project or for JetBrains to invest in IDE support.
-
Why OCaml?
> Pretty good, https://ionide.io
It pains me to admit it because I really like F# but, with due respect to the developers, Ionide and its related projects are the most unstable toolchain I've ever used.
Spend half a day reloading the editor because the extension keeps hanging on non-trivial MSBuild only to discover that the formatter has truncated in half one of the files you worked on due to a soundness bug. (OCaml's editor support, in contrast, is quite stable.)
Rider is the best editing experience I've had with F#, by far.
-
How to get a non-broken F# development experience?
I know it's a recurring topic but it's reaching a high level of pain *again* (see NET SDK 6.0.400 and 7.0.100 previews don't currently work with Ionide).
-
The Case for C# and .NET
I don't disagree but it owes a lot of that to OCaml. That said, since we're talking about C#, F# and VS Code I'm gonna talk about a pet peeve I have. If you open a C# project in VS Code when the "Ionide" (basically the F# plugin for Code) is installed then Ionide thinks it's a F# project and will open some F# stuff after a few seconds (or prompt you to setup some F# stuff in its gitignore). The root cause has been identified (plugin activates when it sees a ".sln" file), a PR have been opened and rejected with no mention as to why (https://github.com/ionide/ionide-vscode-fsharp/pull/1401) and the developers behind it are frustratingly non-communicative about it, closing issues about it (https://github.com/ionide/ionide-vscode-fsharp/issues/1701). Usual rules about OSS maintainers apply, they don't technically owe us users anything ... but man it feels like we're being trolled by now :D
-
Rust Is Hard, Or: The Misery of Mainstream Programming
F# doesn't have a hard dependency on vscode. Resources from MS will obviously encourage using MS tooling, but ionide [1] is really good. The lsp+neovim workflow is not as good but getting better.
-
Making Ionide less "intrusive" in its new vscode version
Important thread about this: https://github.com/ionide/ionide-vscode-fsharp/issues/1693
-
Perf Avore: A Rule Based CrossPlatform Performance Based Monitoring and Analysis Tool
Perf Avore was developed on VSCode using the ionide plugin and dotnet cli.
-
A few newbie questions
I was on .Net 5 but same issue on 6. I tried the fix here- setting FSharp.dotnetRoot explicitly in settings.json and so far it seems better.
-
Debugging tests in VS Code
Make sure to keep an eye on this MR for that very capability :)
smartstring
-
Does using "String" instead of "&str" a lot results in unoptimised code?
Your use case sounds like it will involve a lot of small strings that use a subset of UTF-8. If you’re concerned about performance, you could look into something like smartstring. Sixbit also looks interesting, but it looks like it won’t give you any more characters and it’d probably require additional computation to do the conversion (and they’d have to be converted back out).
-
Rust Is Hard, Or: The Misery of Mainstream Programming
> If you have a long-running async function, then pass parameters by value! If you have a polymorphic async function, then return your result in a Box.
I've taken to making heavy use of the smallvec and smartstring crates for this. Most lists and strings are small in practice. Using smallvec / smartstring lets you keep most clone() calls allocation-free. This in turn lets you use owned objects, which are easier to reason about - for you and the borrow checker. And you keep a lot of the performance of just passing around references.
I tried to use async rust a couple of years ago, and fell on my face in the process. Most of my rust at the moment is designed to compile to wasm - and then I'm leaning on nodejs for networking and IO. Writing async networked code is oh so much easier to reason about in javascript. When GAT, TAIT and some other language features to fix async land I'll muster up the courage to make another attempt. But rust's progress at fixing these problems feels painfully slow.
https://crates.io/crates/smallvec / https://crates.io/crates/smartstring
-
GitHub - epage/string-benchmarks-rs: Comparison of Rust string types
Just to point out, smartstring no longer assumes String memory layout. From the changelog:
-
Why is str not just [char]?
There's some really good crates that implement SSO floating around - eg, SmartString. But I agree - its a pity they're needed. Swift built this into the core string type in the language. I think that was the right call.
-
Announcing `compact_str`! A super memory efficient immutable string that is transparently stored on the stack, when possible
Comparatively: * SmolStr can inline up to 22 bytes but does not adjust down for 32-bit architectures, meaning it's potentially wasting memory on 32-bit archs. Similarly though it's immutable and Clone is O(1) * SmartString can inline up to 23 bytes, but it's mutable and Clone is O(n). Also this crate makes assumptions about the memory layout of a String, which in theory should be fine, but is a slight caveat.
-
Version 0.19.15 released.
SmartString is used to store identifiers (which tends to be short, fewer than 23 characters, and ASCII-based) because they can usually be stored inline. Map keys now also use SmartString.
-
Speed of Rust vs. C
I’ve been using smartstrings, which is both excellent and maintained. https://github.com/bodil/smartstring
What are some alternatives?
playwright-dotnet - .NET version of the Playwright testing and automation library.
smol_str
proposal-pipeline-operator - A proposal for adding a useful pipe operator to JavaScript.
compact_str - A memory efficient string type that can store up to 24* bytes on the stack
Feliz - A fresh retake of the React API in Fable and a collection of high-quality components to build React applications in F#, optimized for happiness
min-sized-rust - 🦀 How to minimize Rust binary size 📦
jakt - The Jakt Programming Language
libskry_r - Lucky imaging library
fs-components
bitter - Extract bits from a byte slice
Perla - A cross-platform tool for unbundled front-end development that doesn't depend on Node or requires you to install a complex toolchain
redgrep - ♥ Janusz Brzozowski