Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add template generics, with optional constraints but no [SFINAE](https://en.cppreference.com/w/cpp/language/sfinae), to Carbon. Template generics allows the compiler postpone type checking of expressions dependent on a template parameter until the function is called and the value of that parameter is known. Example usage: ```carbon fn Identity[template T:! Type](x: T) -> T { return x; } ``` Co-authored-by: Richard Smith <[email protected]> Co-authored-by: Chandler Carruth <[email protected]>
- Loading branch information