Skip to content

Add Length property to BSTR #717

@JeremyKuhne

Description

@JeremyKuhne

Something like the following would be useful:

/// <summary>
/// Returns the length of the native BSTR.
/// </summary>
public unsafe uint Length => Value is null ? 0 : *(((uint*)Value) - 1) / 2;

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions