model: MVirtualType::resolve_for do not resilve self is cleanup_virtual is not set
authorJean Privat <jean@pryen.org>
Fri, 21 Nov 2014 14:17:39 +0000 (09:17 -0500)
committerJean Privat <jean@pryen.org>
Tue, 2 Dec 2014 05:42:53 +0000 (00:42 -0500)
Signed-off-by: Jean Privat <jean@pryen.org>

src/model/model.nit

index f5c24dd..be8a9dc 100644 (file)
@@ -1201,6 +1201,7 @@ class MVirtualType
 
        redef fun resolve_for(mtype, anchor, mmodule, cleanup_virtual)
        do
+               if not cleanup_virtual then return self
                assert can_resolve_for(mtype, anchor, mmodule)
                # self is a virtual type declared (or inherited) in mtype
                # The point of the function it to get the bound of the virtual type that make sense for mtype