Skip to content

Create [WarningAttribute] and [ErrorAttribute] that triggers compiler warnings/errors the way [ObsoleteAttribute] does. #156

@TwoRedCells

Description

@TwoRedCells

FEATUREREQUEST
COMPILER

Add a [WarningAttribute] or [CompilerWarningAttribute] and [CompilerErrorAttribute] that works the same way as [ObsoleteAttribute]; it would trigger a compiler warning or error with a customized message. Ideally it would not be sealed. You could do things like:

[Warning("This class uses PInvoke and will prevent ARM compatibility.")]

[Experimental("This method has not completed Quality Assurance, and should not be used in a production environment.")] 

This feature would be particularly useful for component creators.

This would be the bees' knees.

[WarningAttribute] on UserVoice

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions