Hacker News new | ask | show | jobs
by t1m 3388 days ago
I wrote a language called T for Bell Northern Research, not knowing there was already another T language based on Scheme. The language was used for black box testing testing of terminal interfaces, and so needed good string handling.

One aspect of the language was that Unix regular expressions were a built-in type, and so were associate arrays. These two features worked together in a cool way:

  x['hi there'] = 5
  x['hello'] = 2

  # regular expressions are enclosed in `backquotes`
  x[`hell.`] == [2]
  x[`h.*`] == [5, 2]