RiotGames/solve — pull request #22 by rymai (2013-06-27 22:02:07+00:00)
Title: Pre-release versions should satisfy non-pre-release versions

Hi,

it seems that RiotGames/solve@47c4bda5fda0eaebd01baac69b168ff7adfdab6a introduced a change that is not right IMO. This commit says that a pre-release version cannot satisfy a constraint that does not contain a pre-release version:

```ruby
subject { Solve::Constraint.new("<= 1.0.0") }

it { should_not satisfies("1.0.0-alpha") }
```

We used to solve without any specific version constraint but now I have to set the `>= 0.0.0-alpha` version constraint for all `demands` if I want the old behavior.

The issue is that on [semver.org](http://semver.org), it's said that:

> Pre-release versions satisfy but have a lower precedence than the associated normal version. Examples: 1.0.0-alpha, 1.0.0-alpha.1, 1.0.0-0.3.7, 1.0.0-x.7.z.92.

So I think this change was wrong, according to the specs `1.0.0-alpha` should satisfy `<= 1.0.0`. What do you think?

/cc @thibaudgg