winsafe
win32metadata
winsafe | win32metadata | |
---|---|---|
41 | 27 | |
440 | 1,281 | |
- | 0.5% | |
9.5 | 0.0 | |
2 days ago | 20 days ago | |
Rust | C++ | |
MIT License | GNU General Public License v3.0 or later |
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.
winsafe
-
Sorry... what diskette?
I know all that shit because I'm the author of Rust's WinSafe library, which is a safer Rust layer over native Win32, so I had to deal with a lot of shit like this.
-
Accessing List of Installed Apps on Windows 11
[dependencies] winsafe = { git = "https://github.com/rodrigocfd/winsafe", features = ["kernel"] }
-
What is Rust's potential in game development?
Externally, you can write a lot of native Windows stuff in Rust already. Personally, I'm having a lot of fun with WinSafe.
-
What are the scenarios where "Rewrite it in Rust" didn't meet your expectations or couldn't be successfully implemented?
If you had such problems (which I also had in the past), I'm really interested in you opinion about WinSafe, and if it could help you solving them.
-
Is there a more "traditional" desktop front end I can use with Tauri?
If you're after a native Windows application, WinSafe may suit your needs.
-
GitHub - ryanmcgrath/cacao: Rust bindings for AppKit (macOS) and UIKit (iOS/tvOS). Experimental, but working!
As the author of WinSafe, I can say it's tedious sometimes, but it's often very challenging, because you have to translate crazy unsafe behaviors into Rust's ownership model. It's surely hard, but also very rewarding at the end.
-
Microsoft is rewriting core Windows libraries in Rust
As the author of the WinSafe lib, I wholeheartedly agree.
-
A Proposal for Safe Window Handles
I don't know how rare this is (or how rare it should be), but this issue warned me about this potential problem, and I had to make a huge refactoring to treat the possibility. I had to rethink many aspects of all handle implementations. It was hard work, but in the end it was worth it.
-
Why is building a UI in Rust so hard?
WinSafe says hello.
-
Use ManuallyDrop in Rust to control drop order of structure fields
WinSafe, for example (which attemps to be a safe layer over the Windows API), provides lots of RAII automations. A fine example is the BeginPaint function:
win32metadata
-
Hey Rustaceans! Got a question? Ask here (18/2023)!
As /u/huellenoperator notes, that this needs a pointer to a mutable string comes straight from microsoft through win32metadata. Maybe it's a mistake on Microsoft's side, but if it's not you're taking big risks.
-
Kernel Headers for Windows could soon make it into windows-rs
Microsoft offers official "bindings" to Win32 APIs through win32metadata. However, until recently, it did not include metadata for kernel-level functions or WDK. In early 2021, an issue was raised through windows-rs regarding this limitation, but progress was slow until now. Microsoft has finally released official metadata for WDK, which can be found on the wdkmetadata repository. The latest comment on the issue thread can be found here:
-
winreader: read memory from other programs
for win32metadata's kernel api tracking issue, https://github.com/microsoft/win32metadata/issues/401
-
Best windows stubs
Any examples? Since the API bindings in windows-sys are generated from the metadata generated from official Windows SDK headers I'd not expect to see this kind of difference.
-
can we be free of c?
You might also look at this project: https://github.com/microsoft/win32metadata
-
Is it time to retire C and C++ for Rust in new programs?
There is still the occasional incredibly subtle link time fuckery in Rust.
https://github.com/microsoft/win32metadata/issues/1274
"Minor" semver updates to crates breaking things via e.g. unexpected MSRV bumps is pretty common too, with some resulting bitrot. That said, I agree with you that things in Rust are at least better. Imperfect, but better.
-
Are there any Windows-centric perks of using C# that other non-Microsoft languages simply can't offer (or at least don't out of the box)?
Win32 is available as metadata to enable adoption in as many languages as possible. Are there some things missing? Yes. The Microsoft team acknowledges that and encourages asking for the things you need so they can add them to the metadata.
-
Using Windows API in Julia?
It might be interesting to have bindings generated for the entirety of Win32 API through https://github.com/microsoft/win32metadata
- Would std code for Windows ever use the windows crate by Microsoft?
-
The Atrocities of COM win32 headers
Hi JB! Funny to cross paths with you in this context. I don't know if you remember me but I was a rookie programmer who got the pleasure of joining the VideoLan Conference in Dublin back in 2014, and then Paris the next year, and you were very kind to me.
The GitHub issue title here is unfortunately misleading. I have renamed it to "ideas to improve windows header files and libc". Also, I hope it is clear that I rebutted the points made by the OP, because I completely agree with your summary that the mingw-w64 people are skilled, nice and very clever and think about all use cases.
If any drive-by HN readers work at Microsoft, please help us with this issue: https://github.com/microsoft/win32metadata/issues/766
What are some alternatives?
panamax - Mirror rustup and crates.io repositories, for offline Rust and cargo usage.
rust-bindgen - Automatically generates Rust FFI bindings to C (and some C++) libraries.
winlamb - A lightweight modern C++11 library for Win32 API, using lambdas to handle Windows messages.
JNA - Java Native Access
skytable - Skytable is a modern scalable NoSQL database with BlueQL, designed for performance, scalability and flexibility. Skytable gives you spaces, models, data types, complex collections and more to build powerful experiences
go - The Go programming language
rust-psvita - Project to build PS Vita apps in rust
winapi - Windows API declarations without <windows.h>, for internal Boost use.
kube - Rust Kubernetes client and controller runtime
zig - General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
calligrapher-ai - Handwriting Synthesis with RNNs ✍🏻
panama-foreign - https://openjdk.org/projects/panama