Hi,

Example that doesn't work: 
    
    
    import pegs
    
    var matches = newSeq[string]() # --> Works if using for example: 
newSeq[string](10)
    
    let
      fixedString = "cd   C:\\something\\sometimes\\someone"
      result = fixedString.match(peg"cd\s+{\D}\:", matches)
    
    if fixedString.match(peg"cd\s+{\D}\:", matches):
      echo matches [0]
    
    
    Run

How do I use pegs' " **proc match(s: string; pattern: Peg; matches: var 
openArray[string]; start = 0): bool** " without guessing the length of 
**matches**? Or is there another procedure that can be used for this?

Thanks

Reply via email to