Workaround for complexType parsing
This commit is contained in:
@@ -254,6 +254,10 @@ class BasicTestCase extends Test {
|
||||
function testRest() {
|
||||
_testRest();
|
||||
}
|
||||
|
||||
function testTypeParsing() {
|
||||
_testTypeParsing();
|
||||
}
|
||||
}
|
||||
|
||||
class BasicObject {
|
||||
|
@@ -370,4 +370,16 @@
|
||||
(Assert.equals 15 (last myList)))
|
||||
|
||||
(defun _testRest []
|
||||
(Assert.equals (.toString [2 3 4]) (.toString (rest [1 2 3 4]))))
|
||||
(Assert.equals (.toString [2 3 4]) (.toString (rest [1 2 3 4]))))
|
||||
|
||||
(defun doSomething [:Int->Int func]
|
||||
(func 5))
|
||||
|
||||
(defun itsAMonster [:Null<Map<String,Map<String,Array<String>>>> monsterArg] "but it still compiles")
|
||||
|
||||
(defun _testTypeParsing []
|
||||
// Do stuff with functions that take complex type parameters, mostly just to check if it compiles
|
||||
(Assert.equals 5 (doSomething (lambda [i] i)))
|
||||
(Assert.equals 7 (doSomething (lambda [i] (+ i 2))))
|
||||
// Pass null to the really crazy one because I'm lazy:
|
||||
(Assert.equals "but it still compiles" (itsAMonster null)))
|
Reference in New Issue
Block a user