Skip to content

Feature: UnsafeAttribute #53

@Lamparter

Description

@Lamparter

What feature or improvement do you think would benefit the app?

There should be an UnsafeAttribute with an analyser that can be used to explain to the consumer that the object is not safe.

Requirements

  • Create attribute
  • Create analyser
  • Create source generator to automatically apply on unsafe methods

Version

No response

API Changes

public sealed class UnsafeAttribute : Attribute

Intended Use-Case

For example:

[Unsafe("This method can sometimes break the control.")]
public void SetImage(Image image)

There should be multiple constructors that can be used to give a justification, a severity level, or no arguments.

Comments

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions