Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

forall notation: what does the period / dot mean?

What does the period / dot mean?

forall a. Num a => a -> a -> a

Is it merely a separator?

like image 272
M. Walker Avatar asked Sep 09 '17 23:09

M. Walker


1 Answers

Yes, it's just a syntactic separator. It separates variable declarations from variable usages, just like the -> in a lambda expression. It means "Here endeth the binders". I suppose the language designers went for . because it's 22 characters shorter.

like image 83
Benjamin Hodgson Avatar answered Oct 18 '22 07:10

Benjamin Hodgson