code: func (p *Parser) parse() (internalSelector, error) {
  	p.scan() // init scannedItems
  
  	var requirements internalSelector
  	for {
  		tok, lit := p.lookahead(Values)
  		switch tok {
  		case IdentifierToken, DoesNotExistToken:
  			r, err := p.parseRequirement()
  			if err != nil {
  				return nil, fmt.Errorf("unable to parse requirement: %v", err)
  			}
  			requirements = append(requirements, *r)
  			t, l := p.consume(Values)
  			switch t {
  			case EndOfStringToken:
  				return requirements, nil
  			case CommaToken:
  				t2, l2 := p.lookahead(Values)
  				if t2 != IdentifierToken && t2 != DoesNotExistToken {
  					return nil, fmt.Errorf("found '%s', expected: identifier after ','", l2)
  				}
  			default:
  				return nil, fmt.Errorf("found '%s', expected: ',' or 'end of string'", l)
  			}
  		case EndOfStringToken:
  			return requirements, nil
  		default:
  			return nil, fmt.Errorf("found '%s', expected: !, identifier, or 'end of string'", lit)
  		}
  	}
  }
docs: // parse runs the left recursive descending algorithm
  // on input string. It returns a list of Requirement objects.