Skip to content

Allow common types in attribute values (nullable, decimal) #4525

@GSPP

Description

@GSPP

Values in attributes currently do not support nullable values. That is annoying because it forces us back to obsolete techniques used pre-.NET-2.0. Decimal support also would be nice.

Maybe we can even have a general way we can add "JSON-like" object trees. e.g.

[ActionMethod(
  name: "abc",
  routes: new [] { "/a", "/b" },
  connectionString: new ConnectionString() { Server = "s", Port = 42 })]

I hope you get what I mean. I made up a contrived, yet plausible, example.

That way we can have very high generality in attributes. We no longer need to make up rules and add piecemeal support for certain things.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-TypeSystem-coreclrenhancementProduct code improvement that does NOT require public API changes/additions

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions