##### SUMMARY
Running ansible with `--limit a,` or `--limit a,,b` or `--limit ,` leads to (when `-vvv` is added)
```
ERROR! Unexpected Exception, this is probably a bug: string index out of range
the full traceback was:

Traceback (most recent call last):
  File ".../ansible/bin/ansible-playbook", line 123, in <module>
    exit_code = cli.run()
  File ".../ansible/lib/ansible/cli/playbook.py", line 116, in run
    CLI.get_host_list(inventory, context.CLIARGS['subset'])
  File ".../ansible/lib/ansible/cli/__init__.py", line 487, in get_host_list
    inventory.subset(subset)
  File ".../ansible/lib/ansible/inventory/manager.py", line 614, in subset
    if x[0] == "@":
IndexError: string index out of range
ERROR! Unexpected Exception, this is probably a bug: string index out of range
to see the full traceback, use -vvv
```

##### ISSUE TYPE
- Bug Report

##### COMPONENT NAME
lib/ansible/inventory/manager.py

##### ANSIBLE VERSION
```
2.9.0
```
Also happens with `devel`, and potentially older ansible versions.

##### STEPS TO REPRODUCE
Run `ansible-playbook playbook.yml --limit a,` for an existing playbook `playbook.yml` (doesn't matter what it actually does, and also does not matter whether you use `a` or a real host name). Same result with `--limit a,,b` or similar expressions where `.split(',')` will lead to an empty string in the resulting list.

##### EXPECTED RESULTS
Ansible complaining about syntax, or simply ignoring the trailing comma / empty parts of the `.split(',')`.

##### ACTUAL RESULTS
```
ERROR! Unexpected Exception, this is probably a bug: string index out of range
to see the full traceback, use -vvv
```

if not ignore_restrictions and self._restriction:
                pattern_list.extend(self._restriction)
            
            
            pattern_hash = tuple(pattern_list)
            if pattern_hash not in self._hosts_patterns_cache:
                patterns = split_host_pattern(pattern)
                hosts[:] = self._evaluate_patterns(patterns)
                
                if not ignore_limits and self._subset:
                    
                    subset_uuids = set(s._uuid for s in self._evaluate_patterns(self._subset))
                    hosts[:] = [h for h in hosts if h._uuid in subset_uuids]
                if not ignore_restrictions and self._restriction:
                    
                    hosts[:] = [h for h in hosts if h.name in self._restriction]
                self._hosts_patterns_cache[pattern_hash] = deduplicate_list(hosts)
            
            if order in ['sorted', 'reverse_sorted']:
                hosts[:] = sorted(self._hosts_patterns_cache[pattern_hash][:], key=attrgetter('name'), reverse=(order == 'reverse_sorted'))
            elif order == 'reverse_inventory':
                hosts[:] = self._hosts_patterns_cache[pattern_hash][::-1]
            else:
                hosts[:] = self._hosts_patterns_cache[pattern_hash][:]
                if order == 'shuffle':
                    shuffle(hosts)
                elif order not in [None, 'inventory']:
                    raise AnsibleOptionsError("Invalid 'order' specified for inventory hosts: %s" % order)
        return hosts
    def _evaluate_patterns(self, patterns):