* Bad value in file-coding-system-alist
@ 2007-07-04 16:43 Lennart Borgman (gmail)
2007-07-06 8:25 ` Lennart Borgman (gmail)
` (2 more replies)
0 siblings, 3 replies; 11+ messages in thread
From: Lennart Borgman (gmail) @ 2007-07-04 16:43 UTC (permalink / raw)
To: bug-gnu-emacs
When trying to customize the variable file-coding-system-alist I get the
error
Invalid coding system: po-find-file-coding-system
(Started Emacs with "emacs -Q".)
In GNU Emacs 22.1.50.1 (i386-mingw-nt5.1.2600)
of 2007-06-17 on LENNART-69DE564
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4) --cflags -Ic:/g/include'
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: nil
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: ENU
locale-coding-system: cp1252
default-enable-multibyte-characters: t
Major mode: Custom
Minor modes in effect:
encoded-kbd-mode: t
tooltip-mode: t
tool-bar-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
unify-8859-on-encoding-mode: t
utf-translate-cjk-mode: t
auto-compression-mode: t
line-number-mode: t
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
[not found] <mailman.3064.1183567427.32220.bug-gnu-emacs@gnu.org>
@ 2007-07-05 5:12 ` Katsumi Yamaoka
0 siblings, 0 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-05 5:12 UTC (permalink / raw)
To: gnu-emacs-bug
>>>>> Lennart Borgman (gmail) wrote:
> When trying to customize the variable file-coding-system-alist I get
> the error
> Invalid coding system: po-find-file-coding-system
> (Started Emacs with "emacs -Q".)
I tried fixing it.
2007-07-05 Katsumi Yamaoka <yamaoka@jpl.org>
* cus-start.el (file-coding-system-alist): Fix custom type.
*** cus-start.el~ Sun Jul 1 21:52:18 2007
--- cus-start.el Thu Jul 5 05:03:26 2007
***************
*** 116,130 ****
mule
(alist
:key-type (regexp :tag "File regexp")
! :value-type (choice
! :value (undecided . undecided)
! (cons :tag "Encoding/decoding pair"
! :value (undecided . undecided)
! (coding-system :tag "Decoding")
! (coding-system :tag "Encoding"))
! (coding-system :tag "Single coding system"
! :value undecided)
! (function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
(completion-ignored-extensions dired
--- 116,141 ----
mule
(alist
:key-type (regexp :tag "File regexp")
! :value-type
! (choice
! :value (undecided . undecided)
! (cons :tag "Encoding/decoding pair"
! :value (undecided . undecided)
! (coding-system :tag "Decoding")
! (coding-system :tag "Encoding"))
! (coding-system
! :tag "Single coding system"
! :value undecided
! :validate
! (lambda (widget)
! (unless (or (coding-system-p (widget-value widget))
! (functionp (widget-value widget)))
! (widget-put
! widget
! :error (format "Invalid coding system: %S"
! (widget-value widget)))
! widget)))
! (function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
(completion-ignored-extensions dired
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
2007-07-04 16:43 Bad value in file-coding-system-alist Lennart Borgman (gmail)
@ 2007-07-06 8:25 ` Lennart Borgman (gmail)
2007-07-06 8:39 ` Lennart Borgman (gmail)
[not found] ` <mailman.3116.1183710309.32220.bug-gnu-emacs@gnu.org>
2 siblings, 0 replies; 11+ messages in thread
From: Lennart Borgman (gmail) @ 2007-07-06 8:25 UTC (permalink / raw)
To: bug-gnu-emacs
I have gotten exactly 0 answers to this one.
Lennart Borgman (gmail) wrote:
> When trying to customize the variable file-coding-system-alist I get the
> error
>
> Invalid coding system: po-find-file-coding-system
>
> (Started Emacs with "emacs -Q".)
>
>
>
> In GNU Emacs 22.1.50.1 (i386-mingw-nt5.1.2600)
> of 2007-06-17 on LENNART-69DE564
> Windowing system distributor `Microsoft Corp.', version 5.1.2600
> configured using `configure --with-gcc (3.4) --cflags -Ic:/g/include'
>
> Important settings:
> value of $LC_ALL: nil
> value of $LC_COLLATE: nil
> value of $LC_CTYPE: nil
> value of $LC_MESSAGES: nil
> value of $LC_MONETARY: nil
> value of $LC_NUMERIC: nil
> value of $LC_TIME: nil
> value of $LANG: ENU
> locale-coding-system: cp1252
> default-enable-multibyte-characters: t
>
> Major mode: Custom
>
> Minor modes in effect:
> encoded-kbd-mode: t
> tooltip-mode: t
> tool-bar-mode: t
> mouse-wheel-mode: t
> menu-bar-mode: t
> file-name-shadow-mode: t
> global-font-lock-mode: t
> font-lock-mode: t
> blink-cursor-mode: t
> unify-8859-on-encoding-mode: t
> utf-translate-cjk-mode: t
> auto-compression-mode: t
> line-number-mode: t
>
>
> _______________________________________________
> bug-gnu-emacs mailing list
> bug-gnu-emacs@gnu.org
> http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs
>
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
2007-07-04 16:43 Bad value in file-coding-system-alist Lennart Borgman (gmail)
2007-07-06 8:25 ` Lennart Borgman (gmail)
@ 2007-07-06 8:39 ` Lennart Borgman (gmail)
[not found] ` <mailman.3116.1183710309.32220.bug-gnu-emacs@gnu.org>
2 siblings, 0 replies; 11+ messages in thread
From: Lennart Borgman (gmail) @ 2007-07-06 8:39 UTC (permalink / raw)
To: bug-gnu-emacs
Lennart Borgman (gmail) wrote:
> When trying to customize the variable file-coding-system-alist I get the
> error
>
> Invalid coding system: po-find-file-coding-system
>
> (Started Emacs with "emacs -Q".)
file-coding-system-alist is defined in C. Its customization type
definition in cus-start.el looks like this:
(file-coding-system-alist
mule
(alist
:key-type (regexp :tag "File regexp")
:value-type (choice
:value (undecided . undecided)
(cons :tag "Encoding/decoding pair"
:value (undecided . undecided)
(coding-system :tag "Decoding")
(coding-system :tag "Encoding"))
(coding-system :tag "Single coding system"
:value undecided)
(function :value ignore))))
po-find-file-coding-system is a function. However in the customization
buffer it shows up marked as "Single coding system".
So this looks like a bug in customize.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
[not found] ` <mailman.3116.1183710309.32220.bug-gnu-emacs@gnu.org>
@ 2007-07-06 11:33 ` Katsumi Yamaoka
2007-07-06 14:41 ` Lennart Borgman (gmail)
[not found] ` <mailman.3136.1183732892.32220.bug-gnu-emacs@gnu.org>
0 siblings, 2 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-06 11:33 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: bug-gnu-emacs
>>>>> Lennart Borgman (gmail) wrote:
> I have gotten exactly 0 answers to this one.
I'm sorry to have posted a reply only to the gnu.emacs.bug
newsgroup. I'll install the following fix in the near future.
*** cus-start.el~ Sun Jul 1 21:52:18 2007
--- cus-start.el Thu Jul 5 05:03:26 2007
***************
*** 116,130 ****
mule
(alist
:key-type (regexp :tag "File regexp")
! :value-type (choice
! :value (undecided . undecided)
! (cons :tag "Encoding/decoding pair"
! :value (undecided . undecided)
! (coding-system :tag "Decoding")
! (coding-system :tag "Encoding"))
! (coding-system :tag "Single coding system"
! :value undecided)
! (function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
(completion-ignored-extensions dired
--- 116,141 ----
mule
(alist
:key-type (regexp :tag "File regexp")
! :value-type
! (choice
! :value (undecided . undecided)
! (cons :tag "Encoding/decoding pair"
! :value (undecided . undecided)
! (coding-system :tag "Decoding")
! (coding-system :tag "Encoding"))
! (coding-system
! :tag "Single coding system"
! :value undecided
! :validate
! (lambda (widget)
! (unless (or (coding-system-p (widget-value widget))
! (functionp (widget-value widget)))
! (widget-put
! widget
! :error (format "Invalid coding system: %S"
! (widget-value widget)))
! widget)))
! (function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
(completion-ignored-extensions dired
Regards,
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
2007-07-06 11:33 ` Katsumi Yamaoka
@ 2007-07-06 14:41 ` Lennart Borgman (gmail)
[not found] ` <mailman.3136.1183732892.32220.bug-gnu-emacs@gnu.org>
1 sibling, 0 replies; 11+ messages in thread
From: Lennart Borgman (gmail) @ 2007-07-06 14:41 UTC (permalink / raw)
To: Katsumi Yamaoka; +Cc: bug-gnu-emacs
Katsumi Yamaoka wrote:
>>>>>> Lennart Borgman (gmail) wrote:
>
>> I have gotten exactly 0 answers to this one.
>
> I'm sorry to have posted a reply only to the gnu.emacs.bug
> newsgroup. I'll install the following fix in the near future.
Oh, sorry, I did not know. I do not read the newsgroups. Many thanks for
taking a look at this.
But is this really the right fix? It looks to me like there is a more
general bug in customize, please see the message I sent after the one
you responded to hear.
Maybe I am missing something?
> *** cus-start.el~ Sun Jul 1 21:52:18 2007
> --- cus-start.el Thu Jul 5 05:03:26 2007
> ***************
> *** 116,130 ****
> mule
> (alist
> :key-type (regexp :tag "File regexp")
> ! :value-type (choice
> ! :value (undecided . undecided)
> ! (cons :tag "Encoding/decoding pair"
> ! :value (undecided . undecided)
> ! (coding-system :tag "Decoding")
> ! (coding-system :tag "Encoding"))
> ! (coding-system :tag "Single coding system"
> ! :value undecided)
> ! (function :value ignore))))
> (selection-coding-system mule coding-system)
> ;; dired.c
> (completion-ignored-extensions dired
> --- 116,141 ----
> mule
> (alist
> :key-type (regexp :tag "File regexp")
> ! :value-type
> ! (choice
> ! :value (undecided . undecided)
> ! (cons :tag "Encoding/decoding pair"
> ! :value (undecided . undecided)
> ! (coding-system :tag "Decoding")
> ! (coding-system :tag "Encoding"))
> ! (coding-system
> ! :tag "Single coding system"
> ! :value undecided
> ! :validate
> ! (lambda (widget)
> ! (unless (or (coding-system-p (widget-value widget))
> ! (functionp (widget-value widget)))
> ! (widget-put
> ! widget
> ! :error (format "Invalid coding system: %S"
> ! (widget-value widget)))
> ! widget)))
> ! (function :value ignore))))
> (selection-coding-system mule coding-system)
> ;; dired.c
> (completion-ignored-extensions dired
>
> Regards,
>
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
[not found] ` <mailman.3136.1183732892.32220.bug-gnu-emacs@gnu.org>
@ 2007-07-07 1:43 ` Katsumi Yamaoka
2007-07-09 0:20 ` Katsumi Yamaoka
[not found] ` <mailman.3199.1183940449.32220.bug-gnu-emacs@gnu.org>
0 siblings, 2 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-07 1:43 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: bug-gnu-emacs
>>>>> "Lennart Borgman (gmail)" <lennart.borgman@gmail.com> wrote:
> But is this really the right fix? It looks to me like there is a more
> general bug in customize, please see the message I sent after the one
> you responded to hear.
I see. Thanks. I guess the reason the `coding-system' widget
doesn't check whether the value is a coding system is for the
coding systems that are defined afterward, e.g., the ones to be
autoloaded. So, I think the right fix is to check whether the
value is not a function. A new patch is below. WDYT?
*** cus-start.el~ Tue Jul 3 14:41:31 2007
--- cus-start.el Sat Jul 7 01:41:21 2007
***************
*** 122,129 ****
:value (undecided . undecided)
(coding-system :tag "Decoding")
(coding-system :tag "Encoding"))
! (coding-system :tag "Single coding system"
! :value undecided)
(function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
--- 122,134 ----
:value (undecided . undecided)
(coding-system :tag "Decoding")
(coding-system :tag "Encoding"))
! (coding-system
! :tag "Single coding system"
! :value undecided
! :match (lambda (widget value)
! (and value
! (symbolp value)
! (not (functionp value)))))
(function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
P.S. I'm sorry I'm inactive in the net every weekend.
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
2007-07-07 1:43 ` Katsumi Yamaoka
@ 2007-07-09 0:20 ` Katsumi Yamaoka
[not found] ` <mailman.3199.1183940449.32220.bug-gnu-emacs@gnu.org>
1 sibling, 0 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-09 0:20 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: bug-gnu-emacs
>>>>> Katsumi Yamaoka wrote:
> I guess the reason the `coding-system' widget doesn't check whether
> the value is a coding system is for the coding systems that are
> defined afterward, e.g., the ones to be autoloaded.
Therefore, I modified the `coding-system' widget only for
`file-coding-system-alist' so that it may not issue an error
signal when the value is a function. Committed in both
the Emacs trunk and the EMACS_22_BASE branch.
Regards,
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
[not found] ` <mailman.3199.1183940449.32220.bug-gnu-emacs@gnu.org>
@ 2007-07-09 1:34 ` Katsumi Yamaoka
2007-07-09 19:45 ` Lennart Borgman (gmail)
[not found] ` <mailman.3234.1184010349.32220.bug-gnu-emacs@gnu.org>
0 siblings, 2 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-09 1:34 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: bug-gnu-emacs
>>>>> Katsumi Yamaoka wrote:
>> I guess the reason the `coding-system' widget doesn't check whether
>> the value is a coding system is for the coding systems that are
>> defined afterward, e.g., the ones to be autoloaded.
> Therefore, I modified the `coding-system' widget only for
> `file-coding-system-alist' so that it may not issue an error
> signal when the value is a function. Committed in both
> the Emacs trunk and the EMACS_22_BASE branch.
Oops. The fix I committed was incorrect. I've fixed it again
in the trunk and the EMACS_22_BASE branch. The following patch
for the Emacs 22.1 release represents what I did:
*** cus-start.el~ Thu Apr 12 03:05:31 2007
--- cus-start.el Mon Jul 9 01:33:47 2007
***************
*** 122,129 ****
:value (undecided . undecided)
(coding-system :tag "Decoding")
(coding-system :tag "Encoding"))
! (coding-system :tag "Single coding system"
! :value undecided)
(function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
--- 122,132 ----
:value (undecided . undecided)
(coding-system :tag "Decoding")
(coding-system :tag "Encoding"))
! (coding-system
! :tag "Single coding system"
! :value undecided
! :match (lambda (widget value)
! (and value (not (functionp value)))))
(function :value ignore))))
(selection-coding-system mule coding-system)
;; dired.c
Regards,
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
2007-07-09 1:34 ` Katsumi Yamaoka
@ 2007-07-09 19:45 ` Lennart Borgman (gmail)
[not found] ` <mailman.3234.1184010349.32220.bug-gnu-emacs@gnu.org>
1 sibling, 0 replies; 11+ messages in thread
From: Lennart Borgman (gmail) @ 2007-07-09 19:45 UTC (permalink / raw)
To: Katsumi Yamaoka; +Cc: bug-gnu-emacs
Katsumi Yamaoka wrote:
>>>>>> Katsumi Yamaoka wrote:
>
>>> I guess the reason the `coding-system' widget doesn't check whether
>>> the value is a coding system is for the coding systems that are
>>> defined afterward, e.g., the ones to be autoloaded.
>
>> Therefore, I modified the `coding-system' widget only for
>> `file-coding-system-alist' so that it may not issue an error
>> signal when the value is a function. Committed in both
>> the Emacs trunk and the EMACS_22_BASE branch.
>
> Oops. The fix I committed was incorrect. I've fixed it again
> in the trunk and the EMACS_22_BASE branch. The following patch
> for the Emacs 22.1 release represents what I did:
Are you sure this is the right fix? Is not this a general problem with
Custom?
> *** cus-start.el~ Thu Apr 12 03:05:31 2007
> --- cus-start.el Mon Jul 9 01:33:47 2007
> ***************
> *** 122,129 ****
> :value (undecided . undecided)
> (coding-system :tag "Decoding")
> (coding-system :tag "Encoding"))
> ! (coding-system :tag "Single coding system"
> ! :value undecided)
> (function :value ignore))))
> (selection-coding-system mule coding-system)
> ;; dired.c
> --- 122,132 ----
> :value (undecided . undecided)
> (coding-system :tag "Decoding")
> (coding-system :tag "Encoding"))
> ! (coding-system
> ! :tag "Single coding system"
> ! :value undecided
> ! :match (lambda (widget value)
> ! (and value (not (functionp value)))))
> (function :value ignore))))
> (selection-coding-system mule coding-system)
> ;; dired.c
>
> Regards,
>
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: Bad value in file-coding-system-alist
[not found] ` <mailman.3234.1184010349.32220.bug-gnu-emacs@gnu.org>
@ 2007-07-10 6:05 ` Katsumi Yamaoka
0 siblings, 0 replies; 11+ messages in thread
From: Katsumi Yamaoka @ 2007-07-10 6:05 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: bug-gnu-emacs
>>>>> Lennart Borgman (gmail) wrote:
> Are you sure this is the right fix? Is not this a general problem with
> Custom?
>> *** cus-start.el~ Thu Apr 12 03:05:31 2007
>> --- cus-start.el Mon Jul 9 01:33:47 2007
[...]
>> ! (coding-system
>> ! :tag "Single coding system"
>> ! :value undecided
>> ! :match (lambda (widget value)
>> ! (and value (not (functionp value)))))
Do you think the `coding-system' widget defined in wid-edit.el
should test whether the value is a coding system? If so, is it
really harmless? If it is done, we cannot use a coding system
that is defined afterward for the default value of an option for
example. Eval the following form and try customizing the
`foo-coding-system' variable.
--8<---------------cut here---------------start------------->8---
(require 'wid-edit)
(plist-put (cdr (get 'coding-system 'widget-type))
:match (lambda (widget value) (coding-system-p value)))
(defcustom foo-coding-system 'bar
"doc"
:type 'coding-system)
--8<---------------cut here---------------end--------------->8---
You will see that the value appears with the sexp form because
of the `mismatch' error. I think restricting too much is not a
good idea. Or is this not what you'd like to say?
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2007-07-10 6:05 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-04 16:43 Bad value in file-coding-system-alist Lennart Borgman (gmail)
2007-07-06 8:25 ` Lennart Borgman (gmail)
2007-07-06 8:39 ` Lennart Borgman (gmail)
[not found] ` <mailman.3116.1183710309.32220.bug-gnu-emacs@gnu.org>
2007-07-06 11:33 ` Katsumi Yamaoka
2007-07-06 14:41 ` Lennart Borgman (gmail)
[not found] ` <mailman.3136.1183732892.32220.bug-gnu-emacs@gnu.org>
2007-07-07 1:43 ` Katsumi Yamaoka
2007-07-09 0:20 ` Katsumi Yamaoka
[not found] ` <mailman.3199.1183940449.32220.bug-gnu-emacs@gnu.org>
2007-07-09 1:34 ` Katsumi Yamaoka
2007-07-09 19:45 ` Lennart Borgman (gmail)
[not found] ` <mailman.3234.1184010349.32220.bug-gnu-emacs@gnu.org>
2007-07-10 6:05 ` Katsumi Yamaoka
[not found] <mailman.3064.1183567427.32220.bug-gnu-emacs@gnu.org>
2007-07-05 5:12 ` Katsumi Yamaoka
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.