update NOTICE and LICENSE
[nit.git] / tests / base_closure_default3.nit
index d45c397..91a4149 100644 (file)
@@ -18,11 +18,15 @@ import kernel
 
 class A
        fun foo
-               with bar: Int do
+               !bar: Int do
+                       if maybe then
                        #alt1# return
                        #alt2# return 1
                        #alt3# abort
                        #alt4# continue
+                       #alt6# break 1
+                       end
+                       #alt5# break
                        continue 20 #!alt5#
                end
        do
@@ -32,9 +36,11 @@ class A
        end
 end
 
+fun maybe: Bool do return true
+
 var a = new A
 0.output
-a.foo with do continue 2
+a.foo !bar do continue 2
 0.output
 a.foo
 0.output