bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #30116] (guile) introduces a cycle in the submodules subtree


From: Jose Antonio Ortega Ruiz
Subject: [bug #30116] (guile) introduces a cycle in the submodules subtree
Date: Fri, 11 Jun 2010 15:31:15 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100501 Conkeror/0.9.2 (Debian-0.9.2+git100611-~nightlybuild1276207621)

URL:
  <http://savannah.gnu.org/bugs/?30116>

                 Summary: (guile) introduces a cycle in the submodules
subtree
                 Project: Guile
            Submitted by: jao
            Submitted on: Fri 11 Jun 2010 03:31:13 PM GMT
                Category: None
                Severity: 3 - Normal
              Item Group: None
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

Define the auxiliary procedure:

   (define (submodules m) 
     (hash-map->list list (module-submodules m)))

which just extracts a list of submodules of `m'. Now apply it to the '(guile)
module:

   (define gm (resolve-module '(guile) #f))

   (submodules m)

this evaluates to a duplicate submodule with different names:

   ((%app #<module (%app) 84e7c60>) (app #<module (%app) 84e7c60>))

Asking for the submodules of either one of those gives:

   (define (submodules* m) (cdr (submodules m)))
   (submodules* (car (submodules* m)) => (#<module () 84e7ea0>)

and getting the submodules of this last one, one obtains the list of top
level modules, which again includes `gm'. That means that the module tree
isn't actually a tree, but a DAG, which sounds weird to me (and will most
probably provoke infinite loops in module folders).

Also, the duplicated submodule of '(guile) seems an implementation detail
accidentally leaked (hiding it would break the cycle).

   
   
   




    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?30116>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]