common.js 388 B

123456789101112131415161718192021222324252627
  1. // Copyright 2014 Simon Lydell
  2. // X11 (“MIT”) Licensed. (See LICENSE.)
  3. function u(url) {
  4. return "code\n/*# sourceMappingURL=" + url + " */"
  5. }
  6. function read(x) {
  7. return function() {
  8. return x
  9. }
  10. }
  11. function Throws(x) {
  12. throw new Error(x)
  13. }
  14. function identity(x) {
  15. return x
  16. }
  17. module.exports = {
  18. u: u,
  19. read: read,
  20. Throws: Throws,
  21. identity: identity
  22. }