Permalink
Fetching contributors…
Cannot retrieve contributors at this time
24 lines (17 sloc) 508 Bytes
use(require("core"))
use(require("define"))
use(require("quotes"))
use(require("control-flow"))
use(require("mutation"))
interpolate = require("interpolation")
macro-quoter(r) [r, fs]:
flags = 0
when(fs include?(.m)):
flags |= Regexp MULTILINE
when(fs include?(.i)):
flags |= Regexp IGNORECASE
when(fs include?(.x)):
flags |= Regexp EXTENDED
-- UTF8 by default
flags |= Regexp KCODE_UTF8
`(//Regexp new(~(interpolate interpolated(r)), ~(Atomy Grammar AST Number new(flags))))