Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

First-class everything

Name: Anonymous 2012-03-09 18:57

Do any programming languages have everything as first-class citizens? This includes not only functions, but types, classes, etc. too. Having everything first-class can be a flexible and non-kludgy alternative to generics/templates.

Name: Anonymous 2012-03-10 16:47

>>19
true, but not necessarily syntacically convenient, and support from the compiler for the same sort of capabilities could (in some cases) be more type safe.

Name: >>24 2012-03-10 17:09

nevermind about the type safety. With that kind of generality you kind of have to give up on that. But the syntax would be nice I guess. I could see it being similar to pattern matching syntax of ocaml and friends, where matching a variable with a parameterized type would allow you to extract the parameters used in the type.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List