This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns n01se.externs-for-cljs | |
(:require [clojure.java.io :as io] | |
[cljs.compiler :as comp] | |
[cljs.analyzer :as ana])) | |
(defn read-file [file] | |
(let [eof (Object.)] | |
(with-open [stream (clojure.lang.LineNumberingPushbackReader. (io/reader file))] | |
(vec (take-while #(not= % eof) | |
(repeatedly #(read stream false eof))))))) |