Created
March 11, 2013 03:00
-
-
Save bendlas/5131615 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
From 85fd5c4f3c20c1a557c2da7d06b0c1b41e9533f9 Mon Sep 17 00:00:00 2001 | |
From: Herwig Hochleitner <[email protected]> | |
Date: Mon, 11 Mar 2013 03:57:43 +0100 | |
Subject: [PATCH] Throw exception instead of trying to throw string in | |
defmulti compiler macro | |
--- | |
src/clj/cljs/core.clj | 2 +- | |
1 file changed, 1 insertion(+), 1 deletion(-) | |
diff --git a/src/clj/cljs/core.clj b/src/clj/cljs/core.clj | |
index 17285c9..b58e4a2 100644 | |
--- a/src/clj/cljs/core.clj | |
+++ b/src/clj/cljs/core.clj | |
@@ -1152,7 +1152,7 @@ | |
(conj (meta mm-name) m) | |
m)] | |
(when (= (count options) 1) | |
- (throw "The syntax for defmulti has changed. Example: (defmulti name dispatch-fn :default dispatch-value)")) | |
+ (throw (Exception. "The syntax for defmulti has changed. Example: (defmulti name dispatch-fn :default dispatch-value)"))) | |
(let [options (apply hash-map options) | |
default (core/get options :default :default)] | |
(check-valid-options options :default :hierarchy) | |
-- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment