This project is read-only.

JSON type.

Topics: Language Specification
Jun 30, 2013 at 9:07 AM
I was just wondering if it would be possible to get a JSON type keyword?
It would be similar to any but it would stop you from trying to call (non array) functions on values that are only going to be objects, arrays or primitives, and all properties of a JSON type should be automatically cast to JSON (just as properties of an any object are cast to any).

It should probably also prevent you from casting values straight to functions and other JSON illegal variables without them first being cast to any.