ZyX_I avatar ZyX_I committed fb41e7f

@/fwc: Fixed {prefixes}+{next} completion:
it added variants from {next} section to prefix arguments

Comments (0)

Files changed (2)

plugin/frawor/fwc/topconstructs.vim

                 call self.addif(idxdiffstr.'=='.i)
                 call        self.compilearg(args[i-1], idx.self.string(prefix),
                             \            a:type)
+                call        self.increment(a:caidxstr, idxdiffstr)
                 call        self.break()
                 call self.up()
             endfor
     let addedsavemsgs=a:addedsavemsgs
     let hasnext=s:F.hasnext(a:adescr, 'next')
     if a:type is# 'complete'
-        let condition=a:largsstr.'>='.self.getlastsub()
+        let condition=a:largsstr.'>'.self.getlastsub()
         if self.onlyfirst
             let condition=a:largsstr.'-1 == '.self.getlastsub()
         endif

test/fwccompletetests.dat

 
   @d
   def-b
+
+  @foo+
+  =s:list
 #▶2 {optional}+{next}
 `[in list] + in list2
   @+
 
   @abc+
   allfolds noallfolds
-# vim: cms=#%s fmr=▶,▲ sw=2 ts=2 sts=2 et ft=conf
 #▶1 Messages
 :let s:_messages={'test': 'Test message'}
 `(in list #test match /^a/)
 `(#test in list match /^a/)
   @+
   =filter(copy(s:list), 'v:val[0] is "a"')
+# vim: cms=#%s fmr=▶,▲ sw=2 ts=2 sts=2 et ft=conf
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.