title: Can I ignore zero-length regex match in python when searching for compass directions?
body: <p>Inform 7 text adventure code can heavily feature directions such as north, south, west, east, northwest, southwest, southeast, and northeast. I am developing a code verifying script, and one of its tasks is to find instances of these words. My first try used brute force:</p>
  
  <pre><code>import re
  
  sample_line = 'The westerly barn is a room. The field is east of the barn. \
    The stable is northeast of the field. The forest is northwest of the field.'
  
  # note: this could be generated with zip and north/south'' and east/west/'', but that's another exercise.
  x = [ 'north', 'south', 'east', 'west', 'northwest', 'southwest', 'southeast', 'northeast' ]
  
  regstr = r'\b({0})\b'.format('|'.join(x))
  
  print(re.findall(regstr, sample_line))
  </code></pre>
  
  <p>This worked and gave me what I wanted: <code>[ 'east', 'northeast', 'northwest' ]</code> while ignoring <code>westerly</code>.</p>
  
  <p>I wanted to use a bit of symmetry to cut down the regex some more. But I noticed my preferred way left open the possibility of a zero-length match. So I came up with this:</p>
  
  <pre><code>regstr2 = r'\b(north|south|(north|south)?(east|west))\b'
  
  print(sample_line)
  print([x[0] for x in re.findall(regstr2, sample_line)])
  </code></pre>
  
  <p>This worked, but it felt inelegant.</p>
  
  <p>My third try, with help from <a href="https://stackoverflow.com/questions/31667068/how-can-i-exclude-zero-length-regex-matches-from-my-results/31667149#31667149">this link</a>, was:</p>
  
  <pre><code>regstr3 = r'(?=.)(\b(north|south)?(east|west)?\b)'
  
  print(sample_line)
  print([x[0] for x in re.findall(regstr3, sample_line)])
  </code></pre>
  
  <p>This gots the three directions I want, but it also got a lot of zero-length matches I'd hoped to ignore, even with the recommended (?=.).</p>
  
  <p>Is there a way Python could get a variant of <code>regstr3</code> to work? While there are obvious workarounds, it would be pleasing to have a tidy regex without a lot of repetitions and similar words.</p>