Index: test/mjsunit/call-non-function.js |
=================================================================== |
--- test/mjsunit/call-non-function.js (revision 2334) |
+++ test/mjsunit/call-non-function.js (working copy) |
@@ -51,4 +51,13 @@ |
TryCall("hest"); |
- |
+// Make sure that calling a non-function global doesn't crash the |
+// system while building the IC for it. |
+var NonFunction = 42; |
+function WillThrow() { |
+ NonFunction(); |
+} |
+assertThrows(WillThrow); |
+assertThrows(WillThrow); |
+assertThrows(WillThrow); |
+assertThrows(WillThrow); |