Commits

ZyX_I committed 5034b6a

Added comments

Comments (0)

Files changed (1)

plugin/frawor.vim

 function s:F.loadplugin(plid)
     "▶2 Get plugdict
     if type(a:plid)==type("")
+        "▶3 Checking for empty plid
         if empty(a:plid)
             call s:F._frawor.throw('plidempty')
         endif
+        "▶3 Checking whether plugin is already being loaded
         if has_key(s:g.loading, a:plid)
             return 2
         endif
+        "▲3
         if !has_key(s:g.pls, a:plid)
             execute 'runtime! '.fnameescape(a:plid.'.vim')
         endif
+        "▶3 Checking whether plugin was successfully loaded
         if !has_key(s:g.pls, a:plid)
             return 0
         endif
+        "▲3
         let plugdict=s:g.pls[a:plid]
+    "▶3 Processing dictionary supplied instead of plugin ID
     elseif type(a:plid)==type({})
         if has_key(a:plid, 'id') && type(a:plid.id)==type("") &&
                     \has_key(s:g.pls, a:plid.id) && s:g.pls[a:plid.id] is a:plid
         else
             call s:F._frawor.throw('invplugdict')
         endif
+    "▶3 Error: plid type unknown
     else
         call s:F._frawor.throw('invloadarg')
     endif
             if !plugdict.oneload
                 execute 'source '.fnameescape(plugdict.file)
             endif
+            "▶2 Modifying plugdict status
             let plugdict.status=2
             lockvar! plugdict.status
             "▶2 Adding features to already loaded plugins