Releases: microsoft/windows-rs
0.60.0
This release includes an update to the windows-registry and windows-strings crates, mainly to provide various improvements to registry support for rustup.
What's Changed
- Add precise registry types and allocation-free queries and updates by @kennykerr in #3184
- Add registry
Value
to/fromHSTRING
conversion by @kennykerr in #3190 - Replace
From<&str>
forGUID
withTryFrom<&str>
by @kennykerr in #3193 - Remove uneeded feature dependencies by @kennykerr in #3201
- docs: add root level documentation for all libraries by @Nerixyz in #3202
- Cleanup doc testing by @Nerixyz in #3205
- Revert cfg doc by @kennykerr in #3206
- Remove workaround for "unused" private fields by @kennykerr in #3207
- Immutable Event implementation by @lifers in #3198
- Always treat warnings as errors by @kennykerr in #3210
- Consistent allocation failure handling by @kennykerr in #3209
- Improve class hierarchy support by @kennykerr in #3212
- Consistent allocation failure for stock collections by @kennykerr in #3216
- Consistent allocation failure for
windows-registry
by @kennykerr in #3215 - Add default "std" feature for
windows-registry
crate by @kennykerr in #3214 - Overhaul async and future support by @kennykerr in #3213
- Addressing new nightly Clippy warning by @kennykerr in #3222
- Add async
ready
support by @kennykerr in #3221 - Bump micromatch from 4.0.5 to 4.0.8 in /web/features by @dependabot in #3223
- Add file dialog sample by @kennykerr in #3226
- Use relative path for extension by @glandium in #3224
- Simplify trait bounds for interface implementations by @kennykerr in #3227
- Remove unnecessary closure from generated code by @kennykerr in #3228
- Bump webpack from 5.90.2 to 5.94.0 in /web/features by @dependabot in #3236
- Add async
spawn
support by @kennykerr in #3235 - Nightly Clippy warning about assumed lifetime by @kennykerr in #3243
- Regenerate GNU libs by @riverar in #3241
- Add support for composable constructors by @kennykerr in #3246
- Use workspace dependencies where practical by @kennykerr in #3248
- Add test folders by @kennykerr in #3252
- Improve interop testing by @kennykerr in #3253
- Avoid deriving
Eq
for structs containing floating point type parameters by @kennykerr in #3255 - Add test for composable type authoring support by @kennykerr in #3259
- Factory cache statics don't need to be public by @kennykerr in #3261
- Allow
noexcept
methods in a composable hierarchy by @kennykerr in #3262 - Group more of the WinRT tests together by @kennykerr in #3263
- Remove "riddle" and metadata generation by @kennykerr in #3266
- Improvements to
windows-metadata
by @kennykerr in #3268 - We can now derive
Eq
andPartialEq
for structs containing callbacks by @kennykerr in #3270 - Simpler "retval" heuristic by @kennykerr in #3271
- Test error handling for
windows-bindgen
crate by @kennykerr in #3272 - Exclude
web
on most workflows by @kennykerr in #3279 - Bump serve-static and express in /web/features by @dependabot in #3274
- Update jsonschema requirement from 0.18 to 0.19 by @dependabot in #3283
- Move
VARIANT
support to thewindows
crate by @kennykerr in #3282 - Update
jsonschema
dependency by @kennykerr in #3286 - Expand
raw-dylib
testing by @kennykerr in #3287 - Fix for
cppwinrt
concurrency issue by @kennykerr in #3289 - Address Rust nightly compiler warnings by @kennykerr in #3292
- Add
Deref
implementation forHSTRING
by @kennykerr in #3291 - Release 0.60.0 by @kennykerr in #3293
New Contributors
Full Changelog: 0.59.0...0.60.0
0.59.0
This release includes an update to the windows-sys crate only. The windows-sys
crate is updated very infrequently and only when there is an explicit need to do so. The 0.59.0 release includes a rollup of API fixes, updates, and additions since the 0.52.0 release nine months ago. Notably:
- This update introduces support for Arm64EC (#2957)
- Updated bindings for the latest APIs https://github.com/microsoft/windows-rs/tree/0.59.0/crates/libs/bindgen/default
- Derive standard traits (#3041)
- Updates to code generation to handle newer Rust warnings and lints
- Overall smaller crate and more efficient code gen to reduce build time
- Support for feature search https://microsoft.github.io/windows-rs/features/#/0.59.0
- MSRV is updated to 1.60
Full Changelog: 0.52.0...0.59.0
0.58.0
This release includes updates to metadata for new or fixed API definitions (#3111, #3136), various improvements and fixes to code generation, compliance with new Rust warnings, additional COM authoring support improvements (#3065), limited non-Windows support (#3135), and more.
It includes major updates to the following crates, mainly due to breaking changes in metadata for API definitions.
riddle
0.58.0windows
0.58.0windows-bindgen
0.58.0windows-core
0.58.0windows-implement
0.58.0windows-interface
0.58.0windows-metadata
0.58.0
It also includes major updates to the following utility crates.
windows-result
0.2.0windows-registry
0.2.0
The windows-result
crate now provides limited non-Windows support, and the windows-registry
crate offers new lossless queries for binary and wide string values.
And it includes minor updates to the windows-targets
crates, with the addition of several new APIs.
windows-targets
0.52.6
This release also includes the first published version of the windows-strings
crate, moving the string types from the windows-core
crate into a dedicated crate as a smaller dependency. It also offers an efficient HSTRING
builder (#3133).
To clarify, the only crates that continue to support limited non-Windows builds are:
windows-bindgen
andwindows-metadata
for code generation on non-Windows platforms.windows-core
andwindows-result
for COM support on non-Windows platforms.
What's Changed
- Fix default
rustfmt
for repo by @kennykerr in #3084 - Simplify standalone test by calling
windows-bindgen
directly by @kennykerr in #3086 - Disable docs and tests for test crates by @kennykerr in #3085
- Simplify pointer writes in generated code by @kennykerr in #3089
- Infer return type in generated bindings by @kennykerr in #3090
- Allow
windows-result
to work on non-Windows platforms by @sivadeilra in #3082 - Change tests/standalone so that a tool regenerates its sources by @sivadeilra in #3091
- Bump braces from 3.0.2 to 3.0.3 in /web/features by @dependabot in #3092
- Use malloc on non-Windows platforms by @sivadeilra in #3095
- COM interface impls move from MyApp to MyApp_Impl ("outer" object) by @sivadeilra in #3065
- Workaround for false dead code warning by @kennykerr in #3098
- The
Debug
derive macro does not need to be qualified by @kennykerr in #3097 - Harden detection of missing nested types by @kennykerr in #3099
- Use tools to generate bindings for library crates by @kennykerr in #3102
- Allow
unused
to deal with new warning about "unused" private fields in structs by @kennykerr in #3103 - Remove
mio
dependency by @kennykerr in #3107 - Support some edge cases for the next Win32 metadata update by @kennykerr in #3109
- Simplify how extension code for
windows
crate works by @sivadeilra in #3110 - Directly invoke bindgen instead of recursively calling
cargo run ...
by @sivadeilra in #3113 - Update Win32 metadata by @kennykerr in #3111
- Don't compile
windows
andwindows-sys
in unit test mode by @sivadeilra in #3112 - Remove unused dependencies by @kennykerr in #3117
- Test cross-compilation with stable gnullvm targets by @mati865 in #3104
- Add flexible registry type and byte query support by @kennykerr in #3120
- Remove unnecessary test cfg checks by @kennykerr in #3124
- Add
windows-strings
crate by @kennykerr in #3125 - Lock down
windows-core
internals by @kennykerr in #3129 - Remove "std" writer from
windows-bindgen
by @kennykerr in #3130 - Allow
Error
andResult<()>
to be the same size asHRESULT
by @sivadeilra in #3126 - Remove boxing support from
windows-core
crate by @kennykerr in #3131 - Use conventional testing for
windows_slim_errors
by @kennykerr in #3132 - Clarify support for non-Windows targets by @kennykerr in #3135
- Add
HSTRING
builder and registry support by @kennykerr in #3133 - Update Windows metadata to 10.0.26100.1 by @kennykerr in #3136
- Implement
Send
andSync
forWeak<T>
by @kennykerr in #3138 - Remove
Future
implementation by @kennykerr in #3142 - Ensure that
HSTRING
builder provides initialized memory by @kennykerr in #3141 - Make new
windows-strings
crate Windows-only by @kennykerr in #3143 - Release 0.58.0 by @kennykerr in #3140
Full Changelog: 0.57.0...0.58.0
0.57.0
This release includes updates to a number of crates.
It includes major updates to the following:
riddle
0.57.0windows
0.57.0windows-bindgen
0.57.0windows-core
0.57.0windows-implement
0.57.0windows-interface
0.57.0windows-metadata
0.57.0
It also includes minor updates to the following:
windows-result
0.1.2windows-registry
0.1.2
This includes various improvements and fixes to code generation, compliance with new Rust warnings, COM authoring support helpers, and more.
This release also includes the first published version of the cppwinrt
crate.
What's Changed
- Workflow improvements by @kennykerr in #2994
- Workflow improvements 2 by @kennykerr in #2998
- Workflow improvements 3 by @kennykerr in #3000
- Workflow improvements 4 by @kennykerr in #3001
- Add
as_raw
towindows-registry
by @kennykerr in #3003 - Add Linux smoke test by @kennykerr in #3005
- Add non-windows support for PWSTR and PCWSTR by @tyilo in #3004
- Use generated
E_POINTER
constant inwindows-core
by @kennykerr in #3008 - Use prebuilt gnullvm target by @mati865 in #3007
- Eliminate default features for JSON samples by @kennykerr in #3012
- Add support for freeing handles automatically by @kennykerr in #3013
- Addressing feedback on handle ownership by @kennykerr in #3014
- Bump ejs from 3.1.9 to 3.1.10 in /web/features by @dependabot in #3017
- Reconfigure environment for GNU toolchain by @riverar in #3019
- Remove workaround for empty structs by @kennykerr in #3016
- Derive
Copy
,Clone
, andDebug
for handles by @kennykerr in #3015 - Fix for Clippy
HSTRING
interior mutability warnings in nightly by @riverar in #3021 - Handle new
unexpected_cfgs
warnings by @kennykerr in #3022 - Update jsonschema requirement from 0.17 to 0.18 by @dependabot in #3023
- Add
Ref
andOutRef
to enhance COM authoring support by @kennykerr in #3025 - Simplify derefencing
Ref
interface parameters by @kennykerr in #3027 - Add
from_raw
towindows-registry
by @kennykerr in #3034 - Simplify
windows-registry
readme by @kennykerr in #3035 - Type name deferral in
windows-metadata
andwindows-bindgen
by @kennykerr in #3039 - Streamline
TypeName
to support pattern matching by @kennykerr in #3040 - Derive standard traits for structs by @kennykerr in #3041
- Add missing MSRV workflows for newer lib crates by @kennykerr in #3042
- Provide an explicit
ComObject<T>
type that represents a heap-allocated COM object by @sivadeilra in #3043 - bindgen/default: Improve formatting of the readme by @MarijnS95 in #3045
- Allow windows, windows_core (and several other crates) to be compiled and used in no_std environments. by @sivadeilra in #3047
- Add simple C++ test by @kennykerr in #3046
- Fix soundness hole in ComObject by @sivadeilra in #3051
- Re-enable
unexpected_cfgs
by @ChrisDenton in #3050 - Add
no-default-features
yml workflow by @kennykerr in #3053 - Fix alignment issue in
windows-registry
value iterator by @kennykerr in #3052 - Dynamic casting to COM implementation by @sivadeilra in #3055
- Switch to
windows-2022
hosted runners by @kennykerr in #3056 - Add
cppwinrt
crate and sample by @kennykerr in #3054 - Fix handling of COM interfaces with same method name by @sivadeilra in #3059
- Fix bug in COM interface chain support by @sivadeilra in #3060
- Fix Debug impls for COM interfaces by @sivadeilra in #3066
- Use default rustfmt config for most crates by @sivadeilra in #3064
- Check for null pointers in core
IInspectable
implementation by @kennykerr in #3057 - Fix warnings from Rust 1.80.0 nightly by @sivadeilra in #3074
- Remove
unused_qualifications
entirely by @kennykerr in #3078 - Optimize
IUnknown
identity checks by @sivadeilra in #3073 - Add WinRT
noexcept
support by @kennykerr in #3070 - Release 0.57.0 by @kennykerr in #3081
New Contributors
- @tyilo made their first contribution in #3004
- @sivadeilra made their first contribution in #3043
Full Changelog: 0.56.0...0.57.0
0.56.0
This release includes updates to all crates except windows-sys
.
It includes major updates to the following:
riddle
0.56.0windows
0.56.0windows-bindgen
0.56.0windows-core
0.56.0windows-implement
0.56.0windows-interface
0.56.0windows-metadata
0.56.0
This includes various improvements and fixes to code generation, compliance with new Rust warnings, Arm64EC bindings, as well as ergonomic improvements. The riddle
crate in particular now matches the version of windows-bindgen
as they are inextricably linked.
It includes minor updates to the following:
windows-targets
0.52.5windows-result
0.1.1windows-registry
0.1.1windows-version
0.1.1
The windows-targets
crate adds support for arm64ec-pc-windows-msvc
and i686-pc-windows-gnullvm
. The other crates only update dependencies.
What's Changed
- Avoid
windows
crate dependency inimplement
andinterface
macros by @kennykerr in #2917 - Simplify version declarations in toml and readme files by @kennykerr in #2918
- Format extension files by @kennykerr in #2919
- Riddle 0.3 by @kennykerr in #2920
- Hash impl for HSTRING by @zardini123 in #2924
- Fix generic class signature calculation by @kennykerr in #2927
- Defer module name lowercase conversion for Windows by @kennykerr in #2934
- Document
Param
trait by @kennykerr in #2938 - Add diff check after workflow test run by @kennykerr in #2940
- Update
windows-core
to generate its own bindings by @kennykerr in #2941 - Fix for new Rust nightly warnings related to dead code by @kennykerr in #2951
- Update gnullvm libraries by @riverar in #2953
- Add 0.54.0 to feature search app by @riverar in #2950
- Prep for type name deferral by @kennykerr in #2955
- Fix typo in
windows-targets
readme by @kennykerr in #2962 - Add missing tests for readme code snippets by @kennykerr in #2963
- Simplify type remapping by @kennykerr in #2964
- Simplify
cfg
union calculation by @kennykerr in #2965 - Add i686-pc-windows-gnullvm target by @jeremyd2019 in #2961
- Implement
Deref
for COM interface hierarchies inwindows-bindgen
by @kennykerr in #2968 - Implement
Deref
for COM interface hierarchies defined with theinterface
macro by @kennykerr in #2969 - Remove redundant target checks by @kennykerr in #2973
- Add support for Arm64EC by @dpaoliello in #2957
- Fix for new Clippy warnings in nightly by @kennykerr in #2977
- Add explicit path support to the
interface
macro by @kennykerr in #2976 - Document
Interface::IID
by @kennykerr in #2990 - Release 0.56.0 by @kennykerr in #2989
New Contributors
- @zardini123 made their first contribution in #2924
- @dependabot made their first contribution in #2933
- @jeremyd2019 made their first contribution in #2961
Full Changelog: 0.55.0...0.56.0
0.55.0
This update includes a few improvements to code generation. The following crates are being updated today:
windows-bindgen
windows-metadata
windows-core
What's Changed
- Improve
implement
macro docs by @daladim in #2891 - Restore MSRV for
windows-targets
to 1.56 by @kennykerr in #2898 - Simpler namespace type collection by @kennykerr in #2901
- Allow
PWSTR
/PSTR
to be passed toPCWSTR
/PCSTR
parameters by @kennykerr in #2899 - Consolidate type generation by @kennykerr in #2903
- Add ability to prepend code to type generation by @kennykerr in #2907
- Fix for new Rust nightly warnings related to unnecessary qualifications by @kennykerr in #2911
- Add option to suppress
windows-bindgen
comment in generated code by @kennykerr in #2910 - More unnecessary qualifications by @kennykerr in #2912
- Consolidate internal
interface
andcom_interface
macros by @kennykerr in #2914 - Release 0.55.0 by @kennykerr in #2915
New Contributors
Full Changelog: 0.54.0...0.55.0
0.54.0
This update includes a few improvements to error propagation and expanded VARIANT
support.
What's Changed
- Add natural error translation for RPC by @kennykerr in #2883
- Workaround for confusing
LocalFree
behavior by @kennykerr in #2889 - Avoid
Result
transformation forWIN32_ERROR
by @kennykerr in #2890 - Support additional
VARIANT
types by @kennykerr in #2892 - Release 0.54.0 by @kennykerr in #2894
Full Changelog: 0.53.0...0.54.0
0.53.0
As requested, this release updates the Windows family of crates. Notably:
- The
windows-sys
crate won't be updated at this time. - The
windows-version
crate is unchanged. - There is a minor (compatible) update to the
windows-targets
crates. - This is the first release of the
windows-result
(#2847) crate and provides efficient Windows error handling and propagation with support for Win32, COM, WinRT, and NT APIs. - This is the first release of the
windows-registry
(#2848) crate and provides simple, safe, and efficient access to the Windows registry. VARIANT
andPROPVARIANT
support has been added to thewindows-core
crate (#2786), making it a lot easier to work with Shell and OLE APIs.- Windows metadata has been updated providing additional APIs and fixes.
- A new feature search tool is now available to quickly determine which features to enable for a given API.
- A number of new tutorials have been added.
- A number of new samples have been added.
- Many additional fixes and improvements listed below.
What's Changed
- Update repo readme to list main crates by @kennykerr in #2704
- Minor tooling improvements by @kennykerr in #2705
- Simplify code gen for functions that don't return a value by @kennykerr in #2706
- Adds ability to override
GetTrustLevel
return value by @kennykerr in #2714 - Remove
invalid_mut
whenwriter.std
by @ChrisDenton in #2727 - Update metadata by @riverar in #2724
- Update MSRV for
windows
crate to 1.62 by @kennykerr in #2730 - Calculate type signatures at compile time by @kennykerr in #2729
- Add doc comment for
windows::core::Error::from_win32()
by @Enyium in #2733 - Generate defaulted foundation feature dependencies by @kennykerr in #2735
- Enable workspace lints by @kennykerr in #2741
- Enable workspace lint
unused_qualifications
by @kennykerr in #2743 - Simpler associated item code gen by @kennykerr in #2744
- Update API contracts by @riverar in #2745
- Clarify
HSTRING::len
documentation by @kennykerr in #2749 - Derive
Copy
,Clone
,Default
for enums by @kennykerr in #2760 - Make the
matches
function safe by @kennykerr in #2761 - Check MSRV and prefer
Option
for propagation by @kennykerr in #2766 - Relax the build target checks in windows-targets sub-crates by @seritools in #2774
- Simplified parameter bindings and type projection by @kennykerr in #2775
- Fix tests which rely on English UI language by @kaivol in #2776
- Truncate standalone test files instead of removing by @ChrisDenton in #2778
- Implement
From<T>
andFrom<&T>
for interface hierarchies by @kennykerr in #2779 - Use signed byte for C's
char
type by @kennykerr in #2781 - Standalone code generation should collect pointer types by @kennykerr in #2785
- Add
VARIANT
andPROPVARIANT
support by @kennykerr in #2786 - Add
VT_UNKNOWN
support forVARIANT
andPROPVARIANT
by @kennykerr in #2788 - Add Windows shell sample illustrating
VARIANT
support by @kennykerr in #2789 - Adjust Win32 return value code transformation by @kennykerr in #2790
- Harden generic type parameter binding by @kennykerr in #2791
- Expand WMI sample for
ExecQuery
andExecMethod
by @kennykerr in #2794 - Limit
AssociatedEnum
attribute to input parameters by @kennykerr in #2797 - Enable workspace lint
missing_docs
by @kennykerr in #2799 - Add task dialog samples by @kennykerr in #2802
- Include
Windows.Win32.UI.Shell.Common
in thewindows-sys
crate by @kennykerr in #2804 - Omit parameter names from internal vtable definitions by @kennykerr in #2808
- Fix for test reliability by @kennykerr in #2809
- Consistent
const
functions across string types by @kennykerr in #2810 - Update Win32 metadata by @kennykerr in #2812
- Add "hello world" component sample by @kennykerr in #2814
- Add JSON validator sample by @kennykerr in #2815
- Remove old Windows 7 support code by @kennykerr in #2817
- Leaner interface representation for
windows-sys
crate by @kennykerr in #2818 - Optimize error propagation by @kennykerr in #2819
- Update dependabot to check github actions by @kennykerr in #2826
- Update yml actions by @kennykerr in #2825
- Add JSON validator sample for WinRT by @kennykerr in #2824
- Remove doc comments by @kennykerr in #2830
- Add delay load samples by @kennykerr in #2839
- Address new nightly unsafe precondition check panics by @riverar in #2841
- Improve natvis compatibility by @riverar in #2838
- Add error translation support for
std::io::Error
by @kennykerr in #2840 - Improve
HRESULT
ergonomics by @kennykerr in #2843 - Metadata generation of attributes and constants by @kennykerr in #2844
- Add "vtbl" option for low-level interface vtable generation by @kennykerr in #2845
- Add
windows-result
crate by @kennykerr in #2847 - Add
windows-registry
crate by @kennykerr in #2848 - Update repo readme with new crates by @kennykerr in #2852
- Map
TryFromIntError
toERROR_INVALID_DATA
inwindows-result
by @kennykerr in #2851 - Update Win32 metadata by @kennykerr in #2850
- Natvis cleanup following the
windows-result
crate split by @tim-weis in #2853 - Fix for new redundant import warnings in nightly Rust by @kennykerr in #2858
- Improve
HRESULT
constant literal generation by @kennykerr in #2857 - Generate features index for windows and sys crates by @riverar in #2859
- Improve
NTSTATUS
constant literal generation by @kennykerr in #2860 - Add
NTSTATUS
message formatting support to thewindows-result
crate by @kennykerr in #2861 - Simpler package layout for natvis files by @kennykerr in #2862
- String trait refactoring by @kennykerr in #2863
- Add feature search links by @kennykerr in #2865
- Add HashRouter to web app for deep links by @riverar in #2867
- Release 0.53.0 by @kennykerr in #2854
New Contributors
- @Enyium made their first contribution in #2733
- @seritools made their first contribution in #2774
Full Changelog: 0.52.0...0.53.0
0.52.0
This release includes updates to all crates. This includes the first update to the windows-sys
crate in 8 months. It also includes the first published version of the riddle tool and the windows-version crate.
What's Changed
- Simplify issue templates by @riverar in #2621
- Switch all crates to Rust edition 2021 by @kennykerr in #2620
- Correct workflow trigger ignore paths by @riverar in #2622
- Detect unused
bindgen
/riddle
filters by @kennykerr in #2634 - Fix
BOOLEAN
parameter binding by @kennykerr in #2635 - Provide individual crate readme files by @kennykerr in #2645
- Tweak Win32 error code conversion to handle
HRESULT
input by @kennykerr in #2646 - Remove support for the defunct
StaticLibrary
attribute by @kennykerr in #2647 - Derive
PartialEq
,Eq
,Debug
,Clone
for interfaces by @kennykerr in #2651 - Internal
bindgen
refactoring by @kennykerr in #2654 - Disable signature transformation for
NTSTATUS
by @kennykerr in #2658 - Unhide
query
method onComInterface
trait by @kennykerr in #2659 - Harden
QueryInterface
implementation by @kennykerr in #2660 - Mask non-reproducible linker artifacts in libs by @riverar in #2661
- Slim doc generation by @kennykerr in #2671
- Update SDK and WDK metadata by @riverar in #2664
- Add feature documentation quotes by @kennykerr in #2675
- Add
docs
feature by @kennykerr in #2676 - Simplify metadata reader by @kennykerr in #2682
- Add bindgen config option to disable generating inner attributes by @dpaoliello in #2683
- Simplify metadata filtering by @kennykerr in #2684
- Simplify code generation by @kennykerr in #2686
- Fix link from docs.rs to full API documentation by @ChrisDenton in #2688
- Optimize tick trimming by @kennykerr in #2689
- Small bindgen refactor and tools refresh by @kennykerr in #2695
- Document
implement
andinterface
macros by @kennykerr in #2696 - Perform checked integral type conversions for APIs by @kennykerr in #2699
- Add
windows-version
crate by @kennykerr in #2702 - Add crate-specific readme files by @kennykerr in #2703
New Contributors
- @dpaoliello made their first contribution in #2683
Full Changelog: 0.48.5...0.52.0
0.48.5
As discussed in #2613, this update bumps windows-targets
to 0.48.5 and will be the final release to support 1.48.
I will then switch everything in windows-rs
to use edition 2021 and MSRV 1.56.
What's Changed
- 0.48.5 by @kennykerr in #2617
Full Changelog: 0.48.4...0.48.5