From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?ISO-8859-15?Q?Andreas_R=F6hler?= Newsgroups: gmane.emacs.devel Subject: Re: nxml maintainer? Date: Sat, 11 May 2013 08:47:04 +0200 Message-ID: <518DE968.5010900@online.de> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1368254694 8913 80.91.229.3 (11 May 2013 06:44:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 11 May 2013 06:44:54 +0000 (UTC) Cc: Stefan Monnier To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat May 11 08:44:54 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Ub3Y4-0007Th-6f for ged-emacs-devel@m.gmane.org; Sat, 11 May 2013 08:44:52 +0200 Original-Received: from localhost ([::1]:60011 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ub3Y3-0002ei-SG for ged-emacs-devel@m.gmane.org; Sat, 11 May 2013 02:44:51 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:41771) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ub3Xy-0002eY-Tf for emacs-devel@gnu.org; Sat, 11 May 2013 02:44:49 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ub3Xw-0003b7-Oe for emacs-devel@gnu.org; Sat, 11 May 2013 02:44:46 -0400 Original-Received: from moutng.kundenserver.de ([212.227.17.8]:60922) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ub3Xw-0003ay-9A for emacs-devel@gnu.org; Sat, 11 May 2013 02:44:44 -0400 Original-Received: from [192.168.178.21] (brln-4dbc6de0.pool.mediaWays.net [77.188.109.224]) by mrelayeu.kundenserver.de (node=mrbap0) with ESMTP (Nemesis) id 0LviEG-1UT80j2eA0-017Xwq; Sat, 11 May 2013 08:44:42 +0200 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130329 Thunderbird/17.0.5 In-Reply-To: X-Provags-ID: V02:K0:GRk0gANsuJqgdOG1nT06m8rkxnI5PKwGeI3vmo+thHO vojOF6sqdkVPw8Ngq3KBAOZ0pHefJRkLFaQQon/r2bdJYvZP9J WunYXYsBqDllzU3zltB7RDzA6464DF+1pIgHVWEc4Xf8Z0mBr0 N0nfuu6CGuw3TItdj/GRaE8zIKtXCh1RK7jI9239PVg1eMXjJ/ GiiInY9kRVPPRLNd77gxPiDs7m/wKC32LKCQOh0UiuU67wVW+3 yVmiluDxsV9Au4FzJX62gbJyzCZ55Q+tDnyQ8bWAKzedSVX0Na nInF/sCg6O1oHXWC5qQf4ycV1xlvRtSBFVzAWWV/aPBIgSbtKf jGCG7Mc3NvvJ5Zp12PBQ3swhyJDN929JAd5s7ERyi X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 212.227.17.8 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:159496 Archived-At: Am 10.05.2013 19:25, schrieb Stefan Monnier: > I'd like to install the patch below, which removes a "feature" which > I find dubious: it's a lot of code just to provide a behavior which is > not clearly superior. > > The behavior in question is to treat an unmatched rather than to consider that the matching ?> is "somewhere after > point-max". > > > Stefan > > > === modified file 'lisp/nxml/nxml-mode.el' > --- lisp/nxml/nxml-mode.el 2013-03-23 02:21:25 +0000 > +++ lisp/nxml/nxml-mode.el 2013-05-09 22:42:47 +0000 > @@ -352,11 +352,6 @@ > See the function `xmltok-forward-prolog' for more information.") > (make-variable-buffer-local 'nxml-prolog-regions) > > -(defvar nxml-last-fontify-end nil > - "Position where fontification last ended. > -It is nil if the buffer changed since the last fontification.") > -(make-variable-buffer-local 'nxml-last-fontify-end) > - > (defvar nxml-degraded nil > "Non-nil if currently operating in degraded mode. > Degraded mode is enabled when an internal error is encountered in the > @@ -538,7 +533,6 @@ > (save-excursion > (save-restriction > (widen) > - (nxml-clear-dependent-regions (point-min) (point-max)) > (setq nxml-scan-end (copy-marker (point-min) nil)) > (with-silent-modifications > (nxml-clear-inside (point-min) (point-max)) > @@ -583,12 +577,9 @@ > ;; Clean up fontification. > (save-excursion > (widen) > - (let ((inhibit-read-only t) > - (buffer-undo-list t) > - (modified (buffer-modified-p))) > + (with-silent-modifications > (nxml-with-invisible-motion > - (remove-text-properties (point-min) (point-max) '(face))) > - (set-buffer-modified-p modified))) > + (remove-text-properties (point-min) (point-max) '(face))))) > (remove-hook 'change-major-mode-hook 'nxml-cleanup t)) > > (defun nxml-degrade (context err) > @@ -638,10 +629,6 @@ > For bookkeeping, call this function even when fontification is > disabled." > (let ((pre-change-end (+ start pre-change-length))) > - (setq start > - (nxml-adjust-start-for-dependent-regions start > - end > - pre-change-length)) > ;; If the prolog might have changed, rescan the prolog > (when (<= start > ;; Add 2 so as to include the < and following char that > @@ -902,8 +889,7 @@ > > (defun nxml-extend-after-change-region (start end pre-change-length) > (unless nxml-degraded > - (setq nxml-last-fontify-end nil) > - (let ((region (nxml-with-degradation-on-error > + (nxml-with-degradation-on-error > 'nxml-extend-after-change-region > (save-excursion > (save-restriction > @@ -911,17 +897,8 @@ > (save-match-data > (nxml-with-invisible-motion > (with-silent-modifications > - (nxml-extend-after-change-region1 > + (nxml-after-change1 > start end pre-change-length))))))))) > - (if (consp region) region)))) > - > -(defun nxml-extend-after-change-region1 (start end pre-change-length) > - (let* ((region (nxml-after-change1 start end pre-change-length)) > - (font-lock-beg (car region)) > - (font-lock-end (cdr region))) > - > - (nxml-extend-region) > - (cons font-lock-beg font-lock-end))) > > (defun nxml-fontify-matcher (bound) > "Called as font-lock keyword matcher." > @@ -936,13 +913,12 @@ > (nxml-fontify-prolog) > (goto-char nxml-prolog-end)) > > - (let (xmltok-dependent-regions > - xmltok-errors) > + (let (xmltok-errors) > (while (and (nxml-tokenize-forward) > (<= (point) bound)) ; Intervals are open-ended. > (nxml-apply-fontify-rule))) > > - (setq nxml-last-fontify-end (point))) > + ) > > ;; Since we did the fontification internally, tell font-lock to not > ;; do anything itself. > > === modified file 'lisp/nxml/nxml-rap.el' > --- lisp/nxml/nxml-rap.el 2013-03-23 02:21:25 +0000 > +++ lisp/nxml/nxml-rap.el 2013-05-09 22:37:06 +0000 > @@ -69,18 +69,6 @@ > ;; typical proportion of comments, CDATA sections and processing > ;; instructions is small relative to other things. Secondly, to scan > ;; we just search for the regexp <[!?]. > -;; > -;; One problem is unclosed comments, processing instructions and CDATA > -;; sections. Suppose, for example, we encounter a . This is not an unexpected situation if the user is > -;; creating a comment. It is not helpful to treat the whole of the > -;; file starting from the gets added to the buffer after the unclosed ") > - (xmltok-add-dependent 'xmltok-unclosed-reparse-p > - nil > - nil > - ;; not --> because > - ;; -- is not allowed > - ;; in comments in XML > - "--") > - 'not-well-formed) > - ((eq (char-after) ?>) > + (cond ((or (eq (char-after) ?>) (not found--)) > (goto-char (1+ (point))) > 'comment) > (t > - (xmltok-add-dependent > - 'xmltok-semi-closed-reparse-p > - nil > - (point) > - "--" > - 2) > ;; just include the