reworkcss/css-stringify — pull request #41 by lydell (2014-06-02 18:21:39+00:00)
Title: Make relative applied source paths relative to CWD

When generating a source map, the paths put into the `sources` array of
the source map normally come from `pos.source` properties on the AST
nodes. These are today assumed to be relative to the current working
directory, since that’s how any original source maps are resolved and
applied.

Paths in the `sources` array can also come from applied original maps.
Relative such source paths are relative to the original source map --
not to the current working directory!

It does not make sense to mix paths that are relative to different
things. Therefore this commit makes sure that applied relative source
maps are rewritten to be relative to the current working directory, like
all other sources.

An existing test was updated to test this.