Mercurial > emacs
comparison lisp/vc-rcs.el @ 33610:32bcc6e27e02
(vc-rcs-state): Call vc-workfile-unchanged-p only here, and
differentiate according to checkout model.
(vc-rcs-fetch-master-state): Don't call vc-workfile-unchanged-p, since
this function is only concerned with master state.
author | André Spiegel <spiegel@gnu.org> |
---|---|
date | Sun, 19 Nov 2000 09:46:04 +0000 |
parents | da206bbad86b |
children | 2c1708b98891 |
comparison
equal
deleted
inserted
replaced
33609:9ac783bec98a | 33610:32bcc6e27e02 |
---|---|
3 ;; Copyright (C) 1992,93,94,95,96,97,98,99,2000 Free Software Foundation, Inc. | 3 ;; Copyright (C) 1992,93,94,95,96,97,98,99,2000 Free Software Foundation, Inc. |
4 | 4 |
5 ;; Author: FSF (see vc.el for full credits) | 5 ;; Author: FSF (see vc.el for full credits) |
6 ;; Maintainer: Andre Spiegel <spiegel@gnu.org> | 6 ;; Maintainer: Andre Spiegel <spiegel@gnu.org> |
7 | 7 |
8 ;; $Id: vc-rcs.el,v 1.11 2000/10/03 12:08:40 spiegel Exp $ | 8 ;; $Id: vc-rcs.el,v 1.12 2000/11/16 18:13:16 spiegel Exp $ |
9 | 9 |
10 ;; This file is part of GNU Emacs. | 10 ;; This file is part of GNU Emacs. |
11 | 11 |
12 ;; GNU Emacs is free software; you can redistribute it and/or modify | 12 ;; GNU Emacs is free software; you can redistribute it and/or modify |
13 ;; it under the terms of the GNU General Public License as published by | 13 ;; it under the terms of the GNU General Public License as published by |
124 (vc-file-getprop file | 124 (vc-file-getprop file |
125 'vc-workfile-version)))) | 125 'vc-workfile-version)))) |
126 (if (eq state 'up-to-date) | 126 (if (eq state 'up-to-date) |
127 (if (vc-workfile-unchanged-p file) | 127 (if (vc-workfile-unchanged-p file) |
128 'up-to-date | 128 'up-to-date |
129 'unlocked-changes) | 129 (if (eq (vc-checkout-model file) 'locking) |
130 'unlocked-changes | |
131 'edited)) | |
130 state))) | 132 state))) |
131 | 133 |
132 (defun vc-rcs-state-heuristic (file) | 134 (defun vc-rcs-state-heuristic (file) |
133 "State heuristic for RCS." | 135 "State heuristic for RCS." |
134 (let (vc-rcs-headers-result) | 136 (let (vc-rcs-headers-result) |
686 ;; not locked | 688 ;; not locked |
687 ((not locking-user) | 689 ((not locking-user) |
688 (if (or workfile-is-latest | 690 (if (or workfile-is-latest |
689 (vc-rcs-latest-on-branch-p file workfile-version)) | 691 (vc-rcs-latest-on-branch-p file workfile-version)) |
690 ;; workfile version is latest on branch | 692 ;; workfile version is latest on branch |
691 (if (eq (vc-checkout-model file) 'locking) | 693 'up-to-date |
692 'up-to-date | |
693 (require 'vc) | |
694 (if (vc-workfile-unchanged-p file) | |
695 'up-to-date | |
696 'edited)) | |
697 ;; workfile version is not latest on branch | 694 ;; workfile version is not latest on branch |
698 'needs-patch)) | 695 'needs-patch)) |
699 ;; locked by the calling user | 696 ;; locked by the calling user |
700 ((and (stringp locking-user) | 697 ((and (stringp locking-user) |
701 (string= locking-user (vc-user-login-name))) | 698 (string= locking-user (vc-user-login-name))) |