[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] invoking external spell checker always sets modified fl
Re: [Nano-devel] invoking external spell checker always sets modified flag
Mon, 23 Feb 2015 12:07:03 -0500
On Sat, Feb 21, 2015 at 12:54:18PM +0100, Benno Schulenberg wrote:
> In Savannah the following bug was posted:
> It points out that when using an external spell checker,
> like aspell, doing a spell check will always set the file-
> -is-modified flag, even when nothing at all was changed.
> I see two possible solutions:
> 1) Get the timestamp of the created temp file, and
> check whether it changed after the spell checker has
> completed. But that requires that all spell checkers
> don't modify the temp file at all when no words were
> changed, just like aspell does. Is that a safe assumption
> to make?
This seems like a very reasonable assumption. Looking at the
equivalent formatters (e.g. gofmt), they do not seem to change
the modification time when the file isn't modified, and it doesn't
seem like they should, so this assumption seems reasonable to me.
Chris Allegretta http://www.asty.org
Description: Digital signature