Skip to content

"Address of" operation on generic functions with type parameters #559

Open
@Prabhuk

Description

@Prabhuk

Generic functions in Checked C accept type parameters. There are two function specifiers that can be used for this.

  • _Itype_for_any (<COMMA_SEPARATED_TYPE_VARIABLES>)
  • _For_any(<COMMA_SEPARATED_TYPE_VARIABLES>)

e.g.
_Itype_for_any(T1, T2) void * myfunction(void * param1 : itype(_Ptr),
void * param2 : itype(_Ptr)
) : itype(_Ptr);

Currently, the "address of" operation can be performed on these functions without type parameters. This produces a value with generic function types.

e.g.
genericFunctionPointerVariable = &myfunction;

We must be able to supply concrete type parameters along with the address of operations.

e.g.
integerFunctionPointerVariable = &myfunction<int, int>

Metadata

Metadata

Assignees

No one assigned

    Labels

    future workThis labels issues that need further triaging and discussion.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions