Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- template<class A, class B>
- class Pair{
- A fst;
- B snd;
- }
- template<class A, class B>
- A get_fst(Pair<A,B> p){
- return p.fst;
- }
- void main(){
- Pair<()->i32, i32> p{() => 42, 17};
- auto x = get_fst(p);
- // does this compile?
- // whats the type of x?
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement