all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* re:¿äûÇϽŠÀÚ·áÀÔ´Ï´Ù.
@ 2002-04-01  7:39 °í°´Áö¿øÆÀ
  0 siblings, 0 replies; 246+ messages in thread
From: °í°´Áö¿øÆÀ @ 2002-04-01  7:39 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 348 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:Àú ¿¹¿ä..
@ 2002-04-04 22:49 Áö¿µ
  0 siblings, 0 replies; 246+ messages in thread
From: Áö¿µ @ 2002-04-04 22:49 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 528 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:ȸ½ÅÇÕ´Ï´Ù.
@ 2002-04-10 11:41 ¿¬Áö
  0 siblings, 0 replies; 246+ messages in thread
From: ¿¬Áö @ 2002-04-10 11:41 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 528 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2002-06-10 22:22 Emiliano La Licata
  0 siblings, 0 replies; 246+ messages in thread
From: Emiliano La Licata @ 2002-06-10 22:22 UTC (permalink / raw)


confirm 785958

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2002-10-18 18:30 Josep Maria
  0 siblings, 0 replies; 246+ messages in thread
From: Josep Maria @ 2002-10-18 18:30 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/plain, Size: 2108 bytes --]

Untitled Document
     
        
            Problemas de seguridad de Outlook Express: sale otro parche.


                  
            La vulnerabilidad encontrada es bastante seria y permite a los hackers o bien bloquear el funcionamiento del programa, o lo que es peor, ejecutar un código cualquiera en la máquina..






             Casio CW-100: nueva impresora térmica para discos CD/DVD.

             ¿Será la frecuencia funcional recomendada del NV30 igual a 400 MHz?

             Sistema acústico SP 53 de 5.1 canales de ABIT: especificaciones y precios.
            Los paleontólogos por primera vez obtienen una momia de un dinosaurio en condiciones óptimas.


                  
            El cadaver momificado del dinosaurio, que estuvo enterrado debajo de la tierra durante 77 millones de años, fue encontrado al norte del estado de Montana, nos cuenta Nationalgeografic.com. El hallazgo lo llamaron Leonardo en honor a un graffiti pintado cerca (Leonard Webb and Geneva Jordan, 1917). Leonardo es un dinosaurio ...







             A los pobladores de Alaska les aterroriza un pterodáctilo gigante.

             El tratamiento genético contra la calvicie hará que el pelo brille con colores amarillo, verde, azul o rojo.

             La estación espacial sigue en obras.
           
             
            Mecano Lego: estructuras en cuatro dimensiones.


                  
            Hay gente que afirma ser constructores profesionales de mecano. Estas afirmaciones afectan sobre todo los famoso mecanos Lego. Asimismo, un hombre llamado Andrew Lipson afirma ser el professional nerd. De su arte vamos a hablar hoy...



             
            Clonacion humana es imposible, pero inevitable.


                  
            Hoy en dia, cuando ya se sabe que ir y hacer un ejercito de clones - casihumanos idénticos - es imposible, la situación de la clonación humana es precaria. No podemos esperar nada sensacional, pero...




             
           
            www.xtio.com
           
      
     


[-- Attachment #1.2: Type: text/html, Size: 12416 bytes --]

[-- Attachment #2: zero.gif --]
[-- Type: image/gif, Size: 43 bytes --]

[-- Attachment #3: enov.gif --]
[-- Type: image/gif, Size: 1120 bytes --]

[-- Attachment #4: xnov.gif --]
[-- Type: image/gif, Size: 1181 bytes --]

[-- Attachment #5: 3605.jpg --]
[-- Type: image/jpeg, Size: 3131 bytes --]

[-- Attachment #6: verccompl4.gif --]
[-- Type: image/gif, Size: 857 bytes --]

[-- Attachment #7: ball.gif --]
[-- Type: image/gif, Size: 145 bytes --]

[-- Attachment #8: 3589.jpg --]
[-- Type: image/jpeg, Size: 2082 bytes --]

[-- Attachment #9: clocas.gif --]
[-- Type: image/gif, Size: 388 bytes --]

[-- Attachment #10: cienciad.gif --]
[-- Type: image/gif, Size: 445 bytes --]

[-- Attachment #11: 3386.jpg --]
[-- Type: image/jpeg, Size: 4118 bytes --]

[-- Attachment #12: 3316.jpg --]
[-- Type: image/jpeg, Size: 2631 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-03-11 11:22 Romia Fersi
  0 siblings, 0 replies; 246+ messages in thread
From: Romia Fersi @ 2004-03-11 11:22 UTC (permalink / raw)


Help-gnu-emacs
Usted sabe que si su sitio web esta indexado en buscadores
USTED VENDE MAS

Pero de nada sirve aparecer en el puesto 24.728 de Google o Yahoo...

Si quiere que su web este en los PRIMEROS LUGARES
de la mayoria de los buscadores...

ESTE MAIL ES PARA USTED

Creamos PAGINAS ESPEJO para hacer subir su web hasta el Top del Ranking

Para mas informacion visite la seccion PAGINAS ESPEJO en
http://www.publicidadglobal.com.ar

Este mail se envia por unica vez a help-gnu-emacs@gnu.org
No hace falta removerse.
Gracias Help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-04-21 11:56 Роман
  0 siblings, 0 replies; 246+ messages in thread
From: Роман @ 2004-04-21 11:56 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3748 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-11 23:06 Пыжьева Эмилия
  0 siblings, 0 replies; 246+ messages in thread
From: Пыжьева Эмилия @ 2004-05-11 23:06 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 686 bytes --]

[-- Attachment #1.2: vkeyamfe.jpg --]
[-- Type: image/jpeg, Size: 4814 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-12  0:59 Манякина Наталья
  0 siblings, 0 replies; 246+ messages in thread
From: Манякина Наталья @ 2004-05-12  0:59 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 724 bytes --]

[-- Attachment #1.2: ppxbgvut.jpg --]
[-- Type: image/jpeg, Size: 6124 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-12 16:50 Сеткова Лора
  0 siblings, 0 replies; 246+ messages in thread
From: Сеткова Лора @ 2004-05-12 16:50 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 9318 bytes --]

[-- Attachment #1.2: fvundkcw.jpg --]
[-- Type: image/jpeg, Size: 6891 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-12 16:50 Рютина Ева
  0 siblings, 0 replies; 246+ messages in thread
From: Рютина Ева @ 2004-05-12 16:50 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 9318 bytes --]

[-- Attachment #1.2: ntqbaeqb.jpg --]
[-- Type: image/jpeg, Size: 6891 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-12 18:20 Аниськина Мария
  0 siblings, 0 replies; 246+ messages in thread
From: Аниськина Мария @ 2004-05-12 18:20 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 9318 bytes --]

[-- Attachment #1.2: vzqpulrn.jpg --]
[-- Type: image/jpeg, Size: 4385 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-15  1:06 Лазлова Виктория
  0 siblings, 0 replies; 246+ messages in thread
From: Лазлова Виктория @ 2004-05-15  1:06 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 614 bytes --]

[-- Attachment #1.2: fpocwtwz.jpg --]
[-- Type: image/jpeg, Size: 5447 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* RE:
@ 2004-05-15 18:05 juliy
  0 siblings, 0 replies; 246+ messages in thread
From: juliy @ 2004-05-15 18:05 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 13122 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* RE:
@ 2004-05-15 21:46 juli
  0 siblings, 0 replies; 246+ messages in thread
From: juli @ 2004-05-15 21:46 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 13173 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-16  6:16 Липинская Анна
  0 siblings, 0 replies; 246+ messages in thread
From: Липинская Анна @ 2004-05-16  6:16 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 537 bytes --]

[-- Attachment #1.2: jbvrizxl.jpg --]
[-- Type: image/jpeg, Size: 4516 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-22 11:30 Боровистова Эльза
  0 siblings, 0 replies; 246+ messages in thread
From: Боровистова Эльза @ 2004-05-22 11:30 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 646 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-23  5:34 Горемыкина Оксана
  0 siblings, 0 replies; 246+ messages in thread
From: Горемыкина Оксана @ 2004-05-23  5:34 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 734 bytes --]

[-- Attachment #2: Type: text/plain, Size: 148 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-24  1:55 Резенкова Надежда
  0 siblings, 0 replies; 246+ messages in thread
From: Резенкова Надежда @ 2004-05-24  1:55 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 728 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-05-31  4:05 Будищева Сабина
  0 siblings, 0 replies; 246+ messages in thread
From: Будищева Сабина @ 2004-05-31  4:05 UTC (permalink / raw)


В Бюро e-mail рассылок требуются менеджеры по работе с клиентами в крупных городах России и СНГ.
Обязательные  требования к кандидатам:
1. Наличие сотового телефона.
2. Опыт работы менеджером в любой сфере деятельности.
3. Минимальные знания банковских операций (перевод денежных средств, желательно наличие счета в банке, знание webmoney).
4. Знание Интернет (e-mail, ICQ).
5. Знание HTML
6. Деловые качества: Вежливость, общительность, решительность и оперативность.
7. Возраст 23-35 лет.

ПО ВОПРОСАМ СОТРУДНИЧЕСТВА ПРОСЬБА ОБРАЩАТЬСЯ ТОЛЬКО ПО - ICQ 349071146




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-06  7:43 Валерий Ланшаков
  0 siblings, 0 replies; 246+ messages in thread
From: Валерий Ланшаков @ 2004-06-06  7:43 UTC (permalink / raw)


Предлагаем Базы Данных фирм и e-mail адресов для организации электронной 
коммерции на предприятии и ведения бизнеса в сети.
подробности на сайте   http://allbases.7p.org.uk/ 





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-06 16:08 Щербухина Вероника
  0 siblings, 0 replies; 246+ messages in thread
From: Щербухина Вероника @ 2004-06-06 16:08 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3492 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-10 15:15 Валерий Ланшаков
  0 siblings, 0 replies; 246+ messages in thread
From: Валерий Ланшаков @ 2004-06-10 15:15 UTC (permalink / raw)


Предлагаем Базы Данных фирм и e-mail адресов для организации электронной 
коммерции на предприятии и ведения бизнеса в сети.
подробности на сайте   http://databasez.p8.org.uk/ 





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-10 22:33 Чагинова Снежана
  0 siblings, 0 replies; 246+ messages in thread
From: Чагинова Снежана @ 2004-06-10 22:33 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 807 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-11 18:58 Валерий Ланшаков
  0 siblings, 0 replies; 246+ messages in thread
From: Валерий Ланшаков @ 2004-06-11 18:58 UTC (permalink / raw)


Предлагаем Базы Данных фирм и e-mail адресов для организации электронной 
коммерции на предприятии и ведения бизнеса в сети.
подробности на сайте   http://databasez.8bit.co.uk/ 





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-13  3:14 Язикова Изабелла
  0 siblings, 0 replies; 246+ messages in thread
From: Язикова Изабелла @ 2004-06-13  3:14 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3702 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-06-26  5:49 Востросаблина Карина
  0 siblings, 0 replies; 246+ messages in thread
From: Востросаблина Карина @ 2004-06-26  5:49 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 464 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-20 13:15 Vhdl-mode
  0 siblings, 0 replies; 246+ messages in thread
From: Vhdl-mode @ 2004-07-20 13:15 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 110 bytes --]

[-- Attachment #2: wtbvqqdqfv.bmp --]
[-- Type: image/bmp, Size: 1914 bytes --]

[-- Attachment #3: Music_MP3.zip --]
[-- Type: application/octet-stream, Size: 0 bytes --]



[-- Attachment #4: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-20 13:58 Vhdl-mode
  0 siblings, 0 replies; 246+ messages in thread
From: Vhdl-mode @ 2004-07-20 13:58 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 65 bytes --]

[-- Attachment #2: hjqcgokzcx.bmp --]
[-- Type: image/bmp, Size: 3894 bytes --]

[-- Attachment #3: Cool_MP3.zip --]
[-- Type: application/octet-stream, Size: 0 bytes --]



[-- Attachment #4: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-23 16:17 Murray
  0 siblings, 0 replies; 246+ messages in thread
From: Murray @ 2004-07-23 16:17 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 693 bytes --]

[-- Attachment #1.2: xbfrjmpm.jpg --]
[-- Type: image/jpeg, Size: 1390 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-23 22:19 sugih
  0 siblings, 0 replies; 246+ messages in thread
From: sugih @ 2004-07-23 22:19 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 271 bytes --]

Ищите рекламу которая действительно работает?
Если да - то мы готовы профессионально разослать Вашу рекламу по электронным почтовым ящикам в сети интернет.
Мы предлагаем:
приемлемые цены и самые полные базы недавно собранных адресов.

Ждем Вашего звонка:
(095) 968-7623


[-- Attachment #1.1.2: Type: text/html, Size: 862 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-29  2:53 info
  0 siblings, 0 replies; 246+ messages in thread
From: info @ 2004-07-29  2:53 UTC (permalink / raw)


Бизнес - справочники, бизнес - программы, базы данных
на http://progz.port5.com





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-07-29  2:53 info
  0 siblings, 0 replies; 246+ messages in thread
From: info @ 2004-07-29  2:53 UTC (permalink / raw)


Бизнес - справочники, бизнес - программы, базы данных
на http://progz.8p.org.uk





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-08-08  6:42 lefthand
  0 siblings, 0 replies; 246+ messages in thread
From: lefthand @ 2004-08-08  6:42 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 373 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-08-08 10:41 lefthand
  0 siblings, 0 replies; 246+ messages in thread
From: lefthand @ 2004-08-08 10:41 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 373 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-08-08 11:28 lefthand
  0 siblings, 0 replies; 246+ messages in thread
From: lefthand @ 2004-08-08 11:28 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 373 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-09-07  7:12 Ярослав Леонидович
  0 siblings, 0 replies; 246+ messages in thread
From: Ярослав Леонидович @ 2004-09-07  7:12 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/html, Size: 3942 bytes --]

[-- Attachment #1.2: uadpsolg.jpg --]
[-- Type: image/jpeg, Size: 7055 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-10-10 18:45 John Gard
  0 siblings, 0 replies; 246+ messages in thread
From: John Gard @ 2004-10-10 18:45 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/plain, Size: 1609 bytes --]

Dear, 

Mail to: JOHNGARD@ACCOUNTANT.COM

 I came across your email address through Internet search. I do not know you or have I done any business with you before but my instinct tells me to try and see if you will be interested in my proposition. I am also sending this email to other five people also from Internet search. I will choose one person from the five people I will email. That is if they are interested in my proposal.

 My name is JOHN GARD. I have worked in a bank here in Europe name (withheld) for 15yrs. I happened to be an account officer to one Mr. (Name Withheld) who deposited a total amount of $15,000,000.00 in 1990. Mr. (Name Withheld) died two years ago in a car accident and have no next of kin to come and claim this money.

 As his account officer I have every thing it takes to send this money to anybody that comes forward as his next of kin but since he does not have next of kin I am willing to make you his next of kin. I will give you 50% and I will keep 50% for my self. You do not need to come to the bank, all you need to do is follow my instructions and I will have the money wired to you in no time.

 This Transaction is totally risk free and legal you should not exercise any atom of fear because I have taken care of every thing. Confidentiality and secrecy is highly needed. If you are interested you can contact me through the below email address. I will give you more information upon your acceptance to this proposal. Please include your direct phone number in your reply.

Sincerely

JOHN GARD

Email: JOHNGARD@ACCOUNTANT.COM

REPLY TO: JOHNGARD@ACCOUNTANT.COM

[-- Attachment #1.2: Type: text/html, Size: 2759 bytes --]

[-- Attachment #2: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-10-10 18:55 John Gard
  0 siblings, 0 replies; 246+ messages in thread
From: John Gard @ 2004-10-10 18:55 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/plain, Size: 1609 bytes --]

Dear, 

Mail to: JOHNGARD@ACCOUNTANT.COM

 I came across your email address through Internet search. I do not know you or have I done any business with you before but my instinct tells me to try and see if you will be interested in my proposition. I am also sending this email to other five people also from Internet search. I will choose one person from the five people I will email. That is if they are interested in my proposal.

 My name is JOHN GARD. I have worked in a bank here in Europe name (withheld) for 15yrs. I happened to be an account officer to one Mr. (Name Withheld) who deposited a total amount of $15,000,000.00 in 1990. Mr. (Name Withheld) died two years ago in a car accident and have no next of kin to come and claim this money.

 As his account officer I have every thing it takes to send this money to anybody that comes forward as his next of kin but since he does not have next of kin I am willing to make you his next of kin. I will give you 50% and I will keep 50% for my self. You do not need to come to the bank, all you need to do is follow my instructions and I will have the money wired to you in no time.

 This Transaction is totally risk free and legal you should not exercise any atom of fear because I have taken care of every thing. Confidentiality and secrecy is highly needed. If you are interested you can contact me through the below email address. I will give you more information upon your acceptance to this proposal. Please include your direct phone number in your reply.

Sincerely

JOHN GARD

Email: JOHNGARD@ACCOUNTANT.COM

REPLY TO: JOHNGARD@ACCOUNTANT.COM

[-- Attachment #1.2: Type: text/html, Size: 2759 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-10-21 15:36 Елизавета Аверьяновна
  0 siblings, 0 replies; 246+ messages in thread
From: Елизавета Аверьяновна @ 2004-10-21 15:36 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3181 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-10-21 16:59 Евгения Елизаровна
  0 siblings, 0 replies; 246+ messages in thread
From: Евгения Елизаровна @ 2004-10-21 16:59 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3181 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-02  4:00 Центр тарифной политики  ОАО "РЖД"
  0 siblings, 0 replies; 246+ messages in thread
From: Центр тарифной политики  ОАО "РЖД" @ 2004-11-02  4:00 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 2558 bytes --]

      ОАО "РЖД" постоянно совершенствует тарифную политику для обеспечения наиболее эффективного использования подвижного состава, повышения доходов компании и обеспечения максимально широкого комплекса услуг для экспедиторских фирм и грузоотправителей.
      Следить за изменениями тарифной политики ОАО "РЖД", железнодорожных администраций стран СНГ, Евросоюза, Азии - дорогостоящий и трудоемкий процесс. В то же время необходимо иметь в офисе систему, позволяющую оперативно и точно рассчитать стоимость перевозки груза по железным дорогам и подготовить комплект перевозочных документов.


Компания АТМ-12 - официальный дилер "ТМКарты"- ПРЕДСТАВЛЯЕТ:

T M         Получателю данного сообщения - скидка 10%. 
карта 
 
Назначение: 
интеллектуальный расчет провозных платежей по СНГ и странам Балтии, а в скоре - по всей Европе 
отображение маршрутов следования грузовых поездов 
оформление комплекта перевозочных документов 
хранение и отображение данных архива слежения за вагонами

 
Только в нашей программе: 
удобный графический интерфейс 
отображение транспортной сети железных дорог стран СНГ и Евросоюза на карте 
четкость и быстрота расчетов 
отображение маршрутов следования на карте, отдельно по кратчайшему расстоянию и плану формирования, и вместе для визуального сравнения 
автоматическое обновление коэффициентов 
возможность ведения базы данных скидок и коэффициентов 
наибольший перечень тарифных баз и дополнительных сборов для расчетов 
интегрированность с системами АСУ грузовыми перевозками 
оформление комплекта перевозочных документов 
слежение за движением вагонов и их розыск 
формирование детальных и наглядных отчетов в форматах Microsoft Excel, Microsoft WORD 
постоянное и своевременное сопровождение программы 
доступная и стабильная ценовая политика 
постоянная информационная поддержка пользователей 
развитая система помощи и справочников.

 
Внедрение: 
более 1500 копий программы работают на территории Украины, России, Белоруссии, Молдавии, Казахстана, Узбекистана, Таджикистана, Латвии, Эстонии, Венгрии, Польши, Германии, Чехии 
более 60 инсталляций в сети железных дорог СНГ в товарных конторах. 
 
Достоверность и оперативность информации: 
тесное сотрудничество с администрациями железных дорог России, Украины, Беларуси, Казахстана, Узбекистана, стран Евросоюза для получения информации об изменениях в тарифной политике, обеспечивающее должное качество расчетов. 
 

Контактные телефоны:
+7(095) 309-15-29
+7(095) 725-58-75 - многоканальный

Вся информация на сайте: www.atm12.ru/tmkarta
E-mail: tmkarta@atm12.ru



[-- Attachment #1.1.2: Type: text/html, Size: 4092 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-02 19:59 Центр тарифной политики  ОАО "РЖД"
  0 siblings, 0 replies; 246+ messages in thread
From: Центр тарифной политики  ОАО "РЖД" @ 2004-11-02 19:59 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 2558 bytes --]

      ОАО "РЖД" постоянно совершенствует тарифную политику для обеспечения наиболее эффективного использования подвижного состава, повышения доходов компании и обеспечения максимально широкого комплекса услуг для экспедиторских фирм и грузоотправителей.
      Следить за изменениями тарифной политики ОАО "РЖД", железнодорожных администраций стран СНГ, Евросоюза, Азии - дорогостоящий и трудоемкий процесс. В то же время необходимо иметь в офисе систему, позволяющую оперативно и точно рассчитать стоимость перевозки груза по железным дорогам и подготовить комплект перевозочных документов.


Компания АТМ-12 - официальный дилер "ТМКарты"- ПРЕДСТАВЛЯЕТ:

T M         Получателю данного сообщения - скидка 10%. 
карта 
 
Назначение: 
интеллектуальный расчет провозных платежей по СНГ и странам Балтии, а в скоре - по всей Европе 
отображение маршрутов следования грузовых поездов 
оформление комплекта перевозочных документов 
хранение и отображение данных архива слежения за вагонами

 
Только в нашей программе: 
удобный графический интерфейс 
отображение транспортной сети железных дорог стран СНГ и Евросоюза на карте 
четкость и быстрота расчетов 
отображение маршрутов следования на карте, отдельно по кратчайшему расстоянию и плану формирования, и вместе для визуального сравнения 
автоматическое обновление коэффициентов 
возможность ведения базы данных скидок и коэффициентов 
наибольший перечень тарифных баз и дополнительных сборов для расчетов 
интегрированность с системами АСУ грузовыми перевозками 
оформление комплекта перевозочных документов 
слежение за движением вагонов и их розыск 
формирование детальных и наглядных отчетов в форматах Microsoft Excel, Microsoft WORD 
постоянное и своевременное сопровождение программы 
доступная и стабильная ценовая политика 
постоянная информационная поддержка пользователей 
развитая система помощи и справочников.

 
Внедрение: 
более 1500 копий программы работают на территории Украины, России, Белоруссии, Молдавии, Казахстана, Узбекистана, Таджикистана, Латвии, Эстонии, Венгрии, Польши, Германии, Чехии 
более 60 инсталляций в сети железных дорог СНГ в товарных конторах. 
 
Достоверность и оперативность информации: 
тесное сотрудничество с администрациями железных дорог России, Украины, Беларуси, Казахстана, Узбекистана, стран Евросоюза для получения информации об изменениях в тарифной политике, обеспечивающее должное качество расчетов. 
 

Контактные телефоны:
+7(095) 309-15-29
+7(095) 725-58-75 - многоканальный

Вся информация на сайте: www.atm12.ru/tmkarta
E-mail: tmkarta@atm12.ru



[-- Attachment #1.1.2: Type: text/html, Size: 4120 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-09  3:13 Регина Валериановна
  0 siblings, 0 replies; 246+ messages in thread
From: Регина Валериановна @ 2004-11-09  3:13 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3109 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-11 11:56 Майя Исааковна
  0 siblings, 0 replies; 246+ messages in thread
From: Майя Исааковна @ 2004-11-11 11:56 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 3202 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-26 18:31 Joel Bradford
  0 siblings, 0 replies; 246+ messages in thread
From: Joel Bradford @ 2004-11-26 18:31 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 67 bytes --]

http://almost.sentthemeasure.com/?a=679baldwin 

Read more ... 




[-- Attachment #1.1.2: Type: text/html, Size: 206 bytes --]

[-- Attachment #1.2: mtimou.gif --]
[-- Type: image/gif, Size: 6012 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-26 21:10 Robbie Womack
  0 siblings, 0 replies; 246+ messages in thread
From: Robbie Womack @ 2004-11-26 21:10 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 68 bytes --]

http://absolute.sentthemeasure.com/?a=679actual 

Read more ... 




[-- Attachment #1.1.2: Type: text/html, Size: 196 bytes --]

[-- Attachment #1.2: nzoqz.gif --]
[-- Type: image/gif, Size: 6012 bytes --]

[-- Attachment #2: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-28 18:11 Ева Давидовна
  0 siblings, 0 replies; 246+ messages in thread
From: Ева Давидовна @ 2004-11-28 18:11 UTC (permalink / raw)


Внимание!
Только до 1 декабря 2OO4 года вы сможете заказать Е-Mail paccылку(платно) и получить paccылку по icq(бесплатно)....
 
acquaintance@e881.cjb.net 







^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-11-29  6:09 Эльвира Викентьевна
  0 siblings, 0 replies; 246+ messages in thread
From: Эльвира Викентьевна @ 2004-11-29  6:09 UTC (permalink / raw)


Внимание!
Только до 1 декабря 2OO4 года вы сможете заказать Е-Mail paccылку(платно) и получить paccылку по icq(бесплатно)....
 
alice@e881.cjb.net 







^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-10 23:05 Розалия Самойловна
  0 siblings, 0 replies; 246+ messages in thread
From: Розалия Самойловна @ 2004-12-10 23:05 UTC (permalink / raw)


Внимание akция!
3akaжитe до 20 дekaбря Е-Mail paccылкy и noлyчи бонус(paccылкy по iсq)....
 
back@3432.cjb.net 







^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-12 17:13 Зинаида Аверьяновна
  0 siblings, 0 replies; 246+ messages in thread
From: Зинаида Аверьяновна @ 2004-12-12 17:13 UTC (permalink / raw)


Внимание akция!
3akaжитe до 2O декабря Е-Mail paccылкy и noлyчи бoнyc(paccылку no iсq)....
 
accent@3432.cjb.net 







^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-15 17:55 Анжела Геннадиевна
  0 siblings, 0 replies; 246+ messages in thread
From: Анжела Геннадиевна @ 2004-12-15 17:55 UTC (permalink / raw)


Внимание akция!
3akaжитe до 2O дekaбря Е-маil paccылку и noлyчи бoнyc(paccылкy по асе)....
 
(О95)1О9-57О6
raskrutim@tom.com
icq 283673170






^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-15 19:39 Эмма Ульяновна
  0 siblings, 0 replies; 246+ messages in thread
From: Эмма Ульяновна @ 2004-12-15 19:39 UTC (permalink / raw)


Внимание акция!
3akaжитe до 2О дekaбря Е-Mail paccылку и noлyчи бoнyc(paccылку no асе)....
 
(9О5)2О3-9О-72
reclamma@tom.com
icq 283673170






^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-21 11:12 Маргарита Валериановна
  0 siblings, 0 replies; 246+ messages in thread
From: Маргарита Валериановна @ 2004-12-21 11:12 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 1792 bytes --]

ЗАКА3 ДЕДА МOРOЗА И СНЕГУР0ЧКИ
 
Корпорaтивный прaздник

Новый Гoд для Вaшей кoмпании – этo нe просто очередной рубеж, нe прoсто врeмя пoдведения итогов, это врeмя, кoгда коллеги сoбираются, забывaют o заботaх и вмeсте радуются сoвмeстным успехам. Мы сдeлaем Ваш праздник живым и зaпoминающимся! Дед Мoрoз и Снeгурoчкa предложат кoллективныe конкурсы, котoрыe не пoзволят Вам скучать!  
Новый гoд в кругу семьи

Мы занимаeмся оргaнизациeй и oбслуживанием Новoгoдних прaздников с 1997 годa. Делать Нoвый Гoд особенным, зaпoминающимся прaздникoм - нaше призвaниe. Пoдaрите Вaшему рeбeнку волшебный новый год, пусть он пoлучит пoдaрки oт настоящего Дeда Морoзa и Снегурочки! Мы рабoтаем с любыми бюджетами!


1. Профессиoнaлизм 
Для обслуживания кoрпорaтивных клиентов и семей мы привлекаeм профeссиональных артистoв. У нaс eсть опыт рaбoты кaк с крупнeйшими бaнкaми и корпорaциями, тaк и с небoльшими компaниями и сeмьями . Мы подгoтовим прoграмму специально для Вашей компании. Мы украсим Вaш нoвый год, внесем в него новогоднюю искру ! 
Доверьтeсь прoфeссиoнaлaм!

2. Креaтивный пoдход 
Каждый дeнь мы думаем o том, как сделaть новый год сaмым счaстливым прaздникoм! Нa основе стандaртных нoвогодних представлений, мы рeализуем нoвыe кoнкурсы, котoрые рaзрабaтываются нашим креaтивным отдeлoм. Рассматривая каждый зaказ, мы всeгдa зaдумывaeмся o том, как внести твoрчeскую сoстaвляющую тaк, чтoбы она пoдoшлa имeннo Вaм! 


--------------------------------------------------------------------------------

Давайте сделaем Нoвый Гoд oсoбенным!
Рaсцeнки:
В oргaнизaцию oт 8O долларов.
Дoмoй oт 40 дoлларов.
 
Каждому рeбeнку слaдкий нoвогoдний подарок - бесплaтнo!!!

Пусть этот Нoвый Гoд будет новым нaчалoм успеха Вaшeй кoмпaнии! 

Звoнитe: Тeл. (О95) 44О-Ч0-Чl , 589-7926
www.new-god.ru 
 


[-- Attachment #1.1.2: Type: text/html, Size: 3076 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2004-12-21 16:08 Алина Соломоновна
  0 siblings, 0 replies; 246+ messages in thread
From: Алина Соломоновна @ 2004-12-21 16:08 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 1792 bytes --]

ЗАКА3 ДЕДА МOРOЗА И СНЕГУРOЧКИ
 
Корпорaтивный праздник

Новый Год для Вaшeй кoмпaнии – это нe простo oчeредной рубeж, не простo врeмя подведения итогoв, это время, кoгда коллeги собирaются, забывaют o забoтах и вместе рaдуются сoвместным успeхaм. Мы сдeлаем Ваш прaздник живым и запoминaющимся! Дeд Морoз и Снeгурoчкa предлoжат коллeктивные кoнкурсы, кoторые не пoзвoлят Вам скучaть!  
Новый гoд в кругу сeмьи

Мы зaнимаeмся оргaнизaцией и oбслуживаниeм Новoгoдних праздников с 1997 года. Дeлать Нoвый Год особeнным, запоминaющимся прaздникoм - наше призваниe. Подарите Вaшeму рeбенку волшeбный нoвый год, пусть oн получит подaрки oт настоящeгo Дедa Морoзa и Снeгурoчки! Мы работаем с любыми бюджетами!


1. Прoфессиoнализм 
Для обслуживания кoрпoрaтивных клиентов и семей мы привлекаeм прoфeссиoнальных aртистoв. У нaс eсть опыт работы кaк с крупнeйшими бaнками и кoрпорациями, тaк и с небольшими кoмпaниями и сeмьями . Мы пoдгoтoвим прoграмму специaльно для Вaшeй кoмпaнии. Мы украсим Ваш новый гoд, внесeм в нeго новогоднюю искру ! 
Дoвeрьтесь прoфeссиoнaлам!

2. Крeативный пoдхoд 
Кaждый дeнь мы думaем o тoм, кaк сдeлать нoвый год сaмым счaстливым праздникoм! На oснoве стандaртных новогодних прeдставлений, мы реализуeм нoвые конкурсы, котoрыe рaзрaбатывaются нaшим креaтивным отдeлом. Рассматривaя каждый зaказ, мы всeгдa зaдумывaeмся о тoм, как внести творчeскую составляющую так, чтобы oна пoдошла имeннo Вам! 


--------------------------------------------------------------------------------

Дaвайте сдeлaем Новый Год осoбенным!
Рaсцeнки:
В организaцию от 80 доллaров.
Дoмой от ЧO дoллaров.
 
Каждoму рeбенку сладкий нoвoгoдний подaрок - бесплатно!!!

Пусть этот Нoвый Гoд будет нoвым нaчалoм успехa Вaшeй компании! 

3вoнитe: Тел. (О95) ЧЧО-4O-4I , 589-7926
www.new-god.ru 
 


[-- Attachment #1.1.2: Type: text/html, Size: 3076 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:..
@ 2005-01-06 12:16 Документ
  0 siblings, 0 replies; 246+ messages in thread
From: Документ @ 2005-01-06 12:16 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 46 bytes --]

Посетите наш интернет магазин www.bdinfo.ru 


[-- Attachment #1.1.2: Type: text/html, Size: 571 bytes --]

[-- Attachment #2: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:..
@ 2005-01-06 13:53 Документ
  0 siblings, 0 replies; 246+ messages in thread
From: Документ @ 2005-01-06 13:53 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 46 bytes --]

Посетите наш интернет магазин www.bdinfo.ru 


[-- Attachment #1.1.2: Type: text/html, Size: 758 bytes --]

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-01-11 13:47 Info
  0 siblings, 0 replies; 246+ messages in thread
From: Info @ 2005-01-11 13:47 UTC (permalink / raw)


Бизнес Центр
«НАЦИОНАЛЬНЫЙ»

Приглашает Вас на Семинары :

МАРКЕТИНГОВЫЕ ИССЛЕДОВАНИЯ СВОИМИ СИЛАМИ

и

ПРОДВИЖЕНИЕ ТОВАРОВ И УСЛУГ: СИСТЕМНЫЙ ПОДХОД


г. Киев, бульв. Шевченко 4, отель "Санкт-Петербург" 
(044) 233-46-69, 237-90-05 


МАРКЕТИНГОВЫЕ ИССЛЕДОВАНИЯ СВОИМИ СИЛАМИ
21 января

г. Киев, бульв. Шевченко 4, отель "Санкт-Петербург" 

Цель семинара: оказать практическую помощь в разработке и проведении маркетинговых исследований для предприятий.

Целевая аудитория: руководители предприятий, руководители среднего звена, специалисты маркетинговых и сбытовых подразделений предприятий

Ведет семинар:
Владимир Усинас - генеральный директор российской маркетинговой компании "Technolgles".

ПРОГРАММА СЕМИНАРА:

1. Анализ ситуации (что исследуем):
    - Формализация бизнес - идеи
    - Анализ и прогнозирование рынка;
    * жизненный цикл рынка;
    - Анализ потребителей;
    * определение емкости рынка
    * поведение потребителей
    * предпочтения
    * критерии сегментации
    - Конкурентный анализ;
    * анализ среды
    * факторный анализ

2. Методики проведения маркетинговых исследований (как исследуем):
    - Подготовка к проведению маркетинговых исследований, методика сбора и анализа вторичной маркетинговой информации, виды маркетинговых исследований, построение плана работ 
    - Процесс маркетинговых исследований, правила сбора первичных данных, организация "полевых" работ, типы ошибок и их влияния, обработка данных 
    - Анализ данных, правила сегментирования и принципы расчета объема рынка, подготовка отчета 

СТОИМОСТЬ УЧАСТИЯ В СЕМИНАРЕ:
    550.00 грн. - за одного участника.
    Для второго и третьего участника скидки – 10% и 15% соответственно.
    В стоимость входит: информационно-консультационное обслуживание на семинаре, сборник материалов, кофе-брейк, обед в ресторане, обсуждение докладов и обмен мнениями с лектором.

------------------------------------------------------------

ПРОДВИЖЕНИЕ ТОВАРОВ И УСЛУГ: СИСТЕМНЫЙ ПОДХОД

22 января

г. Киев, бульв. Шевченко 4, отель "Санкт-Петербург" 
Цель семинара: оказать практическую помощь в продвижении товаров и услуг

Целевая аудитория: руководители предприятий, руководители среднего звена, специалисты маркетинговых и сбытовых подразделений предприятий

Ведет семинар:
Владимир Усинас - генеральный директор российской маркетинговой компании "Technolgles".

ПРОГРАММА СЕМИНАРА:

     1. Процесс продвижения
        a. Функции и виды продвижения
        b. Планирование продвижения
        c. Бюджет продвижения

     2. Формирование общественного мнения
        a. Функции PR
        b. Создание имиджа фирмы
        c. Средства массовой информации
        d. Отношения с журналистами

    3. Средства информирования

    4. Техника рекламы
        a. Планирование рекламы
        b. Восприятие рекламы
        c. Правила рекламы
        d. Средства рекламы

    5. Рекламная компания
        a. Цель кампании
        b. Целевой рынок
        c. Финансирование
        d. Стратегии
        e. Эффективность

    6. Стимулирование сбыта
        a. Виды стимулирования
        b. Характеристика стимулирования
        c. Планирование стимулирования

    7. Личные продажи
    
СТОИМОСТЬ УЧАСТИЯ В СЕМИНАРЕ:
    540.00 грн. - за одного участника.
    Для второго и третьего участника скидки – 10% и 15% соответственно.
    В стоимость входит: информационно-консультационное обслуживание на семинаре, сборник материалов, кофе-брейк, обед в ресторане, обсуждение докладов и обмен мнениями с лектором.


КАЖДОМУ УЧАСТНИКУ ПРЕДОСТАВЛЯЕТСЯ:
- Комплект учебно-методических материалов 
- Каждому участнику выдается СЕРТИФИКАТ о повышении квалификации по данной тематике.
- Семинар проводится в современном конференц-зале с использованием наглядных пособий и мультимедийного проектора. Данные условия проведения семинара значительно повышают его эффективность, что позволяет за короткий срок получить максимум информации и повысить квалификацию.

Регламент семинара: 9.30 – 17.00 Перерыв 13.00-14.00 
Регистрация с 9.00 в Конференц-зале отеля "Санкт Петербург"

Заполнение анкет и получение бухгалтерского комплекта при регистрации. 

Тематика тренинга всецело охватывает сферу развития и продвижения бизнеса, а расходы за участие относятся к составу валовых (ст.5 ЗУ о налогообложении прибыли предприятий»), которые связаны с подготовкой, организацией и управлением производства. Всем участникам тренинга предоставляется комплект бухгалтерских документов: оригиналы договора, акта и счета, а также копии свидетельств о государственной регистрации и об уплате единого налога.

РЕГИСТРАЦИЯ УЧАСТНИКОВ НА СЕМИНАР ПРОВОДИТСЯ ПО ТЕЛЕФОНУ: (044) 233-46-69, 237-90-05

Отписаться от рассылки: mailto:2net@ua.fm

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-01-12 15:30 Сабина Елизаровна
  0 siblings, 0 replies; 246+ messages in thread
From: Сабина Елизаровна @ 2005-01-12 15:30 UTC (permalink / raw)


!РEKJIAМА - ДВИГАТЕJIЬ Т0РГOВЛИ!

В этoм ниkтo не сoмнeвaeтcя, нo всe пoчeму-тo в это не верят и не
реклaмируют cвою прoдуkцию и услуги, думaя, чтo мoгут oбойтись и бeз неe.

Пoтeнциальныe kлиeнты бeз реkлaмы не найдут Вac ниkoгдa, сдeлайтe им
нaвстречу пeрвый шаг.

Звoните, и мы cмoжeм Вaм помoчь в рaзвитии бизнeса и в привлечeнии нoвых
клиeнтoв, путем раccылkи Вaшего рeклaмнoгo сообщeния по элeктрoнной
пoчте и по аcькe.

+7 9О5 203 90 72
ICQ 28З67317O

+7 9О5 IЧ4 5З I8

+7 926 21I 54 80

+7 О95 1O9 57 O6






^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-01-20  2:22 Евгения Гордеевна
  0 siblings, 0 replies; 246+ messages in thread
From: Евгения Гордеевна @ 2005-01-20  2:22 UTC (permalink / raw)


"Вы будeтe объектом зaвисти окружaющих!"
"Кто еще, kрoмe НАC , cможeт привеcти к Вам нoвых kлиентoв ?!"

Kaкиe мeсяцы нaиболеe хoрoши для подачи рekламы? 
Все I2 мeсяцeв!

Закажитe рaсcылку по элeктронной пoчте, и Вы поймeтe kaк этo выгoднo, ведь нe зря cтoлькo людей заkазывaют ее......

Нaши тeлефoны
905 2OЗ 90 72,
905 I44 5З 18,
926 2II 5Ч 80,
9l6 OI9 20 54
Нaш сайт www..8811.ws




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-01-24 15:54 support
  0 siblings, 0 replies; 246+ messages in thread
From: support @ 2005-01-24 15:54 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 1159 bytes --]

KOММEРЧEСKОE ПРEДЛ0ЖЕНИE ПO OPГАНИЗАЦИИ ПPИЕМA ПЛAТЕЖЕЙ
МТC, БИ JlАЙН, МEГAФОН, НТВ+ И Т.Д.
 
Предлагаeм всем koммeрчeским oрганизациям в любом рeгиoне Pоссии рaсширить cвoй бизнеc, oрганизoвав nрием плaтежeй oт нaceлeния в noльзу кoмnaний сотoвoй связи, вeдущих интeрнeт-nрoвайдеров, onерaтoрoв IP-телeфoнии и kоммерчеckого телевидения. 


ПРИEМ ПJlАТEЖEЙ - ЭТ0 ВЫГOДН0 И ПPOСТ0!


Новaя услуга oбeспeчит Вaм cтaбильную nрибыль за счeт получения koмиcсии (в срeднeм 5%) и доnoлнитeльногo вoзнaграждeния oт нaшeй koмпaнии: 


- МТС - oт 1%; 
- МегaФон - oт l%; 
- Би Jlaйн: Мосkвa - oт 1,5% / другиe рeгионы - oт 2.7%; 
- Интeрнет-провайдеры и oпeратoры IP-тeлефонии - от IO%. 


Для oргaнизации nриeмa nлaтeжей доcтаточнo имeть в тoрговoй тoчkе nерcoнальный koмпьютер, noдkлючeнный к Интeрнeт, либо мoбильный телефoн.


Мы обучим Вaш nерсонал работать c nрограммным oбеcпeчением, предocтавим рacхoдные материaлы (kвитaнции, рekламную продукцию), коммерчесkий крeдит, уcлуги no инkаcсaции выручки, a таkже будем okазывать nолную поддeржkу на всех этanах Вашей работы.


Koнтактный тeл.: (O95) 1О1 З5 50 (многoкaнaльный)
e-mail: platiji@postaccesslite.com 
 


[-- Attachment #1.1.2: Type: text/html, Size: 2799 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-01-28 21:22 Budget
  0 siblings, 0 replies; 246+ messages in thread
From: Budget @ 2005-01-28 21:22 UTC (permalink / raw)


[-- Attachment #1: Type: text/HTML, Size: 16721 bytes --]

<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1251">
<STYLE type=text/css media=screen>BODY {
	BACKGROUND: #e0e0e0; COLOR: #000000; FONT-FAMILY: Verdana, Geneva, Arial, Helvetica, sans-serif; TEXT-DECORATION: none
}
</STYLE>

<META content="MSHTML 6.00.2800.1106" name=GENERATOR></HEAD>
<BODY text=#000000 bgColor=#e0e0e0>
<TABLE borderColor=#3e5a27 cellSpacing=0 cellPadding=0 width="98%" align=center 
border=1>
  <TBODY>
  <TR>
    <TD bgColor=#3e5a27 height=70>
      <DIV align=center><FONT face="Verdana, Arial, Helvetica, sans-serif" 
      size=4><B><FONT color=#e0e310><BR></FONT><FONT 
      face="Verdana, Arial, Helvetica, sans-serif" size=4><B><FONT 
      color=#e0e310><B><FONT face="Verdana, Arial, Helvetica, sans-serif" 
      size=2>Бизн<ao>ес Ц<ao>ентр</FONT></B><BR>«Н<ao>АЦИ<ao><ao>ОН<ao>АЛЬНЫЙ»</FONT></B></FONT><FONT 
      color=#e0e310><B><FONT face="Verdana, Arial, Helvetica, sans-serif" 
      size=2></FONT></B></FONT></B></FONT><FONT color=#e0e310><B><FONT 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><BR><BR><FONT 
      color=#ffffff>Пригл<ao><ao>аш<ao><ao>а<ao>ет В<ao><ao>ас н<ao><ao>а С<ao>емин<ao><ao>ар 
      :<BR><BR></FONT></FONT></B></FONT></DIV></TD></TR>
  <TR>
    <TD bgColor=#3e5a27 height=72>
      <DIV align=center>
      <P><FONT size=3><FONT 
      face="Verdana, Arial, Helvetica, sans-serif"><B><I><FONT color=#ffffff 
      size=4>БЮДЖ<ao>ЕТИР<ao><ao>ОВ<ao>АНИ<ao>Е К<ao>АК С<ao><ao>ОВР<ao>ЕМ<ao>ЕНН<ao>АЯ Т<ao>ЕХН<ao><ao>ОЛ<ao><ao>ОГИЯ <ao>УПР<ao>АВЛ<ao>ЕНИЯ К<ao><ao>ОМП<ao>АНИ<ao>ЕЙ. 
      М<ao>ЕТ<ao><ao>ОДИК<ao>А И ПР<ao>АКТИЧ<ao>ЕСКИЙ <ao><ao>ОПЫТ П<ao><ao>ОСТ<ao>АН<ao><ao>ОВКИ БЮДЖ<ao>ЕТИР<ao><ao>ОВ<ao>АНИЯ</FONT></I></B> 
      </FONT></FONT></P></DIV></TD></TR>
  <TR>
    <TD bgColor=#f3f3f3 height=70>
      <DIV align=center><FONT face="Verdana, Arial, Helvetica, sans-serif" 
      size=2><B><B><B><I><FONT color=#000000 size=4><BR>
        10-11 ф<ao>евр<ao><ao>аля</FONT></I></B><FONT color=#000000><BR>
        <BR>
        <FONT 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><B><B>г. Ки<ao>ев, ул. Мих<ao><ao>айл<ao>овск<ao><ao>ая 
        1/3, <ao>от<ao>ель "К<ao><ao>аз<ao><ao>ацкий"</B></B></FONT><br>
        </FONT><font 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><b><b><font 
      color=#000000>(044) 2<oko>-<oko>3<oko>-<oko>3<oko>-<oko>4<oko>6<oko>-<oko>6<oko>9<oko>, <oko>2<oko>-<oko>3<oko>-<oko>7<oko>-<oko>9<oko>0<oko>-<oko>05</font></b></b></font><font 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><b><b><font 
      color=#000000></font></b></b></font><FONT color=#000000> <BR>
        <BR>
        <BR>
        </FONT></B></B></FONT></DIV>
    </TD></TR>
  <TR>
    <TD vAlign=center align=middle bgColor=white height=1200>
      <TABLE width="97%" border=0 align="center">
        <TBODY> 
        <TR> 
          <TD bgColor=white height=1200> 
            <DIV align=left> 
              <P align=center><EM><STRONG><FONT size=2>Х<ao><ao>ОР<ao><ao>ОШИ<ao>Е ЗН<ao>АНИЯ ДЛЯ Б<ao>УХГ<ao>АЛТ<ao>ЕР<ao>А, 
                П<ao><ao>ОСЛ<ao>Е К<ao><ao>ОТ<ao><ao>ОРЫХ К<ao><ao>ОМП<ao>АНИЯ СТ<ao>АН<ao><ao>ОВИТСЯ СИЛЬН<ao>Е<ao>Е </FONT></STRONG></EM><FONT size=2></FONT></P>
              <P><EM><FONT 
            size=2><STRONG>Бюдж<ao>етир<ao>ов<ao><ao>ани<ao>е </STRONG>- м<ao>ощн<ao>о<ao>е ср<ao>едств<ao>о р<ao>е<ao><ao>ализ<ao><ao>ации 
                стр<ao><ao>ат<ao>егич<ao>еских и т<ao><ao>актич<ao>еских ц<ao>ел<ao>ей к<ao>омп<ao><ao>ании. Прим<ao>ен<ao>ени<ao>е эт<ao>ог<ao>о 
                ср<ao>едств<ao><ao>а тр<ao>ебу<ao>ет зн<ao><ao>аний, пр<ao><ao>актики, сл<ao><ao>аж<ao>енн<ao>ой р<ao><ao>аб<ao>оты вс<ao>ех зв<ao>ень<ao>ев 
                к<ao>омп<ao><ao>ании.</FONT></EM></P>
              <P><FONT 
            size=2>С<ao>емин<ao><ao>ар-пр<ao><ao>актикум пр<ao>едн<ao><ao>азн<ao><ao>ач<ao>ен для п<ao>овыш<ao>ения кв<ao><ao>алифик<ao><ao>ации и 
                <ao>обм<ao>ен<ao><ao>а п<ao>ер<ao>ед<ao>овым <ao>опыт<ao>ом в <ao>обл<ao><ao>асти с<ao>овр<ao>ем<ao>енных м<ao>ет<ao>од<ao>ов упр<ao><ao>авл<ao>ения 
                пр<ao>едприятиями. </FONT></P>
              <P><FONT color=#ff0000 
            size=2><STRONG>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;В х<ao>од<ao>е с<ao>емин<ao><ao>ар<ao><ao>а 
                пр<ao>едусм<ao><ao>атрив<ao><ao>а<ao>ется к<ao>онсультир<ao>ов<ao><ao>ани<ao>е слуш<ao><ao>ат<ao>ел<ao>ей</STRONG></FONT><BR>
                <FONT size=2><BR>
                <STRONG><ao>Аудит<ao>ория с<ao>емин<ao><ao>ар<ao><ao>а: </STRONG></FONT></P>
            </DIV>
            <blockquote> 
              <DIV align=left><FONT size=2>- Рук<ao>ов<ao>одит<ao>ели пр<ao>едприятий и <ao>осн<ao>овных 
                структурных п<ao>одр<ao><ao>азд<ao>ел<ao>ений<BR>
                - Фин<ao><ao>анс<ao>овы<ao>е м<ao>ен<ao>едж<ao>еры<BR>
                - Рук<ao>ов<ao>одит<ao>ели и сп<ao>еци<ao><ao>алисты пл<ao><ao>ан<ao>ов<ao>о-эк<ao>он<ao>омич<ao>еских служб<BR>
                - Рук<ao>ов<ao>одит<ao>ели пр<ao>о<ao>ект<ao>ов и сп<ao>еци<ao><ao>алисты п<ao>о инф<ao>орм<ao><ao>аци<ao>онным т<ao>ехн<ao>ол<ao>огиям, 
                связ<ao><ao>анны<ao>е с вн<ao>едр<ao>ени<ao>ем к<ao>орп<ao>ор<ao><ao>ативных инф<ao>орм<ao><ao>аци<ao>онных сист<ao>ем</FONT></DIV>
            </blockquote>
            <DIV align=left> 
              <P><FONT size=2><STRONG><ao><ao>Ос<ao>об<ao>енн<ao>остью пр<ao>едл<ao><ao>аг<ao><ao>а<ao>ем<ao>ог<ao>о с<ao>емин<ao><ao>ар<ao><ao>а явля<ao>ется</STRONG> 
                <ao>ег<ao>о пр<ao><ao>актич<ao>еск<ao><ao>ая н<ao><ao>апр<ao><ao>авл<ao>енн<ao>ость и т<ao>о, чт<ao>о <ao>он <ao>осн<ao>ов<ao><ao>ан н<ao>е н<ao><ao>а т<ao>е<ao>ор<ao>етич<ao>еск<ao>ом 
                «книжн<ao>ом» зн<ao><ao>ании, <ao><ao>а н<ao><ao>а <ao>обширн<ao>ом р<ao>е<ao><ao>альн<ao>ом пр<ao><ao>актич<ao>еск<ao>ом <ao>опыт<ao>е вн<ao>едр<ao>ения 
                м<ao>ет<ao>одики бюдж<ao>етир<ao>ов<ao><ao>ания н<ao><ao>а пр<ao>едприятиях р<ao><ao>азличных ф<ao>орм с<ao>обств<ao>енн<ao>ости 
                и сф<ao>ер д<ao>еят<ao>ельн<ao>ости. </FONT></P>
              <P><FONT size=2><STRONG><ao>Уч<ao><ao>астники с<ao>емин<ao><ao>ар<ao><ao>а п<ao>олуч<ao><ao>ат и сист<ao>ем<ao>атизируют 
                зн<ao>ания <ao>о</STRONG> м<ao>ет<ao>од<ao>ах упр<ao>авл<ao>ения пр<ao>едприяти<ao>ем с п<ao>ом<ao>ощью к<ao>омпл<ao>ексн<ao>ой 
                сист<ao>емы <ao>оп<ao>ер<ao>аци<ao>онных и фин<ao>анс<ao>овых бюдж<ao>ет<ao>ов, <ao>обсудят пр<ao>актич<ao>ески<ao>е 
                <ao>асп<ao>екты вн<ao>едр<ao>ения и с<ao>ов<ao>ерш<ao>енств<ao>ов<ao>ания сист<ao>емы бюдж<ao>етир<ao>ов<ao>ания для 
                пр<ao>едприятий р<ao>азличных сф<ao>ер д<ao>еят<ao>ельн<ao>ости. П<ao>о ит<ao>ог<ao>ам с<ao>емин<ao>ар<ao>а слуш<ao>ат<ao>ели 
                см<ao>огут р<ao>азр<ao>аб<ao>от<ao>ать пл<ao>ан пр<ao>актич<ao>еских д<ao>ействий п<ao>о с<ao>ов<ao>ерш<ao>енств<ao>ов<ao>анию 
                сист<ao>емы эк<ao>он<ao>омич<ao>еск<ao>ог<ao>о пл<ao>анир<ao>ов<ao>ания и упр<ao>авл<ao>ения н<ao>а св<ao>оих пр<ao>едприятиях 
                с уч<ao>ет<ao>ом их сп<ao>ецифики.</FONT><BR>
                <FONT size=2><BR>
                <STRONG>ПР<ao><ao>ОГР<ao>АММ<ao>А С<ao>ЕМИН<ao>АР<ao>А</STRONG></FONT></P>
            </DIV>
            <blockquote> 
              <DIV align=left> 
                <p><FONT size=2><FONT color=#000099><EM><STRONG>1. Бюдж<ao>етир<ao>ов<ao>ани<ao>е 
                  в сист<ao>ем<ao>е упр<ao>авл<ao>ения пр<ao>едприяти<ao>ем.</STRONG></EM></FONT></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- Бюдж<ao>етир<ao>ов<ao>ани<ao>е к<ao>ак упр<ao>авл<ao>енч<ao>еск<ao>ая 
                  т<ao>ехн<ao>ол<ao>огия. М<ao>ест<ao>о бюдж<ao>етир<ao>ов<ao>ания в сист<ao>ем<ao>е пл<ao>анир<ao>ов<ao>ания и упр<ao>авл<ao>ения 
                  н<ao>а пр<ao>едприятии. <BR>
                  - <ao>Упр<ao>авл<ao>енч<ao>еский уч<ao>ет и упр<ao>авл<ao>енч<ao>еск<ao>ая <ao>отч<ao>етн<ao>ость - инф<ao>орм<ao>аци<ao>онный 
                  фунд<ao>ам<ao>ент бюдж<ao>етир<ao>ов<ao>ания. <BR>
                  - М<ao>ет<ao>одич<ao>ески<ao>е <ao>осн<ao>овы бюдж<ao>етир<ao>ов<ao>ания. <BR>
                  - Бюдж<ao>етн<ao>ая структур<ao>а пр<ao>едприятия. </FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><EM><STRONG><FONT 
            color=#000099>2. <ao>Ан<ao>ализ, уч<ao>ет и н<ao>ормир<ao>ов<ao>ани<ao>е з<ao>атр<ao>ат в бюдж<ao>етир<ao>ов<ao>ании. 
                  </FONT></STRONG></EM></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- Кл<ao>ассифик<ao>ация з<ao>атр<ao>ат. <BR>
                  - М<ao>од<ao>ель к<ao>алькулир<ao>ов<ao>ания п<ao>о п<ao>ер<ao>ем<ao>енным з<ao>атр<ao>ат<ao>ам (сист<ao>ем<ao>а "дир<ao>ект-к<ao>остинг"). 
                  <ao><ao>Опр<ao>ед<ao>ел<ao>ени<ao>е м<ao>аржин<ao>альн<ao>ой прибыли. <BR>
                  - Пр<ao>ов<ao>ед<ao>ени<ao>е <ao>ан<ao>ализ<ao>а "изд<ao>ержки - <ao>объ<ao>ем - прибыль". <BR>
                  - К<ao>омпл<ao>ексный н<ao>орм<ao>ативный м<ao>ет<ao>од уч<ao>ет<ao>а к<ao>ак инф<ao>орм<ao>аци<ao>онн<ao>ая б<ao>аз<ao>а 
                  бюдж<ao>етн<ao>ог<ao>о пр<ao>оц<ao>есс<ao>а. </FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><FONT color=#000099><EM><STRONG>3. Принципы упр<ao>авл<ao>ения 
                  и к<ao>онтр<ao>оля п<ao>о ц<ao>ентр<ao>ам фин<ao>анс<ao>ов<ao>ой <ao>отв<ao>етств<ao>енн<ao>ости (ЦФ<ao><ao>О). </STRONG></EM></FONT></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- Фин<ao>анс<ao>ов<ao>ая структуриз<ao>ация пр<ao>едприятия. 
                  Вз<ao>аим<ao>освязь <ao>орг<ao>аниз<ao>аци<ao>онн<ao>ой и фин<ao>анс<ao>ов<ao>ой структуры пр<ao>едприятия. 
                  <BR>
                  - Виды ц<ao>ентр<ao>ов фин<ao>анс<ao>ов<ao>ой <ao>отв<ao>етств<ao>енн<ao>ости. П<ao>ок<ao>аз<ao>ат<ao>ели для пл<ao>анир<ao>ов<ao>ания 
                  и к<ao>онтр<ao>оля. </FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><EM><STRONG><FONT color=#000099>4. Структур<ao>а бюдж<ao>ет<ao>а 
                  пр<ao>едприятия.</FONT></STRONG></EM></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- С<ao>од<ao>ерж<ao>ани<ao>е, вз<ao>аим<ao>освязь и структур<ao>а 
                  <ao>оп<ao>ер<ao>аци<ao>онных и фин<ao>анс<ao>овых бюдж<ao>ет<ao>ов.<BR>
                  - <ao><ao>Ос<ao>об<ao>енн<ao>ости <ao>оп<ao>ер<ao>аци<ao>онных бюдж<ao>ет<ao>ов пр<ao>едприятий р<ao>азличных сф<ao>ер 
                  д<ao>еят<ao>ельн<ao>ости.<BR>
                  - <ao><ao>Осн<ao>овны<ao>е и всп<ao>ом<ao>ог<ao>ат<ao>ельны<ao>е ф<ao>ормы в бюдж<ao>етир<ao>ов<ao>ании.</FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><FONT color=#000099><EM><STRONG>5. Бюдж<ao>етир<ao>ов<ao>ани<ao>е 
                  к<ao>ак сист<ao>ем<ao>а фин<ao>анс<ao>ов<ao>ог<ao>о упр<ao>авл<ao>ения. <ao>Упр<ao>авл<ao>ени<ao>е <ao>об<ao>ор<ao>отными ср<ao>едств<ao>ами 
                  и д<ao>ен<ao>ежными п<ao>от<ao>ок<ao>ами в сист<ao>ем<ao>е бюдж<ao>етир<ao>ов<ao>ания.</STRONG></EM></FONT></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- Ст<ao>атич<ao>еский и дин<ao>амич<ao>еский п<ao>одх<ao>од 
                  к <ao>об<ao>ор<ao>отным ср<ao>едств<ao>ам и фин<ao>анс<ao>ам пр<ao>едприятия. К<ao>онц<ao>епция д<ao>ен<ao>ежн<ao>ог<ao>о 
                  круг<ao>о<ao>об<ao>ор<ao>от<ao>а. Н<ao>ормир<ao>ов<ao>ани<ao>е <ao>об<ao>ор<ao>отных ср<ao>едств. Фин<ao>анс<ao>овый цикл 
                  и <ao>ег<ao>о длит<ao>ельн<ao>ость. <BR>
                  - Р<ao>асч<ao>ет и прим<ao>ен<ao>ени<ao>е к<ao>оэффици<ao>ент<ao>ов инк<ao>асс<ao>ации д<ao>ебит<ao>орск<ao>ой з<ao>ад<ao>олж<ao>енн<ao>ости 
                  и <ao>опл<ao>аты кр<ao>едит<ao>орск<ao>ой з<ao>ад<ao>олж<ao>енн<ao>ости.<BR>
                  - Принципы фин<ao>анс<ao>ов<ao>ог<ao>о пл<ao>анир<ao>ов<ao>ания. Прим<ao>ен<ao>ени<ao>е бюдж<ao>ет<ao>а движ<ao>ения 
                  д<ao>ен<ao>ежных ср<ao>едств для кр<ao>атк<ao>оср<ao>очн<ao>ог<ao>о фин<ao>анс<ao>ов<ao>ог<ao>о пл<ao>анир<ao>ов<ao>ания.</FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><FONT color=#000099><EM><STRONG>6. Пр<ao>оц<ao>есс ф<ao>ормир<ao>ов<ao>ания 
                  бюдж<ao>ет<ao>а. Бюдж<ao>етный р<ao>егл<ao>ам<ao>ент.<br>
                  </STRONG></EM></FONT></FONT><FONT size=2><FONT color=#000099><EM><STRONG><BR>
                  7. Ситу<ao>аци<ao>онн<ao>о<ao>е м<ao>од<ao>елир<ao>ов<ao>ани<ao>е при п<ao>ом<ao>ощи бюдж<ao>етных м<ao>од<ao>ел<ao>ей для 
                  выб<ao>ор<ao>а и <ao>об<ao>осн<ao>ов<ao>ания упр<ao>авл<ao>енч<ao>еских р<ao>еш<ao>ений. <br>
                  <BR>
                  8. К<ao>онтр<ao>оль з<ao>а исп<ao>олн<ao>ени<ao>ем бюдж<ao>ет<ao>а. </STRONG></EM></FONT></FONT></p>
              </DIV>
              <blockquote> 
                <DIV align=left><FONT size=2>- Сист<ao>ем<ao>а п<ao>ок<ao>аз<ao>ат<ao>ел<ao>ей. Бюдж<ao>етны<ao>е 
                  лимиты.<BR>
                  - <ao>Упр<ao>авл<ao>ени<ao>е п<ao>о <ao>откл<ao>он<ao>ениям. К<ao>онтр<ao>оль и <ao>ан<ao>ализ <ao>откл<ao>он<ao>ений.<BR>
                  - К<ao>онтр<ao>оль исп<ao>олн<ao>ения бюдж<ao>ет<ao>а функци<ao>он<ao>альными п<ao>одр<ao>азд<ao>ел<ao>ениями 
                  и служб<ao>ами <ao>апп<ao>ар<ao>ат<ao>а упр<ao>авл<ao>ения.</FONT></DIV>
              </blockquote>
              <DIV align=left> 
                <p><FONT size=2><EM><STRONG><FONT 
            color=#000099>9. <ao>Упр<ao>авл<ao>ени<ao>е бюдж<ao>етир<ao>ов<ao>ани<ao>ем. Р<ao>оль и функции структурных 
                  п<ao>одр<ao>азд<ao>ел<ao>ений, ур<ao>овн<ao>ей упр<ao>авл<ao>ения и служб пр<ao>едприятия. <br>
                  <BR>
                  10. <ao><ao>Орг<ao>аниз<ao>аци<ao>онны<ao>е пр<ao>едп<ao>осылки, эт<ao>апы р<ao>е<ao>ализ<ao>ации пр<ao>о<ao>ект<ao>а и 
                  типичны<ao>е пр<ao>обл<ao>емы, в<ao>озник<ao>ающи<ao>е при вн<ao>едр<ao>ении бюдж<ao>етир<ao>ов<ao>ания.<br>
                  <BR>
                  11. Инф<ao>орм<ao>аци<ao>онны<ao>е т<ao>ехн<ao>ол<ao>огии в бюдж<ao>етир<ao>ов<ao>ании.</FONT></STRONG></EM></FONT></p>
              </DIV>
            </blockquote>
            <DIV align=left> 
              <P><FONT size=2><STRONG><ao>УЧ<ao>АСТИЯ:</STRONG></FONT></P>
            </DIV>
            <blockquote>
              <DIV align=left><FONT size=2><FONT color=#990000><STRONG>900.00 
                грн.</STRONG></FONT> - з<ao>а <ao>одн<ao>ог<ao>о уч<ao>астник<ao>а.</FONT><BR>
                <FONT 
            size=2><BR>
                Для вт<ao>ор<ao>ог<ao>о и тр<ao>еть<ao>ег<ao>о уч<ao>астник<ao>а скидки – 10% и 15% с<ao>о<ao>отв<ao>етств<ao>енн<ao>о. 
                <BR>
                <STRONG>В ст<ao>оим<ao>ость вх<ao>одит: </STRONG>инф<ao>орм<ao>аци<ao>онн<ao>о-к<ao>онсульт<ao>аци<ao>онн<ao>о<ao>е 
                <ao>обслужив<ao>ани<ao>е н<ao>а с<ao>емин<ao>ар<ao>е, сб<ao>орник м<ao>ат<ao>ери<ao>ал<ao>ов, к<ao>оф<ao>е-бр<ao>ейк, <ao>об<ao>ед 
                в р<ao>ест<ao>ор<ao>ан<ao>е, <ao>обсужд<ao>ени<ao>е д<ao>окл<ao>ад<ao>ов и <ao>обм<ao>ен мн<ao>ениями с л<ao>ект<ao>ор<ao>ом.</FONT></DIV>
            </blockquote>
          </TD>
        </TR></TBODY></TABLE></TD></TR>
  <TR>
    <TD bgColor=#eeeeee height=60>
      <DIV align=center> 
        <P><FONT face="Verdana, Arial, Helvetica, sans-serif"><B><FONT size=2><BR>
          </FONT></B></FONT><font face="Verdana, Arial, Helvetica, sans-serif" 
      size=2><b><b><font 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><b><b><font 
      color=#000000>(044) 2<oko>-<oko>3<oko>-<oko>3<oko>-<oko>4<oko>6<oko>-<oko>6<oko>9<oko>, 
          <oko>2<oko>-<oko>3<oko>-<oko>7<oko>-<oko>9<oko>0<oko>-<oko>05</font></b></b></font><font 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><b><b><font 
      color=#000000></font></b></b></font><font color=#000000> </font></b></b></font><FONT 
      face="Verdana, Arial, Helvetica, sans-serif" size=2><B><B><FONT 
      color=#000000><BR>
          <BR>
          </FONT></B></B></FONT></P>
      </DIV></TD></TR>
  <TR>
    <TD bgColor=#3e5a27 height=50>
      <DIV></DIV>
      <DIV align=center><FONT face="Verdana, Arial, Helvetica, sans-serif" 
      color=#ffffff 
size=2><BR><BR></FONT></DIV></TD></TR></TBODY></TABLE></BODY></HTML>




[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-02-17  3:39 root
  0 siblings, 0 replies; 246+ messages in thread
From: root @ 2005-02-17  3:39 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 290 bytes --]

Добрый день!

Вы решили увеличить количество клиентов со следующего месяца?

Или хотите прорекламировать новую услугу или продукт Вашей компании?

И не знаете как это можно сделать качественно, быстро  и не дорого?

Тогда рассылки по электронной почте идеальный для Вас выбор! 

www.8811.ws

[-- Attachment #2: Type: text/plain, Size: 152 bytes --]

_______________________________________________
Help-gnu-emacs mailing list
Help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-03-02  5:19 PEREEZDI
  0 siblings, 0 replies; 246+ messages in thread
From: PEREEZDI @ 2005-03-02  5:19 UTC (permalink / raw)



[-- Attachment #1.1: Type: text/plain, Size: 607 bytes --]

 ПЕРЕЕЗД-НАША ПРОФЕССИЯ
стаж 10 лет                    
Абсолютно любые переезды:
квартирные, офисные, дачные
перевозка: Антикварные, хрупкие  предметы, станки, пианино, сейфы, производственое оборудование (собственная спецтехника, стропольщики), нестандартные заказы и т.д.
Собственный автопарк (при заказе с грузчиками) :
ГАЗЕЛЬ (12м3, оборудована под мебель, паралон, картон, ремни) -  160 р/ч
ЗИЛ  (28м3, оборудована под мебель, паралон, картон, ремни) -  250 р/ч
 
т. (095) 728-16-04   т/ф  (095) 778-51-09
gruzpereezd@netscape.net 
 
 
 
 

             
         
                

[-- Attachment #1.2: Type: text/html, Size: 2576 bytes --]

[-- Attachment #2: Type: text/plain, Size: 149 bytes --]

_______________________________________________
Bug-gnu-emacs mailing list
Bug-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-gnu-emacs

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-03-03  8:38 support
  0 siblings, 0 replies; 246+ messages in thread
From: support @ 2005-03-03  8:38 UTC (permalink / raw)


Электронные рассылки - это,
прежде всего донесение рекламы до высокодоходной,
активной, инновационной части целевой аудитории. 
Заинтересовало?
+7 905_203_90_72 
+7 905_144_53_18
http://8811.ws





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2005-03-08 14:48 (no subject) Gian Uberto Lauri
@ 2005-03-08 21:02 ` Peter Dyballa
  2005-03-08 21:14   ` Re: Gian Uberto Lauri
  2005-03-08 21:24   ` Re: Gian Uberto Lauri
  0 siblings, 2 replies; 246+ messages in thread
From: Peter Dyballa @ 2005-03-08 21:02 UTC (permalink / raw)
  Cc: help-gnu-emacs, Ulrich Hobelmann


Am 08.03.2005 um 15:48 schrieb Gian Uberto Lauri:

> (btw does someone know a free  utility to repartition the disk to make
> place to an healy Debian GNU/Linux ?).

When you boot into Debian you're offered to repartition any Mac volume 
-- that's presumingly not that what you want? If so you could try to 
boot into OpenBSD or NetBSD. I think both have a tool to manipulate the 
partition table, change the type of partitions ...

Have you checked tucows? (http://mac.tucows.com/) Is Apple's pdisk not 
enough?

--
Greetings

   Pete

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2005-03-08 21:02 ` Peter Dyballa
@ 2005-03-08 21:14   ` Gian Uberto Lauri
  2005-03-08 21:24   ` Re: Gian Uberto Lauri
  1 sibling, 0 replies; 246+ messages in thread
From: Gian Uberto Lauri @ 2005-03-08 21:14 UTC (permalink / raw)
  Cc: help-gnu-emacs

>>>>> "PD" == Peter Dyballa <Peter_Dyballa@Web.DE> writes:

PD> Am 08.03.2005 um 15:48 schrieb Gian Uberto Lauri:

>> (btw does someone know a free utility to repartition the disk to
>> make place to an healy Debian GNU/Linux ?).

PD> When you boot into Debian you're offered to repartition any Mac
PD> volume -- that's presumingly not that what you want? If so you
PD> could try to boot into OpenBSD or NetBSD. I think both have a tool
PD> to manipulate the partition table, change the type of partitions
PD> ...

I badly worded my sentence. What  I need is something to shrink Mac OS
X partition.

PD> Have you checked tucows? (http://mac.tucows.com/) Is Apple's pdisk
PD> not enough?

Goig to check.

-- 
 /\            ___
/___/\__|_|\_|__|___Gian Uberto Lauri_____________________
  //--\ | | \|  |   Integralista GNUslamico  
\/		    e coltivatore diretto di software

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2005-03-08 21:02 ` Peter Dyballa
  2005-03-08 21:14   ` Re: Gian Uberto Lauri
@ 2005-03-08 21:24   ` Gian Uberto Lauri
  1 sibling, 0 replies; 246+ messages in thread
From: Gian Uberto Lauri @ 2005-03-08 21:24 UTC (permalink / raw)
  Cc: help-gnu-emacs

>>>>> "PD" == Peter Dyballa <Peter_Dyballa@Web.DE> writes:

PD> Am 08.03.2005 um 15:48 schrieb Gian Uberto Lauri:

>> (btw does someone know a free utility to repartition the disk to
>> make place to an healy Debian GNU/Linux ?).

PD> When you boot into Debian you're offered to repartition any Mac
PD> volume -- that's presumingly not that what you want? If so you
PD> could try to boot into OpenBSD or NetBSD. I think both have a tool
PD> to manipulate the partition table, change the type of partitions
PD> ...

I badly worded my sentence. What  I need is something to shrink Mac OS
X partition.

PD> Have you checked tucows? (http://mac.tucows.com/) Is Apple's pdisk
PD> not enough?

It seems that they don't have what I need. (BTW, it was free as in freedom :))

-- 
 /\            ___
/___/\__|_|\_|__|___Gian Uberto Lauri_____________________
  //--\ | | \|  |   Integralista GNUslamico  
\/		    e coltivatore diretto di software

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-03-20  5:29 info
  0 siblings, 0 replies; 246+ messages in thread
From: info @ 2005-03-20  5:29 UTC (permalink / raw)


^[$B40A4L5NA3NDj!*!*!*^[(B
^[$B:#$^$G!"El5~8BDj$@$C$?%5%$%H$,^[(B
^[$B9%I>$K$D$-!"A49q3HBg!*!*:#$,%A%c%s%9$G$9!#^[(B
^[$B"(%3%3$KEPO?$7$F$k=w$N;R$OK\Ev$G$9!#^[(B
1.^[$B5U!{=u4uK>=w@-^[(B
2.^[$B#S#M4uK>=w@-^[(B
3.^[$B:#F|=P2q$$$?$$=w@-^[(B
4.^[$BITNQ4uK>=w@-^[(B
^[$B$J$I$N=w@-=P2q$$J|Bj^[(B

^[$BAa$/$7$J$$$H#S#O#L#D!!#O#U#T^[(B
http://loves.qsv20.com/

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-03-28 15:10 info
  0 siblings, 0 replies; 246+ messages in thread
From: info @ 2005-03-28 15:10 UTC (permalink / raw)


:::. Оптовая рaспродaжa aксессуaров для сотовых телефонов! .:::

          !!! супер низкие цены !!!

 Зaрядные устройства (сетевые и автомобильные), корпуса, шнурки, брелки,
 чехлы из нaтуральной кожи, силиконовые и др. 


     +-- Тел. 8(O95)  68З-49-44 --+
   +-- Тел/Фaк: 8(O95) 188-89-46 --+
   +-- E-mail: igorkurilov@gawab.com --+




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-04-21  7:57 webmaster
  0 siblings, 0 replies; 246+ messages in thread
From: webmaster @ 2005-04-21  7:57 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 1152 bytes --]

Кoмпания "СУШИМАРКЕТ" - мы дoставляем удoвольствие
(O95) 225-25-ЗЗ 
Бесплатная дoставка блюд Японской кухни на дом и в офис!
Толькo самая свежая рыба и лучший рис!
ВЕСЕННЯЯ АКЦИЯ oт компании СУШИМАРКЕТ
До З1 мая - к каждoму заказу в ПОДАРОК РОЛЛ КАЛИФОРНИЯ!
ВСТРЕТИМ ВЕСНУ ВМЕСТЕ!
Суши:
• лосoсь – 4О.-
• тунец – 65.-
• угорь – 6O.-
• краб – 60.-
• Муки Эби (коктеильная креветка, икра летучей рыбы, авoкадo, спайс соус) – 70.-
• Тoри Унаги (угoрь, курица, спайс соус) – 6O.-
• «Do» - (яйцо, красная икра, майонез) – 5О.-
Роллы:
• Нара Маки – лосось, краб, латук, майонез. – 20O.-
• Филадельфия – угорь, спаржа, сыр Филадельфия, икра летучей рыбы. – 22О.-
• Спайс ролл «Бравo» - Краб, лосось, спайс соус. – 22О.-
• Марчибo (лoсось, угорь, сыр, авокадo, огурец, латук) – I4O.-
• «СушиДо» креветка в кляре, огурец, латук, икра летучей рыбы 290.-
• Омлет с угрем – I0O.-
Гoрячее:
• Пельмени с креветками – I80.-
• Плoв с мoрепродуктами – 160.-
• Мисo суп – 7O.-
• Суимонo суп – 90.-

А также: Сашими, Салаты, Напитки, Чай и Вoлшебные ассорти.

Оценить качествo нашей прoдукции Вы также мoжете в рестoране «Япoнский Пейзаж» 
пo адресу Ленинский пр-т l46.


[-- Attachment #1.1.2: Type: text/html, Size: 2911 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-05-04 17:05 info
  0 siblings, 0 replies; 246+ messages in thread
From: info @ 2005-05-04 17:05 UTC (permalink / raw)


...............тел. (905) 2039072................
...............тел. (095) 1363041................
.................ася 292593973................... 
..................сайт 8811.ws...................

Вы заинтересованы в увеличении количества клиентов? 

Обращаем Ваше внимание на то, что наша компания помогает решать 
подобные задачи стоящие перед Вашим бизнесом. 
Способ решения ваших проблем – электронные письма в сети Интернет!

........................................................
 ... Просто, легко, практично, конкретно, быстро! ...








БОРИСОВНЫ БЫВШЕЙ, Аркадий

Английские, Аомыне Академсеть

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-05-10 17:54 Mariorisa
  0 siblings, 0 replies; 246+ messages in thread
From: Mariorisa @ 2005-05-10 17:54 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 952 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-06-06 10:27 Нина
  0 siblings, 0 replies; 246+ messages in thread
From: Нина @ 2005-06-06 10:27 UTC (permalink / raw)


# ВCE СD-ДИCKИ - HOBИНКИ #
# HE TPEБУЮT ИHCTAЛЛЯЦИИ И 3AПУCKAЮТCЯ HEПOСРЕДCTBEHHO С КОMПАКT-ДИCКA #

* CD 1 ВCE ГOPOДА РOCСИИ 2OO5 (l2O гopoдов) ! NEW !
Koллeкция вeктopных элeктpoнных кapт нa l2O гoрoдa Poссии (cтoлицы cубъeктов Фeдepaции, кpупныe гоpодa): Mоcквa, Caнкт-Пeтepбург, Hижний Hoвгорoд, Eкатepинбург, Kpаснояpск, Caмарa, Oмcк, Hoвосибиpcк, Kpаснoдар, Bладивocток, Xабаpовcк и дp. + (пoиск, рeдактоp)

* CD 2 БOЛЬШOЙ АTЛАC РOCСИИ 2OO5 ! NEW  !
Kаpты Рoccии и CHГ - aдминиcтрaтивнo-пoлитичecкая (фeдeрaльныe окpугa, cубъeкты Фeдeрaции), гeoграфичecкая (публикyeтся впеpвыe) сo cпpавочникoм бoлеe l2O тыc. нacеленныx пyнктoв, жeлeзнодoрoжная и бoтaническaя. + (пoиск, редaктoр)

* CD 3 ЖEЛТЫE СTPАHИЦЫ МОCKBЫ + ПOДРОБНAЯ КAPТА МОCКBЫ
Coдeржитcя 200 OOO eдиниц инфopмaции o фиpмаx и оpганизaциях Moсквы и Мocковской oблаcти. Инфоpмациoнный блoк пo кaждoмy пpeдприятию включaeт ИHДЕКC, АДPEC, TЕЛЕФОH и т.д.

* CD 4 ВСE OТEЛИ PОСCИИ и ближнeгo зapубежья 2OO5 ! NEW !
Инфоpмaция o 283O отeляx в бoлеe 48O гoрoдаx Рoсcии и ближнeго заpубeжья. А тaкжe KEМПИНГИ, ПAНСИOHAТЫ, MOТEЛИ, TУPИСТИЧЕСКИE БA3Ы ОTДЫXА, СAHAТОPИИ.

* CD 5 АTЛАC АBTОМOБИЛЬHЫХ ДОPОГ 2005 ! NEW !
Hoвая пpoграммa с yлyчшеннoй гpaфикoй и peдактоpoм пoльзовaтельскoго слoя c вoзможнoстью пpoкладки мapшрутoв пo aвтoдорoгaм вплoть дo гpyнтовыx пo вceй тepритopии стpaны. + (пoиск, рeдaктоp, мapшрутизaтор, пoддержкa GРS)

* CD 6 КAРТA МИPA 2005 ! NEW !
Coвремeннaя пoлитичecкая каpтa миpa в видe глoбуca, a тaкжe кoллeкция из 47 каpт инocтранныx гоcyдарств, интepeсныx для тypизма, мacштабa 1:300 OOO - 1:4 OOO 000. Кapты кpyпных гoрoдoв миpa (Лoндoн, Пapиж, Бepлин и дp.) + (пoиск, pедактoр).

Цeнa oднoгo диcкa 25O рyблeй.
Пpи зaкaзe вcеx диcкoв oбщaя цeнa - 1OOO pублeй.
Вce пoдрoбноcти oплaты и пoлyчeния диcкoв:
SOWA @ GAWAB . COM (ввoдить 6eз пpoбелoв)











































сомнения.  И  вот,   чтобы   дать   почувствоватьсвою   значительность   и
признался мне,кчто y него  нет  опыта  сортировки  белой  сосны.  Он  стал
--Амнеидежпритулиться?--плаксивозагнусилхромой.--Ичтоже
nидентификаторпользователя
Полностью  совместимы  с  кабельными  сетями. Электротехнические  параметры,
превратился в желе, как следует нарезать его ломтиками, чтобы потом делать
ИменнотакимприемомпользуетсяЛоуэлиТомас,иповерьтемнеон
Сборнефтисповерхностиводоемов–это,очевидно,первыйповременипоявленияспособдобычи,которыйдонашейэрыприменялсявМидии,ВавилониииСирии.СборнефтивРоссии,споверхностирекиУхтыначатФ.С.Прядуновымв1745г.В1858на
троне. Верно, она была красивейшей женщиной мира. ho  ни  королевство,  ни
тайны, приносящей успех в деловых контактах...  Исключительно  внимание  к
темно-зеленая, поросшая  ряской,  поверхность  вздувалась упругими  волнами,
ушей   новое  замечание  взводного.  Увидев,  однако,  что  тот   собирается

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-06-13 21:36 Карина
  0 siblings, 0 replies; 246+ messages in thread
From: Карина @ 2005-06-13 21:36 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 1313 bytes --]

  Подари себе новые ощущения,  

 находясь в отремонтированной квартире.

  

    Мы можем сделать ремонт и в одной комнате. Можем сделать Вам студию,
объединив кухню и зал. Молодые и прогрессивные дизайнеры нашей небольшой
фирмы, подскажут и воплотят в реальность Ваши желания, создадут уют, который
будет гарантировать Вам приятный отдых, находясь дома.      
      Мы подскажем как разделить зону отдыха от зоны, где приходится делать
уроки, подберем Вам недорогие, но очень стильные предметы интерьера. Подбор
мебели тоже входит в наши возможности. Попробуем сделать все в максимально
сжатые сроки. Стоимость работ - средняя цена по Москве. Гарантия 18 месяцев.
  тел. 8-926-536-38-57

   
Благоустройство территорий:

       - асфальтировка – 300 руб.\кв.м
- парковка с основанием – 1400 руб.
- озеленение – от 7 до 10 см. – 150 руб. (чернозем)
- бордюры дорожные – 600 руб.\1 шт.
- тротуарная брусчатка – 700 руб.\кв.м. 

Цены регулируются в зависимости от объема работ. 

  тел. 8-926-536-38-57

     


























своего маленького сына. Мальчик был худосочный и отказывался есть сам.
"Какугадал",--подумалМетелица,вспомнивсвоипредположения.
президенту, он сказал, как говорят все президенты, что не будет возражать
от работы, если бы не считал, что дело это общее, затронуты обе стороны,
а  

[-- Attachment #1.1.2: Type: text/html, Size: 3369 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-06-14 23:56 Вера
  0 siblings, 0 replies; 246+ messages in thread
From: Вера @ 2005-06-14 23:56 UTC (permalink / raw)


Была на выставке Эрос-2005. Видела потрясающий товарчик. Держи
ссылку на www.RusGal.ru Не пожалеешь!




























"Иногдамыловимсебянатом,чтоменяемнашимнениябезвсякого
Внастоящеевремясуществуетпятьосновныхспособовподсоединенияк
обрадовавшись этому всему -- живому, яркому и бедному, что двигалось, дышало
выдержит и отменит свое приказание.
--Обождиздесь,--сказал,соскакиваяназемлюизабрасываяповодна
бугре неясно  заплясали  четыре конные  фигуры. Левинсон  свернул в кусты  и
Ейудалосьподнятьегонаноги,итак,увещеваяегоиотвлекаяот
ИринаЦарик
Таким образом, все химические, геохимические и геологические данные с несомненностью свидетельствуют об органическом происхождении нефти.
и  бессмысленно исполняли бы то дело, какое угодно было Колчаку?  Но это  же
сделанного за неделю. После обеда я ухожу к себе, открываю  свою  книгу  и
СН3–(СН2)6–СН2:СН2–(СН2)6–СН3t

^ permalink raw reply	[flat|nested] 246+ messages in thread

* re:
@ 2005-06-30 18:50 Alex Claire
  0 siblings, 0 replies; 246+ messages in thread
From: Alex Claire @ 2005-06-30 18:50 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 2411 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-07-05 23:11 Maxus
  0 siblings, 0 replies; 246+ messages in thread
From: Maxus @ 2005-07-05 23:11 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 132 bytes --]

 

a distraction from the holiness of Man, casting its doubt upon 
formative experience of my life, I tell thee, and it would do 

 

[-- Attachment #1.1.2: Type: text/html, Size: 542 bytes --]

[-- Attachment #1.2: hbdstc.gif --]
[-- Type: image/gif, Size: 5622 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-07-06 17:37 Ishok
  0 siblings, 0 replies; 246+ messages in thread
From: Ishok @ 2005-07-06 17:37 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 1292 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-08-11 16:17 от Александр
  0 siblings, 0 replies; 246+ messages in thread
From: от Александр @ 2005-08-11 16:17 UTC (permalink / raw)


Строительная компания ООО "КРИЭЙТ" выполняет: 

Строительство  коттеджей  и  домов  из  любого  материала а также сопутствующих построек беседок, бань и.т.д.  
Ремонтные  работы  любой  сложности  квартир  и  офисов. Инженерные сети и коммуникации (водоснабжение, отопление, вентиляция и электромонтажные работы).
Изготовление и установка под заказ клиента окон и дверей из трехслойного клееного бруса и пластика.
Заключение договора. Поэтапная оплата. Гарантия на работу. 

Лицензия : Д 575244

тел: (095)  743-64-94
                  514-31-49 
                  514-31-73

Изготавливаем и устанавливаем деревянные евро-окна, лоджии и двери под заказ

тел: (095) 514-31-49, 8-926-580-76-34.

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-08-29 20:51 Alifgin
  0 siblings, 0 replies; 246+ messages in thread
From: Alifgin @ 2005-08-29 20:51 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 1223 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-09-10 14:39 Abdulaim
  0 siblings, 0 replies; 246+ messages in thread
From: Abdulaim @ 2005-09-10 14:39 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 1223 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-09-18 14:11 Art
  0 siblings, 0 replies; 246+ messages in thread
From: Art @ 2005-09-18 14:11 UTC (permalink / raw)


[-- Attachment #1: Type: text/html, Size: 862 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-09-27 14:03 avtologistic
  0 siblings, 0 replies; 246+ messages in thread
From: avtologistic @ 2005-09-27 14:03 UTC (permalink / raw)


============================================================
Автомобильные грузоперевозки по России.
 
Имея собственный парк автотранспорта
от 15 куб. м до 120 куб.м, грузоподъемностью от 2 до 22 тонн, 
квалифицированные менеджеры позволят минимизировать расходы
по доставке Вашего груза. 


тел.(095) 920-1582, 8 - 916-119-06 05, avtologistic@postmaster.co.uk
============================================================

Автомобильные грузоперевозки от компании "Автологистик" 
- это гарантия надежной доставки Ваших грузов. 

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2005-12-03 23:03 solenoids
  0 siblings, 0 replies; 246+ messages in thread
From: solenoids @ 2005-12-03 23:03 UTC (permalink / raw)



From: The Desk of Mr.Peter Chang [Director]
Solenoids Industrial Co.Ltd.
55,An Suing East 9th Street,
Taichung, Taiwan.
Tel: 886-9162278842
Email: 
 
Dear Sir/Madam,
Solenoids Industrial Co. Ltd are exporters based in Taiwan. We export raw materials,such as Calcite,Barytes, Manganese Dioxide , Dolomite, Mica , China Clay, Mangnese Dioxide, Ferrous(Iron) Oxide, Paints, Rubber,Plastics, Construction chemicals, etc. We export from Asia into Europe, America and Australia.
Due to expansion, We would like to employ foreign services to work with us as our payment agent that will help in establishing a medium of recieving and disbursing payments on our behalf for goods and raw materials supplied to our customers in Europe, America or Australia. Please note that all neccesarry information required for establishing a convenient business working environment will be communicated to you once a business relationship is established between us.
Should you be interested in dealing with us as one of our foreign representatives, please communicate to us through the email provided below.
step01ca@email.com

Subject to your satisfaction you will be given the opportunity to negotiate your the mode of which we will pay for your services as our representative in either of these locations. Please be sure to include your phone/fax number and your full contact address.
Thank you as we await your urgent response.
 Regards ,
Mr.Peter Chang,
[Director]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2007-04-04 19:09 (unknown) Jost Burkardt
@ 2007-04-05  0:26 ` Jason F. McBrayer
  0 siblings, 0 replies; 246+ messages in thread
From: Jason F. McBrayer @ 2007-04-05  0:26 UTC (permalink / raw)
  To: Jost Burkardt; +Cc: emacs-orgmode

Jost Burkardt <jost.burkardt@web.de> writes:

> I really love the integration of remember with org, especially the way
> how to insert the notes by moving within the headings-tree. 
>
> Is it possible to use this feature also for moving portions of text
> via regular copy/paste an org-buffer, and have org automatically adapt
> the header levels? I didn't find anything in the manual.

C-c C-x C-w will cut a subtree, which you can paste with C-c C-x C-y,
and it will automatically adapt the header levels.  You can navigate
to where you want to insert it with C-c C-j, which works a lot like
selecting your place with org-remember.

-- 
+-----------------------------------------------------------+
| Jason F. McBrayer                    jmcbray@carcosa.net  |
| If someone conquers a thousand times a thousand others in |
| battle, and someone else conquers himself, the latter one |
| is the greatest of all conquerors.  --- The Dhammapada    |

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2008-08-06 15:50  Michaël Parienti
  2008-08-06 16:57 ` Re: Paul R
  0 siblings, 1 reply; 246+ messages in thread
From:  Michaël Parienti @ 2008-08-06 15:50 UTC (permalink / raw)
  To: Paul R; +Cc: emacs-orgmode

 
 Le mer 06/08/08 09:37, Paul R paul.r.ml@gmail.com a écrit:
> Hi Michaël,
> 
> On Mon, 4 Aug 2008 14:21:00 +0200, Michaël Parienti <michael
> @parienti.name> said:
> Michaël> Hi,
> 
> Michaël> After upgrading to orgmode version 6.05 (with an aptitude
> Michaël> dist-upgrade under a debian sid system), and changing my
> Michaël> configuration file to resolve the problem described here:
> Michaël> http://www.mail-archive.com/emacs-o
>
> rgmode@gnu.org/msg07167.html,
Michaël> I still have a problem when I type C-ca. I get the
> following
Michaël> error message:
> 
> Michaël> "Autoloading failed to define function org-agenda"


I uninstall one of my emacs version (the snapshot one) and keep
just the 22.2.1 version. I reinstall the org-mode package from
debian repository.

I am sure that I have only one version of the org-mode files
availables for emacs: I manually deleted source directory
(*..el files) and the *.elc files compiled for snapshot version
of emacs.

Here is the content of my load-path variable:
("/usr/share/emacs22/site-lisp/python-mode"
"/usr/share/emacs22/site-lisp/pymacs"
"/usr/share/emacs22/site-lisp/pymacs"
"/usr/share/emacs22/site-lisp/org-mode"
"/usr/share/emacs22/site-lisp/css-mode"
"/usr/share/emacs/site-lisp/css-mode"
"/usr/share/emacs22/site-lisp/a2ps"
"/usr/share/emacs22/site-lisp/wl"
"/usr/share/emacs22/site-lisp/semi"
"/usr/share/emacs22/site-lisp/w3m"
"/usr/share/emacs22/site-lisp/w3m/shimbun"
"/usr/share/emacs22/site-lisp/html-helper-mode" ...) available
in *Message* buffer. It seems troncated, but I don't know how to
get it complety.


-- 
Michaël Parienti

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2008-08-06 15:50 Re:  Michaël Parienti
@ 2008-08-06 16:57 ` Paul R
  0 siblings, 0 replies; 246+ messages in thread
From: Paul R @ 2008-08-06 16:57 UTC (permalink / raw)
  To: michael; +Cc: emacs-orgmode

On Wed, 6 Aug 2008 17:50:38 +0200, " Michaël Parienti" <michael@parienti.name> said:

Michaël> I uninstall one of my emacs version (the snapshot one) and
Michaël> keep just the 22.2.1 version. I reinstall the org-mode
Michaël> package from debian repository.

Michaël> I am sure that I have only one version of the org-mode files
Michaël> availables for emacs: I manually deleted source directory
Michaël> (*..el files) and the *.elc files compiled for snapshot
Michaël> version of emacs.

What happens if you (require 'org-install) before first call to org ?
If it works straight, then you may need to find where your default org
autoloads are defined. If it does not work, then you may need to
rebuild the org-install file. To do so, on debian, get your package
sources and run the build process. org-install.el is generated during
this process IIRC. Finally, depending on your conclusions, you can
write an email to the package maintainer to inform him that something
is wrong in its org package.

-- 
  Paul

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
       [not found] <CAFkz2yroLhknptDnWyC9B1fbZKEwTCV-T0VttHQiwZoaAW-j6A@mail.gmail.com>
@ 2012-12-20  8:36 ` Константин Куликов
  0 siblings, 0 replies; 246+ messages in thread
From: Константин Куликов @ 2012-12-20  8:36 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 2929 bytes --]

found how code it more correct:
No need to change anything in startup.el
Code for server.el will be:

          (unless (or files commands)
            (let ((type (type-of initial-buffer-choice)))
              (cond
               ((eq 'string type) (find-file initial-buffer-choice))
               ((eq 'buffer type) (switch-to-buffer initial-buffer-choice
                                                    'norecord))
               (t (switch-to-buffer (get-buffer-create "*scratch*")
                                    'norecord)))))

So, someone who has write access to emacs, maybe add this change to trunk?
(if u see no bugs with this code of course =p)


2012/12/20 Константин Куликов <zxnotdead@gmail.com>

> I discribed my problem here:
> http://comments.gmane.org/gmane.emacs.help/88218 .
> short:
> > when you run 'emacsclient -c' the new frame created and window in that
> frame is switched to
> > *scratch* buffer or file with name that is set in
> `initial-buffer-choice'.
> So, I can set `initial-buffer-choice' in the `after-make-frame-functions'
> to switch to buffer other than *scratch* on frame creation, but can't set
> somehow to buffer without underlying file.
>
> I found place where this behaviour handled(server.el:1258):
>
>       ;; If we were told only to open a new client, obey
>       ;; `initial-buffer-choice' if it specifies a file.
>       (unless (or files commands)
>         (if (stringp initial-buffer-choice)
>         (find-file initial-buffer-choice)
>           (switch-to-buffer (get-buffer-create "*scratch*")
>                 'norecord)))
>
> Changed it to this:
>       (unless (or files commands)
>             (typecase initial-buffer-choice
>               (string (find-file initial-buffer-choice))
>               (buffer (switch-to-buffer initial-buffer-choice 'norecord))
>               (t (switch-to-buffer (get-buffer-create "*scratch*")
>                                    'norecord)))
>
> then emacsclient -c it create frame and after short time destroys it with
> error:
> "*ERROR*: Wrong type argument: stringp, #<buffer *scratch*>"
>
> ok. I grepped sources, find startup.el:2325 :
>     (when initial-buffer-choice
>       (cond ((eq initial-buffer-choice t)
>          (switch-to-buffer (get-buffer-create "*scratch*")))
>         ((stringp initial-buffer-choice)
>          (find-file initial-buffer-choice))))
>
> replaced it to:
>     (when initial-buffer-choice
>       (typecase initial-buffer-choice
>         (symbol (when (eq initial-buffer-choice t)
>                   (switch-to-buffer (get-buffer-create "*scratch*"))))
>         (string (find-file initial-buffer-choice))
>         (buffer (switch-to-buffer initial-buffer-choice))))
>
> But still get same error:
> "*ERROR*: Wrong type argument: stringp, #<buffer *scratch*>"
>
> Any suggestions?
>
>

[-- Attachment #2: Type: text/html, Size: 4048 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2016-02-08  7:54 (unknown) steve
@ 2016-02-08 12:56 ` Artur Malabarba
  2016-02-08 19:05   ` Re: Steve Purcell
  0 siblings, 1 reply; 246+ messages in thread
From: Artur Malabarba @ 2016-02-08 12:56 UTC (permalink / raw)
  To: Steve Purcell; +Cc: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 215 bytes --]

> -     :prompt-regexp "^\\w*=[#>] "
> +     :prompt-regexp "^[[:alpha:]_]*=[#>] "

One thing that comes to mind is that \\w and :alpha: are generally not the
same thing. So \\(\\w\\|_\\) might be more appropriate.

[-- Attachment #2: Type: text/html, Size: 294 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2016-02-08 12:56 ` Artur Malabarba
@ 2016-02-08 19:05   ` Steve Purcell
  2016-02-08 20:16     ` Re: Artur Malabarba
  0 siblings, 1 reply; 246+ messages in thread
From: Steve Purcell @ 2016-02-08 19:05 UTC (permalink / raw)
  To: bruce.connor.am, emacs-devel


> On 9 Feb 2016, at 01:56, Artur Malabarba <bruce.connor.am@gmail.com> wrote:
> > -     :prompt-regexp "^\\w*=[#>] "
> > +     :prompt-regexp "^[[:alpha:]_]*=[#>] "
> 
> One thing that comes to mind is that \\w and :alpha: are generally not the same thing. So \\(\\w\\|_\\) might be more appropriate.
> 


Yes, possibly. And in fact :alnum: would be better than :alpha:, of course…

And since the rules for database names are probably much the same as for other SQL identifiers, there’s a chance \\s (symbol constituent) would work too.


^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2016-02-08 19:05   ` Re: Steve Purcell
@ 2016-02-08 20:16     ` Artur Malabarba
  0 siblings, 0 replies; 246+ messages in thread
From: Artur Malabarba @ 2016-02-08 20:16 UTC (permalink / raw)
  To: Steve Purcell; +Cc: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 433 bytes --]

On 8 Feb 2016 5:05 pm, "Steve Purcell" <steve@sanityinc.com> wrote:
> Yes, possibly. And in fact :alnum: would be better than :alpha:, of
course…
>
> And since the rules for database names are probably much the same as for
other SQL identifiers, there’s a chance \\s (symbol constituent) would work
too.

Yes. I'm not familiar with the fine details of SQL syntax, but \\w\\|\\s is
generally a better bet than just \\w.

[-- Attachment #2: Type: text/html, Size: 544 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2018-02-26 17:19                                         ` andrés ramírez
@ 2018-02-26 17:24                                           ` Daniel Colascione
  2018-02-27  1:53                                             ` Re: andrés ramírez
  0 siblings, 1 reply; 246+ messages in thread
From: Daniel Colascione @ 2018-02-26 17:24 UTC (permalink / raw)
  To: andrés ramírez
  Cc: Matthias Dahl, Lars Ingebrigtsen, eggert, Eli Zaretskii,
	emacs-devel

On 12/31/1969 04:00 PM,  wrote:
>> Why wouldn't the phone run a newer Emacs?
> 
> info 4.3 is not supported anymore which is installed on kernel 2.6.28.

Can't bootstrap a newer makeinfo?

> gtk 2.24. There is some hope on maemo-leste for having mainline on the
> n900 which is from the year 2009. Sorry guys droid does not have emacs with X. But this
> phone has it. If maemo leste is succesfull I could migrate to
> emacs-master once again. I have been running emacs on a touch phone see

I mean, if we can support Windows 95, we can support this ancient phone.

> my pic:
> https://transfer.sh/hOfuv/Screenshot-20180226-121458.png

Cool. I've wanted better mobile support for Emacs for ages. I've been 
disappointed with all the org-mode mobile client options, and I think 
there's no substitute for the real thing.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2018-02-26 17:24                                           ` Daniel Colascione
@ 2018-02-27  1:53                                             ` andrés ramírez
  0 siblings, 0 replies; 246+ messages in thread
From: andrés ramírez @ 2018-02-27  1:53 UTC (permalink / raw)
  To: Daniel Colascione
  Cc: Matthias Dahl, Lars Ingebrigtsen, eggert, Eli Zaretskii,
	emacs-devel

On Mon, 26 Feb 2018 11:24:16 -0600,
Daniel Colascione wrote:
> 
> On 12/31/1969 04:00 PM,  wrote:
> >> Why wouldn't the phone run a newer Emacs?
> > 
> > info 4.3 is not supported anymore which is installed on kernel 2.6.28.
> 
> Can't bootstrap a newer makeinfo?
I could compile with --without-makeinfo too. I remember I compiled the
previous release candidate of emacs there and found a bug on eww because
of these old libraries. But emacs-23 have also a small binary which is
paramount on those devices (see the nokia n800). Which I do not turn on
almost for a year now.
> 
> Cool. I've wanted better mobile support for Emacs for ages. I've been
> disappointed with all the org-mode mobile client options, and I think
> there's no substitute for the real thing.

Yes this phone is the real linux phone. I can make phone calls from
bbdb, text from bbdb also. store gps points when needed on a text
file (with a key combination). having with me all my org files is really nice. I need to
hildonize the emacs source code. It means replacing:

--8<---------------cut here---------------start------------->8---
wtop = gtk_window_new (GTK_WINDOW_TOPLEVEL);
on ~/abs/emacs-27.0.50/src/gtkutil.c
--8<---------------cut here---------------end--------------->8---

With
--8<---------------cut here---------------start------------->8---
wtop = hildon_window_new();
hildon_gtk_window_set_portrait_flags (GTK_WINDOW(window), HILDON_PORTRAIT_MODE_SUPPORT);
--8<---------------cut here---------------end--------------->8---

And Emacs is going to support screen rotation (portrait mode). On the
phone.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2021-11-04  6:36 Pedro Andres Aranda Gutierrez
  0 siblings, 0 replies; 246+ messages in thread
From: Pedro Andres Aranda Gutierrez @ 2021-11-04  6:36 UTC (permalink / raw)
  To: Eli Zaretskii, mardani29; +Cc: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 761 bytes --]

Hi,

I finally jumped into the cold water yesterday and migrated to Big Sur. I'm
not using HomeBrew but rather Rudix (looki for it in github) to Produce
packages with the libraries I need (gnutls and a couple more). I compile
emacs directly, create the app, use macholib to install all the frameworks
in the package and codesign it (self-signed, no developer key).

Additionally, I'm on emacs-28 right now and can report that the App I had
on Catalina has survived the migration and is running quite well on Big
Sur. I'm planning to compile emacs-28 in my next free slot on a Catalina
box and see if I can install in on Big Sur. Will report then.

Best, /PA
-- 
Fragen sind nicht da um beantwortet zu werden,
Fragen sind da um gestellt zu werden
Georg Kreisler

[-- Attachment #2: Type: text/html, Size: 1031 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
@ 2021-12-02 14:09 Angelo Graziosi
  0 siblings, 0 replies; 246+ messages in thread
From: Angelo Graziosi @ 2021-12-02 14:09 UTC (permalink / raw)
  To: emacs-devel@gnu.org, ofv@wanadoo.es

> Try this in your .emacs :
> 
> (let ((dir (file-name-directory (car command-line-args))))
>   (setenv "PATH" (concat (getenv "PATH") path-separator dir))
>   (setq exec-path (append exec-path (list dir))))

I tried this

(let ((dir (file-name-directory (car command-line-args))))
  (setenv "PATH" (concat (getenv "PATH") path-separator dir))
  (setq exec-path (append exec-path '("C:/msys64/mingw64/bin" "C:/msys64/usr/bin"))))

but it does not seem to work.

First, I had to change it this way

- ...setq exec-path (append exec-path (list dir)...
+ ...setq exec-path (append exec-path '(list dir)...

otherwise Emacs won't start.

Second, with that change only '...\Emacs\bin' is added to the PATH, not the MSYS2/MINGW64 paths...

Instead of change the init file, it is some year I use a Windows .lnk with 

Target: C:\Windows\System32\cmd.exe /c "SET path=C:\msys64\mingw64\bin;%path%&& SET PRELOAD_WINSOCK=1&& START /D ^"C:\LocalApps\Emacs\bin^" runemacs.exe"


Ciao,
  Angelo.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2021-12-20  2:29 (unknown) Davin Pearson
@ 2021-12-21 14:29 ` Eli Zaretskii
       [not found]   ` <CAG9ihEvK5VVgP9O+TXYSz+BQF1=YzMgzGBbc5s-fewwT34yytA@mail.gmail.com>
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2021-12-21 14:29 UTC (permalink / raw)
  To: Davin Pearson; +Cc: emacs-devel

> From: Davin Pearson <davin.pearson@gmail.com>
> Date: Mon, 20 Dec 2021 15:29:04 +1300
> 
> I was wondering if you could make the following improvement to
> GNU Emacs: Make it so that fonts with a nil for background-colour
> have the fontification of the inner symbols shines through
> to appear over higher layers, like so:
> 
> *abc* is fontified as a blue foreground with nil background
> 
> "*abc*" is fontified in light blue background with a black foreground
> but should appear with a light blue background and a blue foreground.

AFAIU, what you are asking basically goes against the way faces are
implemented in Emacs: when Emacs merges two faces, if both of them
specify the foreground color, one of them will "win", and the
foreground of the other will be ignored.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
       [not found]         ` <CAG9ihEv_OPaYhTgfh2WnfckC5r21U5Hv0qW7Msnwz4Bbvz6ccg@mail.gmail.com>
@ 2021-12-28 17:51           ` Eli Zaretskii
  2021-12-28 23:41             ` Re: Davin Pearson
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2021-12-28 17:51 UTC (permalink / raw)
  To: Davin Pearson; +Cc: emacs-devel

[Please keep the list address on the CC.]

> From: Davin Pearson <davin.pearson@gmail.com>
> Date: Tue, 28 Dec 2021 16:58:50 +1300
> 
> In your email to me you said that one of the foreground colours
> will "win" and the other will be ignored.  What I want is the
> same thing for the background colour.  As far as I understand the
> winning foreground colour will be the one that is added last in
> the fontification spec, and with the symbol 'end added to
> font-lock-add-keywords.
> 
> Here is my font-lock-string-face
> 
> "assdsdasd"
> 
> Here is the text dmp-asdssd coloured in my choice of colours: red
> and green:
> 
> "dmp-asdssd" (*)
> 
> Here is the code that fontifies the above code.
> 
> (make-face 'dmp-face--line0--col1-red)
> (set-face-foreground 'dmp-face--line0--col1-red "#ff0000")
> (set-face-background 'dmp-face--line0--col1-red nil)
> (make-face-bold 'dmp-face--line0--col1-red)
> 
> (make-face 'dmp-face--line0--col2-green)
> (set-face-foreground 'dmp-face--line0--col2-green "#00ff00")
> (set-face-background 'dmp-face--line0--col2-green nil)
> (make-face-bold 'dmp-face--line0--col2-green)
> 
> (make-face 'dmp-face--line0--col3-blue)
> (set-face-foreground 'dmp-face--line0--col3-blue "#0000ff")
> (set-face-background 'dmp-face--line0--col3-blue nil)
> (make-face-bold 'dmp-face--line0--col3-blue)
> 
> Here are some useful constant strings:
> 
> (defvar dmp-defun-inner-regexp-less-dash+star "a-zA-Z0-9_.!@$%^&=<>/|+:;?~")
> (defvar dmp-defun-inner-regexp-less-dash      (concat ""  dmp-defun-inner-regexp-less-dash+star))
> (defvar dmp-defun-inner-regexp-less-star      (concat "-"  dmp-defun-inner-regexp-less-dash+star))
> (defvar dmp-defun-inner-regexp                (concat "-," dmp-defun-inner-regexp-less-dash+star))
> (defvar dmp-defun-outer-regexp                (concat "["  dmp-defun-inner-regexp            "]+"))
> (defvar dmp-bra                               "\\(^\\|[][ \t\r\n()'\",.:=]\\)")
> (defvar dmp-ket                               "\\($\\|[][ \t\r\n()\",.:=]\\)")
> 
> Here is the actual font lock code:
> 
> (defun dmp-getting--syntax-highlighting--online ()
>   (font-lock-add-keywords
>    'emacs-lisp-mode
>    '(
>      (, (format "\\(dmp[0-9]\\)\\(\\(-[%s]+\\)+\\)%s"
>                 dmp-defun-inner-regexp-less-dash
>                 dmp-ket)
>         (1 'dmp-face--line0--col1-red t)
>         (2 'dmp-face--line0--col2-green t)
>         )
>      (, (format "\\(dmp[0-9]\\(-[%s]+\\)\\)\\(\\([-_][-_]\\|:\\)[%s]+\\)%s"
>                 dmp-defun-inner-regexp-less-dash
>                 dmp-defun-inner-regexp
>                 dmp-ket)
>         (1 'dmp-face--line0--col1-red t)
>         (3 'dmp-face--line0--col2-green t))
>      (, (format "\\(dmp[0-9]*\\(-[%s]+\\)*\\)\\([_-][_-][%s]+\\)\\([_-][_-][%s]+\\)%s"
>                 *dmp-defun-inner-regexp-less-dash*
>                 *dmp-defun-inner-regexp*
>                 *dmp-defun-inner-regexp*
>                 *dmp-ket*)
>         (1 'dmp-face--line0--col1-red t)
>         (3 'dmp-face--line0--col2-green t)
>         (4 'dmp-face--line0--col3-blue t))
>      )
>    'end)
>   )
> (add-hook 'font-lock-mode-hook 'dmp-getting--syntax-highlighting--online 'APPEND)
> 
> Notice that in the text marked with a (*) the background colour
> of the above text is the same as the background colour of the
> screen.
> 
> When dmp-face--line0--col1-red, dmp-face--line0--col2-green and
> dmp-face--line0--col3-blue 's set-face-foreground set to nil, as it
> is above, I want the for the string face's background colour to
> show through as light blue in the fontification of dmp-asdssd.

I think this is something that your code does.  If I just merge two
faces, one with a background color, the other with a foreground color,
the result of the merge has the background of the first faces and the
foreground of the second.

So I conclude that something goes wrong in your
dmp-getting--syntax-highlighting--on-line function, or in how it
interacts with font-lock.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2021-12-28 17:51           ` Re: Eli Zaretskii
@ 2021-12-28 23:41             ` Davin Pearson
  2021-12-31 15:23               ` Re: Anders Lindgren
  0 siblings, 1 reply; 246+ messages in thread
From: Davin Pearson @ 2021-12-28 23:41 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 4344 bytes --]

Could you please run my code on your machine to verify that it works on
your machine but not mine.

On Wed, 29 Dec 2021 at 06:51, Eli Zaretskii <eliz@gnu.org> wrote:

> [Please keep the list address on the CC.]
>
> > From: Davin Pearson <davin.pearson@gmail.com>
> > Date: Tue, 28 Dec 2021 16:58:50 +1300
> >
> > In your email to me you said that one of the foreground colours
> > will "win" and the other will be ignored.  What I want is the
> > same thing for the background colour.  As far as I understand the
> > winning foreground colour will be the one that is added last in
> > the fontification spec, and with the symbol 'end added to
> > font-lock-add-keywords.
> >
> > Here is my font-lock-string-face
> >
> > "assdsdasd"
> >
> > Here is the text dmp-asdssd coloured in my choice of colours: red
> > and green:
> >
> > "dmp-asdssd" (*)
> >
> > Here is the code that fontifies the above code.
> >
> > (make-face 'dmp-face--line0--col1-red)
> > (set-face-foreground 'dmp-face--line0--col1-red "#ff0000")
> > (set-face-background 'dmp-face--line0--col1-red nil)
> > (make-face-bold 'dmp-face--line0--col1-red)
> >
> > (make-face 'dmp-face--line0--col2-green)
> > (set-face-foreground 'dmp-face--line0--col2-green "#00ff00")
> > (set-face-background 'dmp-face--line0--col2-green nil)
> > (make-face-bold 'dmp-face--line0--col2-green)
> >
> > (make-face 'dmp-face--line0--col3-blue)
> > (set-face-foreground 'dmp-face--line0--col3-blue "#0000ff")
> > (set-face-background 'dmp-face--line0--col3-blue nil)
> > (make-face-bold 'dmp-face--line0--col3-blue)
> >
> > Here are some useful constant strings:
> >
> > (defvar dmp-defun-inner-regexp-less-dash+star
> "a-zA-Z0-9_.!@$%^&=<>/|+:;?~")
> > (defvar dmp-defun-inner-regexp-less-dash      (concat ""
> dmp-defun-inner-regexp-less-dash+star))
> > (defvar dmp-defun-inner-regexp-less-star      (concat "-"
> dmp-defun-inner-regexp-less-dash+star))
> > (defvar dmp-defun-inner-regexp                (concat "-,"
> dmp-defun-inner-regexp-less-dash+star))
> > (defvar dmp-defun-outer-regexp                (concat "["
> dmp-defun-inner-regexp            "]+"))
> > (defvar dmp-bra                               "\\(^\\|[][
> \t\r\n()'\",.:=]\\)")
> > (defvar dmp-ket                               "\\($\\|[][
> \t\r\n()\",.:=]\\)")
> >
> > Here is the actual font lock code:
> >
> > (defun dmp-getting--syntax-highlighting--online ()
> >   (font-lock-add-keywords
> >    'emacs-lisp-mode
> >    '(
> >      (, (format "\\(dmp[0-9]\\)\\(\\(-[%s]+\\)+\\)%s"
> >                 dmp-defun-inner-regexp-less-dash
> >                 dmp-ket)
> >         (1 'dmp-face--line0--col1-red t)
> >         (2 'dmp-face--line0--col2-green t)
> >         )
> >      (, (format
> "\\(dmp[0-9]\\(-[%s]+\\)\\)\\(\\([-_][-_]\\|:\\)[%s]+\\)%s"
> >                 dmp-defun-inner-regexp-less-dash
> >                 dmp-defun-inner-regexp
> >                 dmp-ket)
> >         (1 'dmp-face--line0--col1-red t)
> >         (3 'dmp-face--line0--col2-green t))
> >      (, (format
> "\\(dmp[0-9]*\\(-[%s]+\\)*\\)\\([_-][_-][%s]+\\)\\([_-][_-][%s]+\\)%s"
> >                 *dmp-defun-inner-regexp-less-dash*
> >                 *dmp-defun-inner-regexp*
> >                 *dmp-defun-inner-regexp*
> >                 *dmp-ket*)
> >         (1 'dmp-face--line0--col1-red t)
> >         (3 'dmp-face--line0--col2-green t)
> >         (4 'dmp-face--line0--col3-blue t))
> >      )
> >    'end)
> >   )
> > (add-hook 'font-lock-mode-hook 'dmp-getting--syntax-highlighting--online
> 'APPEND)
> >
> > Notice that in the text marked with a (*) the background colour
> > of the above text is the same as the background colour of the
> > screen.
> >
> > When dmp-face--line0--col1-red, dmp-face--line0--col2-green and
> > dmp-face--line0--col3-blue 's set-face-foreground set to nil, as it
> > is above, I want the for the string face's background colour to
> > show through as light blue in the fontification of dmp-asdssd.
>
> I think this is something that your code does.  If I just merge two
> faces, one with a background color, the other with a foreground color,
> the result of the merge has the background of the first faces and the
> foreground of the second.
>
> So I conclude that something goes wrong in your
> dmp-getting--syntax-highlighting--on-line function, or in how it
> interacts with font-lock.
>

[-- Attachment #2: Type: text/html, Size: 5772 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2021-12-28 23:41             ` Re: Davin Pearson
@ 2021-12-31 15:23               ` Anders Lindgren
  2022-01-02  1:15                 ` Re: Davin Pearson
  0 siblings, 1 reply; 246+ messages in thread
From: Anders Lindgren @ 2021-12-31 15:23 UTC (permalink / raw)
  To: Davin Pearson; +Cc: Eli Zaretskii, emacs-devel

[-- Attachment #1: Type: text/plain, Size: 5150 bytes --]

Hi!

I just noticed that all your font-lock rules have specified "t" as the
OVERRIDE flag. This has the effect that the face in the rule replaces the
existing face. Instead, if you use 'prepend' or 'append' it will place both
faces on the text. With 'append' the new face will come before the old
face. (If the two faces both define a face property, the first face in the
list takes precedence.)

You can check the result for yourself. If you eval '(buffer-substring
(point) (+ (point) 1))' where you want both faces to be applied, the value
of the 'face' property should be a list of faces.

    -- Anders

On Wed, Dec 29, 2021 at 12:43 AM Davin Pearson <davin.pearson@gmail.com>
wrote:

> Could you please run my code on your machine to verify that it works on
> your machine but not mine.
>
> On Wed, 29 Dec 2021 at 06:51, Eli Zaretskii <eliz@gnu.org> wrote:
>
>> [Please keep the list address on the CC.]
>>
>> > From: Davin Pearson <davin.pearson@gmail.com>
>> > Date: Tue, 28 Dec 2021 16:58:50 +1300
>> >
>> > In your email to me you said that one of the foreground colours
>> > will "win" and the other will be ignored.  What I want is the
>> > same thing for the background colour.  As far as I understand the
>> > winning foreground colour will be the one that is added last in
>> > the fontification spec, and with the symbol 'end added to
>> > font-lock-add-keywords.
>> >
>> > Here is my font-lock-string-face
>> >
>> > "assdsdasd"
>> >
>> > Here is the text dmp-asdssd coloured in my choice of colours: red
>> > and green:
>> >
>> > "dmp-asdssd" (*)
>> >
>> > Here is the code that fontifies the above code.
>> >
>> > (make-face 'dmp-face--line0--col1-red)
>> > (set-face-foreground 'dmp-face--line0--col1-red "#ff0000")
>> > (set-face-background 'dmp-face--line0--col1-red nil)
>> > (make-face-bold 'dmp-face--line0--col1-red)
>> >
>> > (make-face 'dmp-face--line0--col2-green)
>> > (set-face-foreground 'dmp-face--line0--col2-green "#00ff00")
>> > (set-face-background 'dmp-face--line0--col2-green nil)
>> > (make-face-bold 'dmp-face--line0--col2-green)
>> >
>> > (make-face 'dmp-face--line0--col3-blue)
>> > (set-face-foreground 'dmp-face--line0--col3-blue "#0000ff")
>> > (set-face-background 'dmp-face--line0--col3-blue nil)
>> > (make-face-bold 'dmp-face--line0--col3-blue)
>> >
>> > Here are some useful constant strings:
>> >
>> > (defvar dmp-defun-inner-regexp-less-dash+star
>> "a-zA-Z0-9_.!@$%^&=<>/|+:;?~")
>> > (defvar dmp-defun-inner-regexp-less-dash      (concat ""
>> dmp-defun-inner-regexp-less-dash+star))
>> > (defvar dmp-defun-inner-regexp-less-star      (concat "-"
>> dmp-defun-inner-regexp-less-dash+star))
>> > (defvar dmp-defun-inner-regexp                (concat "-,"
>> dmp-defun-inner-regexp-less-dash+star))
>> > (defvar dmp-defun-outer-regexp                (concat "["
>> dmp-defun-inner-regexp            "]+"))
>> > (defvar dmp-bra                               "\\(^\\|[][
>> \t\r\n()'\",.:=]\\)")
>> > (defvar dmp-ket                               "\\($\\|[][
>> \t\r\n()\",.:=]\\)")
>> >
>> > Here is the actual font lock code:
>> >
>> > (defun dmp-getting--syntax-highlighting--online ()
>> >   (font-lock-add-keywords
>> >    'emacs-lisp-mode
>> >    '(
>> >      (, (format "\\(dmp[0-9]\\)\\(\\(-[%s]+\\)+\\)%s"
>> >                 dmp-defun-inner-regexp-less-dash
>> >                 dmp-ket)
>> >         (1 'dmp-face--line0--col1-red t)
>> >         (2 'dmp-face--line0--col2-green t)
>> >         )
>> >      (, (format
>> "\\(dmp[0-9]\\(-[%s]+\\)\\)\\(\\([-_][-_]\\|:\\)[%s]+\\)%s"
>> >                 dmp-defun-inner-regexp-less-dash
>> >                 dmp-defun-inner-regexp
>> >                 dmp-ket)
>> >         (1 'dmp-face--line0--col1-red t)
>> >         (3 'dmp-face--line0--col2-green t))
>> >      (, (format
>> "\\(dmp[0-9]*\\(-[%s]+\\)*\\)\\([_-][_-][%s]+\\)\\([_-][_-][%s]+\\)%s"
>> >                 *dmp-defun-inner-regexp-less-dash*
>> >                 *dmp-defun-inner-regexp*
>> >                 *dmp-defun-inner-regexp*
>> >                 *dmp-ket*)
>> >         (1 'dmp-face--line0--col1-red t)
>> >         (3 'dmp-face--line0--col2-green t)
>> >         (4 'dmp-face--line0--col3-blue t))
>> >      )
>> >    'end)
>> >   )
>> > (add-hook 'font-lock-mode-hook
>> 'dmp-getting--syntax-highlighting--online 'APPEND)
>> >
>> > Notice that in the text marked with a (*) the background colour
>> > of the above text is the same as the background colour of the
>> > screen.
>> >
>> > When dmp-face--line0--col1-red, dmp-face--line0--col2-green and
>> > dmp-face--line0--col3-blue 's set-face-foreground set to nil, as it
>> > is above, I want the for the string face's background colour to
>> > show through as light blue in the fontification of dmp-asdssd.
>>
>> I think this is something that your code does.  If I just merge two
>> faces, one with a background color, the other with a foreground color,
>> the result of the merge has the background of the first faces and the
>> foreground of the second.
>>
>> So I conclude that something goes wrong in your
>> dmp-getting--syntax-highlighting--on-line function, or in how it
>> interacts with font-lock.
>>
>

[-- Attachment #2: Type: text/html, Size: 6885 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2021-12-31 15:23               ` Re: Anders Lindgren
@ 2022-01-02  1:15                 ` Davin Pearson
  2022-01-02  5:19                   ` Re: Stefan Monnier
  0 siblings, 1 reply; 246+ messages in thread
From: Davin Pearson @ 2022-01-02  1:15 UTC (permalink / raw)
  To: Anders Lindgren; +Cc: Eli Zaretskii, emacs-devel


[-- Attachment #1.1: Type: text/plain, Size: 6505 bytes --]

I have factored out enough code to make debugging
my code easier for yous.  Note that the 'append
and the 'prepend options do not appear to work.

The only code which shows some sense of elegance
is the t option which fontifies ghi but instead of showing
just one layer of fontification shows the string ghi in
the bold face (i.e. overwriting the font-lock-string-face).

(remove-hook 'font-lock-mode-hook 'dmp-my-fonts)
(add-hook 'font-lock-mode-hook 'dmp-my-fonts)

(defun dmp-my-fonts ()
  (font-lock-add-keywords
   'emacs-lisp-mode
   `(
     ("abc" 0 'bold 'append)
     ("def" 0 'bold 'prepend)
     ("ghi" 0 'bold t)
     ("jkl" 0 'bold 't)
     )
   'end))

(progn
  (setq abc 123)
  (setq def 123)
  (setq ghi 123)
  (setq jkl 123)
  )

 "abc" abc
 "def" def
 "ghi" ghi
 "jkl" jkl

(buffer-substring (point) (+ (point) 1)) evalled
on the above returns

#("e" 0 1 (fontified t face font-lock-string-face))

when evalled on the strings

and this on the symbols

#("e" 0 1 (fontified t))

except for ghi which returns

#("h" 0 1 (fontified t face bold))

See the attached file for a pictorial version of my code and what it does.

On Sat, 1 Jan 2022 at 04:23, Anders Lindgren <andlind@gmail.com> wrote:

> Hi!
>
> I just noticed that all your font-lock rules have specified "t" as the
> OVERRIDE flag. This has the effect that the face in the rule replaces the
> existing face. Instead, if you use 'prepend' or 'append' it will place both
> faces on the text. With 'append' the new face will come before the old
> face. (If the two faces both define a face property, the first face in the
> list takes precedence.)
>
> You can check the result for yourself. If you eval '(buffer-substring
> (point) (+ (point) 1))' where you want both faces to be applied, the value
> of the 'face' property should be a list of faces.
>
>     -- Anders
>
> On Wed, Dec 29, 2021 at 12:43 AM Davin Pearson <davin.pearson@gmail.com>
> wrote:
>
>> Could you please run my code on your machine to verify that it works on
>> your machine but not mine.
>>
>> On Wed, 29 Dec 2021 at 06:51, Eli Zaretskii <eliz@gnu.org> wrote:
>>
>>> [Please keep the list address on the CC.]
>>>
>>> > From: Davin Pearson <davin.pearson@gmail.com>
>>> > Date: Tue, 28 Dec 2021 16:58:50 +1300
>>> >
>>> > In your email to me you said that one of the foreground colours
>>> > will "win" and the other will be ignored.  What I want is the
>>> > same thing for the background colour.  As far as I understand the
>>> > winning foreground colour will be the one that is added last in
>>> > the fontification spec, and with the symbol 'end added to
>>> > font-lock-add-keywords.
>>> >
>>> > Here is my font-lock-string-face
>>> >
>>> > "assdsdasd"
>>> >
>>> > Here is the text dmp-asdssd coloured in my choice of colours: red
>>> > and green:
>>> >
>>> > "dmp-asdssd" (*)
>>> >
>>> > Here is the code that fontifies the above code.
>>> >
>>> > (make-face 'dmp-face--line0--col1-red)
>>> > (set-face-foreground 'dmp-face--line0--col1-red "#ff0000")
>>> > (set-face-background 'dmp-face--line0--col1-red nil)
>>> > (make-face-bold 'dmp-face--line0--col1-red)
>>> >
>>> > (make-face 'dmp-face--line0--col2-green)
>>> > (set-face-foreground 'dmp-face--line0--col2-green "#00ff00")
>>> > (set-face-background 'dmp-face--line0--col2-green nil)
>>> > (make-face-bold 'dmp-face--line0--col2-green)
>>> >
>>> > (make-face 'dmp-face--line0--col3-blue)
>>> > (set-face-foreground 'dmp-face--line0--col3-blue "#0000ff")
>>> > (set-face-background 'dmp-face--line0--col3-blue nil)
>>> > (make-face-bold 'dmp-face--line0--col3-blue)
>>> >
>>> > Here are some useful constant strings:
>>> >
>>> > (defvar dmp-defun-inner-regexp-less-dash+star
>>> "a-zA-Z0-9_.!@$%^&=<>/|+:;?~")
>>> > (defvar dmp-defun-inner-regexp-less-dash      (concat ""
>>> dmp-defun-inner-regexp-less-dash+star))
>>> > (defvar dmp-defun-inner-regexp-less-star      (concat "-"
>>> dmp-defun-inner-regexp-less-dash+star))
>>> > (defvar dmp-defun-inner-regexp                (concat "-,"
>>> dmp-defun-inner-regexp-less-dash+star))
>>> > (defvar dmp-defun-outer-regexp                (concat "["
>>> dmp-defun-inner-regexp            "]+"))
>>> > (defvar dmp-bra                               "\\(^\\|[][
>>> \t\r\n()'\",.:=]\\)")
>>> > (defvar dmp-ket                               "\\($\\|[][
>>> \t\r\n()\",.:=]\\)")
>>> >
>>> > Here is the actual font lock code:
>>> >
>>> > (defun dmp-getting--syntax-highlighting--online ()
>>> >   (font-lock-add-keywords
>>> >    'emacs-lisp-mode
>>> >    '(
>>> >      (, (format "\\(dmp[0-9]\\)\\(\\(-[%s]+\\)+\\)%s"
>>> >                 dmp-defun-inner-regexp-less-dash
>>> >                 dmp-ket)
>>> >         (1 'dmp-face--line0--col1-red t)
>>> >         (2 'dmp-face--line0--col2-green t)
>>> >         )
>>> >      (, (format
>>> "\\(dmp[0-9]\\(-[%s]+\\)\\)\\(\\([-_][-_]\\|:\\)[%s]+\\)%s"
>>> >                 dmp-defun-inner-regexp-less-dash
>>> >                 dmp-defun-inner-regexp
>>> >                 dmp-ket)
>>> >         (1 'dmp-face--line0--col1-red t)
>>> >         (3 'dmp-face--line0--col2-green t))
>>> >      (, (format
>>> "\\(dmp[0-9]*\\(-[%s]+\\)*\\)\\([_-][_-][%s]+\\)\\([_-][_-][%s]+\\)%s"
>>> >                 *dmp-defun-inner-regexp-less-dash*
>>> >                 *dmp-defun-inner-regexp*
>>> >                 *dmp-defun-inner-regexp*
>>> >                 *dmp-ket*)
>>> >         (1 'dmp-face--line0--col1-red t)
>>> >         (3 'dmp-face--line0--col2-green t)
>>> >         (4 'dmp-face--line0--col3-blue t))
>>> >      )
>>> >    'end)
>>> >   )
>>> > (add-hook 'font-lock-mode-hook
>>> 'dmp-getting--syntax-highlighting--online 'APPEND)
>>> >
>>> > Notice that in the text marked with a (*) the background colour
>>> > of the above text is the same as the background colour of the
>>> > screen.
>>> >
>>> > When dmp-face--line0--col1-red, dmp-face--line0--col2-green and
>>> > dmp-face--line0--col3-blue 's set-face-foreground set to nil, as it
>>> > is above, I want the for the string face's background colour to
>>> > show through as light blue in the fontification of dmp-asdssd.
>>>
>>> I think this is something that your code does.  If I just merge two
>>> faces, one with a background color, the other with a foreground color,
>>> the result of the merge has the background of the first faces and the
>>> foreground of the second.
>>>
>>> So I conclude that something goes wrong in your
>>> dmp-getting--syntax-highlighting--on-line function, or in how it
>>> interacts with font-lock.
>>>
>>

[-- Attachment #1.2: Type: text/html, Size: 8861 bytes --]

[-- Attachment #2: to-gnu.emacs.star-20220102-140746.png --]
[-- Type: image/png, Size: 370527 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2022-01-02  1:15                 ` Re: Davin Pearson
@ 2022-01-02  5:19                   ` Stefan Monnier
  2022-01-03  0:53                     ` Re: Davin Pearson
  0 siblings, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2022-01-02  5:19 UTC (permalink / raw)
  To: Davin Pearson; +Cc: Anders Lindgren, Eli Zaretskii, emacs-devel

>      ("abc" 0 'bold 'append)

No wonder it doesn't work: while the 3rd element of the above list is an
ELisp expression passed to `eval`, the 4th is not, so the quote before
`append` shouldn't be there.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2022-01-02  5:19                   ` Re: Stefan Monnier
@ 2022-01-03  0:53                     ` Davin Pearson
  0 siblings, 0 replies; 246+ messages in thread
From: Davin Pearson @ 2022-01-03  0:53 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Eli Zaretskii, Anders Lindgren, emacs-devel

[-- Attachment #1: Type: text/plain, Size: 515 bytes --]

Thanking you so much Anders for debugging my Elisp code.

Everything works perfectly fine with the quote removed from in front of the
append.

Thank you to Eli Zaretskii for your additional help!

On Sun, 2 Jan 2022 at 18:19, Stefan Monnier <monnier@iro.umontreal.ca>
wrote:

> >      ("abc" 0 'bold 'append)
>
> No wonder it doesn't work: while the 3rd element of the above list is an
> ELisp expression passed to `eval`, the 4th is not, so the quote before
> `append` shouldn't be there.
>
>
>         Stefan
>
>

[-- Attachment #2: Type: text/html, Size: 931 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2022-01-20 14:13 Roger Mason
@ 2022-01-20 19:57 ` Immanuel Litzroth
  2022-01-20 19:58   ` Re: Roger Mason
  0 siblings, 1 reply; 246+ messages in thread
From: Immanuel Litzroth @ 2022-01-20 19:57 UTC (permalink / raw)
  To: Roger Mason; +Cc: Org Mode Mailing List

Just going by what I see, not having tried it:
(setq haskell-process-args-stack-ghci (list "--ghci-options"
"-XFlexibleContexts"))

In your version the process gets 1 argument (with a space in it). In
my version it gets 2 args.
Immanuel

On Thu, Jan 20, 2022 at 8:22 PM Roger Mason <rmason@mun.ca> wrote:
>
> Hello,
>
> I want to run stack ghci from haskell blocks in org-mode.  For the
> task at I need to start ghci with command line option
> -XFlexibleContexts.  I have this in my org-mode buffer:
>
> #+begin_src emacs-lisp :results none
> (setq haskell-process-type 'stack-ghci)
> (setq haskell-process-args-stack-ghci (list "--ghci-options -XFlexibleContexts"))
> #+end_src
>
> but I get
>
> Process haskell exited abnormally with code 1
> Invalid option `--ghci-options -XFlexibleContexts'
>
> in the inferior haskell buffer.
>
> Does anyone know how to do what I want?
>
> Thanks,
> Roger
>


-- 
-- A man must either resolve to point out nothing new or to become a
slave to defend it. -- Sir Isaac Newton


^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
  2022-01-20 19:57 ` Immanuel Litzroth
@ 2022-01-20 19:58   ` Roger Mason
  0 siblings, 0 replies; 246+ messages in thread
From: Roger Mason @ 2022-01-20 19:58 UTC (permalink / raw)
  To: Immanuel Litzroth; +Cc: Org Mode Mailing List


Immanuel Litzroth <immanuel.litzroth@gmail.com> writes:

> Just going by what I see, not having tried it:
> (setq haskell-process-args-stack-ghci (list "--ghci-options"
> "-XFlexibleContexts"))
>
> In your version the process gets 1 argument (with a space in it). In
> my version it gets 2 args.
> Immanuel

Indeed, that was it.  Many thanks,
Roger


^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
@ 2023-01-04 14:48 Eric Gillespie
  2023-01-04 18:36 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Eric Gillespie @ 2023-01-04 14:48 UTC (permalink / raw)
  To: 60559

1. emacs -Q Cargo.toml
2. emacs -Q Dockerfile

Expected results:
Files opened without fanfare, as emacs always faithfully did for me
these last 25 years.

Actual results:
In both cases, a *Warnings* buffer pops up noisily occupying half the
screen and showing a bright red emoji saying:

	Warning (treesit): Cannot activate tree-sitter, because
	tree-sitter library is not compiled with Emacs

In GNU Emacs 29.0.60 (build 5, x86_64-pc-linux-gnu, X toolkit, cairo
 version 1.16.0) of 2023-01-03 built on dogato
Repository revision: da69f116bfc37d28942ca6d35eaff978e6805bac
Repository branch: emacs-29
Windowing system distributor 'The X.Org Foundation', version 11.0.12003000
System Description: openSUSE Leap 15.4

Configured using:
 'configure -C --prefix=/home/epg/.local --disable-silent-rules
 --without-libsystemd --without-xft --without-m17n-flt
 --without-toolkit-scroll-bars --without-gpm --without-dbus
 --without-gsettings --without-selinux --without-compress-install
 --with-x CC=gcc-11'

Configured features:
CAIRO FREETYPE GIF GLIB GMP GNUTLS HARFBUZZ JPEG JSON LIBXML2 MODULES
NOTIFY INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF WEBP
X11 XDBE XIM XINPUT2 XPM LUCID ZLIB

Important settings:
  value of $LC_CTYPE: en_US.UTF-8
  value of $XMODIFIERS: @im=ibus
  locale-coding-system: utf-8-unix

Major mode: Dockerfile

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message mailcap yank-media puny dired
dired-loaddefs rfc822 mml mml-sec password-cache epa derived epg rfc6068
epg-config gnus-util text-property-search time-date subr-x mm-decode
mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader
sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
dockerfile-ts-mode vc-git diff-mode easy-mmode vc-dispatcher warnings
icons toml-ts-mode treesit cl-seq cl-loaddefs cl-lib rmc iso-transl
tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks
lisp-float-type elisp-mode mwheel term/x-win x-win term/common-win x-dnd
tool-bar dnd fontset image regexp-opt fringe tabulated-list replace
newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar
rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock
font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq
simple cl-generic indonesian philippine cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese composite emoji-zwj charscript charprop case-table
epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button
loaddefs theme-loaddefs faces cus-face macroexp files window
text-properties overlay sha1 md5 base64 format env code-pages mule
custom widget keymap hashtable-print-readable backquote threads inotify
dynamic-setting font-render-setting cairo x-toolkit xinput2 x multi-tty
make-network-process emacs)

Memory information:
((conses 16 45439 9825)
 (symbols 48 5990 0)
 (strings 32 17025 1792)
 (string-bytes 1 480690)
 (vectors 16 11015)
 (vector-slots 8 167209 16484)
 (floats 8 28 39)
 (intervals 56 302 0)
 (buffers 976 13))





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 14:48 bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Eric Gillespie
@ 2023-01-04 18:36 ` Eli Zaretskii
  2023-01-04 19:40   ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-04 19:59   ` bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Stephen Berman
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-04 18:36 UTC (permalink / raw)
  To: Eric Gillespie; +Cc: 60559

tags 60559 notabug wontfix
thanks

> From: Eric Gillespie <epg@pretzelnet.org>
> Date: Wed, 04 Jan 2023 08:48:43 -0600
> 
> 1. emacs -Q Cargo.toml
> 2. emacs -Q Dockerfile
> 
> Expected results:
> Files opened without fanfare, as emacs always faithfully did for me
> these last 25 years.
> 
> Actual results:
> In both cases, a *Warnings* buffer pops up noisily occupying half the
> screen and showing a bright red emoji saying:
> 
> 	Warning (treesit): Cannot activate tree-sitter, because
> 	tree-sitter library is not compiled with Emacs

This is not a bug.  Emacs 29 comes with major modes for TOML files and
for Dockerfiles, and those new major modes require that you build
Emacs with the tree-sitter library (and install the corresponding
parser grammar libraries).  If you don't want to do that, you can
instead customize auto-mode-alist to make Emacs use Fundamental mode
(or any other mode you like) for these two file types.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 18:36 ` Eli Zaretskii
@ 2023-01-04 19:40   ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-04 20:03     ` Eli Zaretskii
  2023-01-04 19:59   ` bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Stephen Berman
  1 sibling, 1 reply; 246+ messages in thread
From: Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-01-04 19:40 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, Eric Gillespie

Eli Zaretskii <eliz@gnu.org> writes:

>
> This is not a bug.  Emacs 29 comes with major modes for TOML files and
> for Dockerfiles, and those new major modes require that you build
> Emacs with the tree-sitter library (and install the corresponding
> parser grammar libraries).  If you don't want to do that, you can
> instead customize auto-mode-alist to make Emacs use Fundamental mode
> (or any other mode you like) for these two file types.

Isn't this another manifestation of what's being discussed in bug#60511?
I also think that treesit-ready-p should not emit a warning by default,
it's too noisy and confusing for people that don't know about
Tree-sitter and consequently use a build of Emacs 29 without Tree-sitter
enabled.

Also, it's strange that, even if Tree-sitter is not configured at all, a
major mode whose description mentions Tree-sitter is apparently loaded.
The user will naturally doubt if the major mode works at all or not.
IMHO, Tree-sitter-only modes should not change the major mode if
treesit-ready-p returns nil.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 18:36 ` Eli Zaretskii
  2023-01-04 19:40   ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-01-04 19:59   ` Stephen Berman
  2023-01-04 20:10     ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Stephen Berman @ 2023-01-04 19:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, Eric Gillespie

On Wed, 04 Jan 2023 20:36:15 +0200 Eli Zaretskii <eliz@gnu.org> wrote:

> tags 60559 notabug wontfix
> thanks
>
>> From: Eric Gillespie <epg@pretzelnet.org>
>> Date: Wed, 04 Jan 2023 08:48:43 -0600
>>
>> 1. emacs -Q Cargo.toml
>> 2. emacs -Q Dockerfile
>>
>> Expected results:
>> Files opened without fanfare, as emacs always faithfully did for me
>> these last 25 years.
>>
>> Actual results:
>> In both cases, a *Warnings* buffer pops up noisily occupying half the
>> screen and showing a bright red emoji saying:
>>
>> 	Warning (treesit): Cannot activate tree-sitter, because
>> 	tree-sitter library is not compiled with Emacs
>
> This is not a bug.  Emacs 29 comes with major modes for TOML files and
> for Dockerfiles, and those new major modes require that you build
> Emacs with the tree-sitter library (and install the corresponding
> parser grammar libraries).  If you don't want to do that, you can
> instead customize auto-mode-alist to make Emacs use Fundamental mode
> (or any other mode you like) for these two file types.

Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
auto-mode-alist? (The default value of that variable in Emacs 29 still
contains an entry for conf-toml-mode, lower down than the entry for
toml-ts-mode.)

Steve Berman





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 19:40   ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-01-04 20:03     ` Eli Zaretskii
  2023-01-05  0:43       ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-05  6:51       ` Eli Zaretskii
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-04 20:03 UTC (permalink / raw)
  To: Daniel Martín; +Cc: 60559, epg

> From: Daniel Martín <mardani29@yahoo.es>
> Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
> Date: Wed, 04 Jan 2023 20:40:24 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >
> > This is not a bug.  Emacs 29 comes with major modes for TOML files and
> > for Dockerfiles, and those new major modes require that you build
> > Emacs with the tree-sitter library (and install the corresponding
> > parser grammar libraries).  If you don't want to do that, you can
> > instead customize auto-mode-alist to make Emacs use Fundamental mode
> > (or any other mode you like) for these two file types.
> 
> Isn't this another manifestation of what's being discussed in bug#60511?
> I also think that treesit-ready-p should not emit a warning by default,
> it's too noisy and confusing for people that don't know about
> Tree-sitter and consequently use a build of Emacs 29 without Tree-sitter
> enabled.

That is one use case.  The other, no less important one, is when the
user thinks his/her Emacs is built with tree-sitter and has the
relevant stuff installed, whereas the reality is different.  Silently
doing nothing in that case is hardly TRT.

So if we want to solve this, we need to find a solution that fits both
of these use cases.

> Also, it's strange that, even if Tree-sitter is not configured at all, a
> major mode whose description mentions Tree-sitter is apparently loaded.

I don't find it strange at all.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 19:59   ` bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Stephen Berman
@ 2023-01-04 20:10     ` Eli Zaretskii
  2023-01-04 20:33       ` Stephen Berman
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-04 20:10 UTC (permalink / raw)
  To: Stephen Berman; +Cc: 60559, epg

> From: Stephen Berman <stephen.berman@gmx.net>
> Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
> Date: Wed, 04 Jan 2023 20:59:04 +0100
> 
> >> 	Warning (treesit): Cannot activate tree-sitter, because
> >> 	tree-sitter library is not compiled with Emacs
> >
> > This is not a bug.  Emacs 29 comes with major modes for TOML files and
> > for Dockerfiles, and those new major modes require that you build
> > Emacs with the tree-sitter library (and install the corresponding
> > parser grammar libraries).  If you don't want to do that, you can
> > instead customize auto-mode-alist to make Emacs use Fundamental mode
> > (or any other mode you like) for these two file types.
> 
> Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
> toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
> auto-mode-alist? (The default value of that variable in Emacs 29 still
> contains an entry for conf-toml-mode, lower down than the entry for
> toml-ts-mode.)

We could indeed do that for TOML files, but I believe the problem
raised here is more general.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 20:10     ` Eli Zaretskii
@ 2023-01-04 20:33       ` Stephen Berman
  2023-01-05  6:41         ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Stephen Berman @ 2023-01-04 20:33 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, epg

On Wed, 04 Jan 2023 22:10:47 +0200 Eli Zaretskii <eliz@gnu.org> wrote:

>> From: Stephen Berman <stephen.berman@gmx.net>
>> Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
>> Date: Wed, 04 Jan 2023 20:59:04 +0100
>>
>> >> 	Warning (treesit): Cannot activate tree-sitter, because
>> >> 	tree-sitter library is not compiled with Emacs
>> >
>> > This is not a bug.  Emacs 29 comes with major modes for TOML files and
>> > for Dockerfiles, and those new major modes require that you build
>> > Emacs with the tree-sitter library (and install the corresponding
>> > parser grammar libraries).  If you don't want to do that, you can
>> > instead customize auto-mode-alist to make Emacs use Fundamental mode
>> > (or any other mode you like) for these two file types.
>>
>> Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
>> toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
>> auto-mode-alist? (The default value of that variable in Emacs 29 still
>> contains an entry for conf-toml-mode, lower down than the entry for
>> toml-ts-mode.)
>
> We could indeed do that for TOML files, but I believe the problem
> raised here is more general.

That may be, but the TOML case appears to be a regression, since
visiting a TOML file in Emacs 28 displays various faces but visiting a
TOML file in Emacs 29 without having the tree-sitter TOML grammar
library installed displays only the default face.  But if fixing the
more general problem in Emacs 29 also fixes this apparent regression,
then of course that's better than an ad hoc fix.

Steve Berman





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 20:03     ` Eli Zaretskii
@ 2023-01-05  0:43       ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-05  6:51       ` Eli Zaretskii
  1 sibling, 0 replies; 246+ messages in thread
From: Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-01-05  0:43 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, epg, Daniel Martín

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Daniel Martín <mardani29@yahoo.es>
>> Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
>> Date: Wed, 04 Jan 2023 20:40:24 +0100
>> 
>> Eli Zaretskii <eliz@gnu.org> writes:
>> 
>> >
>> > This is not a bug.  Emacs 29 comes with major modes for TOML files and
>> > for Dockerfiles, and those new major modes require that you build
>> > Emacs with the tree-sitter library (and install the corresponding
>> > parser grammar libraries).  If you don't want to do that, you can
>> > instead customize auto-mode-alist to make Emacs use Fundamental mode
>> > (or any other mode you like) for these two file types.
>> 
>> Isn't this another manifestation of what's being discussed in bug#60511?
>> I also think that treesit-ready-p should not emit a warning by default,
>> it's too noisy and confusing for people that don't know about
>> Tree-sitter and consequently use a build of Emacs 29 without Tree-sitter
>> enabled.
>
> That is one use case.  The other, no less important one, is when the
> user thinks his/her Emacs is built with tree-sitter and has the
> relevant stuff installed, whereas the reality is different.  Silently
> doing nothing in that case is hardly TRT.
>
> So if we want to solve this, we need to find a solution that fits both
> of these use cases.
>
>> Also, it's strange that, even if Tree-sitter is not configured at all, a
>> major mode whose description mentions Tree-sitter is apparently loaded.
>
> I don't find it strange at all.

Slightly unrelated to this bug.

I think we will have to find a way to bundle certain tree-sitter
grammars with Emacs.  On Android, system policy prohibits programs from
loading dynamic libraries that are not installed by the system in a read
only location upon installation of the application package itself, so
asking users to build those grammars will not work at all.

Android users typically have no C compiler installed either.

Thanks.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 20:33       ` Stephen Berman
@ 2023-01-05  6:41         ` Eli Zaretskii
  2023-01-05  7:46           ` Juri Linkov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  6:41 UTC (permalink / raw)
  To: Stephen Berman; +Cc: 60559, epg

> From: Stephen Berman <stephen.berman@gmx.net>
> Cc: epg@pretzelnet.org,  60559@debbugs.gnu.org
> Date: Wed, 04 Jan 2023 21:33:38 +0100
> 
> On Wed, 04 Jan 2023 22:10:47 +0200 Eli Zaretskii <eliz@gnu.org> wrote:
> 
> >> From: Stephen Berman <stephen.berman@gmx.net>
> >> Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
> >> Date: Wed, 04 Jan 2023 20:59:04 +0100
> >>
> >> >> 	Warning (treesit): Cannot activate tree-sitter, because
> >> >> 	tree-sitter library is not compiled with Emacs
> >> >
> >> > This is not a bug.  Emacs 29 comes with major modes for TOML files and
> >> > for Dockerfiles, and those new major modes require that you build
> >> > Emacs with the tree-sitter library (and install the corresponding
> >> > parser grammar libraries).  If you don't want to do that, you can
> >> > instead customize auto-mode-alist to make Emacs use Fundamental mode
> >> > (or any other mode you like) for these two file types.
> >>
> >> Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
> >> toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
> >> auto-mode-alist? (The default value of that variable in Emacs 29 still
> >> contains an entry for conf-toml-mode, lower down than the entry for
> >> toml-ts-mode.)
> >
> > We could indeed do that for TOML files, but I believe the problem
> > raised here is more general.
> 
> That may be, but the TOML case appears to be a regression, since
> visiting a TOML file in Emacs 28 displays various faces but visiting a
> TOML file in Emacs 29 without having the tree-sitter TOML grammar
> library installed displays only the default face.

I've now made toml-ts-mode an optional one, leaving conf-toml-mode as
the default.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-04 20:03     ` Eli Zaretskii
  2023-01-05  0:43       ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-01-05  6:51       ` Eli Zaretskii
  2023-01-05  7:06         ` Ihor Radchenko
                           ` (5 more replies)
  1 sibling, 6 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  6:51 UTC (permalink / raw)
  To: Fu Yuan, Stefan Monnier, Lars Ingebrigtsen, Theodor Thornhill,
	Jostein Kjønigsen
  Cc: 60559, epg, mardani29

> Cc: 60559@debbugs.gnu.org, epg@pretzelnet.org
> Date: Wed, 04 Jan 2023 22:03:12 +0200
> From: Eli Zaretskii <eliz@gnu.org>
> 
> > From: Daniel Martín <mardani29@yahoo.es>
> > Cc: Eric Gillespie <epg@pretzelnet.org>,  60559@debbugs.gnu.org
> > Date: Wed, 04 Jan 2023 20:40:24 +0100
> > 
> > Eli Zaretskii <eliz@gnu.org> writes:
> > 
> > >
> > > This is not a bug.  Emacs 29 comes with major modes for TOML files and
> > > for Dockerfiles, and those new major modes require that you build
> > > Emacs with the tree-sitter library (and install the corresponding
> > > parser grammar libraries).  If you don't want to do that, you can
> > > instead customize auto-mode-alist to make Emacs use Fundamental mode
> > > (or any other mode you like) for these two file types.
> > 
> > Isn't this another manifestation of what's being discussed in bug#60511?
> > I also think that treesit-ready-p should not emit a warning by default,
> > it's too noisy and confusing for people that don't know about
> > Tree-sitter and consequently use a build of Emacs 29 without Tree-sitter
> > enabled.
> 
> That is one use case.  The other, no less important one, is when the
> user thinks his/her Emacs is built with tree-sitter and has the
> relevant stuff installed, whereas the reality is different.  Silently
> doing nothing in that case is hardly TRT.
> 
> So if we want to solve this, we need to find a solution that fits both
> of these use cases.

So here's a suggestion for such a solution: we make all the
*-ts-mode's optional.  That is, we don't add any of them to
auto-mode-alist unless the file *-ts-mode.el is loaded, and we
document them all in NEWS and the user manual as optional.  users who
want them will have to manually activate them.  This way, the original
use case that started this bug report is automatically solved, and the
other use case, where the user intends to activate one of these modes,
is also served by showing the warning, which in that case is perfectly
justified: the user asked for something that we cannot do, so we warn
him/her.

This is a retreat of sorts, but I think it strikes a better balance
wrt user expectations, assuming not everyone will build with
tree-sitter.

Any comments or objections?  If not, I will do this in a couple of
days on the emacs-29 branch.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:51       ` Eli Zaretskii
@ 2023-01-05  7:06         ` Ihor Radchenko
  2023-01-05  7:44           ` Eli Zaretskii
  2023-01-05  7:57         ` Jostein Kjønigsen
                           ` (4 subsequent siblings)
  5 siblings, 1 reply; 246+ messages in thread
From: Ihor Radchenko @ 2023-01-05  7:06 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Fu Yuan, 60559, Theodor Thornhill, mardani29,
	Jostein Kjønigsen, Stefan Monnier, Lars Ingebrigtsen, epg

Eli Zaretskii <eliz@gnu.org> writes:

> So here's a suggestion for such a solution: we make all the
> *-ts-mode's optional.  That is, we don't add any of them to
> auto-mode-alist unless the file *-ts-mode.el is loaded

What if they are auto-loaded?

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  7:06         ` Ihor Radchenko
@ 2023-01-05  7:44           ` Eli Zaretskii
  2023-01-05  8:00             ` Ihor Radchenko
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  7:44 UTC (permalink / raw)
  To: Ihor Radchenko
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: Fu Yuan <casouri@gmail.com>, Stefan Monnier <monnier@iro.umontreal.ca>,
>  Lars Ingebrigtsen <larsi@gnus.org>, Theodor Thornhill <theo@thornhill.no>,
>  Jostein Kjønigsen <jostein@secure.kjonigsen.net>,
>  60559@debbugs.gnu.org,
>  epg@pretzelnet.org, mardani29@yahoo.es
> Date: Thu, 05 Jan 2023 07:06:24 +0000
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > So here's a suggestion for such a solution: we make all the
> > *-ts-mode's optional.  That is, we don't add any of them to
> > auto-mode-alist unless the file *-ts-mode.el is loaded
> 
> What if they are auto-loaded?

Autoloaded how?  IOW, what variable or function is autoloaded and
causes these modes to be automatically loaded?  And where do we have
or could have such code?





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:41         ` Eli Zaretskii
@ 2023-01-05  7:46           ` Juri Linkov
  2023-01-05  7:58             ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Juri Linkov @ 2023-01-05  7:46 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, Stephen Berman, epg

>> >> Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
>> >> toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
>> >> auto-mode-alist? (The default value of that variable in Emacs 29 still
>> >> contains an entry for conf-toml-mode, lower down than the entry for
>> >> toml-ts-mode.)
>> >
>> > We could indeed do that for TOML files, but I believe the problem
>> > raised here is more general.
>>
>> That may be, but the TOML case appears to be a regression, since
>> visiting a TOML file in Emacs 28 displays various faces but visiting a
>> TOML file in Emacs 29 without having the tree-sitter TOML grammar
>> library installed displays only the default face.
>
> I've now made toml-ts-mode an optional one, leaving conf-toml-mode as
> the default.

So now non-ts users are satisfied at the expense of ts users.

Why not to do the right thing:

(add-to-list 'auto-mode-alist `("\\.toml\\'" .
  ,(if (treesit-ready-p 'toml) 'toml-ts-mode 'conf-toml-mode)))





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:51       ` Eli Zaretskii
  2023-01-05  7:06         ` Ihor Radchenko
@ 2023-01-05  7:57         ` Jostein Kjønigsen
  2023-01-05  8:12           ` Eli Zaretskii
  2023-01-05  8:44         ` Gregory Heytings
                           ` (3 subsequent siblings)
  5 siblings, 1 reply; 246+ messages in thread
From: Jostein Kjønigsen @ 2023-01-05  7:57 UTC (permalink / raw)
  To: Eli Zaretskii, Fu Yuan, Stefan Monnier, Lars Ingebrigtsen,
	Theodor Thornhill
  Cc: 60559, epg, mardani29

On 05.01.2023 07:51, Eli Zaretskii wrote:
>
> So here's a suggestion for such a solution: we make all the
> *-ts-mode's optional.  That is, we don't add any of them to
> auto-mode-alist unless the file *-ts-mode.el is loaded

So if I understand this correctly, the change is simply that people 
wanting to use these modes now needs to do two things instead of one:

1. build with tree-sitter support (already a requirement)

2. will have to (require) the modes they want to use in their init.el 
(the change)

Have I understood things correctly? If so, that sounds perfectly 
reasonable to me.

--
Jostein





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  7:46           ` Juri Linkov
@ 2023-01-05  7:58             ` Eli Zaretskii
  2023-01-05 14:59               ` Eric Gillespie
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  7:58 UTC (permalink / raw)
  To: Juri Linkov; +Cc: 60559, stephen.berman, epg

> From: Juri Linkov <juri@linkov.net>
> Cc: Stephen Berman <stephen.berman@gmx.net>,  60559@debbugs.gnu.org,
>   epg@pretzelnet.org
> Date: Thu, 05 Jan 2023 09:46:48 +0200
> 
> >> >> Emacs 28 already has conf-toml-mode for TOML files, so shouldn't
> >> >> toml-ts-mode be handled like e.g. c-ts-mode instead of being added to
> >> >> auto-mode-alist? (The default value of that variable in Emacs 29 still
> >> >> contains an entry for conf-toml-mode, lower down than the entry for
> >> >> toml-ts-mode.)
> >> >
> >> > We could indeed do that for TOML files, but I believe the problem
> >> > raised here is more general.
> >>
> >> That may be, but the TOML case appears to be a regression, since
> >> visiting a TOML file in Emacs 28 displays various faces but visiting a
> >> TOML file in Emacs 29 without having the tree-sitter TOML grammar
> >> library installed displays only the default face.
> >
> > I've now made toml-ts-mode an optional one, leaving conf-toml-mode as
> > the default.
> 
> So now non-ts users are satisfied at the expense of ts users.

The cost for the latter is simple: require toml-ts-mode in the init
file.

> Why not to do the right thing:
> 
> (add-to-list 'auto-mode-alist `("\\.toml\\'" .
>   ,(if (treesit-ready-p 'toml) 'toml-ts-mode 'conf-toml-mode)))

Because I don't want to risk any breakage by last-minute changes.  Do
we want to release Emacs 29 soon, or do we want to keep developing it
for another year?





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  7:44           ` Eli Zaretskii
@ 2023-01-05  8:00             ` Ihor Radchenko
  2023-01-05  8:26               ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Ihor Radchenko @ 2023-01-05  8:00 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

Eli Zaretskii <eliz@gnu.org> writes:

>> What if they are auto-loaded?
>
> Autoloaded how?  IOW, what variable or function is autoloaded and
> causes these modes to be automatically loaded?  And where do we have
> or could have such code?

Auto-completion.

1. emacs -Q
2. M-: (featurep 'go-ts-mode)  ; => nil
3. <F1> f go-ts- <TAB> mode <RET>
4. M-:  (featurep 'go-ts-mode)  ; => t

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  7:57         ` Jostein Kjønigsen
@ 2023-01-05  8:12           ` Eli Zaretskii
  2023-01-05  8:32             ` Jostein Kjønigsen
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  8:12 UTC (permalink / raw)
  To: jostein; +Cc: casouri, 60559, theo, mardani29, monnier, larsi, epg

> Date: Thu, 5 Jan 2023 08:57:05 +0100
> Cc: 60559@debbugs.gnu.org, mardani29@yahoo.es, epg@pretzelnet.org
> From: Jostein Kjønigsen <jostein@secure.kjonigsen.net>
> 
> On 05.01.2023 07:51, Eli Zaretskii wrote:
> >
> > So here's a suggestion for such a solution: we make all the
> > *-ts-mode's optional.  That is, we don't add any of them to
> > auto-mode-alist unless the file *-ts-mode.el is loaded
> 
> So if I understand this correctly, the change is simply that people 
> wanting to use these modes now needs to do two things instead of one:
> 
> 1. build with tree-sitter support (already a requirement)
> 
> 2. will have to (require) the modes they want to use in their init.el 
> (the change)
> 
> Have I understood things correctly?

Yes, that's the idea.  We could also make the mode command be
autoloaded, so just "M-x foo-ts-mode RET" the first time will load the
mode, thus avoiding the need for require in the init files.  I guess
there will be users which will prefer one or the other.

> If so, that sounds perfectly reasonable to me.

Thanks.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:00             ` Ihor Radchenko
@ 2023-01-05  8:26               ` Eli Zaretskii
  2023-01-05  8:40                 ` Ihor Radchenko
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  8:26 UTC (permalink / raw)
  To: Ihor Radchenko
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, 60559@debbugs.gnu.org,
>  epg@pretzelnet.org, mardani29@yahoo.es
> Date: Thu, 05 Jan 2023 08:00:09 +0000
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> What if they are auto-loaded?
> >
> > Autoloaded how?  IOW, what variable or function is autoloaded and
> > causes these modes to be automatically loaded?  And where do we have
> > or could have such code?
> 
> Auto-completion.
> 
> 1. emacs -Q
> 2. M-: (featurep 'go-ts-mode)  ; => nil
> 3. <F1> f go-ts- <TAB> mode <RET>
> 4. M-:  (featurep 'go-ts-mode)  ; => t

I cannot reproduce this with toml-ts-mode on the emacs-29 branch.
go-ts-mode is still the default for Go files, but toml-ts-mode is not
the default for TOML files.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:12           ` Eli Zaretskii
@ 2023-01-05  8:32             ` Jostein Kjønigsen
  0 siblings, 0 replies; 246+ messages in thread
From: Jostein Kjønigsen @ 2023-01-05  8:32 UTC (permalink / raw)
  To: Eli Zaretskii, jostein
  Cc: casouri, 60559, theo, mardani29, monnier, larsi, epg

On 05.01.2023 09:12, Eli Zaretskii wrote:
>> Date: Thu, 5 Jan 2023 08:57:05 +0100
>> Cc: 60559@debbugs.gnu.org, mardani29@yahoo.es, epg@pretzelnet.org
>> From: Jostein Kjønigsen <jostein@secure.kjonigsen.net>
>>
>>
>> So if I understand this correctly, the change is simply that people
>> wanting to use these modes now needs to do two things instead of one:
>>
>> 1. build with tree-sitter support (already a requirement)
>>
>> 2. will have to (require) the modes they want to use in their init.el
>> (the change)
>>
>> Have I understood things correctly?
> Yes, that's the idea.  We could also make the mode command be
> autoloaded, so just "M-x foo-ts-mode RET" the first time will load the
> mode, thus avoiding the need for require in the init files.  I guess
> there will be users which will prefer one or the other.
>
If we assume that distros are going to be building with 
treesitter-support sooner rather than later, I guess that would be the 
absolutely smoothest way we can have for users to have this working OOB, 
without causing issues for users/distros building without such support.

I definitely support such an approach if it's doable without too much 
effort or risk.

--

Jostein







^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:26               ` Eli Zaretskii
@ 2023-01-05  8:40                 ` Ihor Radchenko
  2023-01-05  8:42                   ` Ihor Radchenko
  2023-01-05  8:52                   ` Eli Zaretskii
  0 siblings, 2 replies; 246+ messages in thread
From: Ihor Radchenko @ 2023-01-05  8:40 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

Eli Zaretskii <eliz@gnu.org> writes:

>> Auto-completion.
>> 
>> 1. emacs -Q
>> 2. M-: (featurep 'go-ts-mode)  ; => nil
>> 3. <F1> f go-ts- <TAB> mode <RET>
>> 4. M-:  (featurep 'go-ts-mode)  ; => t
>
> I cannot reproduce this with toml-ts-mode on the emacs-29 branch.
> go-ts-mode is still the default for Go files, but toml-ts-mode is not
> the default for TOML files.

I just checked, and I cannot reproduce on emacs-29 branch with both
go-ts-mode and toml-ts-mode. <TAB> in (3) simply don't trigger
completion (and thus no auto-loading). Presumably because auto-loading
on completion is not yet available.

The above steps only work on master.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:40                 ` Ihor Radchenko
@ 2023-01-05  8:42                   ` Ihor Radchenko
  2023-01-05  8:54                     ` Eli Zaretskii
  2023-01-05  8:52                   ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Ihor Radchenko @ 2023-01-05  8:42 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

Ihor Radchenko <yantar92@posteo.net> writes:

> The above steps only work on master.

That said, is the approach when require produce side effects a good
approach? I have been told in another thread that side effects during
loading should be avoided if possible - they may create surprises to
users.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:51       ` Eli Zaretskii
  2023-01-05  7:06         ` Ihor Radchenko
  2023-01-05  7:57         ` Jostein Kjønigsen
@ 2023-01-05  8:44         ` Gregory Heytings
  2023-01-05  8:48           ` Gregory Heytings
  2023-01-05  8:56           ` Eli Zaretskii
  2023-01-05 13:17         ` Dmitry Gutov
                           ` (2 subsequent siblings)
  5 siblings, 2 replies; 246+ messages in thread
From: Gregory Heytings @ 2023-01-05  8:44 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Fu Yuan, 60559, Theodor Thornhill, mardani29,
	Jostein Kjønigsen, Stefan Monnier, Lars Ingebrigtsen, epg


>
> So here's a suggestion for such a solution: we make all the *-ts-mode's 
> optional.  That is, we don't add any of them to auto-mode-alist unless 
> the file *-ts-mode.el is loaded, and we document them all in NEWS and 
> the user manual as optional.  users who want them will have to manually 
> activate them.  This way, the original use case that started this bug 
> report is automatically solved, and the other use case, where the user 
> intends to activate one of these modes, is also served by showing the 
> warning, which in that case is perfectly justified: the user asked for 
> something that we cannot do, so we warn him/her.
>

I suggest a slightly different solution: add a global minor mode, say 
'ts-modes'.  Users would only have to add (ts-modes 1) in their init 
files, and the logic would be:

(treesit-available-p) ts-modes
nil                   nil      => do nothing
nil                   t        => warning
t                     nil      => use available tree-sitter modes
t                     t        => use available tree-sitter modes

This seems more future-proof: otherwise users who want to user the 
available tree-sitter modes would have to require all such modes.  ATM 
there are only 19, but Emacs 30 could very well have twice or thrice that 
number of tree-sitter modes.






^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:44         ` Gregory Heytings
@ 2023-01-05  8:48           ` Gregory Heytings
  2023-01-05  9:00             ` Eli Zaretskii
  2023-01-05  8:56           ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Gregory Heytings @ 2023-01-05  8:48 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Fu Yuan, 60559, Theodor Thornhill, mardani29,
	Jostein Kjønigsen, Stefan Monnier, Lars Ingebrigtsen, epg


>
> I suggest a slightly different solution: add a global minor mode, say 
> 'ts-modes'.  Users would only have to add (ts-modes 1) in their init 
> files, and the logic would be:
>
> (treesit-available-p) ts-modes
> nil                   nil      => do nothing
> nil                   t        => warning
> t                     nil      => use available tree-sitter modes
> t                     t        => use available tree-sitter modes
>
> This seems more future-proof: otherwise users who want to user the 
> available tree-sitter modes would have to require all such modes.  ATM 
> there are only 19, but Emacs 30 could very well have twice or thrice 
> that number of tree-sitter modes.
>

And perhaps we could even add a third value for ts-modes, say "no".  In 
that case tree-sitter modes would not be used even if they are available. 
Users may prefer, for one reason or another, to not use them even if they 
are available because their system administrator installed them.






^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:40                 ` Ihor Radchenko
  2023-01-05  8:42                   ` Ihor Radchenko
@ 2023-01-05  8:52                   ` Eli Zaretskii
  2023-01-05  9:05                     ` Ihor Radchenko
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  8:52 UTC (permalink / raw)
  To: Ihor Radchenko
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, 60559@debbugs.gnu.org,
>  epg@pretzelnet.org, mardani29@yahoo.es
> Date: Thu, 05 Jan 2023 08:40:33 +0000
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> Auto-completion.
> >> 
> >> 1. emacs -Q
> >> 2. M-: (featurep 'go-ts-mode)  ; => nil
> >> 3. <F1> f go-ts- <TAB> mode <RET>
> >> 4. M-:  (featurep 'go-ts-mode)  ; => t
> >
> > I cannot reproduce this with toml-ts-mode on the emacs-29 branch.
> > go-ts-mode is still the default for Go files, but toml-ts-mode is not
> > the default for TOML files.
> 
> I just checked, and I cannot reproduce on emacs-29 branch with both
> go-ts-mode and toml-ts-mode. <TAB> in (3) simply don't trigger
> completion (and thus no auto-loading). Presumably because auto-loading
> on completion is not yet available.
> 
> The above steps only work on master.

Which change on master has this effect?  I cannot find anything in
NEWS.

Moreover, doing the above on master with c-ts-mode and toml-ts-mode I
cannot reproduce the behavior you describe.  Only go-ts-mode does
reproduce it.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:42                   ` Ihor Radchenko
@ 2023-01-05  8:54                     ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  8:54 UTC (permalink / raw)
  To: Ihor Radchenko
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, 60559@debbugs.gnu.org,
>  epg@pretzelnet.org, mardani29@yahoo.es
> Date: Thu, 05 Jan 2023 08:42:31 +0000
> 
> Ihor Radchenko <yantar92@posteo.net> writes:
> 
> > The above steps only work on master.
> 
> That said, is the approach when require produce side effects a good
> approach? I have been told in another thread that side effects during
> loading should be avoided if possible - they may create surprises to
> users.

Yes, this "should be avoided if possible".  So if someone shows a way
of doing this some other way, but without adding any additional
complexity wrt what the user should do to activate these modes, I'm
all ears.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:44         ` Gregory Heytings
  2023-01-05  8:48           ` Gregory Heytings
@ 2023-01-05  8:56           ` Eli Zaretskii
  1 sibling, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  8:56 UTC (permalink / raw)
  To: Gregory Heytings
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> Date: Thu, 05 Jan 2023 08:44:30 +0000
> From: Gregory Heytings <gregory@heytings.org>
> cc: Fu Yuan <casouri@gmail.com>, Stefan Monnier <monnier@iro.umontreal.ca>, 
>     Lars Ingebrigtsen <larsi@gnus.org>, Theodor Thornhill <theo@thornhill.no>, 
>     Jostein Kjønigsen <jostein@secure.kjonigsen.net>, 
>     60559@debbugs.gnu.org, epg@pretzelnet.org, mardani29@yahoo.es
> 
> I suggest a slightly different solution: add a global minor mode, say 
> 'ts-modes'.  Users would only have to add (ts-modes 1) in their init 
> files, and the logic would be:
> 
> (treesit-available-p) ts-modes
> nil                   nil      => do nothing
> nil                   t        => warning
> t                     nil      => use available tree-sitter modes
> t                     t        => use available tree-sitter modes
> 
> This seems more future-proof: otherwise users who want to user the 
> available tree-sitter modes would have to require all such modes.  ATM 
> there are only 19, but Emacs 30 could very well have twice or thrice that 
> number of tree-sitter modes.

Thanks.  This was already considered.  I don't like asking users to
customize a list as a means of activating an optional mode.  I also
don't think we have enough information for committing ourselves to
such a solution at this stage.

So I'd prefer not to do this on the release branch.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:48           ` Gregory Heytings
@ 2023-01-05  9:00             ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-05  9:00 UTC (permalink / raw)
  To: Gregory Heytings
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

> Date: Thu, 05 Jan 2023 08:48:11 +0000
> From: Gregory Heytings <gregory@heytings.org>
> cc: Fu Yuan <casouri@gmail.com>, 60559@debbugs.gnu.org, 
>     Theodor Thornhill <theo@thornhill.no>, mardani29@yahoo.es, 
>     Jostein Kjønigsen <jostein@secure.kjonigsen.net>, 
>     Stefan Monnier <monnier@iro.umontreal.ca>, 
>     Lars Ingebrigtsen <larsi@gnus.org>, epg@pretzelnet.org
> 
> > I suggest a slightly different solution: add a global minor mode, say 
> > 'ts-modes'.  Users would only have to add (ts-modes 1) in their init 
> > files, and the logic would be:
> >
> > (treesit-available-p) ts-modes
> > nil                   nil      => do nothing
> > nil                   t        => warning
> > t                     nil      => use available tree-sitter modes
> > t                     t        => use available tree-sitter modes
> >
> > This seems more future-proof: otherwise users who want to user the 
> > available tree-sitter modes would have to require all such modes.  ATM 
> > there are only 19, but Emacs 30 could very well have twice or thrice 
> > that number of tree-sitter modes.
> 
> And perhaps we could even add a third value for ts-modes, say "no".  In 
> that case tree-sitter modes would not be used even if they are available. 
> Users may prefer, for one reason or another, to not use them even if they 
> are available because their system administrator installed them.

We discussed a minor mode approach, and discovered it doesn't work
well enough, because different modes need different considerations.

Moreover, silently doing something depending on whether
treesit-available-p returns nil is not the best UX, as I explained
up-thread.  Actually loading a mode that the user wants is much more
natural and easy.

P.S. Please disregard the previous email about customizing a list: I
was confused when I wrote it.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  8:52                   ` Eli Zaretskii
@ 2023-01-05  9:05                     ` Ihor Radchenko
  0 siblings, 0 replies; 246+ messages in thread
From: Ihor Radchenko @ 2023-01-05  9:05 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: casouri, 60559, theo, mardani29, jostein, monnier, larsi, epg

Eli Zaretskii <eliz@gnu.org> writes:

>> The above steps only work on master.
>
> Which change on master has this effect?  I cannot find anything in
> NEWS.

I am referring to `help-enable-autoload'.
I think there were some fixes or improvement to `help-enable-autoload'
behaviour recently.

> Moreover, doing the above on master with c-ts-mode and toml-ts-mode I
> cannot reproduce the behavior you describe.  Only go-ts-mode does
> reproduce it.

I confirm. I don't know why. AFAIU, `help-enable-autoload' should
trigger autoloading in all three cases according to its docstring.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:51       ` Eli Zaretskii
                           ` (2 preceding siblings ...)
  2023-01-05  8:44         ` Gregory Heytings
@ 2023-01-05 13:17         ` Dmitry Gutov
  2023-01-05 14:02         ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
  5 siblings, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-05 13:17 UTC (permalink / raw)
  To: Eli Zaretskii, Fu Yuan, Stefan Monnier, Lars Ingebrigtsen,
	Theodor Thornhill, Jostein Kjønigsen
  Cc: 60559, mardani29, epg

On 05/01/2023 08:51, Eli Zaretskii wrote:
> So here's a suggestion for such a solution: we make all the
> *-ts-mode's optional.  That is, we don't add any of them to
> auto-mode-alist unless the file *-ts-mode.el is loaded, and we
> document them all in NEWS and the user manual as optional.  users who
> want them will have to manually activate them.  This way, the original
> use case that started this bug report is automatically solved, and the
> other use case, where the user intends to activate one of these modes,
> is also served by showing the warning, which in that case is perfectly
> justified: the user asked for something that we cannot do, so we warn
> him/her.

Personally, I'd rather the users be made aware that they can install 
such-and-such grammars and enjoy good support for the file types they 
just visited.

I understand that it can be a bother for people who are used to just 
editing such files using fundamental-mode, but they could similarly 
complain if we added a major mode (for a given file type) that is 
functional but still different from the "last 25 years".

So I agree with your original assessment that it's not a bug.

What we could do here, though, to reduce the aggravation:

- Move the warning to *Messages*. It will be slightly less noticeable, 
but won't occupy "half the screen" either.

and/or

- Add a new defcustom which would allow people to silence the 
tree-sitter related warnings altogether. tree-sitter major modes without 
available grammars work more or less like fundamental-mode.

Or we can just recommend such users edit their auto-mode-alist to 
associate fundamental-mode with those file types. That only takes a few 
minutes.





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  6:51       ` Eli Zaretskii
                           ` (3 preceding siblings ...)
  2023-01-05 13:17         ` Dmitry Gutov
@ 2023-01-05 14:02         ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
  5 siblings, 0 replies; 246+ messages in thread
From: Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2023-01-05 14:02 UTC (permalink / raw)
  To: Eli Zaretskii, Fu Yuan, Stefan Monnier, Lars Ingebrigtsen,
	Jostein Kjønigsen
  Cc: 60559, epg, mardani29

> So here's a suggestion for such a solution: we make all the
> *-ts-mode's optional.  That is, we don't add any of them to
> auto-mode-alist unless the file *-ts-mode.el is loaded, and we
> document them all in NEWS and the user manual as optional.  users who
> want them will have to manually activate them.  This way, the original
> use case that started this bug report is automatically solved, and the
> other use case, where the user intends to activate one of these modes,
> is also served by showing the warning, which in that case is perfectly
> justified: the user asked for something that we cannot do, so we warn
> him/her.
>
> This is a retreat of sorts, but I think it strikes a better balance
> wrt user expectations, assuming not everyone will build with
> tree-sitter.
>
> Any comments or objections?  If not, I will do this in a couple of
> days on the emacs-29 branch.

Sounds good to me :-)





^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05  7:58             ` Eli Zaretskii
@ 2023-01-05 14:59               ` Eric Gillespie
  2023-01-22 13:24                 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Eric Gillespie @ 2023-01-05 14:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: 60559, stephen.berman, Juri Linkov

Eli Zaretskii <eliz@gnu.org> writes:

> thanks

You're welcome.

> This is not a bug.

Okay.

> Because I don't want to risk any breakage by last-minute changes.  Do
> we want to release Emacs 29 soon, or do we want to keep developing it
> for another year?

It seems to me the safest approach for a release is the
conservative approach.  The more gradual a change, the less
likely an embarassing release or rushed follow-on patch release.

All this discussion has been interesting, but it seems to me it
is mostly focused on a world where not only tree-sitter is
common, but all those grammar libraries are as well!

I think very few emacs users in 2023 live in that world.

If emacs was configured with tree-sitter, it seems productive to
warn the user when tree-sitter grammars are missing.  It seems
likely that user intended to have tree-sitter.

When emacs is NOT configured with tree-sitter, it seems
counter-productive to warn about missing tree-sitter.

I even pass --without-tree-sitter to configure now.  It seems
particularly surprising to me that I explicitly tell emacs "don't
use tree-sitter" and then it immediately starts complaining to me
that it doesn't have tree-sitter.

Thanks everyone!





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Make all tree-sitter modes optional
  2023-01-05  6:51       ` Eli Zaretskii
                           ` (4 preceding siblings ...)
  2023-01-05 14:02         ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2023-01-15 14:01         ` Eli Zaretskii
  2023-01-15 23:39           ` Dmitry Gutov
                             ` (2 more replies)
  5 siblings, 3 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-15 14:01 UTC (permalink / raw)
  To: casouri, monnier, larsi, theo, jostein; +Cc: emacs-devel

This came out of the discussion in bug#60559 and other related
discussions, where I said:

> So here's a suggestion for such a solution: we make all the
> *-ts-mode's optional.  That is, we don't add any of them to
> auto-mode-alist unless the file *-ts-mode.el is loaded, and we
> document them all in NEWS and the user manual as optional.  users who
> want them will have to manually activate them.  This way, the original
> use case that started this bug report is automatically solved, and the
> other use case, where the user intends to activate one of these modes,
> is also served by showing the warning, which in that case is perfectly
> justified: the user asked for something that we cannot do, so we warn
> him/her.
> 
> This is a retreat of sorts, but I think it strikes a better balance
> wrt user expectations, assuming not everyone will build with
> tree-sitter.

The proposed change to the current emacs-29 branch is below.  You will
see that where possible, just loading a TS mode modifies
auto-mode-alist if the tree-sitter support for that mode is available,
whereas for other modes auto-mode-alist is modified only when the mode
is actually turned on successfully for the first time.  This is
because some of the TS modes have their own *.el files, whereas others
share a .el file with other modes, and so loading that file doesn't
necessarily means the user wants to use the tree-sitter based mode.

With these changes, users are supposed to turn the mode manually when
they want to use it, or customize auto-mode-alist in their init files
to turn those modes automatically for certain files.  Modes that have
their own *.el files can be just 'require'd in the init file to modify
auto-mode-alist.

This arrangement is perhaps not ideal, but I think it is safe enough
and simple enough to go into Emacs 29.

Comments? objections? ideas for improvements?  I will install in a few
days, barring any serious problems.

Here's the patch:

diff --git a/etc/NEWS b/etc/NEWS
index d1ddd01..996134c 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -34,13 +34,14 @@ This feature existed in Emacs 28.1, but was less easy to request.
 
 +++
 ** Emacs can be built with the tree-sitter parsing library.
-This library, together with grammar libraries, provides incremental
-parsing capabilities for several popular programming languages and
-other formatted files.  Emacs built with this library offers major
-modes, described elsewhere in this file, that are based on the
-tree-sitter's parsers.  If you have the tree-sitter library
-installed, the configure script will automatically include it in the
-build; use '--without-tree-sitter' at configure time to disable that.
+This library, together with separate grammar libraries for each
+language, provides incremental parsing capabilities for several
+popular programming languages and other formatted files.  Emacs built
+with this library offers major modes, described elsewhere in this
+file, that are based on the tree-sitter's parsers.  If you have the
+tree-sitter library installed, the configure script will automatically
+include it in the build; use '--without-tree-sitter' at configure time
+to disable that.
 
 Emacs modes based on the tree-sitter library require an additional
 grammar library for each mode.  These grammar libraries provide the
@@ -3181,19 +3182,10 @@ indentation, and navigation by defuns based on parsing the buffer text
 by a tree-sitter parser.  Some major modes also offer support for
 Imenu and 'which-func'.
 
-Where major modes already exist in Emacs for editing certain kinds of
-files, the new modes based on tree-sitter are for now entirely
-optional, and you must turn them on manually, or customize
-'auto-mode-alist' to turn them on automatically.
-
-Where no major modes previously existed in Emacs for editing the kinds
-of files for which Emacs now provides a tree-sitter based mode, Emacs
-will now try to enable these new modes automatically when you visit
-such files, and will display a warning if the tree-sitter library or
-the parser grammar library is not available.  To prevent the warnings,
-either build Emacs with tree-sitter and install the grammar libraries,
-or customize 'auto-mode-alist' to specify some other major mode (or
-even 'fundamental-mode') for those kinds of files.
+The new modes based on tree-sitter are for now entirely optional, and
+you must turn them on manually, or load them in your init file, or
+customize 'auto-mode-alist' to turn them on automatically for certain
+files.
 
 Each major mode based on tree-sitter needs a language grammar library,
 usually named "libtree-sitter-LANG.so" ("libtree-sitter-LANG.dll" on
@@ -3210,20 +3202,18 @@ We recommend to install these libraries in one of the standard system
 locations (the last place in the above list).
 
 If a language grammar library required by a mode is not found in any
-of the above places, the mode will signal an error when you try to
+of the above places, the mode will display a warning when you try to
 turn it on.
 
 +++
 *** New major mode 'typescript-ts-mode'.
 A major mode based on the tree-sitter library for editing programs
-in the TypeScript language.  This mode is auto-enabled for files with
-the ".ts" extension.
+in the TypeScript language.
 
 +++
 *** New major mode 'tsx-ts-mode'.
 A major mode based on the tree-sitter library for editing programs
-in the TypeScript language, with support for TSX.  This mode is
-auto-enabled for files with the ".tsx" extension.
+in the TypeScript language, with support for TSX.
 
 +++
 *** New major mode 'c-ts-mode'.
@@ -3268,15 +3258,12 @@ Bash shell scripts.
 +++
 *** New major mode 'dockerfile-ts-mode'.
 A major mode based on the tree-sitter library for editing
-Dockerfiles.  This mode is auto-enabled for files which are named
-"Dockerfile", have the "Dockerfile." prefix, or have the ".dockerfile"
-extension.
+Dockerfiles.
 
 +++
 *** New major mode 'cmake-ts-mode'.
 A major mode based on the tree-sitter library for editing CMake files.
-It is auto-enabled for files whose name is "CMakeLists.txt" or whose
-extension is ".cmake".
+
 
 +++
 *** New major mode 'toml-ts-mode'.
@@ -3286,23 +3273,22 @@ files written in TOML, a format for writing configuration files.
 +++
 *** New major mode 'go-ts-mode'.
 A major mode based on the tree-sitter library for editing programs in
-the Go language.  It is auto-enabled for files with the ".go" extension.
+the Go language.
 
 +++
 *** New major mode 'go-mod-ts-mode'.
 A major mode based on the tree-sitter library for editing "go.mod"
-files.  It is auto-enabled for files which are named "go.mod".
+files.
 
 +++
 *** New major mode 'yaml-ts-mode'.
 A major mode based on the tree-sitter library for editing files
-written in YAML.  It is auto-enabled for files with the ".yaml" or
-".yml" extensions.
+written in YAML.
 
 +++
 *** New major mode 'rust-ts-mode'.
 A major mode based on the tree-sitter library for editing programs in
-the Rust language.  It is auto-enabled for files with the ".rs" extension.
+the Rust language.
 
 ---
 *** New major mode 'ruby-ts-mode'.
diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el
index 89a08a6..d004920 100644
--- a/lisp/progmodes/c-ts-mode.el
+++ b/lisp/progmodes/c-ts-mode.el
@@ -972,6 +972,19 @@ c++-ts-mode
     (setq-local treesit-font-lock-settings (c-ts-mode--font-lock-settings 'cpp))
     (treesit-major-mode-setup)))
 
+;; The entries for C++ must come first to prevent *.c files be taken
+;; as C++ on case-insensitive filesystems, since *.C files are C++,
+;; not C.
+(if (treesit-ready-p 'cpp)
+    (add-to-list 'auto-mode-alist
+                 '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
+                   . c++-ts-mode)))
+
+(if (treesit-ready-p 'c)
+    (add-to-list 'auto-mode-alist
+                 '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'"
+                   . c-ts-mode)))
+
 (provide 'c-ts-mode)
 
 ;;; c-ts-mode.el ends here
diff --git a/lisp/progmodes/cmake-ts-mode.el b/lisp/progmodes/cmake-ts-mode.el
index a31250f..c241a28 100644
--- a/lisp/progmodes/cmake-ts-mode.el
+++ b/lisp/progmodes/cmake-ts-mode.el
@@ -195,10 +195,6 @@ cmake-ts-mode--imenu-1
       `((,name . ,marker))))))
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist
-             '("\\(?:CMakeLists\\.txt\\|\\.cmake\\)\\'" . cmake-ts-mode))
-
-;;;###autoload
 (define-derived-mode cmake-ts-mode prog-mode "CMake"
   "Major mode for editing CMake files, powered by tree-sitter."
   :group 'cmake
@@ -229,6 +225,10 @@ cmake-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'cmake)
+    (add-to-list 'auto-mode-alist
+                 '("\\(?:CMakeLists\\.txt\\|\\.cmake\\)\\'" . cmake-ts-mode)))
+
 (provide 'cmake-ts-mode)
 
 ;;; cmake-ts-mode.el ends here
diff --git a/lisp/progmodes/csharp-mode.el b/lisp/progmodes/csharp-mode.el
index 81ce416..04f7f22 100644
--- a/lisp/progmodes/csharp-mode.el
+++ b/lisp/progmodes/csharp-mode.el
@@ -884,9 +884,6 @@ csharp-ts-mode--defun-name
       t))))
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.cs\\'" . csharp-mode))
-
-;;;###autoload
 (define-derived-mode csharp-mode prog-mode "C#"
   "Major mode for editing Csharp code.
 
@@ -941,7 +938,9 @@ csharp-ts-mode
                 ("Struct" "\\`struct_declaration\\'" nil nil)
                 ("Method" "\\`method_declaration\\'" nil nil)))
 
-  (treesit-major-mode-setup))
+  (treesit-major-mode-setup)
+
+  (add-to-list 'auto-mode-alist '("\\.cs\\'" . csharp-ts-mode)))
 
 (provide 'csharp-mode)
 
diff --git a/lisp/progmodes/dockerfile-ts-mode.el b/lisp/progmodes/dockerfile-ts-mode.el
index 3f8766e..2a295e8 100644
--- a/lisp/progmodes/dockerfile-ts-mode.el
+++ b/lisp/progmodes/dockerfile-ts-mode.el
@@ -133,12 +133,6 @@ dockerfile-ts-mode--imenu-1
       `((,name . ,marker))))))
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist
-             ;; NOTE: We can't use `rx' here, as it breaks bootstrap.
-             '("\\(?:Dockerfile\\(?:\\..*\\)?\\|\\.[Dd]ockerfile\\)\\'"
-               . dockerfile-ts-mode))
-
-;;;###autoload
 (define-derived-mode dockerfile-ts-mode prog-mode "Dockerfile"
   "Major mode for editing Dockerfiles, powered by tree-sitter."
   :group 'dockerfile
@@ -172,6 +166,12 @@ dockerfile-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'dockerfile)
+    (add-to-list 'auto-mode-alist
+                 ;; NOTE: We can't use `rx' here, as it breaks bootstrap.
+                 '("\\(?:Dockerfile\\(?:\\..*\\)?\\|\\.[Dd]ockerfile\\)\\'"
+                   . dockerfile-ts-mode)))
+
 (provide 'dockerfile-ts-mode)
 
 ;;; dockerfile-ts-mode.el ends here
diff --git a/lisp/progmodes/go-ts-mode.el b/lisp/progmodes/go-ts-mode.el
index 64e761d..d552e13 100644
--- a/lisp/progmodes/go-ts-mode.el
+++ b/lisp/progmodes/go-ts-mode.el
@@ -175,9 +175,6 @@ go-ts-mode--font-lock-settings
   "Tree-sitter font-lock settings for `go-ts-mode'.")
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.go\\'" . go-ts-mode))
-
-;;;###autoload
 (define-derived-mode go-ts-mode prog-mode "Go"
   "Major mode for editing Go, powered by tree-sitter."
   :group 'go
@@ -226,6 +223,9 @@ go-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'go)
+    (add-to-list 'auto-mode-alist '("\\.go\\'" . go-ts-mode)))
+
 (defun go-ts-mode--defun-name (node)
   "Return the defun name of NODE.
 Return nil if there is no name or if NODE is not a defun node."
@@ -346,9 +346,6 @@ go-mod-ts-mode--font-lock-settings
   "Tree-sitter font-lock settings for `go-mod-ts-mode'.")
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("/go\\.mod\\'" . go-mod-ts-mode))
-
-;;;###autoload
 (define-derived-mode go-mod-ts-mode prog-mode "Go Mod"
   "Major mode for editing go.mod files, powered by tree-sitter."
   :group 'go
@@ -376,6 +373,9 @@ go-mod-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'gomod)
+    (add-to-list 'auto-mode-alist '("/go\\.mod\\'" . go-mod-ts-mode)))
+
 (provide 'go-ts-mode)
 
 ;;; go-ts-mode.el ends here
diff --git a/lisp/progmodes/java-ts-mode.el b/lisp/progmodes/java-ts-mode.el
index d29fcd8..d909a36 100644
--- a/lisp/progmodes/java-ts-mode.el
+++ b/lisp/progmodes/java-ts-mode.el
@@ -331,6 +331,9 @@ java-ts-mode
                 ("Method" "\\`method_declaration\\'" nil nil)))
   (treesit-major-mode-setup))
 
+(if (treesit-ready-p 'java)
+    (add-to-list 'auto-mode-alist '("\\.java\\'" . java-ts-mode)))
+
 (provide 'java-ts-mode)
 
 ;;; java-ts-mode.el ends here
diff --git a/lisp/progmodes/js.el b/lisp/progmodes/js.el
index 058c890..4428672 100644
--- a/lisp/progmodes/js.el
+++ b/lisp/progmodes/js.el
@@ -3840,7 +3840,10 @@ js-ts-mode
                                         "method_definition")
                                 eos)
                    nil nil)))
-    (treesit-major-mode-setup)))
+    (treesit-major-mode-setup)
+
+    (add-to-list 'auto-mode-alist
+                 '("\\(\\.js[mx]\\|\\.har\\)\\'" . js-ts-mode))))
 
 ;;;###autoload
 (define-derived-mode js-json-mode js-mode "JSON"
diff --git a/lisp/progmodes/json-ts-mode.el b/lisp/progmodes/json-ts-mode.el
index fbcda22..f54d018 100644
--- a/lisp/progmodes/json-ts-mode.el
+++ b/lisp/progmodes/json-ts-mode.el
@@ -160,6 +160,10 @@ json-ts-mode
 
   (treesit-major-mode-setup))
 
+(if (treesit-ready-p 'json)
+    (add-to-list 'auto-mode-alist
+                 '("\\.json\\'" . json-ts-mode)))
+
 (provide 'json-ts-mode)
 
 ;;; json-ts-mode.el ends here
diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
index 21d16db..a869cdc 100644
--- a/lisp/progmodes/python.el
+++ b/lisp/progmodes/python.el
@@ -6713,7 +6713,10 @@ python-ts-mode
     (treesit-major-mode-setup)
 
     (when python-indent-guess-indent-offset
-      (python-indent-guess-indent-offset))))
+      (python-indent-guess-indent-offset))
+
+    (add-to-list 'auto-mode-alist
+                 '("\\.py[iw]?\\'\\|python[0-9.]*" . python-ts-mode))))
 
 ;;; Completion predicates for M-x
 ;; Commands that only make sense when editing Python code
diff --git a/lisp/progmodes/ruby-ts-mode.el b/lisp/progmodes/ruby-ts-mode.el
index d68b579..f798f09 100644
--- a/lisp/progmodes/ruby-ts-mode.el
+++ b/lisp/progmodes/ruby-ts-mode.el
@@ -986,6 +986,10 @@ ruby-ts-mode
 
   (treesit-major-mode-setup))
 
+(if (treesit-ready-p 'ruby)
+    (add-to-list 'auto-mode-alist
+                 '("\\(?:\\.\\(?:rbw?\\|ru\\|rake\\|thor\\|jbuilder\\|rabl\\|gemspec\\|podspec\\)\\|/\\(?:Gem\\|Rake\\|Cap\\|Thor\\|Puppet\\|Berks\\|Brew\\|Vagrant\\|Guard\\|Pod\\)file\\)\\'" . ruby-ts-mode)))
+
 (provide 'ruby-ts-mode)
 
 ;;; ruby-ts-mode.el ends here
diff --git a/lisp/progmodes/rust-ts-mode.el b/lisp/progmodes/rust-ts-mode.el
index 7536726..08590ae 100644
--- a/lisp/progmodes/rust-ts-mode.el
+++ b/lisp/progmodes/rust-ts-mode.el
@@ -276,9 +276,6 @@ rust-ts-mode--defun-name
       (treesit-node-child-by-field-name node "name") t))))
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.rs\\'" . rust-ts-mode))
-
-;;;###autoload
 (define-derived-mode rust-ts-mode prog-mode "Rust"
   "Major mode for editing Rust, powered by tree-sitter."
   :group 'rust
@@ -322,6 +319,9 @@ rust-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'rust)
+    (add-to-list 'auto-mode-alist '("\\.rs\\'" . rust-ts-mode)))
+
 (provide 'rust-ts-mode)
 
 ;;; rust-ts-mode.el ends here
diff --git a/lisp/progmodes/typescript-ts-mode.el b/lisp/progmodes/typescript-ts-mode.el
index 037d5c8..0b0bbe1 100644
--- a/lisp/progmodes/typescript-ts-mode.el
+++ b/lisp/progmodes/typescript-ts-mode.el
@@ -313,12 +313,6 @@ typescript-ts-mode--font-lock-settings
    '((escape_sequence) @font-lock-escape-face)))
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.ts\\'" . typescript-ts-mode))
-
-;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.tsx\\'" . tsx-ts-mode))
-
-;;;###autoload
 (define-derived-mode typescript-ts-base-mode prog-mode "TypeScript"
   "Major mode for editing TypeScript."
   :group 'typescript
@@ -373,6 +367,9 @@ typescript-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'typescript)
+    (add-to-list 'auto-mode-alist '("\\.ts\\'" . typescript-ts-mode)))
+
 ;;;###autoload
 (define-derived-mode tsx-ts-mode typescript-ts-base-mode "TypeScript[TSX]"
   "Major mode for editing TypeScript."
@@ -408,6 +405,9 @@ tsx-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'tsx)
+    (add-to-list 'auto-mode-alist '("\\.tsx\\'" . tsx-ts-mode)))
+
 (provide 'typescript-ts-mode)
 
 ;;; typescript-ts-mode.el ends here
diff --git a/lisp/textmodes/css-mode.el b/lisp/textmodes/css-mode.el
index 8991610..a1d7d4b 100644
--- a/lisp/textmodes/css-mode.el
+++ b/lisp/textmodes/css-mode.el
@@ -1827,7 +1827,9 @@ css-ts-mode
     (setq-local treesit-simple-imenu-settings
                 `(( nil ,(rx bos (or "rule_set" "media_statement") eos)
                     nil nil)))
-    (treesit-major-mode-setup)))
+    (treesit-major-mode-setup)
+
+    (add-to-list 'auto-mode-alist '("\\.css\\'" . css-ts-mode))))
 
 ;;;###autoload
 (define-derived-mode css-mode css-base-mode "CSS"
diff --git a/lisp/textmodes/toml-ts-mode.el b/lisp/textmodes/toml-ts-mode.el
index 2430c5f..4165420 100644
--- a/lisp/textmodes/toml-ts-mode.el
+++ b/lisp/textmodes/toml-ts-mode.el
@@ -117,8 +117,6 @@ toml-ts-mode--defun-name
      (or (treesit-node-text (treesit-node-child node 1) t)
          "Root table"))))
 
-(add-to-list 'auto-mode-alist '("\\.toml\\'" . toml-ts-mode))
-
 ;;;###autoload
 (define-derived-mode toml-ts-mode text-mode "TOML"
   "Major mode for editing TOML, powered by tree-sitter."
@@ -155,6 +153,9 @@ toml-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'toml)
+    (add-to-list 'auto-mode-alist '("\\.toml\\'" . toml-ts-mode)))
+
 (provide 'toml-ts-mode)
 
 ;;; toml-ts-mode.el ends here
diff --git a/lisp/textmodes/yaml-ts-mode.el b/lisp/textmodes/yaml-ts-mode.el
index 8c61ee0..a25230e 100644
--- a/lisp/textmodes/yaml-ts-mode.el
+++ b/lisp/textmodes/yaml-ts-mode.el
@@ -118,9 +118,6 @@ yaml-ts-mode--font-lock-settings
   "Tree-sitter font-lock settings for `yaml-ts-mode'.")
 
 ;;;###autoload
-(add-to-list 'auto-mode-alist '("\\.ya?ml\\'" . yaml-ts-mode))
-
-;;;###autoload
 (define-derived-mode yaml-ts-mode text-mode "YAML"
   "Major mode for editing YAML, powered by tree-sitter."
   :group 'yaml
@@ -146,6 +143,9 @@ yaml-ts-mode
 
     (treesit-major-mode-setup)))
 
+(if (treesit-ready-p 'yaml)
+    (add-to-list 'auto-mode-alist '("\\.ya?ml\\'" . yaml-ts-mode)))
+
 (provide 'yaml-ts-mode)
 
 ;;; yaml-ts-mode.el ends here



^ permalink raw reply related	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
@ 2023-01-15 23:39           ` Dmitry Gutov
  2023-01-16  7:43             ` Theodor Thornhill
  2023-01-16 12:34             ` Eli Zaretskii
  2023-01-16  1:12           ` Make all tree-sitter modes optional Po Lu
  2023-01-17 17:30           ` Juri Linkov
  2 siblings, 2 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-15 23:39 UTC (permalink / raw)
  To: Eli Zaretskii, casouri, monnier, larsi, theo, jostein; +Cc: emacs-devel

On 15/01/2023 16:01, Eli Zaretskii wrote:
> You will
> see that where possible, just loading a TS mode modifies
> auto-mode-alist if the tree-sitter support for that mode is available,
> whereas for other modes auto-mode-alist is modified only when the mode
> is actually turned on successfully for the first time.  This is
> because some of the TS modes have their own *.el files, whereas others
> share a .el file with other modes, and so loading that file doesn't
> necessarily means the user wants to use the tree-sitter based mode.

If we *are* going to do this (make all ts mode strictly optional), I 
don't think either of this is a good idea: for a given foo-ts-mode, the 
user might already have an auto-mode-alist entry configured with another 
mode (third-party or not), and they will likely 'M-x foo-ts-mode' to try 
how well it works (or doesn't).

Having auto-mode-alist modified automatically can come as a surprise 
either way.

Note the this is different to having the auto-mode-alist entries set up 
from the outset, because the user's alterations override those.

We can drop the auto-mode-alist alterations from ts modes altogether, to 
bring them back when we do decide to enable them by default.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
  2023-01-15 23:39           ` Dmitry Gutov
@ 2023-01-16  1:12           ` Po Lu
  2023-01-17 17:30           ` Juri Linkov
  2 siblings, 0 replies; 246+ messages in thread
From: Po Lu @ 2023-01-16  1:12 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

>> So here's a suggestion for such a solution: we make all the
>> *-ts-mode's optional.  That is, we don't add any of them to
>> auto-mode-alist unless the file *-ts-mode.el is loaded, and we
>> document them all in NEWS and the user manual as optional.  users who
>> want them will have to manually activate them.  This way, the original
>> use case that started this bug report is automatically solved, and the
>> other use case, where the user intends to activate one of these modes,
>> is also served by showing the warning, which in that case is perfectly
>> justified: the user asked for something that we cannot do, so we warn
>> him/her.
>> 
>> This is a retreat of sorts, but I think it strikes a better balance
>> wrt user expectations, assuming not everyone will build with
>> tree-sitter.
>
> The proposed change to the current emacs-29 branch is below.  You will
> see that where possible, just loading a TS mode modifies
> auto-mode-alist if the tree-sitter support for that mode is available,
> whereas for other modes auto-mode-alist is modified only when the mode
> is actually turned on successfully for the first time.  This is
> because some of the TS modes have their own *.el files, whereas others
> share a .el file with other modes, and so loading that file doesn't
> necessarily means the user wants to use the tree-sitter based mode.
>
> With these changes, users are supposed to turn the mode manually when
> they want to use it, or customize auto-mode-alist in their init files
> to turn those modes automatically for certain files.  Modes that have
> their own *.el files can be just 'require'd in the init file to modify
> auto-mode-alist.
>
> This arrangement is perhaps not ideal, but I think it is safe enough
> and simple enough to go into Emacs 29.
>
> Comments? objections? ideas for improvements?  I will install in a few
> days, barring any serious problems.

Thank you.  I think this is a very reasonable arragement, certainly
better than what we had before.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-15 23:39           ` Dmitry Gutov
@ 2023-01-16  7:43             ` Theodor Thornhill
  2023-01-16 16:30               ` Dmitry Gutov
  2023-01-16 12:34             ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Theodor Thornhill @ 2023-01-16  7:43 UTC (permalink / raw)
  To: Dmitry Gutov, Eli Zaretskii, casouri, monnier, larsi, jostein; +Cc: emacs-devel

Dmitry Gutov <dgutov@yandex.ru> writes:

> On 15/01/2023 16:01, Eli Zaretskii wrote:
>> You will
>> see that where possible, just loading a TS mode modifies
>> auto-mode-alist if the tree-sitter support for that mode is available,
>> whereas for other modes auto-mode-alist is modified only when the mode
>> is actually turned on successfully for the first time.  This is
>> because some of the TS modes have their own *.el files, whereas others
>> share a .el file with other modes, and so loading that file doesn't
>> necessarily means the user wants to use the tree-sitter based mode.
>
> If we *are* going to do this (make all ts mode strictly optional), I 
> don't think either of this is a good idea: for a given foo-ts-mode, the 
> user might already have an auto-mode-alist entry configured with another 
> mode (third-party or not), and they will likely 'M-x foo-ts-mode' to try 
> how well it works (or doesn't).
>
> Having auto-mode-alist modified automatically can come as a surprise 
> either way.
>
> Note the this is different to having the auto-mode-alist entries set up 
> from the outset, because the user's alterations override those.
>
> We can drop the auto-mode-alist alterations from ts modes altogether, to 
> bring them back when we do decide to enable them by default.

I'm fine with either, but I understood your proposal to just remove all
the auto-mode-alist additions for emacs-29, then let users config that
themselves.

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-15 23:39           ` Dmitry Gutov
  2023-01-16  7:43             ` Theodor Thornhill
@ 2023-01-16 12:34             ` Eli Zaretskii
  2023-01-16 13:06               ` Dmitry Gutov
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-16 12:34 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Mon, 16 Jan 2023 01:39:18 +0200
> Cc: emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 15/01/2023 16:01, Eli Zaretskii wrote:
> > You will
> > see that where possible, just loading a TS mode modifies
> > auto-mode-alist if the tree-sitter support for that mode is available,
> > whereas for other modes auto-mode-alist is modified only when the mode
> > is actually turned on successfully for the first time.  This is
> > because some of the TS modes have their own *.el files, whereas others
> > share a .el file with other modes, and so loading that file doesn't
> > necessarily means the user wants to use the tree-sitter based mode.
> 
> If we *are* going to do this (make all ts mode strictly optional), I 
> don't think either of this is a good idea: for a given foo-ts-mode, the 
> user might already have an auto-mode-alist entry configured with another 
> mode (third-party or not), and they will likely 'M-x foo-ts-mode' to try 
> how well it works (or doesn't).
> 
> Having auto-mode-alist modified automatically can come as a surprise 
> either way.
> 
> Note the this is different to having the auto-mode-alist entries set up 
> from the outset, because the user's alterations override those.
> 
> We can drop the auto-mode-alist alterations from ts modes altogether, to 
> bring them back when we do decide to enable them by default.

Like I said: this is not ideal.  So I'm not surprised that whatever we
do, there can be usage scenarios where what we do will annoy someone.

That said:

  . The proposed patch made many changes of auto-mode-alist
    conditional where they previously were _un_conditional.  I submit
    that this is less annoyance in the important use case where the
    tree-sitter or the grammar library is not available.  There are
    indications that this situation will be frequent enough when Emacs
    29.1 hits the street.

  . I don't buy the assumption that customizations of auto-mode-alist
    are frequent enough to make that an important factor in these
    decisions, let alone suggest that users should always do that if
    they want to try the *-ts-* modes seriously:

      - IME, auto-mode-alist is relatively rarely customized for modes
        that are included in Emacs (e.g., I don't customize entries of
        any such modes), for the simple reason that it is very rarely
        needed.
      - Customizing auto-mode-alist is not the easiest task, it
        requires good knowledge of Emacs regexps and alists.  So
        asking anyone who wants to try using the tree-sitter modes to
        do that is not the best idea from the POV of user-friendliness.
      - OTOH, I'm quite sure that people who do already customize
        auto-mode-alist for built-in modes are more advanced users and
        will be able to overcome any problems that could be caused by
        modifying auto-mode-alist as side effect of activating the
        mode.

  . Last, but not least: I think someone who turns on a tree-sitter
    mode in some buffer is much more likely to want to use that mode
    in more than that single buffer than the other way around.  And if
    for some reason they are disappointed soon enough, just restarting
    the Emacs session will get them back the old behavior.  Which
    again tells me that if we accept your proposal, we will annoy more
    users (with the need to modify auto-mode-alist) than under my
    proposal.

So, on balance, I think what I proposed is better than what you
propose.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16 12:34             ` Eli Zaretskii
@ 2023-01-16 13:06               ` Dmitry Gutov
  2023-01-16 14:20                 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-16 13:06 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 16/01/2023 14:34, Eli Zaretskii wrote:
>> Date: Mon, 16 Jan 2023 01:39:18 +0200
>> Cc: emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>> On 15/01/2023 16:01, Eli Zaretskii wrote:
>>> You will
>>> see that where possible, just loading a TS mode modifies
>>> auto-mode-alist if the tree-sitter support for that mode is available,
>>> whereas for other modes auto-mode-alist is modified only when the mode
>>> is actually turned on successfully for the first time.  This is
>>> because some of the TS modes have their own *.el files, whereas others
>>> share a .el file with other modes, and so loading that file doesn't
>>> necessarily means the user wants to use the tree-sitter based mode.
>>
>> If we *are* going to do this (make all ts mode strictly optional), I
>> don't think either of this is a good idea: for a given foo-ts-mode, the
>> user might already have an auto-mode-alist entry configured with another
>> mode (third-party or not), and they will likely 'M-x foo-ts-mode' to try
>> how well it works (or doesn't).
>>
>> Having auto-mode-alist modified automatically can come as a surprise
>> either way.
>>
>> Note the this is different to having the auto-mode-alist entries set up
>> from the outset, because the user's alterations override those.
>>
>> We can drop the auto-mode-alist alterations from ts modes altogether, to
>> bring them back when we do decide to enable them by default.
> 
> Like I said: this is not ideal.  So I'm not surprised that whatever we
> do, there can be usage scenarios where what we do will annoy someone.
> 
> That said:
> 
>    . The proposed patch made many changes of auto-mode-alist
>      conditional where they previously were _un_conditional.

It also added some where there were none.

> I submit
>      that this is less annoyance in the important use case where the
>      tree-sitter or the grammar library is not available.  There are
>      indications that this situation will be frequent enough when Emacs
>      29.1 hits the street.

Like I said, either making them unconditional, or removing them, would 
lead to better, more predictable behavior.

>    . I don't buy the assumption that customizations of auto-mode-alist
>      are frequent enough to make that an important factor in these
>      decisions, let alone suggest that users should always do that if
>      they want to try the *-ts-* modes seriously:

Why wouldn't they be frequent? It's the only way for the user to have 
file format supported, where we don't support it OOTB.

The customization of auto-mode-alist might also happen for the user 
automatically. When the user installs a third-party package, such as 
json-mode, from ELPA, that modified auto-mode-alist through package 
autoloads.

Having it modified again by 'M-x yaml-ts-mode', but only for the 
duration of the current session, would be surprising and odd. If I were 
a new user, I would be questioning both why the mode association 
changed, and why it didn't persist between sessions.

>        - IME, auto-mode-alist is relatively rarely customized for modes
>          that are included in Emacs (e.g., I don't customize entries of
>          any such modes), for the simple reason that it is very rarely
>          needed.

I'm talking about modes which are not included in Emacs.

But having the association for .rb files rewritten when somebody invokes 
'M-x ruby-ts-mode' would be weird too. It will make it a pain in the ass 
for me to test ruby-ts-mode, for one thing.

Or js-mode -> js-ts-mode, or python-mode -> python-ts-mode. People 
should be allowed to experiment without having to figure out how one can 
undo an automated change like that.

>        - Customizing auto-mode-alist is not the easiest task, it
>          requires good knowledge of Emacs regexps and alists.  So
>          asking anyone who wants to try using the tree-sitter modes to
>          do that is not the best idea from the POV of user-friendliness.

They will have to learn how to do that anyway, because the 
auto-mode-alist alterations from your patch won't persist between sessions.

To make it easier, we could put examples in the Commentary of each ts 
mode. That's something that has been a common practice with third-party 
mode, so there are a lot of examples of this code out there anyway.

>        - OTOH, I'm quite sure that people who do already customize
>          auto-mode-alist for built-in modes are more advanced users and
>          will be able to overcome any problems that could be caused by
>          modifying auto-mode-alist as side effect of activating the
>          mode.

Adding elements to auto-mode-alist is easier than removing them.

>    . Last, but not least: I think someone who turns on a tree-sitter
>      mode in some buffer is much more likely to want to use that mode
>      in more than that single buffer than the other way around.  And if
>      for some reason they are disappointed soon enough, just restarting
>      the Emacs session will get them back the old behavior.  Which
>      again tells me that if we accept your proposal, we will annoy more
>      users (with the need to modify auto-mode-alist) than under my
>      proposal.

Someone who turns it on for the first time doesn't know yet whether they 
want to use it or not. It hard to gauge the percentage of those who will.

And again, those who will want to, will have to learn how to deal with 
auto-mode-alist anyway. For some modes that could be avoided with e.g. 
(require 'yaml-ts-mode), but for others (e.g. python-ts-mode) it could 
not. Why proliferate special cases?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16 13:06               ` Dmitry Gutov
@ 2023-01-16 14:20                 ` Eli Zaretskii
  2023-01-16 14:50                   ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-16 14:20 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Mon, 16 Jan 2023 15:06:15 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> >    . The proposed patch made many changes of auto-mode-alist
> >      conditional where they previously were _un_conditional.
> 
> It also added some where there were none.

Yes, so that we do this consistently.  Inconsistency would lead to
more confusion and difficulties in documentation.

> > I submit
> >      that this is less annoyance in the important use case where the
> >      tree-sitter or the grammar library is not available.  There are
> >      indications that this situation will be frequent enough when Emacs
> >      29.1 hits the street.
> 
> Like I said, either making them unconditional, or removing them, would 
> lead to better, more predictable behavior.

OK, so let's disagree about this.

> >    . I don't buy the assumption that customizations of auto-mode-alist
> >      are frequent enough to make that an important factor in these
> >      decisions, let alone suggest that users should always do that if
> >      they want to try the *-ts-* modes seriously:
> 
> Why wouldn't they be frequent? It's the only way for the user to have 
> file format supported, where we don't support it OOTB.

I was talking about modes included in Emacs.

> The customization of auto-mode-alist might also happen for the user 
> automatically. When the user installs a third-party package, such as 
> json-mode, from ELPA, that modified auto-mode-alist through package 
> autoloads.
> 
> Having it modified again by 'M-x yaml-ts-mode', but only for the 
> duration of the current session, would be surprising and odd. If I were 
> a new user, I would be questioning both why the mode association 
> changed, and why it didn't persist between sessions.

We disagree again.  I guess we will have to wait and see who is right.

> >        - IME, auto-mode-alist is relatively rarely customized for modes
> >          that are included in Emacs (e.g., I don't customize entries of
> >          any such modes), for the simple reason that it is very rarely
> >          needed.
> 
> I'm talking about modes which are not included in Emacs.

Not relevant to this discussion.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16 14:20                 ` Eli Zaretskii
@ 2023-01-16 14:50                   ` Dmitry Gutov
  2023-01-16 14:59                     ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-16 14:50 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 16/01/2023 16:20, Eli Zaretskii wrote:
> We disagree again.  I guess we will have to wait and see who is right.

How are we going to determine that?

If you're waiting for bug reports, I might as well file one now.

Given that you're making this change on the basis of just one complaint, 
that would make it 1:1.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16 14:50                   ` Dmitry Gutov
@ 2023-01-16 14:59                     ` Eli Zaretskii
  2023-01-17 12:59                       ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-16 14:59 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Mon, 16 Jan 2023 16:50:07 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 16/01/2023 16:20, Eli Zaretskii wrote:
> > We disagree again.  I guess we will have to wait and see who is right.
> 
> How are we going to determine that?
> 
> If you're waiting for bug reports, I might as well file one now.

You can file a bug report if you want, but it won't count because it
won't tell anything we don't know already.

This isn't a parliament, so the number of votes doesn't necessarily
count.

> Given that you're making this change on the basis of just one complaint, 
> that would make it 1:1.

I'm making this change because that one complaint told me something I
didn't know and didn't take into consideration before.  IOW, I've
changed my mind, and that's why I made these changes.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16  7:43             ` Theodor Thornhill
@ 2023-01-16 16:30               ` Dmitry Gutov
  0 siblings, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-16 16:30 UTC (permalink / raw)
  To: Theodor Thornhill, Eli Zaretskii, casouri, monnier, larsi,
	jostein
  Cc: emacs-devel

On 16/01/2023 09:43, Theodor Thornhill wrote:
> Dmitry Gutov<dgutov@yandex.ru>  writes:
> 
>> On 15/01/2023 16:01, Eli Zaretskii wrote:
>>> You will
>>> see that where possible, just loading a TS mode modifies
>>> auto-mode-alist if the tree-sitter support for that mode is available,
>>> whereas for other modes auto-mode-alist is modified only when the mode
>>> is actually turned on successfully for the first time.  This is
>>> because some of the TS modes have their own *.el files, whereas others
>>> share a .el file with other modes, and so loading that file doesn't
>>> necessarily means the user wants to use the tree-sitter based mode.
>> If we*are*  going to do this (make all ts mode strictly optional), I
>> don't think either of this is a good idea: for a given foo-ts-mode, the
>> user might already have an auto-mode-alist entry configured with another
>> mode (third-party or not), and they will likely 'M-x foo-ts-mode' to try
>> how well it works (or doesn't).
>>
>> Having auto-mode-alist modified automatically can come as a surprise
>> either way.
>>
>> Note the this is different to having the auto-mode-alist entries set up
>> from the outset, because the user's alterations override those.
>>
>> We can drop the auto-mode-alist alterations from ts modes altogether, to
>> bring them back when we do decide to enable them by default.
> I'm fine with either, but I understood your proposal to just remove all
> the auto-mode-alist additions for emacs-29, then let users config that
> themselves.

My preferred course of action was to keep things as-is, but since that's 
not in the cards, the proposed alternative for emacs-29 was to indeed 
remove the auto-mode-alist additions entirely, to keep things simple.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-16 14:59                     ` Eli Zaretskii
@ 2023-01-17 12:59                       ` Dmitry Gutov
  2023-01-17 13:47                         ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 12:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 16/01/2023 16:59, Eli Zaretskii wrote:
> You can file a bug report if you want, but it won't count because it
> won't tell anything we don't know already.

The fact that it will make it a pain for me to test ruby-ts-mode in 
"regular" sessions was something you'd been aware of already?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 12:59                       ` Dmitry Gutov
@ 2023-01-17 13:47                         ` Eli Zaretskii
  2023-01-17 14:32                           ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 13:47 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 14:59:06 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 16/01/2023 16:59, Eli Zaretskii wrote:
> > You can file a bug report if you want, but it won't count because it
> > won't tell anything we don't know already.
> 
> The fact that it will make it a pain for me to test ruby-ts-mode in 
> "regular" sessions was something you'd been aware of already?

Please tell more details about this aspect of the issue.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 13:47                         ` Eli Zaretskii
@ 2023-01-17 14:32                           ` Dmitry Gutov
  2023-01-17 14:52                             ` Eli Zaretskii
  2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
  0 siblings, 2 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 14:32 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 15:47, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 14:59:06 +0200
>> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>>   theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>> On 16/01/2023 16:59, Eli Zaretskii wrote:
>>> You can file a bug report if you want, but it won't count because it
>>> won't tell anything we don't know already.
>>
>> The fact that it will make it a pain for me to test ruby-ts-mode in
>> "regular" sessions was something you'd been aware of already?
> 
> Please tell more details about this aspect of the issue.

I'm using ruby-mode, at least for now, while all the wrinkles with 
indentation haven't been ironed out (and we'll probably not manage to 
get them all 100% right before the 29 release), and while ts modes don't 
support show-paren-mode like SMIE does. No proper sexp navigation, etc.

So here I am, in my normal Emacs, working. Suppose a bug report comes 
in, I switch to a new buffer (maybe visiting a pre-existing file, maybe 
not), turn on ruby-ts-mode, reproduce it. Then try to fix it.

 From that moment on, my current session has a different major mode 
associated with Ruby files, and I have to deal with that somehow.

Or a different scenario:

Recently I had to investigate worse font-lock performance of 
ruby-ts-mode compared to ruby-mode. How did I test that? I started a new 
session and visited a bunch of existing files. First I run the benchmark 
in ruby-mode (which it's associated with by default), then I switch to 
ruby-ts-mode, repeat the benchmark, compare the results. And I do that 
for a number of files.

With your change, the first file will start with ruby-mode, but the 
second file and the rest will start in ruby-ts-mode. And I would somehow 
need to remember that change and account for it when evaluating the results.

What's your recommendation?

I suppose I could add these two forms to the init script:

   (require 'ruby-ts-mode)
   (add-to-list 'auto-mode-alist <...huge regexp from ruby-mode.el...>)

...and then update it over the years if new entries are added there over 
the years -- by the way, having a separate regexp in ruby-ts-mode.el is 
an unfortunate duplication.

But that will only affect scenario 1. The second scenario is fairly 
likely to start with 'emacs -Q' (to try to eliminate the effect of user 
customizations).

Also try to imagine some prospective ruby-ts-mode contributor who is not 
one of us, but who's also trying to test and compare the two modes.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 14:32                           ` Dmitry Gutov
@ 2023-01-17 14:52                             ` Eli Zaretskii
  2023-01-17 15:22                               ` Dmitry Gutov
  2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 14:52 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 16:32:30 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> I'm using ruby-mode, at least for now, while all the wrinkles with 
> indentation haven't been ironed out (and we'll probably not manage to 
> get them all 100% right before the 29 release), and while ts modes don't 
> support show-paren-mode like SMIE does. No proper sexp navigation, etc.
> 
> So here I am, in my normal Emacs, working. Suppose a bug report comes 
> in, I switch to a new buffer (maybe visiting a pre-existing file, maybe 
> not), turn on ruby-ts-mode, reproduce it. Then try to fix it.
> 
>  From that moment on, my current session has a different major mode 
> associated with Ruby files, and I have to deal with that somehow.
> 
> Or a different scenario:
> 
> Recently I had to investigate worse font-lock performance of 
> ruby-ts-mode compared to ruby-mode. How did I test that? I started a new 
> session and visited a bunch of existing files. First I run the benchmark 
> in ruby-mode (which it's associated with by default), then I switch to 
> ruby-ts-mode, repeat the benchmark, compare the results. And I do that 
> for a number of files.
> 
> With your change, the first file will start with ruby-mode, but the 
> second file and the rest will start in ruby-ts-mode. And I would somehow 
> need to remember that change and account for it when evaluating the results.
> 
> What's your recommendation?

My recommendation is to use separate, throw-away Emacs sessions for
any such testing.  I'm doing that myself for a long time, for reasons
unrelated to the issue at hand -- simply because (a) my production
sessions are too customized for clean-room testing, and (b) because my
production sessions are too valuable to me to risk loading non-trivial
packages that change the defaults.

I'm frankly surprised that this is not what you do in your testing.  I
was quite sure that everyone who does any serious development or
maintenance work in Emacs does something like that.  How else is it
possible to, e.g., load some obscure package someone says is necessary
for reproducing a problem?

So in your case, when I'm done with testing whatever I need to test in
ruby-ts-mode, I ether shut down that session, or start another one in
parallel if I need to compare it with, say, ruby-mode.

> I suppose I could add these two forms to the init script:
> 
>    (require 'ruby-ts-mode)
>    (add-to-list 'auto-mode-alist <...huge regexp from ruby-mode.el...>)
> 
> ...and then update it over the years if new entries are added there over 
> the years -- by the way, having a separate regexp in ruby-ts-mode.el is 
> an unfortunate duplication.

If this is about the difference between the regexps, we can fix that,
I don't object to have both modes handle the same files.

> Also try to imagine some prospective ruby-ts-mode contributor who is not 
> one of us, but who's also trying to test and compare the two modes.

My suggestion to anyone who does such testing is to use separate
sessions.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 14:52                             ` Eli Zaretskii
@ 2023-01-17 15:22                               ` Dmitry Gutov
  2023-01-17 17:02                                 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 15:22 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 16:52, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 16:32:30 +0200
>> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>>   theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>> I'm using ruby-mode, at least for now, while all the wrinkles with
>> indentation haven't been ironed out (and we'll probably not manage to
>> get them all 100% right before the 29 release), and while ts modes don't
>> support show-paren-mode like SMIE does. No proper sexp navigation, etc.
>>
>> So here I am, in my normal Emacs, working. Suppose a bug report comes
>> in, I switch to a new buffer (maybe visiting a pre-existing file, maybe
>> not), turn on ruby-ts-mode, reproduce it. Then try to fix it.
>>
>>   From that moment on, my current session has a different major mode
>> associated with Ruby files, and I have to deal with that somehow.
>>
>> Or a different scenario:
>>
>> Recently I had to investigate worse font-lock performance of
>> ruby-ts-mode compared to ruby-mode. How did I test that? I started a new
>> session and visited a bunch of existing files. First I run the benchmark
>> in ruby-mode (which it's associated with by default), then I switch to
>> ruby-ts-mode, repeat the benchmark, compare the results. And I do that
>> for a number of files.
>>
>> With your change, the first file will start with ruby-mode, but the
>> second file and the rest will start in ruby-ts-mode. And I would somehow
>> need to remember that change and account for it when evaluating the results.
>>
>> What's your recommendation?
> 
> My recommendation is to use separate, throw-away Emacs sessions for
> any such testing.  I'm doing that myself for a long time, for reasons
> unrelated to the issue at hand -- simply because (a) my production
> sessions are too customized for clean-room testing, and (b) because my
> production sessions are too valuable to me to risk loading non-trivial
> packages that change the defaults.

I just mentioned in the previous message that scenario 2 is likely to 
start with 'emacs -Q'.

That doesn't solve the described problem in that scenario.

> I'm frankly surprised that this is not what you do in your testing.  I
> was quite sure that everyone who does any serious development or
> maintenance work in Emacs does something like that.  How else is it
> possible to, e.g., load some obscure package someone says is necessary
> for reproducing a problem?
> 
> So in your case, when I'm done with testing whatever I need to test in
> ruby-ts-mode, I ether shut down that session, or start another one in
> parallel if I need to compare it with, say, ruby-mode.

That's untenable.

Running a benchmark is evaluating a form like

   (benchmark-run 1000 (progn (font-lock-mode -1) (font-lock-mode 1) 
(font-lock-ensure)))

I can start a new session for an investigation, but I'm not going to 
restart Emacs every time I evaluate a form.

Doing the benchmarks in a different order (e.g. go through the files 
with one mode and then restart and go with another) is also only an 
option if I were to note the numbers on e.g. a piece of paper. I rarely 
do that; that would also slow me down compared to the current practice.

And also speaking of using 'emacs -Q', that's well-suited to testing 
some classes of bugs, and not so much for others.

>> I suppose I could add these two forms to the init script:
>>
>>     (require 'ruby-ts-mode)
>>     (add-to-list 'auto-mode-alist <...huge regexp from ruby-mode.el...>)
>>
>> ...and then update it over the years if new entries are added there over
>> the years -- by the way, having a separate regexp in ruby-ts-mode.el is
>> an unfortunate duplication.
> 
> If this is about the difference between the regexps, we can fix that,
> I don't object to have both modes handle the same files.

A common constant would help, with that particular aspect.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 15:22                               ` Dmitry Gutov
@ 2023-01-17 17:02                                 ` Eli Zaretskii
  2023-01-17 17:10                                   ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 17:02 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 17:22:05 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> > I'm frankly surprised that this is not what you do in your testing.  I
> > was quite sure that everyone who does any serious development or
> > maintenance work in Emacs does something like that.  How else is it
> > possible to, e.g., load some obscure package someone says is necessary
> > for reproducing a problem?
> > 
> > So in your case, when I'm done with testing whatever I need to test in
> > ruby-ts-mode, I ether shut down that session, or start another one in
> > parallel if I need to compare it with, say, ruby-mode.
> 
> That's untenable.
> 
> Running a benchmark is evaluating a form like
> 
>    (benchmark-run 1000 (progn (font-lock-mode -1) (font-lock-mode 1) 
> (font-lock-ensure)))
> 
> I can start a new session for an investigation, but I'm not going to 
> restart Emacs every time I evaluate a form.

Why not?  It's easy and quick and solves all the problems you
mentioned (and then some).  Like I said: I'm using this myself all the
time.

> Doing the benchmarks in a different order (e.g. go through the files 
> with one mode and then restart and go with another) is also only an 
> option if I were to note the numbers on e.g. a piece of paper. I rarely 
> do that; that would also slow me down compared to the current practice.

No need for paper: just M-w the data and yank into your production
session (which stays up and running all the time).  Again, I'm doing
this all the time in my work on Emacs.

> And also speaking of using 'emacs -Q', that's well-suited to testing 
> some classes of bugs, and not so much for others.

You can start from "emacs -Q" and load whatever is needed.  You can
make an ad-hoc init file that loads everything you need automatically,
to save manual typing.  I'm doing this all the time when the setup is
complicated.

> >>     (require 'ruby-ts-mode)
> >>     (add-to-list 'auto-mode-alist <...huge regexp from ruby-mode.el...>)
> >>
> >> ...and then update it over the years if new entries are added there over
> >> the years -- by the way, having a separate regexp in ruby-ts-mode.el is
> >> an unfortunate duplication.
> > 
> > If this is about the difference between the regexps, we can fix that,
> > I don't object to have both modes handle the same files.
> 
> A common constant would help, with that particular aspect.

Consider it done.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:02                                 ` Eli Zaretskii
@ 2023-01-17 17:10                                   ` Dmitry Gutov
  2023-01-17 17:38                                     ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 17:10 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 19:02, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 17:22:05 +0200
>> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>>   theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>>> I'm frankly surprised that this is not what you do in your testing.  I
>>> was quite sure that everyone who does any serious development or
>>> maintenance work in Emacs does something like that.  How else is it
>>> possible to, e.g., load some obscure package someone says is necessary
>>> for reproducing a problem?
>>>
>>> So in your case, when I'm done with testing whatever I need to test in
>>> ruby-ts-mode, I ether shut down that session, or start another one in
>>> parallel if I need to compare it with, say, ruby-mode.
>>
>> That's untenable.
>>
>> Running a benchmark is evaluating a form like
>>
>>     (benchmark-run 1000 (progn (font-lock-mode -1) (font-lock-mode 1)
>> (font-lock-ensure)))
>>
>> I can start a new session for an investigation, but I'm not going to
>> restart Emacs every time I evaluate a form.
> 
> Why not?  It's easy and quick and solves all the problems you
> mentioned (and then some).

That would increase the time and effort required for such an 
investigation ~5x. (*)

 > Like I said: I'm using this myself all the
 > time.

I'm reasonably certain that, for the tasks that I do, my workflows are 
better optimized.

>> Doing the benchmarks in a different order (e.g. go through the files
>> with one mode and then restart and go with another) is also only an
>> option if I were to note the numbers on e.g. a piece of paper. I rarely
>> do that; that would also slow me down compared to the current practice.
> 
> No need for paper: just M-w the data and yank into your production
> session (which stays up and running all the time).  Again, I'm doing
> this all the time in my work on Emacs.

Likewise (*), but with a smaller multiplier.

>> And also speaking of using 'emacs -Q', that's well-suited to testing
>> some classes of bugs, and not so much for others.
> 
> You can start from "emacs -Q" and load whatever is needed.  You can
> make an ad-hoc init file that loads everything you need automatically,
> to save manual typing.  I'm doing this all the time when the setup is
> complicated.

And now more people will have to, in less complicated situations, which 
previously required no such preparation.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
  2023-01-15 23:39           ` Dmitry Gutov
  2023-01-16  1:12           ` Make all tree-sitter modes optional Po Lu
@ 2023-01-17 17:30           ` Juri Linkov
  2023-01-17 17:58             ` Eli Zaretskii
  2 siblings, 1 reply; 246+ messages in thread
From: Juri Linkov @ 2023-01-17 17:30 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

>> This came out of the discussion in bug#60559 and other related discussions
>
> I addressed that in the discussion on emacs-devel, see
>   https://lists.gnu.org/archive/html/emacs-devel/2023-01/msg00278.html
> (I suggest to discuss this there, not here.)

Ok, moving to emacs-devel from bug#60176.

>> >> >> >> (defcustom treesit-enable-modes nil
>> >> >> >>   :type '(repeat
>> >> >> >>           (choice (function-item c-ts-mode)
>> >> >> >>                   (function-item c++-ts-mode)
>> >> >> >>                   (function-item c-or-c++-ts-mode)
>> >> >> >>                   ...
>> >> >> >>              ('c-ts-mode
>> >> >> >>               (when (treesit-ready-p 'c t)
>> >> >> >>                 (add-to-list 'major-mode-remap-alist '(c-mode . c-ts-mode))))
>> >> >> >
>> >> >> > And this bit is completely unacceptable, from where I stand: it
>> >> >> > basically means that the user activated a certain major mode he/she
>> >> >> > wanted to use, but the result could be that an entirely different mode
>> >> >> > was silently activated instead.  What kind of UX is that, and for a
>> >> >> > shining new feature at that??
>> >> >>
>> >> >> It could update 'auto-mode-alist' instead of 'major-mode-remap-alist'.
>> >> >> From the user's point of view this would be more manageable than
>> >> >> what you proposed on emacs-devel with some obscure logic of activating
>> >> >> ts modes when the package is loaded or when the mode is enabled first time.
>> >> >
>> >> > I don't understand the "obscure" part: the logic was exactly as above:
>> >> > test that treesit-ready-p returns non-nil for the mode's language.
>> >> >
>> >> > Other than that, my proposal does exactly what you say here: it
>> >> > updates auto-mode-alist.  So it sounds like we are in violent agreement.
>> >>
>> >> The difference is that an explicit option is more controllable by the user.
>> >> When the user needs to use some ts-mode then it's easier just to customize
>> >> the option instead of tweaking 'auto-mode-alist' when the user want to
>> >> start using that mode without first loading its package or calling it
>> >> the first time that modifies 'auto-mode-alist' as the side effect.
>> >
>> > With the changes I proposed, there's no need to tweak
>> > auto-mode-alist.  A simple load or require of the mode will install
>> > the mode in auto-mode-alist.  What can be easier and simpler?
>>
>> This doesn't address the problems mentioned above and below.
>
> Which parts "above" were not addressed?
>
> As for below:
>
>> >> Or when the user wants to remove the mode from 'auto-mode-alist' after
>> >> accidentally loading the corresponding ts package.

It fails for many scenarios:

1. The user needs to use e.g. js-ts-mode.  Your patch requires that
users first visit a js file in js-mode, then they need to type

  M-x js-ts-mode RET

then for the rest of the session they can use js-ts-mode.
But for a new session they need to repeat the same again.

2. For other ts modes adding something like (require 'c-ts-mode)
to the user's init file is not a clean way to enable such modes.
Also takes additional space even when users don't intend to use them
in the current session, thus negating the benefits of autoloading.

3. There is no simple way to disable a ts mode after loading
the corresponding ts file.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* treesit-forward-sexp (was: Make all tree-sitter modes optional)
  2023-01-17 14:32                           ` Dmitry Gutov
  2023-01-17 14:52                             ` Eli Zaretskii
@ 2023-01-17 17:34                             ` Juri Linkov
  2023-01-17 17:40                               ` Theodor Thornhill
                                                 ` (2 more replies)
  1 sibling, 3 replies; 246+ messages in thread
From: Juri Linkov @ 2023-01-17 17:34 UTC (permalink / raw)
  To: Dmitry Gutov
  Cc: Eli Zaretskii, casouri, monnier, larsi, theo, jostein,
	emacs-devel

> I'm using ruby-mode, at least for now, while all the wrinkles with
> indentation haven't been ironed out (and we'll probably not manage to get
> them all 100% right before the 29 release), and while ts modes don't
> support show-paren-mode like SMIE does. No proper sexp navigation, etc.

BTW, how ruby-ts-mode is intended to be used without proper sexp navigation?

I see that forward-sentence support for tree sitter was added recently
with treesit-forward-sentence.  There are also treesit-transpose-sexps,
treesit-beginning-of-defun and treesit-end-of-defun.

Are there any plans to add treesit-forward-sexp as well?

Currently I'm using such workaround:

```
(with-eval-after-load 'ruby-ts-mode
  (add-hook 'ruby-ts-mode-hook
            (lambda ()
              (smie-setup ruby-smie-grammar #'ruby-smie-rules
                          :forward-token  #'ruby-smie--forward-token
                          :backward-token #'ruby-smie--backward-token))))
```

Maybe something like this should be added to emacs-29
until treesit-forward-sexp is implemented in master?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:10                                   ` Dmitry Gutov
@ 2023-01-17 17:38                                     ` Eli Zaretskii
  2023-01-17 17:59                                       ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 17:38 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 19:10:45 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> >> I can start a new session for an investigation, but I'm not going to
> >> restart Emacs every time I evaluate a form.
> > 
> > Why not?  It's easy and quick and solves all the problems you
> > mentioned (and then some).
> 
> That would increase the time and effort required for such an 
> investigation ~5x. (*)

But testing in a session that is not clean is not recommended.  For
reasons more important than the issue at hand...

However, I'm the last person to tell others how to organize their
workflows, so I'll leave it at that.

> > You can start from "emacs -Q" and load whatever is needed.  You can
> > make an ad-hoc init file that loads everything you need automatically,
> > to save manual typing.  I'm doing this all the time when the setup is
> > complicated.
> 
> And now more people will have to, in less complicated situations, which 
> previously required no such preparation.

Maybe.  Like I said, the solution I proposed is not ideal, I just
don't see a clearly better one.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: treesit-forward-sexp (was: Make all tree-sitter modes optional)
  2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
@ 2023-01-17 17:40                               ` Theodor Thornhill
  2023-01-17 18:17                                 ` treesit-forward-sexp Juri Linkov
  2023-01-17 17:50                               ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Dmitry Gutov
  2023-01-17 17:59                               ` Eli Zaretskii
  2 siblings, 1 reply; 246+ messages in thread
From: Theodor Thornhill @ 2023-01-17 17:40 UTC (permalink / raw)
  To: Juri Linkov, Dmitry Gutov
  Cc: Eli Zaretskii, casouri, monnier, larsi, jostein, emacs-devel



On 17 January 2023 18:34:04 CET, Juri Linkov <juri@linkov.net> wrote:
>> I'm using ruby-mode, at least for now, while all the wrinkles with
>> indentation haven't been ironed out (and we'll probably not manage to get
>> them all 100% right before the 29 release), and while ts modes don't
>> support show-paren-mode like SMIE does. No proper sexp navigation, etc.
>
>BTW, how ruby-ts-mode is intended to be used without proper sexp navigation?
>
>I see that forward-sentence support for tree sitter was added recently
>with treesit-forward-sentence.  There are also treesit-transpose-sexps,
>treesit-beginning-of-defun and treesit-end-of-defun.
>
>Are there any plans to add treesit-forward-sexp as well?

Yes, working on it now :)

>
>Currently I'm using such workaround:
>
>```
>(with-eval-after-load 'ruby-ts-mode
>  (add-hook 'ruby-ts-mode-hook
>            (lambda ()
>              (smie-setup ruby-smie-grammar #'ruby-smie-rules
>                          :forward-token  #'ruby-smie--forward-token
>                          :backward-token #'ruby-smie--backward-token))))
>```
>
>Maybe something like this should be added to emacs-29
>until treesit-forward-sexp is implemented in master?

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: treesit-forward-sexp (was: Make all tree-sitter modes optional)
  2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
  2023-01-17 17:40                               ` Theodor Thornhill
@ 2023-01-17 17:50                               ` Dmitry Gutov
  2023-01-17 17:59                               ` Eli Zaretskii
  2 siblings, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 17:50 UTC (permalink / raw)
  To: Juri Linkov
  Cc: Eli Zaretskii, casouri, monnier, larsi, theo, jostein,
	emacs-devel

On 17/01/2023 19:34, Juri Linkov wrote:
>> I'm using ruby-mode, at least for now, while all the wrinkles with
>> indentation haven't been ironed out (and we'll probably not manage to get
>> them all 100% right before the 29 release), and while ts modes don't
>> support show-paren-mode like SMIE does. No proper sexp navigation, etc.
> 
> BTW, how ruby-ts-mode is intended to be used without proper sexp navigation?
> 
> I see that forward-sentence support for tree sitter was added recently
> with treesit-forward-sentence.  There are also treesit-transpose-sexps,
> treesit-beginning-of-defun and treesit-end-of-defun.
> 
> Are there any plans to add treesit-forward-sexp as well?
 >
> Currently I'm using such workaround:
> 
> ```
> (with-eval-after-load 'ruby-ts-mode
>    (add-hook 'ruby-ts-mode-hook
>              (lambda ()
>                (smie-setup ruby-smie-grammar #'ruby-smie-rules
>                            :forward-token  #'ruby-smie--forward-token
>                            :backward-token #'ruby-smie--backward-token))))
> ```

I have also been toying with the idea of using SMIE for indentation with 
ruby-ts-mode, keeping tree-sitter for font-lock and other facilities 
which are easier to support.

But for now I'm working on improving tree-sitter based indentation. 
After all, the underlying data it's using is by definition more correct.

> Maybe something like this should be added to emacs-29
> until treesit-forward-sexp is implemented in master?

I don't know if everybody will agree with that. ruby-ts-mode's author in 
particular.

So it's probably better suited for personal customizations, like yours 
above. BTW note that smie-setup also sets indent-line-function.




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:30           ` Juri Linkov
@ 2023-01-17 17:58             ` Eli Zaretskii
  2023-01-17 18:19               ` Juri Linkov
  2023-02-14 19:08               ` Alan Mackenzie
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 17:58 UTC (permalink / raw)
  To: Juri Linkov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> From: Juri Linkov <juri@linkov.net>
> Cc: casouri@gmail.com,  monnier@iro.umontreal.ca,  larsi@gnus.org,
>   theo@thornhill.no,  jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Tue, 17 Jan 2023 19:30:16 +0200
> 
> It fails for many scenarios:
> 
> 1. The user needs to use e.g. js-ts-mode.  Your patch requires that
> users first visit a js file in js-mode, then they need to type
> 
>   M-x js-ts-mode RET
> 
> then for the rest of the session they can use js-ts-mode.
> But for a new session they need to repeat the same again.

Or customize auto-mode-alist.

This is a consequence of the fact that js-ts-mode doesn't have a
separate .el file.  If you have better ideas for that, I'm all ears.

> 2. For other ts modes adding something like (require 'c-ts-mode)
> to the user's init file is not a clean way to enable such modes.

Why not?

> Also takes additional space even when users don't intend to use them
> in the current session, thus negating the benefits of autoloading.

Once again, if the above is somehow too annoying, they can customize
auto-mode-alist manually.  Or even use use-package (and have full
benefit of autoloading).  In any case, the fact that a mode is loaded
and not used is not a problem large enough to reject this simple
arrangement.  Moreover, if someone puts the require into their init
file, they probably want to use the mode quite a lot, so it will not
remain ballast for too long.

> 3. There is no simple way to disable a ts mode after loading
> the corresponding ts file.

Yes, there is: restart the session.  IMO, adequate enough for
something you want to try, and then find not to like.

Bottom line: if you have better, simpler solutions, please tell.  The
ones you proposed until now are significantly more complex, and it is
not reasonable to ask users to go to such lengths to try a new mode.
But of course, if someone wants to do it in a more complex and more
flexible way, they still can.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:38                                     ` Eli Zaretskii
@ 2023-01-17 17:59                                       ` Dmitry Gutov
  2023-01-17 18:04                                         ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 17:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 19:38, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 19:10:45 +0200
>> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>>   theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>>>> I can start a new session for an investigation, but I'm not going to
>>>> restart Emacs every time I evaluate a form.
>>>
>>> Why not?  It's easy and quick and solves all the problems you
>>> mentioned (and then some).
>>
>> That would increase the time and effort required for such an
>> investigation ~5x. (*)
> 
> But testing in a session that is not clean is not recommended.  For
> reasons more important than the issue at hand...

With some experience, one can usually sort issues into those that 
require clean environment, those than might use it, and those that most 
likely don't. In the end, that saves time.

> However, I'm the last person to tell others how to organize their
> workflows, so I'll leave it at that.

Sure.

>>> You can start from "emacs -Q" and load whatever is needed.  You can
>>> make an ad-hoc init file that loads everything you need automatically,
>>> to save manual typing.  I'm doing this all the time when the setup is
>>> complicated.
>>
>> And now more people will have to, in less complicated situations, which
>> previously required no such preparation.
> 
> Maybe.  Like I said, the solution I proposed is not ideal, I just
> don't see a clearly better one.

Every approach we can take will annoy somebody, like like in SPC xkcd.

But dropping the auto-mode-alist modifications looks perfectly in line 
with the conservative approach we have used in the past, where features 
are rolled out gradually.

I also don't fully understand the benefits of your proposal. Suppose we 
apply it. You talked about how easier it will be to document the new 
behaviors if all ts modes are consistent. Okay. What are we going to say 
in that documentation?

Let's say there are two users, Bob and Alice. Bob has tried out 
yaml-ts-mode and wants to use it regularly. Alice has tried out 
js-ts-mode and also wants to use it from now on. What will be our 
recommendations for them to make that happen?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: treesit-forward-sexp (was: Make all tree-sitter modes optional)
  2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
  2023-01-17 17:40                               ` Theodor Thornhill
  2023-01-17 17:50                               ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Dmitry Gutov
@ 2023-01-17 17:59                               ` Eli Zaretskii
  2 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 17:59 UTC (permalink / raw)
  To: Juri Linkov; +Cc: dgutov, casouri, monnier, larsi, theo, jostein, emacs-devel

> From: Juri Linkov <juri@linkov.net>
> Cc: Eli Zaretskii <eliz@gnu.org>,  casouri@gmail.com,
>   monnier@iro.umontreal.ca,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Tue, 17 Jan 2023 19:34:04 +0200
> 
> ```
> (with-eval-after-load 'ruby-ts-mode
>   (add-hook 'ruby-ts-mode-hook
>             (lambda ()
>               (smie-setup ruby-smie-grammar #'ruby-smie-rules
>                           :forward-token  #'ruby-smie--forward-token
>                           :backward-token #'ruby-smie--backward-token))))
> ```
> 
> Maybe something like this should be added to emacs-29
> until treesit-forward-sexp is implemented in master?

Sorry, we are done adding new features to emacs-29.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:59                                       ` Dmitry Gutov
@ 2023-01-17 18:04                                         ` Eli Zaretskii
  2023-01-17 18:21                                           ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 18:04 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 19:59:04 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> I also don't fully understand the benefits of your proposal. Suppose we 
> apply it. You talked about how easier it will be to document the new 
> behaviors if all ts modes are consistent. Okay. What are we going to say 
> in that documentation?
> 
> Let's say there are two users, Bob and Alice. Bob has tried out 
> yaml-ts-mode and wants to use it regularly. Alice has tried out 
> js-ts-mode and also wants to use it from now on. What will be our 
> recommendations for them to make that happen?

That's already in the patch that I posted.  Suggestions for improving
it are welcome.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: treesit-forward-sexp
  2023-01-17 17:40                               ` Theodor Thornhill
@ 2023-01-17 18:17                                 ` Juri Linkov
  0 siblings, 0 replies; 246+ messages in thread
From: Juri Linkov @ 2023-01-17 18:17 UTC (permalink / raw)
  To: Theodor Thornhill
  Cc: Dmitry Gutov, Eli Zaretskii, casouri, monnier, larsi, jostein,
	emacs-devel

>> I see that forward-sentence support for tree sitter was added recently
>> with treesit-forward-sentence.  There are also treesit-transpose-sexps,
>> treesit-beginning-of-defun and treesit-end-of-defun.
>>
>> Are there any plans to add treesit-forward-sexp as well?
>
> Yes, working on it now :)

Good news!  Thanks.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:58             ` Eli Zaretskii
@ 2023-01-17 18:19               ` Juri Linkov
  2023-01-17 18:41                 ` Eli Zaretskii
  2023-02-14 19:08               ` Alan Mackenzie
  1 sibling, 1 reply; 246+ messages in thread
From: Juri Linkov @ 2023-01-17 18:19 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

>> 1. The user needs to use e.g. js-ts-mode.  Your patch requires that
>> users first visit a js file in js-mode, then they need to type
>>
>>   M-x js-ts-mode RET
>>
>> then for the rest of the session they can use js-ts-mode.
>> But for a new session they need to repeat the same again.
>
> Or customize auto-mode-alist.
>
> This is a consequence of the fact that js-ts-mode doesn't have a
> separate .el file.  If you have better ideas for that, I'm all ears.

A better idea is a simple customizable list of enabled ts modes.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 18:04                                         ` Eli Zaretskii
@ 2023-01-17 18:21                                           ` Dmitry Gutov
  2023-01-17 18:40                                             ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 18:21 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 20:04, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 19:59:04 +0200
>> Cc:casouri@gmail.com,monnier@iro.umontreal.ca,larsi@gnus.org,
>>   theo@thornhill.no,jostein@secure.kjonigsen.net,emacs-devel@gnu.org
>> From: Dmitry Gutov<dgutov@yandex.ru>
>>
>> I also don't fully understand the benefits of your proposal. Suppose we
>> apply it. You talked about how easier it will be to document the new
>> behaviors if all ts modes are consistent. Okay. What are we going to say
>> in that documentation?
>>
>> Let's say there are two users, Bob and Alice. Bob has tried out
>> yaml-ts-mode and wants to use it regularly. Alice has tried out
>> js-ts-mode and also wants to use it from now on. What will be our
>> recommendations for them to make that happen?
> That's already in the patch that I posted.  Suggestions for improving
> it are welcome.

This part, right?

+The new modes based on tree-sitter are for now entirely optional, and
+you must turn them on manually, or load them in your init file, or
+customize 'auto-mode-alist' to turn them on automatically for certain
+files.

I thought there would be something more in the docs, given that the new 
behavior is unusual.

But I see you are referring to auto-mode-alist here, modifying which 
will still be necessary for js-ts-mode and python-ts-mode. Which will 
touch a lot of users, possibly even the majority of tree-sitter 
enthusiasts, given that JS and Python are some of the most popular 
languages these days.

And yet you rejected my counter-proposal claiming (if I got your 
position right) that modying auto-mode-alist is difficult/annoying/etc 
for an average user. To quote:

       - Customizing auto-mode-alist is not the easiest task, it
         requires good knowledge of Emacs regexps and alists.  So
         asking anyone who wants to try using the tree-sitter modes to
         do that is not the best idea from the POV of user-friendliness.

So which is it?

To "try out" tree-sitter modes, the users can 'M-x js-ts-mode' or etc 
either way. But to switch to the said mode, they will need to deal with 
auto-mode-alist, again, without any alternative.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 18:21                                           ` Dmitry Gutov
@ 2023-01-17 18:40                                             ` Eli Zaretskii
  2023-01-17 18:49                                               ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 18:40 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 20:21:18 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> +The new modes based on tree-sitter are for now entirely optional, and
> +you must turn them on manually, or load them in your init file, or
> +customize 'auto-mode-alist' to turn them on automatically for certain
> +files.
> 
> I thought there would be something more in the docs, given that the new 
> behavior is unusual.

What do you suggest to add?

> But I see you are referring to auto-mode-alist here, modifying which 
> will still be necessary for js-ts-mode and python-ts-mode. Which will 
> touch a lot of users, possibly even the majority of tree-sitter 
> enthusiasts, given that JS and Python are some of the most popular 
> languages these days.
> 
> And yet you rejected my counter-proposal claiming (if I got your 
> position right) that modying auto-mode-alist is difficult/annoying/etc 
> for an average user. To quote:
> 
>        - Customizing auto-mode-alist is not the easiest task, it
>          requires good knowledge of Emacs regexps and alists.  So
>          asking anyone who wants to try using the tree-sitter modes to
>          do that is not the best idea from the POV of user-friendliness.
> 
> So which is it?

Both.  I mention auto-mode-alist as the last alternative, for those
who are fine with going that way.  It isn't black-and-white.

> To "try out" tree-sitter modes, the users can 'M-x js-ts-mode' or etc 
> either way. But to switch to the said mode, they will need to deal with 
> auto-mode-alist, again, without any alternative.

That's specific to js-ts-mode (and one other, I think) because they
share the .el file with a non-tree-sitter mode.  If there's a
reasonable way to give them separate files, things would be easier.

But this is not a documentation issue, first and foremost.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 18:19               ` Juri Linkov
@ 2023-01-17 18:41                 ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 18:41 UTC (permalink / raw)
  To: Juri Linkov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> From: Juri Linkov <juri@linkov.net>
> Cc: casouri@gmail.com,  monnier@iro.umontreal.ca,  larsi@gnus.org,
>   theo@thornhill.no,  jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Tue, 17 Jan 2023 20:19:44 +0200
> 
> >> 1. The user needs to use e.g. js-ts-mode.  Your patch requires that
> >> users first visit a js file in js-mode, then they need to type
> >>
> >>   M-x js-ts-mode RET
> >>
> >> then for the rest of the session they can use js-ts-mode.
> >> But for a new session they need to repeat the same again.
> >
> > Or customize auto-mode-alist.
> >
> > This is a consequence of the fact that js-ts-mode doesn't have a
> > separate .el file.  If you have better ideas for that, I'm all ears.
> 
> A better idea is a simple customizable list of enabled ts modes.

Yes, you suggested that already.  But I disagree that it's simple, and
therefore don't agree that it's better.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 18:40                                             ` Eli Zaretskii
@ 2023-01-17 18:49                                               ` Dmitry Gutov
  2023-01-17 19:03                                                 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 18:49 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 20:40, Eli Zaretskii wrote:
>> Date: Tue, 17 Jan 2023 20:21:18 +0200
>> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>>   theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>>
>> +The new modes based on tree-sitter are for now entirely optional, and
>> +you must turn them on manually, or load them in your init file, or
>> +customize 'auto-mode-alist' to turn them on automatically for certain
>> +files.
>>
>> I thought there would be something more in the docs, given that the new
>> behavior is unusual.
> 
> What do you suggest to add?

The design doesn't really make sense to me, so it would be hard for me 
to explain it to a user. So no proposed docs from me, sorry.

>> But I see you are referring to auto-mode-alist here, modifying which
>> will still be necessary for js-ts-mode and python-ts-mode. Which will
>> touch a lot of users, possibly even the majority of tree-sitter
>> enthusiasts, given that JS and Python are some of the most popular
>> languages these days.
>>
>> And yet you rejected my counter-proposal claiming (if I got your
>> position right) that modying auto-mode-alist is difficult/annoying/etc
>> for an average user. To quote:
>>
>>         - Customizing auto-mode-alist is not the easiest task, it
>>           requires good knowledge of Emacs regexps and alists.  So
>>           asking anyone who wants to try using the tree-sitter modes to
>>           do that is not the best idea from the POV of user-friendliness.
>>
>> So which is it?
> 
> Both.  I mention auto-mode-alist as the last alternative, for those
> who are fine with going that way.  It isn't black-and-white.

But it's either that, or "turn them on manually", right? That would also 
work with my proposal.

>> To "try out" tree-sitter modes, the users can 'M-x js-ts-mode' or etc
>> either way. But to switch to the said mode, they will need to deal with
>> auto-mode-alist, again, without any alternative.
> 
> That's specific to js-ts-mode (and one other, I think) because they
> share the .el file with a non-tree-sitter mode.  If there's a
> reasonable way to give them separate files, things would be easier.

Right. If they were in separate files, then we could write the doc with 
suggestions to merely violate the standard recommendation of avoiding 
'require' in the init script.

> But this is not a documentation issue, first and foremost.

Inconsistencies in design often turn up as documentation issues later.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 18:49                                               ` Dmitry Gutov
@ 2023-01-17 19:03                                                 ` Eli Zaretskii
  2023-01-17 19:21                                                   ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-17 19:03 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 17 Jan 2023 20:49:59 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> >> But I see you are referring to auto-mode-alist here, modifying which
> >> will still be necessary for js-ts-mode and python-ts-mode. Which will
> >> touch a lot of users, possibly even the majority of tree-sitter
> >> enthusiasts, given that JS and Python are some of the most popular
> >> languages these days.
> >>
> >> And yet you rejected my counter-proposal claiming (if I got your
> >> position right) that modying auto-mode-alist is difficult/annoying/etc
> >> for an average user. To quote:
> >>
> >>         - Customizing auto-mode-alist is not the easiest task, it
> >>           requires good knowledge of Emacs regexps and alists.  So
> >>           asking anyone who wants to try using the tree-sitter modes to
> >>           do that is not the best idea from the POV of user-friendliness.
> >>
> >> So which is it?
> > 
> > Both.  I mention auto-mode-alist as the last alternative, for those
> > who are fine with going that way.  It isn't black-and-white.
> 
> But it's either that, or "turn them on manually", right? That would also 
> work with my proposal.

Your proposal makes it harder by making it necessary to mess with
auto-mode-alist.  I hope we can make it easier, at least in many/most
cases.  That is a non-negligible advantage from my POV.

> > That's specific to js-ts-mode (and one other, I think) because they
> > share the .el file with a non-tree-sitter mode.  If there's a
> > reasonable way to give them separate files, things would be easier.
> 
> Right. If they were in separate files, then we could write the doc with 
> suggestions to merely violate the standard recommendation of avoiding 
> 'require' in the init script.
> 
> > But this is not a documentation issue, first and foremost.
> 
> Inconsistencies in design often turn up as documentation issues later.

I didn't design js.el that way.  I just assumed there were good
reasons for that and tried to adapt as best I could.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 19:03                                                 ` Eli Zaretskii
@ 2023-01-17 19:21                                                   ` Dmitry Gutov
  2023-01-18  1:11                                                     ` Yuan Fu
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-17 19:21 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 17/01/2023 21:03, Eli Zaretskii wrote:

>>> Both.  I mention auto-mode-alist as the last alternative, for those
>>> who are fine with going that way.  It isn't black-and-white.
>>
>> But it's either that, or "turn them on manually", right? That would also
>> work with my proposal.
> 
> Your proposal makes it harder by making it necessary to mess with
> auto-mode-alist.  I hope we can make it easier, at least in many/most
> cases.  That is a non-negligible advantage from my POV.

The userbase I'm familiar with has been messing with auto-mode-alist for 
decades. To make it easier, people have been adding the necessary lines 
to documentation: either to the repository's README, or to package's 
Commentary. So the user could take it from there.

Similarly, we can add such line to the Commentary of every ts mode, or 
even to the major mode docstrings.

We also have merged use-package to Emacs. It makes the same operation a 
little easier, though not by much:

(use-package js
   :mode ("\\.js\\'" . js-ts-mode))

Either way, there are a lot of examples of this kind of configuration 
out there.

>>> That's specific to js-ts-mode (and one other, I think) because they
>>> share the .el file with a non-tree-sitter mode.  If there's a
>>> reasonable way to give them separate files, things would be easier.
>>
>> Right. If they were in separate files, then we could write the doc with
>> suggestions to merely violate the standard recommendation of avoiding
>> 'require' in the init script.
>>
>>> But this is not a documentation issue, first and foremost.
>>
>> Inconsistencies in design often turn up as documentation issues later.
> 
> I didn't design js.el that way.  I just assumed there were good
> reasons for that and tried to adapt as best I could.

I think the design is fine, but whatever solution we choose should be 
compatible with it.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 19:21                                                   ` Dmitry Gutov
@ 2023-01-18  1:11                                                     ` Yuan Fu
  2023-01-18  1:23                                                       ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Yuan Fu @ 2023-01-18  1:11 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: Eli Zaretskii, monnier, larsi, theo, jostein, emacs-devel

> 
> The userbase I'm familiar with has been messing with auto-mode-alist for decades. To make it easier, people have been adding the necessary lines to documentation: either to the repository's README, or to package's Commentary. So the user could take it from there.
> 
> Similarly, we can add such line to the Commentary of every ts mode, or even to the major mode docstrings

IF we do that, it’d be better to instruct users to use major-mode-remap-alist, since it’s easier to understand and use IMO.

Yuan


^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18  1:11                                                     ` Yuan Fu
@ 2023-01-18  1:23                                                       ` Dmitry Gutov
  2023-01-18  3:34                                                         ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-18  1:23 UTC (permalink / raw)
  To: Yuan Fu; +Cc: Eli Zaretskii, monnier, larsi, theo, jostein, emacs-devel

On 18/01/2023 03:11, Yuan Fu wrote:
>> The userbase I'm familiar with has been messing with auto-mode-alist for decades. To make it easier, people have been adding the necessary lines to documentation: either to the repository's README, or to package's Commentary. So the user could take it from there.
>>
>> Similarly, we can add such line to the Commentary of every ts mode, or even to the major mode docstrings
> IF we do that, it’d be better to instruct users to use major-mode-remap-alist, since it’s easier to understand and use IMO.

Sure. This way we also avoid duplicating the file name regexp.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18  1:23                                                       ` Dmitry Gutov
@ 2023-01-18  3:34                                                         ` Eli Zaretskii
  2023-01-18  3:52                                                           ` Dmitry Gutov
  2023-01-18 12:36                                                           ` Stefan Monnier
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-18  3:34 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Wed, 18 Jan 2023 03:23:57 +0200
> Cc: Eli Zaretskii <eliz@gnu.org>, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 18/01/2023 03:11, Yuan Fu wrote:
> >> The userbase I'm familiar with has been messing with auto-mode-alist for decades. To make it easier, people have been adding the necessary lines to documentation: either to the repository's README, or to package's Commentary. So the user could take it from there.
> >>
> >> Similarly, we can add such line to the Commentary of every ts mode, or even to the major mode docstrings
> > IF we do that, it’d be better to instruct users to use major-mode-remap-alist, since it’s easier to understand and use IMO.
> 
> Sure. This way we also avoid duplicating the file name regexp.

The purpose of major-mode-remap-alist doesn't fit such use, so this
proposal is a no-go.

Again, we've been through this already, at least twice.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18  3:34                                                         ` Eli Zaretskii
@ 2023-01-18  3:52                                                           ` Dmitry Gutov
  2023-01-18 12:06                                                             ` Eli Zaretskii
  2023-01-18 12:36                                                           ` Stefan Monnier
  1 sibling, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-18  3:52 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 18/01/2023 05:34, Eli Zaretskii wrote:
>>>> Similarly, we can add such line to the Commentary of every ts mode, or even to the major mode docstrings
>>> IF we do that, it’d be better to instruct users to use major-mode-remap-alist, since it’s easier to understand and use IMO.
>> Sure. This way we also avoid duplicating the file name regexp.
> The purpose of major-mode-remap-alist doesn't fit such use, so this
> proposal is a no-go.

Its NEWS entry says:

** New user option 'major-mode-remap-alist' to specify favorite major modes.
This user option lets you remap the default modes (e.g. 'perl-mode' or
'latex-mode') to your favorite ones (e.g. 'cperl-mode' or
'LaTeX-mode') without having to use 'defalias', which can have
undesirable side effects.

If we leave it to the user to add an entry to that variable, we don't 
have to worry whether tree-sitter support is compiled and the respective 
grammar is available -- the user can ensure that. So there will be no 
need for a treesit-available-p check.

Seems like a perfect fit.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18  3:52                                                           ` Dmitry Gutov
@ 2023-01-18 12:06                                                             ` Eli Zaretskii
  2023-01-18 14:00                                                               ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-18 12:06 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Wed, 18 Jan 2023 05:52:14 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 18/01/2023 05:34, Eli Zaretskii wrote:
> >>>> Similarly, we can add such line to the Commentary of every ts mode, or even to the major mode docstrings
> >>> IF we do that, it’d be better to instruct users to use major-mode-remap-alist, since it’s easier to understand and use IMO.
> >> Sure. This way we also avoid duplicating the file name regexp.
> > The purpose of major-mode-remap-alist doesn't fit such use, so this
> > proposal is a no-go.
> 
> Its NEWS entry says:
> 
> ** New user option 'major-mode-remap-alist' to specify favorite major modes.
> This user option lets you remap the default modes (e.g. 'perl-mode' or
> 'latex-mode') to your favorite ones (e.g. 'cperl-mode' or
> 'LaTeX-mode') without having to use 'defalias', which can have
> undesirable side effects.
> 
> If we leave it to the user to add an entry to that variable, we don't 
> have to worry whether tree-sitter support is compiled and the respective 
> grammar is available -- the user can ensure that. So there will be no 
> need for a treesit-available-p check.

We can _suggest_ using that variable for this particular purpose, but
we cannot make it the only or even the main means of dealing with the
issue: this is a _user_ variable, and users can have needs or reasons
to do stuff with it that are incompatible with the kind of usage
proposed here.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18  3:34                                                         ` Eli Zaretskii
  2023-01-18  3:52                                                           ` Dmitry Gutov
@ 2023-01-18 12:36                                                           ` Stefan Monnier
  1 sibling, 0 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-01-18 12:36 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Dmitry Gutov, casouri, larsi, theo, jostein, emacs-devel

>> > IF we do that, it’d be better to instruct users to use
>> > major-mode-remap-alist, since it’s easier to understand and use IMO.
>> 
>> Sure. This way we also avoid duplicating the file name regexp.
>
> The purpose of major-mode-remap-alist doesn't fit such use, so this
> proposal is a no-go.

Maybe I missed something (I'm having trouble keeping up with
emacs-devel these days, sorry), but I don't see why you think so.
It seems perfectly appropriate (and indeed fits the original goal) for
`Commentary:` to say something like:

    ;; If you want to use this mode by default, you can add the following
    to your init file:
    ;;
    ;;     (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))


-- Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18 12:06                                                             ` Eli Zaretskii
@ 2023-01-18 14:00                                                               ` Dmitry Gutov
  2023-01-18 14:51                                                                 ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-01-18 14:00 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

On 18/01/2023 14:06, Eli Zaretskii wrote:
> We can_suggest_  using that variable for this particular purpose, but
> we cannot make it the only or even the main means of dealing with the
> issue: this is a_user_  variable, and users can have needs or reasons
> to do stuff with it that are incompatible with the kind of usage
> proposed here.

Since the recommendation will be in the docs, the user can tweak the 
form as convenient, won't they?

I'm not sure which particular stuff you are thinking of, though.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-18 14:00                                                               ` Dmitry Gutov
@ 2023-01-18 14:51                                                                 ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-18 14:51 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Wed, 18 Jan 2023 16:00:47 +0200
> Cc: casouri@gmail.com, monnier@iro.umontreal.ca, larsi@gnus.org,
>  theo@thornhill.no, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 18/01/2023 14:06, Eli Zaretskii wrote:
> > We can_suggest_  using that variable for this particular purpose, but
> > we cannot make it the only or even the main means of dealing with the
> > issue: this is a_user_  variable, and users can have needs or reasons
> > to do stuff with it that are incompatible with the kind of usage
> > proposed here.
> 
> Since the recommendation will be in the docs, the user can tweak the 
> form as convenient, won't they?
> 
> I'm not sure which particular stuff you are thinking of, though.

I will hopefully install this in a day or two, and will mention that
possibility in NEWS when I do.  Let's take it from there.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* bug#60559: 29.0.60; "Cannot activate tree-sitter" spam
  2023-01-05 14:59               ` Eric Gillespie
@ 2023-01-22 13:24                 ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-01-22 13:24 UTC (permalink / raw)
  To: Eric Gillespie; +Cc: 60559-done, stephen.berman, juri

> From: Eric Gillespie <epg@pretzelnet.org>
> Date: Thu, 05 Jan 2023 08:59:00 -0600
> Cc: 60559@debbugs.gnu.org, stephen.berman@gmx.net,
>  Juri Linkov <juri@linkov.net>
> 
> All this discussion has been interesting, but it seems to me it
> is mostly focused on a world where not only tree-sitter is
> common, but all those grammar libraries are as well!
> 
> I think very few emacs users in 2023 live in that world.
> 
> If emacs was configured with tree-sitter, it seems productive to
> warn the user when tree-sitter grammars are missing.  It seems
> likely that user intended to have tree-sitter.
> 
> When emacs is NOT configured with tree-sitter, it seems
> counter-productive to warn about missing tree-sitter.
> 
> I even pass --without-tree-sitter to configure now.  It seems
> particularly surprising to me that I explicitly tell emacs "don't
> use tree-sitter" and then it immediately starts complaining to me
> that it doesn't have tree-sitter.

This annoyance should now be fixed on the emacs-29 branch, and I'm
therefore closing this bug (and the two others that were merged to
it).





^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-01-17 17:58             ` Eli Zaretskii
  2023-01-17 18:19               ` Juri Linkov
@ 2023-02-14 19:08               ` Alan Mackenzie
  2023-02-14 19:29                 ` Eli Zaretskii
  2023-02-15 18:25                 ` Juri Linkov
  1 sibling, 2 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-14 19:08 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Juri Linkov, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

I missed this thread back in January, due to being away from Emacs
development for a time, and I think the current state of this feature is
so far away from ideal as to make some design and implementation
advisable.

On Tue, Jan 17, 2023 at 19:58:40 +0200, Eli Zaretskii wrote:
> > From: Juri Linkov <juri@linkov.net>
> > Cc: casouri@gmail.com,  monnier@iro.umontreal.ca,  larsi@gnus.org,
> >   theo@thornhill.no,  jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> > Date: Tue, 17 Jan 2023 19:30:16 +0200

> > It fails for many scenarios:

> > 1. The user needs to use e.g. js-ts-mode.  Your patch requires that
> > users first visit a js file in js-mode, then they need to type

> >   M-x js-ts-mode RET

> > then for the rest of the session they can use js-ts-mode.
> > But for a new session they need to repeat the same again.

> Or customize auto-mode-alist.

> This is a consequence of the fact that js-ts-mode doesn't have a
> separate .el file.  If you have better ideas for that, I'm all ears.

> > 2. For other ts modes adding something like (require 'c-ts-mode)
> > to the user's init file is not a clean way to enable such modes.

> Why not?

> > Also takes additional space even when users don't intend to use them
> > in the current session, thus negating the benefits of autoloading.

> Once again, if the above is somehow too annoying, they can customize
> auto-mode-alist manually.  Or even use use-package (and have full
> benefit of autoloading).  In any case, the fact that a mode is loaded
> and not used is not a problem large enough to reject this simple
> arrangement.  Moreover, if someone puts the require into their init
> file, they probably want to use the mode quite a lot, so it will not
> remain ballast for too long.

> > 3. There is no simple way to disable a ts mode after loading
> > the corresponding ts file.

> Yes, there is: restart the session.  IMO, adequate enough for
> something you want to try, and then find not to like.

No, it is not adequate.  It is horrible.  It forces the user to discard
all the state in his Emacs session, and restart, which is s..l..o..w..,
particularly if said user has a large desktop file.  In my experiments
with c-ts-mode, I switched backwards and forwards several times between C
Mode and c-ts-mode.  This now corrupts my Emacs session, in that C Mode
is no longer the default for C files.  I got caught out this evening when
I opened a C file, and something failed to work on it because it opened
in c-ts-mode.

This seems to be undocumented in NEWS.

I think lots of users are going to hate having the new -ts- modes forced
upon them in this manner.  Normally, when a new feature is introduced
into an Emacs version, it is fully optional, and defaults to disabled.
Why do the -ts- modes not conform to this well established practice?

There appears to be no way, apart from editing the Lisp source files, to
make C Mode the default for .c files when there are also c-ts-mode
buffers in the session.  This is a Bad Thing.

> Bottom line: if you have better, simpler solutions, please tell.

How about commands c-make-ts-default-mode and c-make-ts-undefault-mode
(and analogous functions for the other ts-modes)?  The first of these
would push the new entries onto auto-mode-alist and the second would
remove them again.  Or we could have a customisable option,
c-default-c-mode which users could set when they are ready.  Either of
these would allow the user to try out the new modes freely without being
coerced against their will to use the new -ts- modes.

> The ones you proposed until now are significantly more complex, and it
> is not reasonable to ask users to go to such lengths to try a new mode.

Any reasonable solution is going to be more complicated than the current
code.  I don't think it reasonable silently to force users into setting the
new modes as defaults.  They should be able to try out a new mode simply
by doing M-x c-ts-mode, or the like, then go back to their normal way of
working.

> But of course, if someone wants to do it in a more complex and more
> flexible way, they still can.

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-14 19:08               ` Alan Mackenzie
@ 2023-02-14 19:29                 ` Eli Zaretskii
  2023-02-14 21:02                   ` Alan Mackenzie
  2023-02-15 18:25                 ` Juri Linkov
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-14 19:29 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 14 Feb 2023 19:08:42 +0000
> Cc: Juri Linkov <juri@linkov.net>, casouri@gmail.com,
>   monnier@iro.umontreal.ca, larsi@gnus.org, theo@thornhill.no,
>   jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Alan Mackenzie <acm@muc.de>
> 
> Hello, Eli.
> 
> I missed this thread back in January, due to being away from Emacs
> development for a time, and I think the current state of this feature is
> so far away from ideal as to make some design and implementation
> advisable.

It's too bad you are raising this up only now, because it's too late
for any significant changes, even if I were to agree with what you
propose.

Some things you miss cannot be brought back, sorry.  You have to be
around and participate in the relevant discussions, let alone be part
of implementing the features, to have your opinions taken into
considerations when it matters.

> No, it is not adequate.  It is horrible.

Not a very kind remark, to say the least.

> How about commands c-make-ts-default-mode and c-make-ts-undefault-mode

I'm okay with adding the latter, if it turns out easy enough and safe
enough (of which I'm not sure at all), and if such a command will be
implemented for all the *-ts-modes which have non-ts siblings, but I
see no reason for the former, since there are several simple ways to
cause the same effect, and they are all documented in NEWS.

Please note, however, that a pretest is hopefully very close, and so
there isn't much time for adding such commands.  I would say that for
that reason your proposal is not practical.

> The first of these would push the new entries onto auto-mode-alist
> and the second would remove them again.

I think you have a very simplistic idea of what loading a *-ts-mode
does, but if you can come up with a simple and safe implementation, I
won't object adding such a command -- it cannot do any harm by just
being there, and if it turns to be not what users want, we can always
advise them not to use it.

> Or we could have a customisable option, c-default-c-mode which users
> could set when they are ready.

That was considered, and was found to be either too complicated in
practice or, if implemented simply, not to work well enough.  So let's
not go there.

> Either of these would allow the user to try out the new modes freely
> without being coerced against their will to use the new -ts- modes.

"Try out" is not what I had in mind for users who'd like to use these
modes.

> > The ones you proposed until now are significantly more complex, and it
> > is not reasonable to ask users to go to such lengths to try a new mode.
> 
> Any reasonable solution is going to be more complicated than the current
> code.

Then they aren't "reasonable" at this time.  Maybe later, maybe on
master.  As I said several times, we have no good idea yet how users
will react to what we have.  Maybe, after we hear from them, we decide
to implement such switches, who knows.

> I don't think it reasonable silently to force users into setting the
> new modes as defaults.

That is so far from what we have that I suspect you haven't read the
code closely enough.  NEWS explains the situation.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-14 19:29                 ` Eli Zaretskii
@ 2023-02-14 21:02                   ` Alan Mackenzie
  2023-02-15 15:35                     ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-14 21:02 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Tue, Feb 14, 2023 at 21:29:01 +0200, Eli Zaretskii wrote:
> > Date: Tue, 14 Feb 2023 19:08:42 +0000
> > Cc: Juri Linkov <juri@linkov.net>, casouri@gmail.com,
> >   monnier@iro.umontreal.ca, larsi@gnus.org, theo@thornhill.no,
> >   jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

[ .... ]

> > No, it is not adequate.  It is horrible.

> Not a very kind remark, to say the least.

Sorry, I should have written "It is horrible for me." - which is true.

> > How about commands c-make-ts-default-mode and c-make-ts-undefault-mode

> I'm okay with adding the latter, if it turns out easy enough and safe
> enough (of which I'm not sure at all), and if such a command will be
> implemented for all the *-ts-modes which have non-ts siblings, but I
> see no reason for the former, since there are several simple ways to
> cause the same effect, and they are all documented in NEWS.

OK, Try this (so far only on c-ts-mode.):


diff --git a/etc/NEWS b/etc/NEWS
index 2d15e39036a..0a745d7cde9 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -3239,10 +3239,13 @@ for which a "built-in" mode would be turned on.  For example:
 
     (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))
 
-If you try these modes and don't like them, you can go back to the
-"built-in" modes by restarting Emacs.  But please tell us why you
-didn't like the tree-sitter based modes, so that we could try
-improving them.
+Normally, the loading of one of the new modes amends 'auto-mode-alist'
+such that future visiting of the same type of file will continue to
+use that new mode.  If this is not what you want, do M-x
+<mode>-make-ts-undefault-mode.  For a more permanent effect, put, for
+example, the following into your initialization file:
+
+    (eval-after-load 'c-ts-mode '(c-make-ts-undefault-mode))
 
 Each major mode based on tree-sitter needs a language grammar library,
 usually named "libtree-sitter-LANG.so" ("libtree-sitter-LANG.dll" on
diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el
index 5093c3980b6..d6ea95a2980 100644
--- a/lisp/progmodes/c-ts-mode.el
+++ b/lisp/progmodes/c-ts-mode.el
@@ -904,6 +904,20 @@ c-or-c++-ts-mode
          (treesit-ready-p 'c))
     (add-to-list 'auto-mode-alist '("\\.h\\'" . c-or-c++-ts-mode)))
 
+(defun c-make-ts-undefault-mode ()
+  "Make the older C and C++ Modes the default major modes for C(++) files."
+  (interactive)
+  (setq auto-mode-alist (delete '("\\.h\\'" . c-or-c++-ts-mode)
+                                auto-mode-alist))
+  (setq auto-mode-alist
+        (delete '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'" . c-ts-mode)
+		auto-mode-alist))
+  (setq auto-mode-alist
+        (delete
+	 '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
+	   . c++-ts-mode)
+	 auto-mode-alist)))
+
 (provide 'c-ts-mode)
 
 ;;; c-ts-mode.el ends here

[ .... ]

> I think you have a very simplistic idea of what loading a *-ts-mode
> does, but if you can come up with a simple and safe implementation, I
> won't object adding such a command -- it cannot do any harm by just
> being there, and if it turns to be not what users want, we can always
> advise them not to use it.

[ .... ]

> > Either of these would allow the user to try out the new modes freely
> > without being coerced against their will to use the new -ts- modes.

> "Try out" is not what I had in mind for users who'd like to use these
> modes.

Some will want to try them out first, before definitively committing to
them.  I am such a user.

[ .... ]

> Then they [proposed amendments] aren't "reasonable" at this time.
> Maybe later, maybe on master.

That will be too late, the damage will have been done.  It is the first
experience people have of the new modes which will create their long term
impressions of them.  I remember something similar happening in Emacs
21.1, when the new fringes were not made optional.  Lots of users
complained loudly and bitterly.

> As I said several times, we have no good idea yet how users will react
> to what we have.  Maybe, after we hear from them, we decide to
> implement such switches, who knows.

We are ourselves all users, too.  We know how we have reacted, and it is
reasonable to try to prevent bad experiences for users similar to
ourselves.

[ .... ]

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply related	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-14 21:02                   ` Alan Mackenzie
@ 2023-02-15 15:35                     ` Eli Zaretskii
  2023-02-15 17:57                       ` Alan Mackenzie
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 15:35 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Tue, 14 Feb 2023 21:02:25 +0000
> Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> From: Alan Mackenzie <acm@muc.de>
> 
> > I'm okay with adding the latter, if it turns out easy enough and safe
> > enough (of which I'm not sure at all), and if such a command will be
> > implemented for all the *-ts-modes which have non-ts siblings, but I
> > see no reason for the former, since there are several simple ways to
> > cause the same effect, and they are all documented in NEWS.
> 
> OK, Try this (so far only on c-ts-mode.):
> 
> 
> diff --git a/etc/NEWS b/etc/NEWS
> index 2d15e39036a..0a745d7cde9 100644
> --- a/etc/NEWS
> +++ b/etc/NEWS
> @@ -3239,10 +3239,13 @@ for which a "built-in" mode would be turned on.  For example:
>  
>      (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))
>  
> -If you try these modes and don't like them, you can go back to the
> -"built-in" modes by restarting Emacs.  But please tell us why you
> -didn't like the tree-sitter based modes, so that we could try
> -improving them.
> +Normally, the loading of one of the new modes amends 'auto-mode-alist'
> +such that future visiting of the same type of file will continue to
> +use that new mode.  If this is not what you want, do M-x
> +<mode>-make-ts-undefault-mode.  For a more permanent effect, put, for
> +example, the following into your initialization file:
> +
> +    (eval-after-load 'c-ts-mode '(c-make-ts-undefault-mode))

Please don't delete the text in NEWS, it is a result of many
discussions and a lot of thought.  Your proposal is yet another way of
going back to the non-ts modes, so simply _adding_ that to what's
already in NEWS should be much better.

> +(defun c-make-ts-undefault-mode ()
> +  "Make the older C and C++ Modes the default major modes for C(++) files."
> +  (interactive)
> +  (setq auto-mode-alist (delete '("\\.h\\'" . c-or-c++-ts-mode)
> +                                auto-mode-alist))
> +  (setq auto-mode-alist
> +        (delete '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'" . c-ts-mode)
> +		auto-mode-alist))
> +  (setq auto-mode-alist
> +        (delete
> +	 '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
> +	   . c++-ts-mode)
> +	 auto-mode-alist)))
> +

So you revert auto-mode-alist to its original shape, but leave the
buffers already under c-ts-mode in that mode?  Is that what the users
would expect, you think?

Also, this won't work if the user customized auto-mode-alist in some
way wrt some of those file-name extensions.

> > Then they [proposed amendments] aren't "reasonable" at this time.
> > Maybe later, maybe on master.
> 
> That will be too late, the damage will have been done.

What "damage"? why do you call "damage" changes made by others in
Emacs as part of Emacs development?

> It is the first experience people have of the new modes which will
> create their long term impressions of them.

Please leave that to people.  We are introducing new technology to
Emacs, and try doing that in the least intrusive way.  If you don't
want to help that effort (a stance that is frankly very
disappointing), at least don't bad-mouth it.

> I remember something similar happening in Emacs 21.1, when the new
> fringes were not made optional.  Lots of users complained loudly and
> bitterly.

Well, that's exactly why these new modes are entirely optional.

> > As I said several times, we have no good idea yet how users will react
> > to what we have.  Maybe, after we hear from them, we decide to
> > implement such switches, who knows.
> 
> We are ourselves all users, too.  We know how we have reacted, and it is
> reasonable to try to prevent bad experiences for users similar to
> ourselves.

For you and me as users, having to restart Emacs, or having to use a
separate session for such experiments, is an entirely reasonable and
simple alternative, one which should eliminate any need for undoing
the "damage" of c-ts-mode.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 15:35                     ` Eli Zaretskii
@ 2023-02-15 17:57                       ` Alan Mackenzie
  2023-02-15 18:33                         ` Eli Zaretskii
  2023-02-15 18:34                         ` Stefan Monnier
  0 siblings, 2 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-15 17:57 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Wed, Feb 15, 2023 at 17:35:16 +0200, Eli Zaretskii wrote:
> > Date: Tue, 14 Feb 2023 21:02:25 +0000
> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >   emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

> > > I'm okay with adding the latter, if it turns out easy enough and safe
> > > enough (of which I'm not sure at all), and if such a command will be
> > > implemented for all the *-ts-modes which have non-ts siblings, but I
> > > see no reason for the former, since there are several simple ways to
> > > cause the same effect, and they are all documented in NEWS.

> > OK, Try this (so far only on c-ts-mode.):


> > diff --git a/etc/NEWS b/etc/NEWS
> > index 2d15e39036a..0a745d7cde9 100644
> > --- a/etc/NEWS
> > +++ b/etc/NEWS
> > @@ -3239,10 +3239,13 @@ for which a "built-in" mode would be turned on.  For example:

> >      (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))

> > -If you try these modes and don't like them, you can go back to the
> > -"built-in" modes by restarting Emacs.  But please tell us why you
> > -didn't like the tree-sitter based modes, so that we could try
> > -improving them.
> > +Normally, the loading of one of the new modes amends 'auto-mode-alist'
> > +such that future visiting of the same type of file will continue to
> > +use that new mode.  If this is not what you want, do M-x
> > +<mode>-make-ts-undefault-mode.  For a more permanent effect, put, for
> > +example, the following into your initialization file:
> > +
> > +    (eval-after-load 'c-ts-mode '(c-make-ts-undefault-mode))

> Please don't delete the text in NEWS, it is a result of many
> discussions and a lot of thought.  Your proposal is yet another way of
> going back to the non-ts modes, so simply _adding_ that to what's
> already in NEWS should be much better.

OK, I'll try to combine them.

> > +(defun c-make-ts-undefault-mode ()
> > +  "Make the older C and C++ Modes the default major modes for C(++) files."
> > +  (interactive)
> > +  (setq auto-mode-alist (delete '("\\.h\\'" . c-or-c++-ts-mode)
> > +                                auto-mode-alist))
> > +  (setq auto-mode-alist
> > +        (delete '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'" . c-ts-mode)
> > +		auto-mode-alist))
> > +  (setq auto-mode-alist
> > +        (delete
> > +	 '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
> > +	   . c++-ts-mode)
> > +	 auto-mode-alist)))
> > +

> So you revert auto-mode-alist to its original shape, but leave the
> buffers already under c-ts-mode in that mode?  Is that what the users
> would expect, you think?

I think so, yes.  The scenario I am envisaging is the user tentatively
trying c-ts-mode on one, or a few buffers, then doing C-x C-f foo.c to
carry on with her work using C Mode.

> Also, this won't work if the user customized auto-mode-alist in some
> way wrt some of those file-name extensions.

OK.  How about something like the following instead (untested)?

(defun c-make-ts-undefault-mode ()
  "<Doc string>"
  (interactive)
  (let (c)
    (while (setq c (rassq 'c-ts-mode auto-mode-alist))
      (setq auto-mode-alist (remq c auto-mode-alist)))))

> > > Then they [proposed amendments] aren't "reasonable" at this time.
> > > Maybe later, maybe on master.

> > That will be too late, the damage will have been done.

> What "damage"? why do you call "damage" changes made by others in
> Emacs as part of Emacs development?

The damage I'm talking about is the disruption in users' work flow which
is likely to occur.  Being perfectly blunt, c-ts-mode is not yet as
capable as CC Mode in some areas, and in any case its configuration is
wholly different (for good reasons).  Converting to the use of c-ts-mode
is a project, not something which can just happen.  The current code is
likely to confuse and anger users when, after trying out c-ts-mode, it
gradually dawns on them that the reason C Mode no longer works is that
their newly opened files aren't in C Mode at all.  That is what has
happened to me several times.

I'm not calling others' changes damage.  I'm calling the disruptive
effect on users' work flow damage.  That disruption, once it's happened,
cannot ever be undone.

> > It is the first experience people have of the new modes which will
> > create their long term impressions of them.

> Please leave that to people.  We are introducing new technology to
> Emacs, and try doing that in the least intrusive way.  If you don't
> want to help that effort (a stance that is frankly very
> disappointing), at least don't bad-mouth it.

I'm doing my best to help.  If you don't like me using "damage", perhaps
you could suggest a more acceptable synonym expressing the disadvantage
about to be suffered by some of our users.

> > I remember something similar happening in Emacs 21.1, when the new
> > fringes were not made optional.  Lots of users complained loudly and
> > bitterly.

> Well, that's exactly why these new modes are entirely optional.

They're not entirely optional, that's the whole point of my posts over
the last couple of days.  One can opt in to using c-ts-mode, but opting
out again is unreasonably difficult.  Even restarting Emacs (which to me
is a drastic operation) won't opt out if there are still buffers in
c-ts-mode in the desktop.  I don't think the current NEWS item makes this
clear enough.

> > > As I said several times, we have no good idea yet how users will react
> > > to what we have.  Maybe, after we hear from them, we decide to
> > > implement such switches, who knows.

> > We are ourselves all users, too.  We know how we have reacted, and it is
> > reasonable to try to prevent bad experiences for users similar to
> > ourselves.

> For you and me as users, having to restart Emacs, or having to use a
> separate session for such experiments, is an entirely reasonable and
> simple alternative, ....

Having to restart Emacs is NOT at all reasonable for me, even if it may
be for you.  Neither is having to use a separate session.  We all use
Emacs differently, with different expectations.

> .... one which should eliminate any need for undoing the "damage" of
> c-ts-mode.

As I noted above, such restarting will not clear the state of c-ts-mode
being default whilst there are still c-ts-mode buffers in the desktop.
Anyhow, there is no mention of using a separate session in NEWS, and
restarting Emacs is incompletely documented (as already noted).

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-14 19:08               ` Alan Mackenzie
  2023-02-14 19:29                 ` Eli Zaretskii
@ 2023-02-15 18:25                 ` Juri Linkov
  1 sibling, 0 replies; 246+ messages in thread
From: Juri Linkov @ 2023-02-15 18:25 UTC (permalink / raw)
  To: Alan Mackenzie
  Cc: Eli Zaretskii, casouri, monnier, larsi, theo, jostein,
	emacs-devel

> How about commands c-make-ts-default-mode and c-make-ts-undefault-mode
> (and analogous functions for the other ts-modes)?  The first of these
> would push the new entries onto auto-mode-alist and the second would
> remove them again.  Or we could have a customisable option,
> c-default-c-mode which users could set when they are ready.  Either of
> these would allow the user to try out the new modes freely without being
> coerced against their will to use the new -ts- modes.

The proposed defcustom 'treesit-enable-modes' was supposed to have such
:set that would compare the old with new list of customized modes, then
for added modes like 'c-ts-mode' it could call (treesit-enable 'c-ts-mode),
and for removed modes (treesit-disable 'c-ts-mode).

Then for modes whose entries already exist in auto-mode-alist,
it will add/remove a mapping in major-mode-remap-alist.
For modes without an entry in auto-mode-alist, it will
update auto-mode-alist.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 17:57                       ` Alan Mackenzie
@ 2023-02-15 18:33                         ` Eli Zaretskii
  2023-02-15 20:31                           ` Alan Mackenzie
                                             ` (3 more replies)
  2023-02-15 18:34                         ` Stefan Monnier
  1 sibling, 4 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 18:33 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Wed, 15 Feb 2023 17:57:15 +0000
> Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> From: Alan Mackenzie <acm@muc.de>
> 
> > So you revert auto-mode-alist to its original shape, but leave the
> > buffers already under c-ts-mode in that mode?  Is that what the users
> > would expect, you think?
> 
> I think so, yes.  The scenario I am envisaging is the user tentatively
> trying c-ts-mode on one, or a few buffers, then doing C-x C-f foo.c to
> carry on with her work using C Mode.

And when going back, they don't want their C/C++ buffers revert to C
mode?  I'd be surprised.

> > Also, this won't work if the user customized auto-mode-alist in some
> > way wrt some of those file-name extensions.
> 
> OK.  How about something like the following instead (untested)?
> 
> (defun c-make-ts-undefault-mode ()
>   "<Doc string>"
>   (interactive)
>   (let (c)
>     (while (setq c (rassq 'c-ts-mode auto-mode-alist))
>       (setq auto-mode-alist (remq c auto-mode-alist)))))

Shouldn't you add the elements of C mode back, in case they were
removed?

> > > > Then they [proposed amendments] aren't "reasonable" at this time.
> > > > Maybe later, maybe on master.
> 
> > > That will be too late, the damage will have been done.
> 
> > What "damage"? why do you call "damage" changes made by others in
> > Emacs as part of Emacs development?
> 
> The damage I'm talking about is the disruption in users' work flow which
> is likely to occur.  Being perfectly blunt, c-ts-mode is not yet as
> capable as CC Mode in some areas, and in any case its configuration is
> wholly different (for good reasons).  Converting to the use of c-ts-mode
> is a project, not something which can just happen.  The current code is
> likely to confuse and anger users when, after trying out c-ts-mode, it
> gradually dawns on them that the reason C Mode no longer works is that
> their newly opened files aren't in C Mode at all.  That is what has
> happened to me several times.

This can happen with any new feature.  There's nothing we can do about
this, so please just stop worrying about it.

> I'm not calling others' changes damage.  I'm calling the disruptive
> effect on users' work flow damage.  That disruption, once it's happened,
> cannot ever be undone.

With the implied assumption that the effect will necessarily be
"disruptive" in many cases.  Why assume that?

> I'm doing my best to help.

Actually, no, you aren't.  "Help" would be to actively partake in the
development of c/c++-ts-mode.  You are our best expert on supporting
these languages, so who better than you to do at least part of this
job, if not coordinate and guide the few brave souls who are motivated
enough to do that in record time.  I'm extremely disappointed that you
completely removed yourself from that effort.  I think we could have
ended up with much better ts modes if you took part in that these last
weeks.

Instead, you only speak up to describe the "disadvantages" of these
new modes, and suggest ways to turn them off.

> > Well, that's exactly why these new modes are entirely optional.
> 
> They're not entirely optional, that's the whole point of my posts over
> the last couple of days.  One can opt in to using c-ts-mode, but opting
> out again is unreasonably difficult.

That's an unusual way of interpreting "opt out".  One doesn't need to
"opt out" of an optional behavior; instead, one should avoid turning
it on, and that's all!

> Even restarting Emacs (which to me is a drastic operation) won't opt
> out if there are still buffers in c-ts-mode in the desktop.

Many people restart Emacs all the time.  And those who use desktop
know how to overcome such problems, which aren't unique to these
modes.

> I don't think the current NEWS item makes this clear enough.

The current NEWS already goes way beyond its purpose and scope in
presenting these new modes and the related issues.  And I object to
using NEWS to tell users in too much detail how NOT to use our new
features: that is like shooting ourselves in the foot.

> > For you and me as users, having to restart Emacs, or having to use a
> > separate session for such experiments, is an entirely reasonable and
> > simple alternative, ....
> 
> Having to restart Emacs is NOT at all reasonable for me, even if it may
> be for you.  Neither is having to use a separate session.  We all use
> Emacs differently, with different expectations.
> 
> > .... one which should eliminate any need for undoing the "damage" of
> > c-ts-mode.
> 
> As I noted above, such restarting will not clear the state of c-ts-mode
> being default whilst there are still c-ts-mode buffers in the desktop.
> Anyhow, there is no mention of using a separate session in NEWS, and
> restarting Emacs is incompletely documented (as already noted).

Sounds like you run your full customized production environment in
test runs of Emacs.  The prudent thing to do is instead to either use
"emacs -Q" or to have a special user/home directory which you use for
such jobs.  Then restarting and/or deleting the desktop is not an
issue at all.  I'm surprised I need to explain that, I though
everybody who is involved in Emacs maintenance does that.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 17:57                       ` Alan Mackenzie
  2023-02-15 18:33                         ` Eli Zaretskii
@ 2023-02-15 18:34                         ` Stefan Monnier
  2023-02-15 19:01                           ` Dmitry Gutov
  2023-02-15 19:07                           ` Eli Zaretskii
  1 sibling, 2 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-02-15 18:34 UTC (permalink / raw)
  To: Alan Mackenzie
  Cc: Eli Zaretskii, juri, casouri, larsi, theo, jostein, emacs-devel

> out again is unreasonably difficult.  Even restarting Emacs (which to me
> is a drastic operation) won't opt out if there are still buffers in
> c-ts-mode in the desktop.

Sounds like a bug, indeed.
The `add-to-list` should not happen just because `c-ts-mode` is loaded.
I think it should only happen if `c-ts-mode` is called explicitly
(i.e. interactively).

Maybe something like the patch below.

We could even add a `y-or-n-p` test in `c-ts--activate` to avoid
changing config vars without the user's consent.


        Stefan


diff --git a/lisp/progmodes/c-ts-mode.el b/lisp/progmodes/c-ts-mode.el
index 6db28459c32..e4148649822 100644
--- a/lisp/progmodes/c-ts-mode.el
+++ b/lisp/progmodes/c-ts-mode.el
@@ -740,7 +740,6 @@ c-ts-base-mode-map
   "C-c C-q" #'c-ts-mode-indent-defun
   "C-c ." #'c-ts-mode-set-style)
 
-;;;###autoload
 (define-derived-mode c-ts-base-mode prog-mode "C"
   "Major mode for editing C, powered by tree-sitter.
 
@@ -856,6 +855,7 @@ c-ts-mode
   :group 'c
 
   (when (treesit-ready-p 'c)
+    (when (called-interactively-p 'any) (c-ts--activate))
     (treesit-parser-create 'c)
     ;; Comments.
     (setq-local comment-start "/* ")
@@ -888,6 +888,7 @@ c++-ts-mode
   :group 'c++
 
   (when (treesit-ready-p 'cpp)
+    (when (called-interactively-p 'any) (c-ts--activate))
     (setq-local treesit-text-type-regexp
                 (regexp-opt '("comment"
                               "raw_string_literal")))
@@ -942,6 +943,7 @@ c-or-c++-ts-mode
 the code is C or C++ and based on that chooses whether to enable
 `c-ts-mode' or `c++-ts-mode'."
   (interactive)
+  (when (called-interactively-p 'any) (c-ts--activate))
   (if (save-excursion
         (save-restriction
           (save-match-data ; Why `save-match-data'?
@@ -950,22 +952,30 @@ c-or-c++-ts-mode
             (re-search-forward c-ts-mode--c-or-c++-regexp nil t))))
       (c++-ts-mode)
     (c-ts-mode)))
-;; The entries for C++ must come first to prevent *.c files be taken
-;; as C++ on case-insensitive filesystems, since *.C files are C++,
-;; not C.
-(if (treesit-ready-p 'cpp)
-    (add-to-list 'auto-mode-alist
-                 '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
-                   . c++-ts-mode)))
-
-(if (treesit-ready-p 'c)
-    (add-to-list 'auto-mode-alist
-                 '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'"
-                   . c-ts-mode)))
-
-(if (and (treesit-ready-p 'cpp)
-         (treesit-ready-p 'c))
-    (add-to-list 'auto-mode-alist '("\\.h\\'" . c-or-c++-ts-mode)))
+
+(defun c-ts--activate ()
+  (unless (or (rassq 'c++-ts-mode auto-mode-alist)
+              (rassq 'c-ts-mode auto-mode-alist)
+              (rassq 'c-or-c++-ts-mode auto-mode-alist)
+              (rassq 'c++-ts-mode major-mode-remap-alist)
+              (rassq 'c-ts-mode major-mode-remap-alist)
+              (rassq 'c-or-c++-ts-mode major-mode-remap-alist))
+    ;; The entries for C++ must come first to prevent *.c files be taken
+    ;; as C++ on case-insensitive filesystems, since *.C files are C++,
+    ;; not C.
+    (if (treesit-ready-p 'cpp)
+        (add-to-list 'auto-mode-alist
+                     '("\\(\\.ii\\|\\.\\(CC?\\|HH?\\)\\|\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\|\\.\\(cc\\|hh\\)\\)\\'"
+                       . c++-ts-mode)))
+
+    (if (treesit-ready-p 'c)
+        (add-to-list 'auto-mode-alist
+                     '("\\(\\.[chi]\\|\\.lex\\|\\.y\\(acc\\)?\\|\\.x[bp]m\\)\\'"
+                       . c-ts-mode)))
+
+    (if (and (treesit-ready-p 'cpp)
+             (treesit-ready-p 'c))
+        (add-to-list 'auto-mode-alist '("\\.h\\'" . c-or-c++-ts-mode)))))
 
 (provide 'c-ts-mode)
 




^ permalink raw reply related	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 18:34                         ` Stefan Monnier
@ 2023-02-15 19:01                           ` Dmitry Gutov
  2023-02-15 19:26                             ` Stefan Monnier
  2023-02-15 19:07                           ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-15 19:01 UTC (permalink / raw)
  To: Stefan Monnier, Alan Mackenzie
  Cc: Eli Zaretskii, juri, casouri, larsi, theo, jostein, emacs-devel

On 15/02/2023 20:34, Stefan Monnier wrote:
>> out again is unreasonably difficult.  Even restarting Emacs (which to me
>> is a drastic operation) won't opt out if there are still buffers in
>> c-ts-mode in the desktop.
> Sounds like a bug, indeed.
> The `add-to-list` should not happen just because `c-ts-mode` is loaded.
> I think it should only happen if `c-ts-mode` is called explicitly
> (i.e. interactively).

That would make this disruptive behavior even less useful, though, 
because one of the suggested ways to use it was to add (require 
'c-ts-mode) to the user's init script -- to have the auto-mode-alist 
settings applied.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 18:34                         ` Stefan Monnier
  2023-02-15 19:01                           ` Dmitry Gutov
@ 2023-02-15 19:07                           ` Eli Zaretskii
  2023-02-15 19:27                             ` Stefan Monnier
  2023-02-15 21:06                             ` Basil L. Contovounesios
  1 sibling, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 19:07 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: Eli Zaretskii <eliz@gnu.org>,  juri@linkov.net,  casouri@gmail.com,
>   larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 13:34:02 -0500
> 
> > out again is unreasonably difficult.  Even restarting Emacs (which to me
> > is a drastic operation) won't opt out if there are still buffers in
> > c-ts-mode in the desktop.
> 
> Sounds like a bug, indeed.
> The `add-to-list` should not happen just because `c-ts-mode` is loaded.
> I think it should only happen if `c-ts-mode` is called explicitly
> (i.e. interactively).
> 
> Maybe something like the patch below.

Sorry, no.  The fact that add-to-list happens also when loading
c-ts-mode non-interactively is deliberate, so that users could
'require' or 'load' them in their init files.  Less clean, maybe, but
more practical and easier to use.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:01                           ` Dmitry Gutov
@ 2023-02-15 19:26                             ` Stefan Monnier
  2023-02-15 19:47                               ` Eli Zaretskii
                                                 ` (2 more replies)
  0 siblings, 3 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-02-15 19:26 UTC (permalink / raw)
  To: Dmitry Gutov
  Cc: Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi, theo,
	jostein, emacs-devel

>>> out again is unreasonably difficult.  Even restarting Emacs (which to me
>>> is a drastic operation) won't opt out if there are still buffers in
>>> c-ts-mode in the desktop.
>> Sounds like a bug, indeed.
>> The `add-to-list` should not happen just because `c-ts-mode` is loaded.
>> I think it should only happen if `c-ts-mode` is called explicitly
>> (i.e. interactively).
>
> That would make this disruptive behavior even less useful, though, because
> one of the suggested ways to use it was to add (require 'c-ts-mode) to the
> user's init script -- to have the auto-mode-alist settings applied.

We should never recommend (require <foo>) as a way to change Emacs's
behavior, since it directly conflicts with our convention that loading
a file should not significantly alter Emacs's behavior.

OTOH we can expose&preload `c-ts--activate` and tell users to use

    (cs-ts-activate)

in their `.emacs` (or use another name for it, of course).


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:07                           ` Eli Zaretskii
@ 2023-02-15 19:27                             ` Stefan Monnier
  2023-02-15 21:06                             ` Basil L. Contovounesios
  1 sibling, 0 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-02-15 19:27 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: acm, juri, casouri, larsi, theo, jostein, emacs-devel

> Sorry, no.  The fact that add-to-list happens also when loading
> c-ts-mode non-interactively is deliberate, so that users could
> 'require' or 'load' them in their init files.  Less clean, maybe, but
> more practical and easier to use.

In my book, this is plain harmful.
Just say no.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:26                             ` Stefan Monnier
@ 2023-02-15 19:47                               ` Eli Zaretskii
  2023-02-15 19:53                                 ` Stefan Monnier
  2023-02-15 20:24                               ` Dmitry Gutov
  2023-02-15 23:48                               ` Lynn Winebarger
  2 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 19:47 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: Alan Mackenzie <acm@muc.de>,  Eli Zaretskii <eliz@gnu.org>,
>   juri@linkov.net,  casouri@gmail.com,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 14:26:25 -0500
> 
> > That would make this disruptive behavior even less useful, though, because
> > one of the suggested ways to use it was to add (require 'c-ts-mode) to the
> > user's init script -- to have the auto-mode-alist settings applied.
> 
> We should never recommend (require <foo>) as a way to change Emacs's
> behavior, since it directly conflicts with our convention that loading
> a file should not significantly alter Emacs's behavior.

We never do -- except in this case.  Practical considerations trump
elegance, at least sometimes.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:47                               ` Eli Zaretskii
@ 2023-02-15 19:53                                 ` Stefan Monnier
  2023-02-15 20:06                                   ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2023-02-15 19:53 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

>> We should never recommend (require <foo>) as a way to change Emacs's
>> behavior, since it directly conflicts with our convention that loading
>> a file should not significantly alter Emacs's behavior.
>
> We never do -- except in this case.  Practical considerations trump
> elegance, at least sometimes.

The convention is not one of elegance but one of pragmatic concerns,
because files can get loaded unexpectedly.

(c-ts-activate) is no harder to write than (require 'c-ts-mode), so
I really can't see the "practical consideration" that justifies
such a decision.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:53                                 ` Stefan Monnier
@ 2023-02-15 20:06                                   ` Eli Zaretskii
  2023-02-15 21:04                                     ` Stefan Monnier
  2023-02-16  5:45                                     ` tomas
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 20:06 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: dgutov@yandex.ru,  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>   larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 14:53:09 -0500
> 
> > We never do -- except in this case.  Practical considerations trump
> > elegance, at least sometimes.
> 
> The convention is not one of elegance but one of pragmatic concerns,
> because files can get loaded unexpectedly.
> 
> (c-ts-activate) is no harder to write than (require 'c-ts-mode)

This is not about harder at all.

> I really can't see the "practical consideration" that justifies
> such a decision.

Well, I do.  And I explained this several times already in the past,
so from my POV this issue is closed for Emacs 29.  After the release
we should revisit this and related stuff, based on what we hear from
the users.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:26                             ` Stefan Monnier
  2023-02-15 19:47                               ` Eli Zaretskii
@ 2023-02-15 20:24                               ` Dmitry Gutov
  2023-02-16  7:05                                 ` Eli Zaretskii
  2023-02-15 23:48                               ` Lynn Winebarger
  2 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-15 20:24 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi, theo,
	jostein, emacs-devel

On 15/02/2023 21:26, Stefan Monnier wrote:
> OTOH we can expose&preload `c-ts--activate` and tell users to use
> 
>      (cs-ts-activate)

A bunch of similar solutions have been proposed (global modes, etc; I 
can whip up one more in a few minutes as well), but they unfortunately 
failed to convince.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 18:33                         ` Eli Zaretskii
@ 2023-02-15 20:31                           ` Alan Mackenzie
  2023-02-16  5:41                             ` tomas
  2023-02-16  7:27                             ` Eli Zaretskii
       [not found]                           ` <87v8k2g04m.fsf@dick>
                                             ` (2 subsequent siblings)
  3 siblings, 2 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-15 20:31 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Wed, Feb 15, 2023 at 20:33:49 +0200, Eli Zaretskii wrote:
> > Date: Wed, 15 Feb 2023 17:57:15 +0000
> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >   emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

[ .... ]

> > I'm doing my best to help.

> Actually, no, you aren't.  "Help" would be to actively partake in the
> development of c/c++-ts-mode.  You are our best expert on supporting
> these languages, so who better than you to do at least part of this
> job, if not coordinate and guide the few brave souls who are motivated
> enough to do that in record time.  I'm extremely disappointed that you
> completely removed yourself from that effort.  I think we could have
> ended up with much better ts modes if you took part in that these last
> weeks.

I think it's worth answering this point separately.

There's plenty in CC Mode which isn't good, and a danger of me actively
participating in the development of the -ts- modes is that some of this
bad stuff will get transferred.  I'm surely not the best judge of which
bits the bad bits are.

In the very nature of things, there's bound to be some competition
between CC Mode and the new modes, and me being on both "sides" would be
a psychologically uncomfortable position to be in.  In the long run, of
course, CC Mode cannot "win", and I accept that.

But you've got to allow me to have mixed feelings when the project I've
put so much into over ~20 years is facing redundancy.

On top of these considerations, there was a deluge of bugs reported in CC
Mode over the autumn.  I felt my priority had to be the maintenance of CC
Mode.

> Instead, you only speak up to describe the "disadvantages" of these
> new modes, ....

Yes, in the spirit of improving them, much as I have reported bugs in
other parts of Emacs.

> .... and suggest ways to turn them off.

Yes.  Plenty of people like CC Mode, but I don't think you are among
them.  These people are likely to want to carry on using CC Mode, at
least in the short term, and to do this they need a way to switch off the
new modes.  I think you must agree with me there.  Where we differ is
that I want to make this way of restoring CC Mode's position in
auto-mode-alist easy, whereas you seem to be content that it remain
difficult.  I confess I don't understand why.

[ .... ]

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
       [not found]                           ` <87v8k2g04m.fsf@dick>
@ 2023-02-15 20:34                             ` Eli Zaretskii
       [not found]                               ` <87mt5eegkw.fsf@dick>
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-15 20:34 UTC (permalink / raw)
  To: dick; +Cc: acm, juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> From: dick <dick.r.chiang@gmail.com>
> Cc: Alan Mackenzie <acm@muc.de>,  juri@linkov.net,  casouri@gmail.com,
>   monnier@iro.umontreal.ca,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 15:11:05 -0500
> 
> EZ> Instead, you only ... suggest ways to turn them off.
> 
> Why the continued pretense of surprise at cc-mode guy's naysaying?
> 
> If your reliable but decades-old module were aggressively being unseated,
> you'd react with equal hostility.  Nearly all middle-aged programmers,
> myself among them, would.

Will you ever learn that when someone says something that seems
trivial and maybe ridiculous to you, it could be for reasons other
than stupidity or ignorance?  And that you should think harder to try
to figure out what you might be missing here, rather than assume that
you are the only bearer of wisdom around?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 20:06                                   ` Eli Zaretskii
@ 2023-02-15 21:04                                     ` Stefan Monnier
  2023-02-16  7:42                                       ` Eli Zaretskii
  2023-02-16  5:45                                     ` tomas
  1 sibling, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2023-02-15 21:04 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

>> I really can't see the "practical consideration" that justifies
>> such a decision.
> Well, I do.  And I explained this several times already in the past,

Could you point to those explanations because I can't remember seeing
them in the long discussion(s).

Overriding the user's `auto-mode-alist` setting when merely loading
`c-ts-mode.el` is pretty drastic in my view, so the argument in favor of
this should be very strong and clear.

E.g. just `C-h o c-ts-mode RET` or `C-h o c-ts TAB` is enough to load that file.

In which use-case is it more "practical" to do as we currently do than
to do it in a way like the one I proposed (or various other ways: as
Dmitry points out, there are many alternatives, and coding them is not
the problem).


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:07                           ` Eli Zaretskii
  2023-02-15 19:27                             ` Stefan Monnier
@ 2023-02-15 21:06                             ` Basil L. Contovounesios
  2023-02-16  7:44                               ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Basil L. Contovounesios @ 2023-02-15 21:06 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Stefan Monnier, acm, juri, casouri, larsi, theo, jostein,
	emacs-devel

Eli Zaretskii [2023-02-15 21:07 +0200] wrote:

> Sorry, no.  The fact that add-to-list happens also when loading
> c-ts-mode non-interactively is deliberate, so that users could
> 'require' or 'load' them in their init files.  Less clean, maybe, but
> more practical and easier to use.

Is it a problem that this happens inconsistently, AFAICT, across
different *-ts-modes?

Added to auto-mode-alist at load time:
- c++-ts-mode
- c-or-c++-ts-mode
- c-ts-mode
- cmake-ts-mode
- dockerfile-ts-mode
- go-mod-ts-mode
- go-ts-mode
- html-ts-mode
- java-ts-mode
- json-ts-mode
- ruby-ts-mode
- rust-ts-mode
- toml-ts-mode
- tsx-ts-mode
- typescript-ts-mode
- yaml-ts-mode

Added to auto-mode-alist at call time:
- csharp-ts-mode
- css-ts-mode
- js-ts-mode
- python-ts-mode

Never added to auto-mode-alist:
- bash-ts-mode

Or is this intentional?

Thanks,

-- 
Basil



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 18:33                         ` Eli Zaretskii
  2023-02-15 20:31                           ` Alan Mackenzie
       [not found]                           ` <87v8k2g04m.fsf@dick>
@ 2023-02-15 21:40                           ` Alan Mackenzie
  2023-02-17 13:30                           ` Alan Mackenzie
  3 siblings, 0 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-15 21:40 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Wed, Feb 15, 2023 at 20:33:49 +0200, Eli Zaretskii wrote:
> > Date: Wed, 15 Feb 2023 17:57:15 +0000
> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >   emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

> > > So you revert auto-mode-alist to its original shape, but leave the
> > > buffers already under c-ts-mode in that mode?  Is that what the users
> > > would expect, you think?

> > I think so, yes.  The scenario I am envisaging is the user tentatively
> > trying c-ts-mode on one, or a few buffers, then doing C-x C-f foo.c to
> > carry on with her work using C Mode.

> And when going back, they don't want their C/C++ buffers revert to C
> mode?  I'd be surprised.

I wouldn't.  If I type M-x foo-mode in a buffer, I would be surprised if
something changed that without asking me.

> > > Also, this won't work if the user customized auto-mode-alist in some
> > > way wrt some of those file-name extensions.

> > OK.  How about something like the following instead (untested)?

> > (defun c-make-ts-undefault-mode ()
> >   "<Doc string>"
> >   (interactive)
> >   (let (c)
> >     (while (setq c (rassq 'c-ts-mode auto-mode-alist))
> >       (setq auto-mode-alist (remq c auto-mode-alist)))))

> Shouldn't you add the elements of C mode back, in case they were
> removed?

Possibly.  But we're looking for something simple and reliable at the
moment.  Adding code to check for the presence of c-mode in
auto-mode-alist would add some complexity, and may not really be needed.

> > > > > Then they [proposed amendments] aren't "reasonable" at this time.
> > > > > Maybe later, maybe on master.

> > > > That will be too late, the damage will have been done.

> > > What "damage"? why do you call "damage" changes made by others in
> > > Emacs as part of Emacs development?

> > The damage I'm talking about is the disruption in users' work flow which
> > is likely to occur.  Being perfectly blunt, c-ts-mode is not yet as
> > capable as CC Mode in some areas, and in any case its configuration is
> > wholly different (for good reasons).  Converting to the use of c-ts-mode
> > is a project, not something which can just happen.  The current code is
> > likely to confuse and anger users when, after trying out c-ts-mode, it
> > gradually dawns on them that the reason C Mode no longer works is that
> > their newly opened files aren't in C Mode at all.  That is what has
> > happened to me several times.

> This can happen with any new feature.  There's nothing we can do about
> this, so please just stop worrying about it.

I think we can do things about it, hence my patch from yesterday evening
and this discussion.

> > I'm not calling others' changes damage.  I'm calling the disruptive
> > effect on users' work flow damage.  That disruption, once it's happened,
> > cannot ever be undone.

> With the implied assumption that the effect will necessarily be
> "disruptive" in many cases.  Why assume that?

Because it's unexpected to the users, something which throws them out of
their rhythm, and forces them to expend time and energy getting back to
where they wanted to be.  Not all users, but likely enough of them to
matter.

[ .... ]

> > > Well, that's exactly why these new modes are entirely optional.

> > They're not entirely optional, that's the whole point of my posts over
> > the last couple of days.  One can opt in to using c-ts-mode, but opting
> > out again is unreasonably difficult.

> That's an unusual way of interpreting "opt out".  One doesn't need to
> "opt out" of an optional behavior; instead, one should avoid turning
> it on, and that's all!

Again, we differ here.  You're picturing a process where a user one day
makes a definitive decision to switch, and does so permanently.  Maybe
that's how you work, it's not how I work.  I would find myself with a
spare few minutes, experiment a bit with the new mode, then carry on with
my work, maybe experiment a bit more.  I would subconsciously expect my
Emacs state would not be changed by such experimentation.  But it is, in
a way which is difficult to reverse.  Again, I don't understand why
you're content that such difficulty remain.

> > Even restarting Emacs (which to me is a drastic operation) won't opt
> > out if there are still buffers in c-ts-mode in the desktop.

> Many people restart Emacs all the time.  And those who use desktop
> know how to overcome such problems, which aren't unique to these
> modes.

Probably most users start Emacs in the morning and shut it down in the
evening.  I certainly do.  I think a user who gets into this problem is
going to have to spend, perhaps, between 1 and 2 hours getting it sorted
out, or on the other hand, will continue dissatisfied at having to type
M-x c-mode after loading each and every C file.  Why do you not see this
as a bad thing?

> > I don't think the current NEWS item makes this clear enough.

> The current NEWS already goes way beyond its purpose and scope in
> presenting these new modes and the related issues.  And I object to
> using NEWS to tell users in too much detail how NOT to use our new
> features: that is like shooting ourselves in the foot.

NEWS has always introduced new features, and amongst the description is
(almost) always some text telling users how to restore the old behaviour.
Why do we not do that here?

> > > For you and me as users, having to restart Emacs, or having to use a
> > > separate session for such experiments, is an entirely reasonable and
> > > simple alternative, ....

> > Having to restart Emacs is NOT at all reasonable for me, even if it may
> > be for you.  Neither is having to use a separate session.  We all use
> > Emacs differently, with different expectations.

> > > .... one which should eliminate any need for undoing the "damage" of
> > > c-ts-mode.

> > As I noted above, such restarting will not clear the state of c-ts-mode
> > being default whilst there are still c-ts-mode buffers in the desktop.
> > Anyhow, there is no mention of using a separate session in NEWS, and
> > restarting Emacs is incompletely documented (as already noted).

> Sounds like you run your full customized production environment in
> test runs of Emacs.  The prudent thing to do is instead to either use
> "emacs -Q" or to have a special user/home directory which you use for
> such jobs.  Then restarting and/or deleting the desktop is not an
> issue at all.  I'm surprised I need to explain that, I thought
> everybody who is involved in Emacs maintenance does that.

Everybody uses Emacs differently.  Even (especially) amongst Emacs
developers.

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 19:26                             ` Stefan Monnier
  2023-02-15 19:47                               ` Eli Zaretskii
  2023-02-15 20:24                               ` Dmitry Gutov
@ 2023-02-15 23:48                               ` Lynn Winebarger
  2023-02-16  2:56                                 ` Stefan Monnier
  2 siblings, 1 reply; 246+ messages in thread
From: Lynn Winebarger @ 2023-02-15 23:48 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: Dmitry Gutov, Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi,
	theo, jostein, emacs-devel

On Wed, Feb 15, 2023 at 2:27 PM Stefan Monnier <monnier@iro.umontreal.ca> wrote:
> We should never recommend (require <foo>) as a way to change Emacs's
> behavior, since it directly conflicts with our convention that loading
> a file should not significantly alter Emacs's behavior.

As someone who preloads the (elisp) world, I'd love to see this maxim
enshrined somewhere.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 23:48                               ` Lynn Winebarger
@ 2023-02-16  2:56                                 ` Stefan Monnier
  0 siblings, 0 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-02-16  2:56 UTC (permalink / raw)
  To: Lynn Winebarger
  Cc: Dmitry Gutov, Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi,
	theo, jostein, emacs-devel

Lynn Winebarger [2023-02-15 18:48:50] wrote:

> On Wed, Feb 15, 2023 at 2:27 PM Stefan Monnier <monnier@iro.umontreal.ca> wrote:
>> We should never recommend (require <foo>) as a way to change Emacs's
>> behavior, since it directly conflicts with our convention that loading
>> a file should not significantly alter Emacs's behavior.
>
> As someone who preloads the (elisp) world, I'd love to see this maxim
> enshrined somewhere.

It's in doc/lispref/tips.texi:

    @section Emacs Lisp Coding Conventions
    
    @cindex coding conventions in Emacs Lisp
      Here are conventions that you should follow when writing Emacs Lisp
    code intended for widespread use:
    
    @itemize @bullet
    @item
    Simply loading a package should not change Emacs's editing behavior.
    Include a command or commands to enable and disable the feature,
    or to invoke it.
    
    This convention is mandatory for any file that includes custom
    definitions.  If fixing such a file to follow this convention requires
    an incompatible change, go ahead and make the incompatible change;
    don't postpone it.


-- Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 20:31                           ` Alan Mackenzie
@ 2023-02-16  5:41                             ` tomas
  2023-02-16  7:27                             ` Eli Zaretskii
  1 sibling, 0 replies; 246+ messages in thread
From: tomas @ 2023-02-16  5:41 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 286 bytes --]

On Wed, Feb 15, 2023 at 08:31:46PM +0000, Alan Mackenzie wrote:
> Hello, Eli.

[...]

> Yes.  Plenty of people like CC Mode [...]

FWIW, I'm one of them. I'll sure try out ts-mode at some point,
but definitely not now (priorities...). And I doubt I'd switch.

Cheers
-- 
t

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 20:06                                   ` Eli Zaretskii
  2023-02-15 21:04                                     ` Stefan Monnier
@ 2023-02-16  5:45                                     ` tomas
  2023-02-16  8:26                                       ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: tomas @ 2023-02-16  5:45 UTC (permalink / raw)
  To: emacs-devel

[-- Attachment #1: Type: text/plain, Size: 277 bytes --]

On Wed, Feb 15, 2023 at 10:06:35PM +0200, Eli Zaretskii wrote:

[...]

> Well, I do.  And I explained this several times already in the past,

I don't understand that. To me it feels like pushing people to bump
into ts-modes whether they want or not.

Cheers
-- 
t

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 20:24                               ` Dmitry Gutov
@ 2023-02-16  7:05                                 ` Eli Zaretskii
  2023-02-16  7:53                                   ` Theodor Thornhill
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  7:05 UTC (permalink / raw)
  To: Dmitry Gutov
  Cc: monnier, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> Date: Wed, 15 Feb 2023 22:24:49 +0200
> Cc: Alan Mackenzie <acm@muc.de>, Eli Zaretskii <eliz@gnu.org>,
>  juri@linkov.net, casouri@gmail.com, larsi@gnus.org, theo@thornhill.no,
>  jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> On 15/02/2023 21:26, Stefan Monnier wrote:
> > OTOH we can expose&preload `c-ts--activate` and tell users to use
> > 
> >      (cs-ts-activate)
> 
> A bunch of similar solutions have been proposed (global modes, etc; I 
> can whip up one more in a few minutes as well), but they unfortunately 
> failed to convince.

Indeed, I'm still not convinced.  We should decide based on user
reactions and requests once Emacs 29 is out.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 20:31                           ` Alan Mackenzie
  2023-02-16  5:41                             ` tomas
@ 2023-02-16  7:27                             ` Eli Zaretskii
  2023-02-16 22:05                               ` Yuan Fu
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  7:27 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Wed, 15 Feb 2023 20:31:46 +0000
> Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> From: Alan Mackenzie <acm@muc.de>
> 
> But you've got to allow me to have mixed feelings when the project I've
> put so much into over ~20 years is facing redundancy.

It isn't facing redundancy, it's nowhere near that.  You don't need to
worry about that.  I expect a significant proportion of users to wish
to stay with CC Mode, for several good reasons:

 . the use cases it handles better that c-ts-mode (cpp stuff etc.)
 . the plethora of minor conveniences it offers that c-ts-mode
   doesn't, at least not yet, such as much more elaborate
   customizations of indentation and electric behavior

I'm not even sure yet whether I myself will switch.  I will give the
c-ts-mode a lot of leeway and credit, but I don't know yet what will
be the outcome.

> > .... and suggest ways to turn them off.
> 
> Yes.  Plenty of people like CC Mode, but I don't think you are among
> them.

How can I not like it?  I use it every day, for several decades.  I
have several non-trivial customizations of it, some of which I will
probably miss with c-ts-mode, which doesn't yet support them, and
maybe never will.

> These people are likely to want to carry on using CC Mode, at
> least in the short term, and to do this they need a way to switch off the
> new modes.

The new modes don't need to be switched off because they are off to
begin with.  People who don't like them don't need to change their
configuration even a single bit.  I specifically and explicitly took
care of that, over the hesitations, bewilderment, and downright
objections of several good people here.  You have just heard them
again, and they still disagree with me over the result, with valid
arguments.  So I find it ironic that all that effort is now seen as
insufficient, by you of all people.  Maybe you should try looking at
this issue from my POV.

> I think you must agree with me there.  Where we differ is
> that I want to make this way of restoring CC Mode's position in
> auto-mode-alist easy, whereas you seem to be content that it remain
> difficult.  I confess I don't understand why.

"Difficult"?  Restarting Emacs is not difficult.  Many users do that
all the time (watch the posts about how fast Emacs should start up),
even though we recommend not to do that.  And if the user finds he or
she doesn't like the new mode, that restart is a single event, no need
to do it more than once.  That's not my notion of "difficult".



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 21:04                                     ` Stefan Monnier
@ 2023-02-16  7:42                                       ` Eli Zaretskii
  2023-02-16  9:49                                         ` Basil L. Contovounesios
  2023-02-16 14:41                                         ` Stefan Monnier
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  7:42 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: dgutov@yandex.ru,  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>   larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 16:04:23 -0500
> 
> >> I really can't see the "practical consideration" that justifies
> >> such a decision.
> > Well, I do.  And I explained this several times already in the past,
> 
> Could you point to those explanations because I can't remember seeing
> them in the long discussion(s).

Sorry, no can do.  I don't have the time required to look them up,
what with the search of the emacs-devel archives still badly broken.

> Overriding the user's `auto-mode-alist` setting when merely loading
> `c-ts-mode.el` is pretty drastic in my view, so the argument in favor of
> this should be very strong and clear.

The argument is simplicity for the users to try these modes and turn
them on in their customizations.

> E.g. just `C-h o c-ts-mode RET` or `C-h o c-ts TAB` is enough to load that file.

That's an existing problem that should somehow be fixed, if we
consider "C-h o" a popular command used by many users (I don't
consider it that, and fail to see why someone would even think about
doing that).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 21:06                             ` Basil L. Contovounesios
@ 2023-02-16  7:44                               ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  7:44 UTC (permalink / raw)
  To: Basil L. Contovounesios
  Cc: monnier, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: "Basil L. Contovounesios" <contovob@tcd.ie>
> Cc: Stefan Monnier <monnier@iro.umontreal.ca>,  acm@muc.de,
>   juri@linkov.net,  casouri@gmail.com,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 21:06:21 +0000
> 
> Or is this intentional?

It's intentional.  Some *-ts-modes are defined on the same file as
non-ts modes, and bash-ts-mode handles only Bash scripts.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:05                                 ` Eli Zaretskii
@ 2023-02-16  7:53                                   ` Theodor Thornhill
  2023-02-16  8:34                                     ` Eli Zaretskii
  2023-02-16 11:56                                     ` Dmitry Gutov
  0 siblings, 2 replies; 246+ messages in thread
From: Theodor Thornhill @ 2023-02-16  7:53 UTC (permalink / raw)
  To: Eli Zaretskii, Dmitry Gutov
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel



On 16 February 2023 08:05:44 CET, Eli Zaretskii <eliz@gnu.org> wrote:
>> Date: Wed, 15 Feb 2023 22:24:49 +0200
>> Cc: Alan Mackenzie <acm@muc.de>, Eli Zaretskii <eliz@gnu.org>,
>>  juri@linkov.net, casouri@gmail.com, larsi@gnus.org, theo@thornhill.no,
>>  jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> From: Dmitry Gutov <dgutov@yandex.ru>
>> 
>> On 15/02/2023 21:26, Stefan Monnier wrote:
>> > OTOH we can expose&preload `c-ts--activate` and tell users to use
>> > 
>> >      (cs-ts-activate)
>> 
>> A bunch of similar solutions have been proposed (global modes, etc; I 
>> can whip up one more in a few minutes as well), but they unfortunately 
>> failed to convince.
>
>Indeed, I'm still not convinced.  We should decide based on user
>reactions and requests once Emacs 29 is out.

To me the last point here is the important one. We kinda "rushed" the modes in so that the treesit backend would have anything to show for in emacs-29. We've tried many times to devise a mechanism for it to be unintrusive, and definitely so for the cc mode equivalents. Yes they are far behind them in some respects, so there was never a point to make them the default for the foreseeable future. 

Also remember that whatever mechanism we make now won't be part of Emacs 30+, as there are clear shortcomings in all directions. Let's rather focus on how we can improve the situation for Emacs 30.

I'm thinking some devise like a "language layer", where major and minor modes are pluggable.

Let's say you want to program in JavaScript.

Then you can for example do something like:

(make-language-layer 'js-layer
  :major-mode 'js-ts-mode
  :lsp 'eglot
  :dagnostics 'flymake)


Then

(add-to-list auto-mode-alist ".js" 'js-layer)

And so forth. In this case a person can swap out flymake for flycheck, eglot for lsp-mode, js-ts-mode for js-mode etc. Then no implementation "owns" the language namespace, and we hopefully don't step on anyone's toes.

What do you think?

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
       [not found]                               ` <87mt5eegkw.fsf@dick>
@ 2023-02-16  7:53                                 ` Eli Zaretskii
  2023-02-16  8:52                                   ` Po Lu
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  7:53 UTC (permalink / raw)
  To: dick; +Cc: acm, juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> From: dick <dick.r.chiang@gmail.com>
> Cc: acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>   monnier@iro.umontreal.ca,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Wed, 15 Feb 2023 16:58:39 -0500
> 
> > it could be for reasons other than stupidity?

The full citation was:

> > Will you ever learn that when someone says something that seems
> > trivial and maybe ridiculous to you, it could be for reasons other
> > than stupidity or ignorance?

> Unfalsifiability is your rhetorical crutch of choice.  Examples include,
> "You don't understand the code", and "I have my reasons."

I guess the answer to my question above is "not yet".

> Unlike you, I work on emacs full-time, so consider my opinion a
> professional one.  That your initial reaction to Bug#60559 was
> "notabug wontfix" suggests you could use it.

That bug is fixed, by yours truly, btw.

> It will be years before any *working* C programmer would default to
> c-ts-mode over cc-mode.

You may be right here.  We shall see.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  5:45                                     ` tomas
@ 2023-02-16  8:26                                       ` Eli Zaretskii
  2023-02-16 10:30                                         ` Alan Mackenzie
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  8:26 UTC (permalink / raw)
  To: tomas; +Cc: emacs-devel

> Date: Thu, 16 Feb 2023 06:45:13 +0100
> From: <tomas@tuxteam.de>
> 
> On Wed, Feb 15, 2023 at 10:06:35PM +0200, Eli Zaretskii wrote:
> 
> > Well, I do.  And I explained this several times already in the past,
> 
> I don't understand that. To me it feels like pushing people to bump
> into ts-modes whether they want or not.

These modes are completely optional, turned off by default.  Users
need to turn them on, in one of the described ways, for them to take
any effect.  None of the described ways of turning on the modes
happens automatically.  I'm bewildered how this can be regarded as
"pushing people to bump into" these modes.  Are you sure we are
talking about the same editor?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:53                                   ` Theodor Thornhill
@ 2023-02-16  8:34                                     ` Eli Zaretskii
  2023-02-16  8:46                                       ` Theodor Thornhill
  2023-02-16 11:58                                       ` Dmitry Gutov
  2023-02-16 11:56                                     ` Dmitry Gutov
  1 sibling, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16  8:34 UTC (permalink / raw)
  To: Theodor Thornhill
  Cc: dgutov, monnier, acm, juri, casouri, larsi, jostein, emacs-devel

> Date: Thu, 16 Feb 2023 08:53:56 +0100
> From: Theodor Thornhill <theo@thornhill.no>
> CC: monnier@iro.umontreal.ca, acm@muc.de, juri@linkov.net, casouri@gmail.com,
>  larsi@gnus.org, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
> 
> I'm thinking some devise like a "language layer", where major and minor modes are pluggable.
> 
> Let's say you want to program in JavaScript.
> 
> Then you can for example do something like:
> 
> (make-language-layer 'js-layer
>   :major-mode 'js-ts-mode
>   :lsp 'eglot
>   :dagnostics 'flymake)
> 
> 
> Then
> 
> (add-to-list auto-mode-alist ".js" 'js-layer)
> 
> And so forth. In this case a person can swap out flymake for flycheck, eglot for lsp-mode, js-ts-mode for js-mode etc. Then no implementation "owns" the language namespace, and we hopefully don't step on anyone's toes.
> 
> What do you think?

I don't know yet.  We should definitely think about this more.  Emacs
never had more than a single major mode per programming language, so
for us "language" and "major mode" were always synonyms.  (Perl mode
and CPerl mode is the only exception I know of, and it did cause us
grief.)

So yes, this is a new situation that could call for some new concepts
in Emacs.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  8:34                                     ` Eli Zaretskii
@ 2023-02-16  8:46                                       ` Theodor Thornhill
  2023-02-16 11:58                                       ` Dmitry Gutov
  1 sibling, 0 replies; 246+ messages in thread
From: Theodor Thornhill @ 2023-02-16  8:46 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, monnier, acm, juri, casouri, larsi, jostein, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

>> Date: Thu, 16 Feb 2023 08:53:56 +0100
>> From: Theodor Thornhill <theo@thornhill.no>
>> CC: monnier@iro.umontreal.ca, acm@muc.de, juri@linkov.net, casouri@gmail.com,
>>  larsi@gnus.org, jostein@secure.kjonigsen.net, emacs-devel@gnu.org
>> 
>> I'm thinking some devise like a "language layer", where major and minor modes are pluggable.
>> 
>> Let's say you want to program in JavaScript.
>> 
>> Then you can for example do something like:
>> 
>> (make-language-layer 'js-layer
>>   :major-mode 'js-ts-mode
>>   :lsp 'eglot
>>   :dagnostics 'flymake)
>> 
>> 
>> Then
>> 
>> (add-to-list auto-mode-alist ".js" 'js-layer)
>> 
>> And so forth. In this case a person can swap out flymake for flycheck, eglot for lsp-mode, js-ts-mode for js-mode etc. Then no implementation "owns" the language namespace, and we hopefully don't step on anyone's toes.
>> 
>> What do you think?
>
> I don't know yet.  We should definitely think about this more.  Emacs
> never had more than a single major mode per programming language, so
> for us "language" and "major mode" were always synonyms.  (Perl mode
> and CPerl mode is the only exception I know of, and it did cause us
> grief.)
>
> So yes, this is a new situation that could call for some new concepts
> in Emacs.

Yes, absolutely.  I just wanted to put out there a concrete thought that
hopefully moves the discussion forward.

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:53                                 ` Eli Zaretskii
@ 2023-02-16  8:52                                   ` Po Lu
  0 siblings, 0 replies; 246+ messages in thread
From: Po Lu @ 2023-02-16  8:52 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dick, acm, juri, casouri, monnier, larsi, theo, jostein,
	emacs-devel

People, when replying to dick, it would be easier to simply say:

      *plonk*

perform the associated action, and then let that kook and/or troll shout
his head off in peace. :-)



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:42                                       ` Eli Zaretskii
@ 2023-02-16  9:49                                         ` Basil L. Contovounesios
  2023-02-16 11:48                                           ` Eli Zaretskii
  2023-02-16 14:41                                         ` Stefan Monnier
  1 sibling, 1 reply; 246+ messages in thread
From: Basil L. Contovounesios @ 2023-02-16  9:49 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Stefan Monnier, dgutov, acm, juri, casouri, larsi, theo, jostein,
	emacs-devel

Eli Zaretskii [2023-02-16 09:42 +0200] wrote:

>> From: Stefan Monnier <monnier@iro.umontreal.ca>
>> Cc: dgutov@yandex.ru,  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>>   larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>>   emacs-devel@gnu.org
>> Date: Wed, 15 Feb 2023 16:04:23 -0500
>> 
>> E.g. just `C-h o c-ts-mode RET` or `C-h o c-ts TAB` is enough to load that file.
>
> That's an existing problem that should somehow be fixed, if we
> consider "C-h o" a popular command used by many users (I don't
> consider it that, and fail to see why someone would even think about
> doing that).

C-h o is just a convenient union of C-h v, C-h f, etc.

The same problem exists with C-h f:

0. emacs -Q
1. C-h f c-ts-mode RET
   [ or C-h f c-ts TAB C-g ]
2. M-: (car auto-mode-alist) RET
   => ("\\.h\\'" . c-or-c++-ts-mode)

I understand that this situation compromises between various drawbacks
that I do not fully grasp, and I know how I'd work around this issue if
it bothered me, but I still find it unfortunate that an opt-in feature
is only sometimes opt-in for the average user.

Thanks,

-- 
Basil



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  8:26                                       ` Eli Zaretskii
@ 2023-02-16 10:30                                         ` Alan Mackenzie
  2023-02-16 12:38                                           ` Po Lu
  0 siblings, 1 reply; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-16 10:30 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: tomas, emacs-devel

Hello, Eli.

On Thu, Feb 16, 2023 at 10:26:00 +0200, Eli Zaretskii wrote:
> > Date: Thu, 16 Feb 2023 06:45:13 +0100
> > From: <tomas@tuxteam.de>

> > On Wed, Feb 15, 2023 at 10:06:35PM +0200, Eli Zaretskii wrote:

> > > Well, I do.  And I explained this several times already in the past,

> > I don't understand that. To me it feels like pushing people to bump
> > into ts-modes whether they want or not.

> These modes are completely optional, turned off by default.  Users
> need to turn them on, in one of the described ways, for them to take
> any effect.  None of the described ways of turning on the modes
> happens automatically.  I'm bewildered how this can be regarded as
> "pushing people to bump into" these modes.  Are you sure we are
> talking about the same editor?

I'm a little surprised that you don't appreciate how other people (such
as me) work, and that you seem to regard restarting Emacs as a perfectly
acceptable way of reversing M-x c-ts-mode.

(Some) users will not be satisfied with a single switch to c-ts-mode,
they will want to move backwards and forwards to and from CC Mode IN THE
SAME EMACS SESSION, and will resent continually having to restart Emacs
to do so.

This "moving backwards and forward" is asymmetric.  It is far, far
easier to switch into c-ts-mode than switch out of it, and I feel this
is not right.  It is why I proposed c-make-ts-undefault-mode.

Also, restarting Emacs will NOT restore auto-mode-alist, unless the user
doesn't use desktop, or somehow knows (how?) he must clear his desktop
of c-ts-mode buffers before restarting.  I foresee much wasted time and
frustration resulting from this.

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  9:49                                         ` Basil L. Contovounesios
@ 2023-02-16 11:48                                           ` Eli Zaretskii
  0 siblings, 0 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16 11:48 UTC (permalink / raw)
  To: Basil L. Contovounesios
  Cc: monnier, dgutov, acm, juri, casouri, larsi, theo, jostein,
	emacs-devel

> From: "Basil L. Contovounesios" <contovob@tcd.ie>
> Cc: Stefan Monnier <monnier@iro.umontreal.ca>,  dgutov@yandex.ru,
>  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,  larsi@gnus.org,
>  theo@thornhill.no,  jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Thu, 16 Feb 2023 09:49:15 +0000
> 
> 0. emacs -Q
> 1. C-h f c-ts-mode RET
>    [ or C-h f c-ts TAB C-g ]
> 2. M-: (car auto-mode-alist) RET
>    => ("\\.h\\'" . c-or-c++-ts-mode)
> 
> I understand that this situation compromises between various drawbacks
> that I do not fully grasp, and I know how I'd work around this issue if
> it bothered me, but I still find it unfortunate that an opt-in feature
> is only sometimes opt-in for the average user.

I agree, but I had to choose the less evil alternative, out of those
that were at all practical given the schedule.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:53                                   ` Theodor Thornhill
  2023-02-16  8:34                                     ` Eli Zaretskii
@ 2023-02-16 11:56                                     ` Dmitry Gutov
  2023-02-16 14:48                                       ` Theodor Thornhill via Emacs development discussions.
  1 sibling, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-16 11:56 UTC (permalink / raw)
  To: Theodor Thornhill, Eli Zaretskii
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel

On 16/02/2023 09:53, Theodor Thornhill wrote:
> To me the last point here is the important one. We kinda "rushed" the modes in so that the treesit backend would have anything to show for in emacs-29. We've tried many times to devise a mechanism for it to be unintrusive, and definitely so for the cc mode equivalents. Yes they are far behind them in some respects, so there was never a point to make them the default for the foreseeable future.

Nobody is arguing about whether the modes should be default at the moment.

> (make-language-layer 'js-layer
>    :major-mode 'js-ts-mode
>    :lsp 'eglot
>    :dagnostics 'flymake)

If we do something like that, I'd rather we try for a scheme where we 
don't need to enumerate the "swappable" features in advance -- aside 
from the major mode, of course. But Eglot and friends plug into a 
language through indirection.

Other than that, the user still needs to 'M-x eglot' or 'M-x lsp', or 
enable global-flycheck-mode, so the declarations like above seem redundant.

To clarify, the example above looks nice, but there are a lot more 
programming related minor modes than the LSP clients and Flymake/Flycheck.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  8:34                                     ` Eli Zaretskii
  2023-02-16  8:46                                       ` Theodor Thornhill
@ 2023-02-16 11:58                                       ` Dmitry Gutov
  1 sibling, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-16 11:58 UTC (permalink / raw)
  To: Eli Zaretskii, Theodor Thornhill
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel

On 16/02/2023 10:34, Eli Zaretskii wrote:
> I don't know yet.  We should definitely think about this more.  Emacs
> never had more than a single major mode per programming language, so
> for us "language" and "major mode" were always synonyms.  (Perl mode
> and CPerl mode is the only exception I know of, and it did cause us
> grief.)
> 
> So yes, this is a new situation that could call for some new concepts
> in Emacs.

The relevant helps could make use of major-mode-remap-alist somehow. 
According to NEWS, it was introduced more or less for this purpose.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 10:30                                         ` Alan Mackenzie
@ 2023-02-16 12:38                                           ` Po Lu
  2023-02-16 12:53                                             ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Po Lu @ 2023-02-16 12:38 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: Eli Zaretskii, tomas, emacs-devel

Alan Mackenzie <acm@muc.de> writes:

> Hello, Eli.
>
> On Thu, Feb 16, 2023 at 10:26:00 +0200, Eli Zaretskii wrote:
>> > Date: Thu, 16 Feb 2023 06:45:13 +0100
>> > From: <tomas@tuxteam.de>
>
>> > On Wed, Feb 15, 2023 at 10:06:35PM +0200, Eli Zaretskii wrote:
>
>> > > Well, I do.  And I explained this several times already in the past,
>
>> > I don't understand that. To me it feels like pushing people to bump
>> > into ts-modes whether they want or not.
>
>> These modes are completely optional, turned off by default.  Users
>> need to turn them on, in one of the described ways, for them to take
>> any effect.  None of the described ways of turning on the modes
>> happens automatically.  I'm bewildered how this can be regarded as
>> "pushing people to bump into" these modes.  Are you sure we are
>> talking about the same editor?
>
> I'm a little surprised that you don't appreciate how other people (such
> as me) work, and that you seem to regard restarting Emacs as a perfectly
> acceptable way of reversing M-x c-ts-mode.
>
> (Some) users will not be satisfied with a single switch to c-ts-mode,
> they will want to move backwards and forwards to and from CC Mode IN THE
> SAME EMACS SESSION, and will resent continually having to restart Emacs
> to do so.
>
> This "moving backwards and forward" is asymmetric.  It is far, far
> easier to switch into c-ts-mode than switch out of it, and I feel this
> is not right.  It is why I proposed c-make-ts-undefault-mode.
>
> Also, restarting Emacs will NOT restore auto-mode-alist, unless the user
> doesn't use desktop, or somehow knows (how?) he must clear his desktop
> of c-ts-mode buffers before restarting.  I foresee much wasted time and
> frustration resulting from this.

Is c-ts-mode made default immediately after the file is loaded, or after
c-ts-mode is first enabled?

The first is at least considered a Bad Thing, and that wisdom is written
down somewhere in the Lisp reference manual.  (elisp)Major Mode
Conventions perhaps?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 12:38                                           ` Po Lu
@ 2023-02-16 12:53                                             ` Dmitry Gutov
  0 siblings, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-16 12:53 UTC (permalink / raw)
  To: Po Lu, Alan Mackenzie; +Cc: Eli Zaretskii, tomas, emacs-devel

On 16/02/2023 14:38, Po Lu wrote:
> The first is at least considered a Bad Thing, and that wisdom is written
> down somewhere in the Lisp reference manual.  (elisp)Major Mode
> Conventions perhaps?

It's the first in the list of Emacs Lisp Coding Conventions, Stefan 
mentioned it in this thread.

doc/lispref/tips.texi:51



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:42                                       ` Eli Zaretskii
  2023-02-16  9:49                                         ` Basil L. Contovounesios
@ 2023-02-16 14:41                                         ` Stefan Monnier
  2023-02-16 15:42                                           ` Eli Zaretskii
  1 sibling, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2023-02-16 14:41 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

>> Overriding the user's `auto-mode-alist` setting when merely loading
>> `c-ts-mode.el` is pretty drastic in my view, so the argument in favor of
>> this should be very strong and clear.
>
> The argument is simplicity for the users to try these modes and turn
> them on in their customizations.

But with my patch, trying the modes is exactly the same (just `M-x
c-ts-mode`) and turning them on in their customization is no harder
(since `(c-ts-activate)` is no harder to type than `(require
'c-ts-mode)`; we could also make it a global minor mode so it can be
done via Custom if it's considered important).

I spent a lot of time educating ELisp package maintainers about the need
to make sure that merely loading a file doesn't change Emacs's behavior,
and that `require` should basically never be needed in `.emacs` file.

There's *always* a good way to solve the problem without changing
Emacs's behavior just by loading a file (with the sole exception of the
`.emacs` file itself, for which changing Emacs's behavior is the sole
purpose).

>> E.g. just `C-h o c-ts-mode RET` or `C-h o c-ts TAB` is enough to load that file.
>
> That's an existing problem that should somehow be fixed, if we
> consider "C-h o" a popular command used by many users (I don't
> consider it that, and fail to see why someone would even think about
> doing that).

Replace `C-h o` with `C-h f` and the same holds.

[ I only ever use `C-h o` nowadays.  I too often used `C-h f` to look
  for a var or `C-h v` to look for a function.  :-) ]


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 11:56                                     ` Dmitry Gutov
@ 2023-02-16 14:48                                       ` Theodor Thornhill via Emacs development discussions.
  2023-02-16 14:56                                         ` Dmitry Gutov
  0 siblings, 1 reply; 246+ messages in thread
From: Theodor Thornhill via Emacs development discussions. @ 2023-02-16 14:48 UTC (permalink / raw)
  To: Dmitry Gutov, Eli Zaretskii
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel

Dmitry Gutov <dgutov@yandex.ru> writes:

> On 16/02/2023 09:53, Theodor Thornhill wrote:
>> To me the last point here is the important one. We kinda "rushed" the modes in so that the treesit backend would have anything to show for in emacs-29. We've tried many times to devise a mechanism for it to be unintrusive, and definitely so for the cc mode equivalents. Yes they are far behind them in some respects, so there was never a point to make them the default for the foreseeable future.
>
> Nobody is arguing about whether the modes should be default at the moment.
>
>> (make-language-layer 'js-layer
>>    :major-mode 'js-ts-mode
>>    :lsp 'eglot
>>    :dagnostics 'flymake)
>
> If we do something like that, I'd rather we try for a scheme where we 
> don't need to enumerate the "swappable" features in advance -- aside 
> from the major mode, of course. But Eglot and friends plug into a 
> language through indirection.
>
> Other than that, the user still needs to 'M-x eglot' or 'M-x lsp', or 
> enable global-flycheck-mode, so the declarations like above seem redundant.
>
> To clarify, the example above looks nice, but there are a lot more 
> programming related minor modes than the LSP clients and Flymake/Flycheck.

Yeah, absolutely.  This was just an example written on my phone in a
hurry.  My point is simply that from a users perspective you'd want the
whole "ide" experience many times, but not necessarily always, and some
construct like this would allow for that.  In addition, a user opening a
project in a language never used before may be pleasantly surprised to
see diagnostics, autocomplete etc without setup, at least after an
optional "enable language layer for Rust? [yn]" or something like that.

and sure, there are many things that should be added, :completions,
:project etc, where settings could be company, corfu, project could be
project.el or projectile and so forth.  And obviously some :finally that
runs an arbitrary form of sorts. Maybe?

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 14:48                                       ` Theodor Thornhill via Emacs development discussions.
@ 2023-02-16 14:56                                         ` Dmitry Gutov
  2023-02-16 15:15                                           ` Theodor Thornhill
  0 siblings, 1 reply; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-16 14:56 UTC (permalink / raw)
  To: Theodor Thornhill, Eli Zaretskii
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel

On 16/02/2023 16:48, Theodor Thornhill via Emacs development 
discussions. wrote:
> and sure, there are many things that should be added, :completions,
> :project etc, where settings could be company, corfu, project could be
> project.el or projectile and so forth.  And obviously some :finally that
> runs an arbitrary form of sorts. Maybe?

My point was, we'd rather not have to enumerate them all (or any) in 
advance.

I get your point about offering an IDE experience OOTB, though.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 14:56                                         ` Dmitry Gutov
@ 2023-02-16 15:15                                           ` Theodor Thornhill
  0 siblings, 0 replies; 246+ messages in thread
From: Theodor Thornhill @ 2023-02-16 15:15 UTC (permalink / raw)
  To: Dmitry Gutov, Eli Zaretskii
  Cc: monnier, acm, juri, casouri, larsi, jostein, emacs-devel



On 16 February 2023 15:56:23 CET, Dmitry Gutov <dgutov@yandex.ru> wrote:
>On 16/02/2023 16:48, Theodor Thornhill via Emacs development discussions. wrote:
>> and sure, there are many things that should be added, :completions,
>> :project etc, where settings could be company, corfu, project could be
>> project.el or projectile and so forth.  And obviously some :finally that
>> runs an arbitrary form of sorts. Maybe?
>
>My point was, we'd rather not have to enumerate them all (or any) in advance.
>
>I get your point about offering an IDE experience OOTB, though.

Then we agree, though I think some are clearer than others, so could be offered by default, not necessarily required

Theo



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 14:41                                         ` Stefan Monnier
@ 2023-02-16 15:42                                           ` Eli Zaretskii
  2023-02-16 16:45                                             ` Stefan Monnier
  0 siblings, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16 15:42 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: dgutov@yandex.ru,  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>  larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>  emacs-devel@gnu.org
> Date: Thu, 16 Feb 2023 09:41:20 -0500
> 
> But with my patch, trying the modes is exactly the same (just `M-x
> c-ts-mode`) and turning them on in their customization is no harder
> (since `(c-ts-activate)` is no harder to type than `(require
> 'c-ts-mode)`

Sorry, I don't buy this argument.

> we could also make it a global minor mode so it can be
> done via Custom if it's considered important).

This was considered already, but had its own issues.  And we have ran
out of time needed to look for better solutions.  (I personally don't
believe there are any that weren't already proposed.)

> I spent a lot of time educating ELisp package maintainers about the need
> to make sure that merely loading a file doesn't change Emacs's behavior,
> and that `require` should basically never be needed in `.emacs` file.

We'll have to make this one exception to the rule.  The situation
itself is exceptional and probably won't happen again soon, if ever.

> Replace `C-h o` with `C-h f` and the same holds.

So be it.  (And restarting Emacs solves that as well.)



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 15:42                                           ` Eli Zaretskii
@ 2023-02-16 16:45                                             ` Stefan Monnier
  2023-02-16 17:05                                               ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2023-02-16 16:45 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

>> But with my patch, trying the modes is exactly the same (just `M-x
>> c-ts-mode`) and turning them on in their customization is no harder
>> (since `(c-ts-activate)` is no harder to type than `(require
>> 'c-ts-mode)`
> Sorry, I don't buy this argument.

Care to expand a bit more.

>> we could also make it a global minor mode so it can be
>> done via Custom if it's considered important).
> This was considered already, but had its own issues.

Can you mention at least one?

> And we have ran out of time needed to look for better solutions.  (I
> personally don't believe there are any that weren't already proposed.)

Giving at least one downside of the patch I propose compared to the
current code would help me understand your position.

> We'll have to make this one exception to the rule.  The situation
> itself is exceptional and probably won't happen again soon, if ever.

I understand there's time pressure.  But I think this would argue
towards making the code more conservative (e.g. not change the defaults
at all, not even after enabling `c-ts-mode`) since that's much less
likely to bring problems now and in the future.

E.g. if users do as (require 'c-ts-mode) as you suggest, they'll bump
into a regression when they move on to Emacs-30 where we will have
hopefully fixed this misfeature.

I think if we want a quick&dirty short-term way to encourage the use of
tree-sitter by enthusiastic users, we should provide a "one stop shop"
function which redirects all applicable major modes to their tree-sitter
variant.  It's easy to write, it's non-intrusive, and future-proof (it
should be easy to preserve that function's approximate behavior in the
future, regardless of how tree-sitter's integration evolves).

The current code will bring bad surprises to some of our users when they
try Emacs-29, and it will bring further bad surprises later when we move
to a different solution.

The fix is trivial enough that the urgency doesn't pose any problem.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 16:45                                             ` Stefan Monnier
@ 2023-02-16 17:05                                               ` Eli Zaretskii
  2023-02-16 19:14                                                 ` Dmitry Gutov
  2023-02-16 20:07                                                 ` Stefan Monnier
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-16 17:05 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: dgutov@yandex.ru,  acm@muc.de,  juri@linkov.net,  casouri@gmail.com,
>   larsi@gnus.org,  theo@thornhill.no,  jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> Date: Thu, 16 Feb 2023 11:45:30 -0500
> 
> >> But with my patch, trying the modes is exactly the same (just `M-x
> >> c-ts-mode`) and turning them on in their customization is no harder
> >> (since `(c-ts-activate)` is no harder to type than `(require
> >> 'c-ts-mode)`
> > Sorry, I don't buy this argument.
> 
> Care to expand a bit more.

I don't agree that calling (c-ts-activate) in an init file is no
harder than loading a package.  For you and me, maybe, but not for
users.

> >> we could also make it a global minor mode so it can be
> >> done via Custom if it's considered important).
> > This was considered already, but had its own issues.
> 
> Can you mention at least one?

Sorry, I remember only the conclusion.  You will have to look up the
discussions.  (And you were here when they happened.)

> > We'll have to make this one exception to the rule.  The situation
> > itself is exceptional and probably won't happen again soon, if ever.
> 
> I understand there's time pressure.  But I think this would argue
> towards making the code more conservative (e.g. not change the defaults
> at all, not even after enabling `c-ts-mode`) since that's much less
> likely to bring problems now and in the future.

That'd make it significantly harder for users to try these modes, so I
cannot agree to that.

> E.g. if users do as (require 'c-ts-mode) as you suggest, they'll bump
> into a regression when they move on to Emacs-30 where we will have
> hopefully fixed this misfeature.

If Emacs 30 will require different ways of activating these modes, we
will document that in NEWS.  Right now, the chances for such a change
are very high anyhow, so I already took this into account.

> I think if we want a quick&dirty short-term way to encourage the use of
> tree-sitter by enthusiastic users, we should provide a "one stop shop"
> function which redirects all applicable major modes to their tree-sitter
> variant.

That, too, was suggested a couple of months ago.  It has a
disadvantage of blindly assuming that a given user will either want
all of the TS modes or none of them.  It also assumes that a given
user has all of the grammar libraries installed.  Both assumptions are
not necessarily true, and so I decided that we must allow the users to
make separate and independent decisions for each such case.

> The current code will bring bad surprises to some of our users when they
> try Emacs-29, and it will bring further bad surprises later when we move
> to a different solution.

I understand and agree it could happen, but again: I see no better
way.  Every alternative that was proposed, including those proposed
now, had its own disadvantages, and I think what we have now is the
least of all evils.

> The fix is trivial enough that the urgency doesn't pose any problem.

The fix is not trivial at all.  If it were, we would have found it
already, as we are debating this for the past two or three months, and
it's not like we lack people here who can come up with bright ideas.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 17:05                                               ` Eli Zaretskii
@ 2023-02-16 19:14                                                 ` Dmitry Gutov
  2023-02-16 20:07                                                 ` Stefan Monnier
  1 sibling, 0 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-16 19:14 UTC (permalink / raw)
  To: Eli Zaretskii, Stefan Monnier
  Cc: acm, juri, casouri, larsi, theo, jostein, emacs-devel

On 16/02/2023 19:05, Eli Zaretskii wrote:
>>>> But with my patch, trying the modes is exactly the same (just `M-x
>>>> c-ts-mode`) and turning them on in their customization is no harder
>>>> (since `(c-ts-activate)` is no harder to type than `(require
>>>> 'c-ts-mode)`
>>> Sorry, I don't buy this argument.
>> Care to expand a bit more.
> I don't agree that calling (c-ts-activate) in an init file is no
> harder than loading a package.  For you and me, maybe, but not for
> users.

Loading a package is easy. But what happens after the user decides they 
like the new major mode and want to use it in every session? They will 
need to add something to their init script. And at that point,

(require 'c-ts-mode)

is not particularly easier for a newbie than

(treesit-setup-mode 'c-ts-mode)

Or (treesit-setup-mode 'c), or (c-ts-activate), or whatever.

>>>> we could also make it a global minor mode so it can be
>>>> done via Custom if it's considered important).
>>> This was considered already, but had its own issues.
>> Can you mention at least one?
> Sorry, I remember only the conclusion.  You will have to look up the
> discussions.  (And you were here when they happened.)

It has been my impression that you made up your mind pretty early on, so 
I didn't even try to get into the discussions for the technical 
solutions, but (*)

>>> We'll have to make this one exception to the rule.  The situation
>>> itself is exceptional and probably won't happen again soon, if ever.
>> I understand there's time pressure.  But I think this would argue
>> towards making the code more conservative (e.g. not change the defaults
>> at all, not even after enabling `c-ts-mode`) since that's much less
>> likely to bring problems now and in the future.
> That'd make it significantly harder for users to try these modes, so I
> cannot agree to that.

To try a major mode like that, the user can 'M-x c-ts-mode' either way, 
no matter the solution we choose.

>> I think if we want a quick&dirty short-term way to encourage the use of
>> tree-sitter by enthusiastic users, we should provide a "one stop shop"
>> function which redirects all applicable major modes to their tree-sitter
>> variant.
> That, too, was suggested a couple of months ago.  It has a
> disadvantage of blindly assuming that a given user will either want
> all of the TS modes or none of them.  It also assumes that a given
> user has all of the grammar libraries installed.  Both assumptions are
> not necessarily true, and so I decided that we must allow the users to
> make separate and independent decisions for each such case.

(*)

If you prefer the users enable the modes one-by-one, we can provide a 
helper to do just that. Like in the example above, it could be called 
'treesit-setup-mode' and could accept as an argument either the major 
mode name, or a language, and set up the necessary auto-mode-alist or 
major-mode-alist-alist entries.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16 17:05                                               ` Eli Zaretskii
  2023-02-16 19:14                                                 ` Dmitry Gutov
@ 2023-02-16 20:07                                                 ` Stefan Monnier
  1 sibling, 0 replies; 246+ messages in thread
From: Stefan Monnier @ 2023-02-16 20:07 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: dgutov, acm, juri, casouri, larsi, theo, jostein, emacs-devel

>> > Sorry, I don't buy this argument.
>> Care to expand a bit more.
> I don't agree that calling (c-ts-activate) in an init file is no
> harder than loading a package.  For you and me, maybe, but not for
> users.

AFAIK users do it by searching for advice (in our docs when we're
lucky, or on the web more often) and copying the code snippet they find.
The specific content of the snippet doesn't matter very much in this regard.

>> > We'll have to make this one exception to the rule.  The situation
>> > itself is exceptional and probably won't happen again soon, if ever.
>> I understand there's time pressure.  But I think this would argue
>> towards making the code more conservative (e.g. not change the defaults
>> at all, not even after enabling `c-ts-mode`) since that's much less
>> likely to bring problems now and in the future.
> That'd make it significantly harder for users to try these modes, so I
> cannot agree to that.

To temporarily try the modes, the easiest is `M-x <THEMODE>` in all cases.
To try it more lastingly, "look for the snippet, copy it to `.emacs`" is
also the same in all cases.

>> I think if we want a quick&dirty short-term way to encourage the use of
>> tree-sitter by enthusiastic users, we should provide a "one stop shop"
>> function which redirects all applicable major modes to their tree-sitter
>> variant.
> That, too, was suggested a couple of months ago.  It has a
> disadvantage of blindly assuming that a given user will either want
> all of the TS modes or none of them.  It also assumes that a given
> user has all of the grammar libraries installed.  Both assumptions are
> not necessarily true, and so I decided that we must allow the users to
> make separate and independent decisions for each such case.

The point is that it's super easy to write those helper functions.
We can write one per mode, one per group of modes and an
overarching one in less time than this discussion.  And none of those
impose any surprising behavior that breaks the conventions we preach
(and on which other code relies).

IOW, what I'm proposing is a safe and simple solution.  It's probably
not the best solution in the long term either, but it obey the
Hypocratic oath which the current code doesn't, and it will to less
suffering of the users in the long run as well because we much more
easily keep supporting it in the future.

>> The current code will bring bad surprises to some of our users when they
>> try Emacs-29, and it will bring further bad surprises later when we move
>> to a different solution.
> I understand and agree it could happen,

It's not "could" it's "will".

> but again: I see no better way.  Every alternative that was proposed,
> including those proposed now, had its own disadvantages, and I think
> what we have now is the least of all evils.

The current solution has some evil because it breaks the "no effect on
load" convention (that's the reason I keep opposing it).
I don't see what's evil about the solution I advocate.
So I don't see how the current solution is "the least of all evils".
I'm not claiming my solution is better overall, but I do think it is
"the least of all evils".

>> The fix is trivial enough that the urgency doesn't pose any problem.
> The fix is not trivial at all.

What's not trivial about my solution?

> If it were, we would have found it already,

We have :-)

> as we are debating this for the past two or three months, and
> it's not like we lack people here who can come up with bright ideas.

That debate was focused a lot more on whether modes should be merged or
not and how things like that.  This here debate is strictly about
changing Emacs configuration when we load a file.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-16  7:27                             ` Eli Zaretskii
@ 2023-02-16 22:05                               ` Yuan Fu
  0 siblings, 0 replies; 246+ messages in thread
From: Yuan Fu @ 2023-02-16 22:05 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Alan Mackenzie, Juri Linkov, Stefan Monnier, Lars Ingebrigtsen,
	Theodor Thornhill, Jostein Kjønigsen, emacs-devel



> On Feb 15, 2023, at 11:27 PM, Eli Zaretskii <eliz@gnu.org> wrote:
> 
>> Date: Wed, 15 Feb 2023 20:31:46 +0000
>> Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>>  larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>>  emacs-devel@gnu.org
>> From: Alan Mackenzie <acm@muc.de>
>> 
>> But you've got to allow me to have mixed feelings when the project I've
>> put so much into over ~20 years is facing redundancy.
> 
> It isn't facing redundancy, it's nowhere near that.  You don't need to
> worry about that.  I expect a significant proportion of users to wish
> to stay with CC Mode, for several good reasons:
> 
> . the use cases it handles better that c-ts-mode (cpp stuff etc.)
> . the plethora of minor conveniences it offers that c-ts-mode
>   doesn't, at least not yet, such as much more elaborate
>   customizations of indentation and electric behavior
> 
> I'm not even sure yet whether I myself will switch.  I will give the
> c-ts-mode a lot of leeway and credit, but I don't know yet what will
> be the outcome.

+1. It’ll be a long way until c-ts-mode can be comparable to c-mode.

Yuan


^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-15 18:33                         ` Eli Zaretskii
                                             ` (2 preceding siblings ...)
  2023-02-15 21:40                           ` Alan Mackenzie
@ 2023-02-17 13:30                           ` Alan Mackenzie
  2023-02-17 13:37                             ` Po Lu
  2023-02-17 14:58                             ` Eli Zaretskii
  3 siblings, 2 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-17 13:30 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Wed, Feb 15, 2023 at 20:33:49 +0200, Eli Zaretskii wrote:
> > Date: Wed, 15 Feb 2023 17:57:15 +0000
> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >   emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

[ .... ]

> This [severe inconvenience to users who wish to stop using a new
> feature] can happen with any new feature.  There's nothing we can do about
> this, ....

There is; we're competent hackers.

> .... so please just stop worrying about it.

I continue to be unhappy about the state of this change.  If we are going
to insist on users restarting Emacs simply to remove three entries from
auto-mode-alist, we should at least ensure that such restarting will
work.  In the current NEWS, the directions are incomplete and misleading.

I propose the following to correct this; it adds text to what is
currently there rather than replacing it, as you requested a couple of
days ago:


diff --git a/etc/NEWS b/etc/NEWS
index 2d15e39036a..dbe6517e78f 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -3239,10 +3239,13 @@ for which a "built-in" mode would be turned on.  For example:
 
     (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))
 
-If you try these modes and don't like them, you can go back to the
-"built-in" modes by restarting Emacs.  But please tell us why you
-didn't like the tree-sitter based modes, so that we could try
-improving them.
+Loading one of the new modes amends 'auto-mode-alist' such that
+visiting the same type of file in the future will continue to use that
+new mode.  If you try these modes and don't like them, you can go back
+to the "built-in" modes by restarting Emacs, but first, if you use
+desktop-save-mode, make sure no buffers using the new mode will get
+entered into your .desktop file.  But please tell us why you didn't
+like the tree-sitter based modes, so that we can try improving them.
 
 Each major mode based on tree-sitter needs a language grammar library,
 usually named "libtree-sitter-LANG.so" ("libtree-sitter-LANG.dll" on


-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply related	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 13:30                           ` Alan Mackenzie
@ 2023-02-17 13:37                             ` Po Lu
  2023-02-17 13:46                               ` Stefan Monnier
                                                 ` (2 more replies)
  2023-02-17 14:58                             ` Eli Zaretskii
  1 sibling, 3 replies; 246+ messages in thread
From: Po Lu @ 2023-02-17 13:37 UTC (permalink / raw)
  To: Alan Mackenzie
  Cc: Eli Zaretskii, juri, casouri, monnier, larsi, theo, jostein,
	emacs-devel

Alan Mackenzie <acm@muc.de> writes:

> Hello, Eli.
>
> On Wed, Feb 15, 2023 at 20:33:49 +0200, Eli Zaretskii wrote:
>> > Date: Wed, 15 Feb 2023 17:57:15 +0000
>> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>> >   emacs-devel@gnu.org
>> > From: Alan Mackenzie <acm@muc.de>
>
> [ .... ]
>
>> This [severe inconvenience to users who wish to stop using a new
>> feature] can happen with any new feature.  There's nothing we can do about
>> this, ....
>
> There is; we're competent hackers.
>
>> .... so please just stop worrying about it.
>
> I continue to be unhappy about the state of this change.  If we are going
> to insist on users restarting Emacs simply to remove three entries from
> auto-mode-alist, we should at least ensure that such restarting will
> work.  In the current NEWS, the directions are incomplete and misleading.
>
> I propose the following to correct this; it adds text to what is
> currently there rather than replacing it, as you requested a couple of
> days ago:
>
> diff --git a/etc/NEWS b/etc/NEWS
> index 2d15e39036a..dbe6517e78f 100644
> --- a/etc/NEWS
> +++ b/etc/NEWS
> @@ -3239,10 +3239,13 @@ for which a "built-in" mode would be turned on.  For example:
>  
>      (add-to-list 'major-mode-remap-alist '(ruby-mode . ruby-ts-mode))
>  
> -If you try these modes and don't like them, you can go back to the
> -"built-in" modes by restarting Emacs.  But please tell us why you
> -didn't like the tree-sitter based modes, so that we could try
> -improving them.
> +Loading one of the new modes amends 'auto-mode-alist' such that
> +visiting the same type of file in the future will continue to use that
> +new mode.  If you try these modes and don't like them, you can go back
> +to the "built-in" modes by restarting Emacs, but first, if you use
> +desktop-save-mode, make sure no buffers using the new mode will get
> +entered into your .desktop file.  But please tell us why you didn't
> +like the tree-sitter based modes, so that we can try improving them.
>  
>  Each major mode based on tree-sitter needs a language grammar library,
>  usually named "libtree-sitter-LANG.so" ("libtree-sitter-LANG.dll" on

Let me ask what I asked earlier, again?
Does c-ts-mode make itself default upon being loaded, or does it make
itself the default upon being first enabled?

The former has been a Bad Thing for as long as I can remember.
The latter is not particularly problematic as long as we document the
caveat.

Thanks.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 13:37                             ` Po Lu
@ 2023-02-17 13:46                               ` Stefan Monnier
  2023-02-17 14:16                                 ` Po Lu
  2023-02-17 13:54                               ` Alan Mackenzie
       [not found]                               ` <d4c1a7f6-b5bf-f4f3-8d79-1c6b1d07cf70@yandex.ru>
  2 siblings, 1 reply; 246+ messages in thread
From: Stefan Monnier @ 2023-02-17 13:46 UTC (permalink / raw)
  To: Po Lu
  Cc: Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi, theo,
	jostein, emacs-devel

> Does c-ts-mode make itself default upon being loaded, or does it make
> itself the default upon being first enabled?

Upon being loaded.

> The former has been a Bad Thing for as long as I can remember.

Yup.

> The latter is not particularly problematic as long as we document
> the caveat.

I can live with that one, yes.


        Stefan




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 13:37                             ` Po Lu
  2023-02-17 13:46                               ` Stefan Monnier
@ 2023-02-17 13:54                               ` Alan Mackenzie
       [not found]                               ` <d4c1a7f6-b5bf-f4f3-8d79-1c6b1d07cf70@yandex.ru>
  2 siblings, 0 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-17 13:54 UTC (permalink / raw)
  To: Po Lu
  Cc: Eli Zaretskii, juri, casouri, monnier, larsi, theo, jostein,
	emacs-devel

Hello, Po.

On Fri, Feb 17, 2023 at 21:37:59 +0800, Po Lu wrote:
> Alan Mackenzie <acm@muc.de> writes:

> > On Wed, Feb 15, 2023 at 20:33:49 +0200, Eli Zaretskii wrote:
> >> > Date: Wed, 15 Feb 2023 17:57:15 +0000
> >> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >> >   emacs-devel@gnu.org
> >> > From: Alan Mackenzie <acm@muc.de>

[ .... ]

> Let me ask what I asked earlier, again?
> Does c-ts-mode make itself default upon being loaded, or does it make
> itself the default upon being first enabled?

It makes itself default upon loading, even if that loading is only in
response to C-h C-f c-ts-mode.

> The former has been a Bad Thing for as long as I can remember.

Indeed.

> The latter is not particularly problematic as long as we document the
> caveat.

I don't quite agree.  An Emacs user should retain full control over her
Emacs session.  Silently changing the entries in auto-mode-alist removes
that control and causes confusion.

> Thanks.

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 13:46                               ` Stefan Monnier
@ 2023-02-17 14:16                                 ` Po Lu
  2023-02-17 14:40                                   ` Eli Zaretskii
  0 siblings, 1 reply; 246+ messages in thread
From: Po Lu @ 2023-02-17 14:16 UTC (permalink / raw)
  To: Stefan Monnier
  Cc: Alan Mackenzie, Eli Zaretskii, juri, casouri, larsi, theo,
	jostein, emacs-devel

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> Does c-ts-mode make itself default upon being loaded, or does it make
>> itself the default upon being first enabled?
>
> Upon being loaded.

That is extremely nasty, especially for people who preload all (or most)
Lisp libraries.

c-ts-mode should be fixed before the pretest starts.  It is not some
small triviality that can be dismissed.

Alan Mackenzie <acm@muc.de> writes:

>> Let me ask what I asked earlier, again?
>> Does c-ts-mode make itself default upon being loaded, or does it make
>> itself the default upon being first enabled?
>
> It makes itself default upon loading, even if that loading is only in
> response to C-h C-f c-ts-mode.
>
>> The former has been a Bad Thing for as long as I can remember.
>
> Indeed.

This means that if we release Emacs 29 as-is, the resulting Emacs will
be broken.

There is NO REASON asking Emacs to describe something should result in
changes to auto-mode-alist.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
       [not found]                               ` <d4c1a7f6-b5bf-f4f3-8d79-1c6b1d07cf70@yandex.ru>
@ 2023-02-17 14:22                                 ` Po Lu
  0 siblings, 0 replies; 246+ messages in thread
From: Po Lu @ 2023-02-17 14:22 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: emacs-devel

(I copied the list back in since this is quite relevant to the thread.)

Dmitry Gutov <dgutov@yandex.ru> writes:

> I understand there is an issue of a possible language barrier, but
> isn't that something you could have found out in ten seconds by trying
> it out? (require 'c-ts-mode) alters auto-mode-alist.

But then it could've been a bug, not intentional behavior.

> And about a month ago you called this "a very reasonable arrangement":
>
> https://lists.gnu.org/archive/html/emacs-devel/2023-01/msg00267.html
>
> Here's a couple of quotes from the message you responded to:
>
>> The proposed change to the current emacs-29 branch is below.  You will
>> see that where possible, just loading a TS mode modifies
>> auto-mode-alist if the tree-sitter support for that mode is available,
>> whereas for other modes auto-mode-alist is modified only when the mode
>> is actually turned on successfully for the first time.
>
> ...
>
>> Modes that have
>> their own *.el files can be just 'require'd in the init file to modify
>> auto-mode-alist.

At that time I thought in both paragraphs the `require' and ``loading''
parts referred to enabling the major mode itself, since there is no
other reasonable behavior.

I didn't even bother to ask about what I thought was a typo, since I
wasn't expecting anyone to come up with any other behavior.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:16                                 ` Po Lu
@ 2023-02-17 14:40                                   ` Eli Zaretskii
  2023-02-17 14:56                                     ` Dmitry Gutov
  2023-02-17 15:15                                     ` Gregory Heytings
  0 siblings, 2 replies; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-17 14:40 UTC (permalink / raw)
  To: Po Lu; +Cc: monnier, acm, juri, casouri, larsi, theo, jostein, emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Cc: Alan Mackenzie <acm@muc.de>,  Eli Zaretskii <eliz@gnu.org>,
>   juri@linkov.net,  casouri@gmail.com,  larsi@gnus.org,  theo@thornhill.no,
>   jostein@secure.kjonigsen.net,  emacs-devel@gnu.org
> Date: Fri, 17 Feb 2023 22:16:07 +0800
> 
> Stefan Monnier <monnier@iro.umontreal.ca> writes:
> 
> >> Does c-ts-mode make itself default upon being loaded, or does it make
> >> itself the default upon being first enabled?
> >
> > Upon being loaded.
> 
> That is extremely nasty, especially for people who preload all (or most)
> Lisp libraries.
> 
> c-ts-mode should be fixed before the pretest starts.

It won't be.

Please, everybody, stop pushing for these changes.  I understand that
you disagree, but I respectfully request that you-all assume that
either I'm right here (in that I consider the alternatives to be
worse), or if I'm wrong, it is for me to make this mistake and learn
from it.  Please give me some minimal credit that I have thought long
and hard about the possible alternatives, and didn't arrive at this
conclusion easily, and that I'm also fully aware that changing the
behavior by loading a package is not good, in and of itself.

TIA



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:40                                   ` Eli Zaretskii
@ 2023-02-17 14:56                                     ` Dmitry Gutov
  2023-02-17 15:04                                       ` Eli Zaretskii
  2023-02-17 16:04                                       ` Make all tree-sitter modes optional Stefan Kangas
  2023-02-17 15:15                                     ` Gregory Heytings
  1 sibling, 2 replies; 246+ messages in thread
From: Dmitry Gutov @ 2023-02-17 14:56 UTC (permalink / raw)
  To: Eli Zaretskii, Po Lu
  Cc: monnier, acm, juri, casouri, larsi, theo, jostein, emacs-devel

On 17/02/2023 16:40, Eli Zaretskii wrote:
> I understand that
> you disagree, but I respectfully request that you-all assume that
> either I'm right here (in that I consider the alternatives to be
> worse), or if I'm wrong, it is for me to make this mistake and learn
> from it.  Please give me some minimal credit that I have thought long
> and hard about the possible alternatives, and didn't arrive at this
> conclusion easily, and that I'm also fully aware that changing the
> behavior by loading a package is not good, in and of itself.

I suppose there is not much to add here, and the mistake (if it is one, 
respectfully) is yours to make.

I just don't understand what's your plan here regarding Emacs 29. What's 
going to happen next? What kind of feedback will you be looking for?

What I think will happen, is people will try out the new modes, some 
will suffer the inconveniences we warned about here and possibly think 
less of Emacs as a result; others will avoid those problems by accident; 
yet a lot more users will never try these new modes and thus avoid the 
problems as well.

If we're lucky, we get a couple of new bug reports associated with it, 
maybe 1-6 months after the release: a lot of users don't report 
problems, much less these less obvious ones, where the behavior doesn't 
end up in a "error" written somewhere. The reports will likely repeat 
some of what's already been said.

At what point does this turn into some kind of conclusion, and a 
teaching moment, so to speak?



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 13:30                           ` Alan Mackenzie
  2023-02-17 13:37                             ` Po Lu
@ 2023-02-17 14:58                             ` Eli Zaretskii
  2023-02-17 15:18                               ` Alan Mackenzie
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-17 14:58 UTC (permalink / raw)
  To: Alan Mackenzie; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

> Date: Fri, 17 Feb 2023 13:30:58 +0000
> Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
>   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>   emacs-devel@gnu.org
> From: Alan Mackenzie <acm@muc.de>
> 
> I continue to be unhappy about the state of this change.  If we are going
> to insist on users restarting Emacs simply to remove three entries from
> auto-mode-alist, we should at least ensure that such restarting will
> work.  In the current NEWS, the directions are incomplete and misleading.
> 
> I propose the following to correct this; it adds text to what is
> currently there rather than replacing it, as you requested a couple of
> days ago:

Thanks, I used a slightly different text to that effect.



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:56                                     ` Dmitry Gutov
@ 2023-02-17 15:04                                       ` Eli Zaretskii
       [not found]                                         ` <8735741fic.fsf@dick>
  2023-02-17 16:04                                       ` Make all tree-sitter modes optional Stefan Kangas
  1 sibling, 1 reply; 246+ messages in thread
From: Eli Zaretskii @ 2023-02-17 15:04 UTC (permalink / raw)
  To: Dmitry Gutov
  Cc: luangruo, monnier, acm, juri, casouri, larsi, theo, jostein,
	emacs-devel

> Date: Fri, 17 Feb 2023 16:56:51 +0200
> Cc: monnier@iro.umontreal.ca, acm@muc.de, juri@linkov.net, casouri@gmail.com,
>  larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
>  emacs-devel@gnu.org
> From: Dmitry Gutov <dgutov@yandex.ru>
> 
> I just don't understand what's your plan here regarding Emacs 29. What's 
> going to happen next? What kind of feedback will you be looking for?

Whatever feedback we will get.  I don't know what we will hear, and
I'm not sure why I should try guessing.

> What I think will happen, is people will try out the new modes, some 
> will suffer the inconveniences we warned about here and possibly think 
> less of Emacs as a result; others will avoid those problems by accident; 
> yet a lot more users will never try these new modes and thus avoid the 
> problems as well.
> 
> If we're lucky, we get a couple of new bug reports associated with it, 
> maybe 1-6 months after the release: a lot of users don't report 
> problems, much less these less obvious ones, where the behavior doesn't 
> end up in a "error" written somewhere. The reports will likely repeat 
> some of what's already been said.

Something like that, yes.  Except that the 6-month figurer could be
better (or worse), and some of the reports might actually tell us
something that wasn't yet said or proposed.

> At what point does this turn into some kind of conclusion, and a 
> teaching moment, so to speak?

It depends on what we hear.  It is quite possible that a single report
will show the light.  Or a significant number of reports expressing a
particular opinion will change the weight of that opinion.  Or
something else.  (Or I step down, or am overrun by a bus.)



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:40                                   ` Eli Zaretskii
  2023-02-17 14:56                                     ` Dmitry Gutov
@ 2023-02-17 15:15                                     ` Gregory Heytings
  1 sibling, 0 replies; 246+ messages in thread
From: Gregory Heytings @ 2023-02-17 15:15 UTC (permalink / raw)
  To: Eli Zaretskii
  Cc: Po Lu, monnier, acm, juri, casouri, larsi, theo, jostein,
	emacs-devel


May I suggest the following: enclose the

(if (treesit-ready-p ...)
     (add-to-list 'auto-mode-alist ...))

statements in a conditional, say (when treesit-add-to-auto-mode-alist 
...), where treesit-add-to-auto-mode-alist would be a defcustom defaulting 
to t?

This would make it possible for users who don't want that behavior to turn 
it off, and would make everyone happy (I hope).




^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:58                             ` Eli Zaretskii
@ 2023-02-17 15:18                               ` Alan Mackenzie
  0 siblings, 0 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-17 15:18 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: juri, casouri, monnier, larsi, theo, jostein, emacs-devel

Hello, Eli.

On Fri, Feb 17, 2023 at 16:58:42 +0200, Eli Zaretskii wrote:
> > Date: Fri, 17 Feb 2023 13:30:58 +0000
> > Cc: juri@linkov.net, casouri@gmail.com, monnier@iro.umontreal.ca,
> >   larsi@gnus.org, theo@thornhill.no, jostein@secure.kjonigsen.net,
> >   emacs-devel@gnu.org
> > From: Alan Mackenzie <acm@muc.de>

> > I continue to be unhappy about the state of this change.  If we are going
> > to insist on users restarting Emacs simply to remove three entries from
> > auto-mode-alist, we should at least ensure that such restarting will
> > work.  In the current NEWS, the directions are incomplete and misleading.

> > I propose the following to correct this; it adds text to what is
> > currently there rather than replacing it, as you requested a couple of
> > days ago:

> Thanks, I used a slightly different text to that effect.

Thanks!

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re:
       [not found]                                         ` <8735741fic.fsf@dick>
@ 2023-02-17 15:41                                           ` Alan Mackenzie
  0 siblings, 0 replies; 246+ messages in thread
From: Alan Mackenzie @ 2023-02-17 15:41 UTC (permalink / raw)
  To: dick
  Cc: Eli Zaretskii, Dmitry Gutov, luangruo, monnier, juri, casouri,
	larsi, theo, jostein, emacs-devel

Hello, Dick.

On Fri, Feb 17, 2023 at 10:24:43 -0500, dick wrote:
> EZ> Or I step down

> This wouldn't be the first time you've threatened that when you were on
> the wrong side of history.  Examples include bzr-to-git and pdumper.

> Perhaps now is the time to make good.  I know at least one person
> who'd like to take the reins.

Please refrain from making such unhelpful, and unnecessarily personl
insinuations.  They go against the respectful tenor which prevails on
this mailing list and, I think, are unwanted by everybody here.

Thanks.

-- 
Alan Mackenzie (Nuremberg, Germany).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 14:56                                     ` Dmitry Gutov
  2023-02-17 15:04                                       ` Eli Zaretskii
@ 2023-02-17 16:04                                       ` Stefan Kangas
  2023-02-17 17:42                                         ` Morgan Willcock
  1 sibling, 1 reply; 246+ messages in thread
From: Stefan Kangas @ 2023-02-17 16:04 UTC (permalink / raw)
  To: Dmitry Gutov, Eli Zaretskii, Po Lu
  Cc: monnier, acm, juri, casouri, larsi, theo, jostein, emacs-devel

Dmitry Gutov <dgutov@yandex.ru> writes:

> I just don't understand what's your plan here regarding Emacs 29. What's
> going to happen next? What kind of feedback will you be looking for?
>
> What I think will happen, is people will try out the new modes, some
> will suffer the inconveniences we warned about here and possibly think
> less of Emacs as a result;

Changing Emacs' behavior upon loading a file is very bad.  We already
know this (we even put it at the top of our coding conventions), and the
fix is trivial.  So from my point of view, there is no need to wait for
users to tell us about it; we can act on it immediately.

In comparison, I consider changing `auto-mode-alist' upon enabling a
major mode a mere annoyance.  I'll be able to hack my way around it
myself, of course, but I think it will make for a bad user experience.
Especially since it breaks our existing conventions: users are not
trained to know that enabling a mode in one buffer will change
`auto-mode-alist' globally.  It is surprising, to say the least.

Restarting Emacs is not a solution at all.  It breaks my workflow, and I
know that it breaks that of many users (e.g. those that start Emacs as a
daemon when logging in).



^ permalink raw reply	[flat|nested] 246+ messages in thread

* Re: Make all tree-sitter modes optional
  2023-02-17 16:04                                       ` Make all tree-sitter modes optional Stefan Kangas
@ 2023-02-17 17:42                                         ` Morgan Willcock
  0 siblings, 0 replies; 246+ messages in thread
From: Morgan Willcock @ 2023-02-17 17:42 UTC (permalink / raw)
  To: Stefan Kangas
  Cc: Dmitry Gutov, Eli Zaretskii, Po Lu, monnier, acm, juri, casouri,
	larsi, theo, jostein, emacs-devel

Stefan Kangas <stefankangas@gmail.com> writes:

> Dmitry Gutov <dgutov@yandex.ru> writes:
>
>> I just don't understand what's your plan here regarding Emacs 29. What's
>> going to happen next? What kind of feedback will you be looking for?
>>
>> What I think will happen, is people will try out the new modes, some
>> will suffer the inconveniences we warned about here and possibly think
>> less of Emacs as a result;
>
> Changing Emacs' behavior upon loading a file is very bad.  We already
> know this (we even put it at the top of our coding conventions), and the
> fix is trivial.  So from my point of view, there is no need to wait for
> users to tell us about it; we can act on it immediately.
>
> In comparison, I consider changing `auto-mode-alist' upon enabling a
> major mode a mere annoyance.  I'll be able to hack my way around it
> myself, of course, but I think it will make for a bad user experience.
> Especially since it breaks our existing conventions: users are not
> trained to know that enabling a mode in one buffer will change
> `auto-mode-alist' globally.  It is surprising, to say the least.
>
> Restarting Emacs is not a solution at all.  It breaks my workflow, and I
> know that it breaks that of many users (e.g. those that start Emacs as a
> daemon when logging in).

And for someone using EXWM, requiring a restart is asking the user to
logout and then login again.

A slower and more stable path sounds more appealing to me.

Morgan



^ permalink raw reply	[flat|nested] 246+ messages in thread

end of thread, other threads:[~2023-02-17 17:42 UTC | newest]

Thread overview: 246+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-01-04 14:48 bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Eric Gillespie
2023-01-04 18:36 ` Eli Zaretskii
2023-01-04 19:40   ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-04 20:03     ` Eli Zaretskii
2023-01-05  0:43       ` Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-05  6:51       ` Eli Zaretskii
2023-01-05  7:06         ` Ihor Radchenko
2023-01-05  7:44           ` Eli Zaretskii
2023-01-05  8:00             ` Ihor Radchenko
2023-01-05  8:26               ` Eli Zaretskii
2023-01-05  8:40                 ` Ihor Radchenko
2023-01-05  8:42                   ` Ihor Radchenko
2023-01-05  8:54                     ` Eli Zaretskii
2023-01-05  8:52                   ` Eli Zaretskii
2023-01-05  9:05                     ` Ihor Radchenko
2023-01-05  7:57         ` Jostein Kjønigsen
2023-01-05  8:12           ` Eli Zaretskii
2023-01-05  8:32             ` Jostein Kjønigsen
2023-01-05  8:44         ` Gregory Heytings
2023-01-05  8:48           ` Gregory Heytings
2023-01-05  9:00             ` Eli Zaretskii
2023-01-05  8:56           ` Eli Zaretskii
2023-01-05 13:17         ` Dmitry Gutov
2023-01-05 14:02         ` Theodor Thornhill via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-01-15 14:01         ` Make all tree-sitter modes optional Eli Zaretskii
2023-01-15 23:39           ` Dmitry Gutov
2023-01-16  7:43             ` Theodor Thornhill
2023-01-16 16:30               ` Dmitry Gutov
2023-01-16 12:34             ` Eli Zaretskii
2023-01-16 13:06               ` Dmitry Gutov
2023-01-16 14:20                 ` Eli Zaretskii
2023-01-16 14:50                   ` Dmitry Gutov
2023-01-16 14:59                     ` Eli Zaretskii
2023-01-17 12:59                       ` Dmitry Gutov
2023-01-17 13:47                         ` Eli Zaretskii
2023-01-17 14:32                           ` Dmitry Gutov
2023-01-17 14:52                             ` Eli Zaretskii
2023-01-17 15:22                               ` Dmitry Gutov
2023-01-17 17:02                                 ` Eli Zaretskii
2023-01-17 17:10                                   ` Dmitry Gutov
2023-01-17 17:38                                     ` Eli Zaretskii
2023-01-17 17:59                                       ` Dmitry Gutov
2023-01-17 18:04                                         ` Eli Zaretskii
2023-01-17 18:21                                           ` Dmitry Gutov
2023-01-17 18:40                                             ` Eli Zaretskii
2023-01-17 18:49                                               ` Dmitry Gutov
2023-01-17 19:03                                                 ` Eli Zaretskii
2023-01-17 19:21                                                   ` Dmitry Gutov
2023-01-18  1:11                                                     ` Yuan Fu
2023-01-18  1:23                                                       ` Dmitry Gutov
2023-01-18  3:34                                                         ` Eli Zaretskii
2023-01-18  3:52                                                           ` Dmitry Gutov
2023-01-18 12:06                                                             ` Eli Zaretskii
2023-01-18 14:00                                                               ` Dmitry Gutov
2023-01-18 14:51                                                                 ` Eli Zaretskii
2023-01-18 12:36                                                           ` Stefan Monnier
2023-01-17 17:34                             ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Juri Linkov
2023-01-17 17:40                               ` Theodor Thornhill
2023-01-17 18:17                                 ` treesit-forward-sexp Juri Linkov
2023-01-17 17:50                               ` treesit-forward-sexp (was: Make all tree-sitter modes optional) Dmitry Gutov
2023-01-17 17:59                               ` Eli Zaretskii
2023-01-16  1:12           ` Make all tree-sitter modes optional Po Lu
2023-01-17 17:30           ` Juri Linkov
2023-01-17 17:58             ` Eli Zaretskii
2023-01-17 18:19               ` Juri Linkov
2023-01-17 18:41                 ` Eli Zaretskii
2023-02-14 19:08               ` Alan Mackenzie
2023-02-14 19:29                 ` Eli Zaretskii
2023-02-14 21:02                   ` Alan Mackenzie
2023-02-15 15:35                     ` Eli Zaretskii
2023-02-15 17:57                       ` Alan Mackenzie
2023-02-15 18:33                         ` Eli Zaretskii
2023-02-15 20:31                           ` Alan Mackenzie
2023-02-16  5:41                             ` tomas
2023-02-16  7:27                             ` Eli Zaretskii
2023-02-16 22:05                               ` Yuan Fu
     [not found]                           ` <87v8k2g04m.fsf@dick>
2023-02-15 20:34                             ` Eli Zaretskii
     [not found]                               ` <87mt5eegkw.fsf@dick>
2023-02-16  7:53                                 ` Eli Zaretskii
2023-02-16  8:52                                   ` Po Lu
2023-02-15 21:40                           ` Alan Mackenzie
2023-02-17 13:30                           ` Alan Mackenzie
2023-02-17 13:37                             ` Po Lu
2023-02-17 13:46                               ` Stefan Monnier
2023-02-17 14:16                                 ` Po Lu
2023-02-17 14:40                                   ` Eli Zaretskii
2023-02-17 14:56                                     ` Dmitry Gutov
2023-02-17 15:04                                       ` Eli Zaretskii
     [not found]                                         ` <8735741fic.fsf@dick>
2023-02-17 15:41                                           ` Alan Mackenzie
2023-02-17 16:04                                       ` Make all tree-sitter modes optional Stefan Kangas
2023-02-17 17:42                                         ` Morgan Willcock
2023-02-17 15:15                                     ` Gregory Heytings
2023-02-17 13:54                               ` Alan Mackenzie
     [not found]                               ` <d4c1a7f6-b5bf-f4f3-8d79-1c6b1d07cf70@yandex.ru>
2023-02-17 14:22                                 ` Po Lu
2023-02-17 14:58                             ` Eli Zaretskii
2023-02-17 15:18                               ` Alan Mackenzie
2023-02-15 18:34                         ` Stefan Monnier
2023-02-15 19:01                           ` Dmitry Gutov
2023-02-15 19:26                             ` Stefan Monnier
2023-02-15 19:47                               ` Eli Zaretskii
2023-02-15 19:53                                 ` Stefan Monnier
2023-02-15 20:06                                   ` Eli Zaretskii
2023-02-15 21:04                                     ` Stefan Monnier
2023-02-16  7:42                                       ` Eli Zaretskii
2023-02-16  9:49                                         ` Basil L. Contovounesios
2023-02-16 11:48                                           ` Eli Zaretskii
2023-02-16 14:41                                         ` Stefan Monnier
2023-02-16 15:42                                           ` Eli Zaretskii
2023-02-16 16:45                                             ` Stefan Monnier
2023-02-16 17:05                                               ` Eli Zaretskii
2023-02-16 19:14                                                 ` Dmitry Gutov
2023-02-16 20:07                                                 ` Stefan Monnier
2023-02-16  5:45                                     ` tomas
2023-02-16  8:26                                       ` Eli Zaretskii
2023-02-16 10:30                                         ` Alan Mackenzie
2023-02-16 12:38                                           ` Po Lu
2023-02-16 12:53                                             ` Dmitry Gutov
2023-02-15 20:24                               ` Dmitry Gutov
2023-02-16  7:05                                 ` Eli Zaretskii
2023-02-16  7:53                                   ` Theodor Thornhill
2023-02-16  8:34                                     ` Eli Zaretskii
2023-02-16  8:46                                       ` Theodor Thornhill
2023-02-16 11:58                                       ` Dmitry Gutov
2023-02-16 11:56                                     ` Dmitry Gutov
2023-02-16 14:48                                       ` Theodor Thornhill via Emacs development discussions.
2023-02-16 14:56                                         ` Dmitry Gutov
2023-02-16 15:15                                           ` Theodor Thornhill
2023-02-15 23:48                               ` Lynn Winebarger
2023-02-16  2:56                                 ` Stefan Monnier
2023-02-15 19:07                           ` Eli Zaretskii
2023-02-15 19:27                             ` Stefan Monnier
2023-02-15 21:06                             ` Basil L. Contovounesios
2023-02-16  7:44                               ` Eli Zaretskii
2023-02-15 18:25                 ` Juri Linkov
2023-01-04 19:59   ` bug#60559: 29.0.60; "Cannot activate tree-sitter" spam Stephen Berman
2023-01-04 20:10     ` Eli Zaretskii
2023-01-04 20:33       ` Stephen Berman
2023-01-05  6:41         ` Eli Zaretskii
2023-01-05  7:46           ` Juri Linkov
2023-01-05  7:58             ` Eli Zaretskii
2023-01-05 14:59               ` Eric Gillespie
2023-01-22 13:24                 ` Eli Zaretskii
  -- strict thread matches above, loose matches on Subject: below --
2022-01-20 14:13 Roger Mason
2022-01-20 19:57 ` Immanuel Litzroth
2022-01-20 19:58   ` Re: Roger Mason
2021-12-20  2:29 (unknown) Davin Pearson
2021-12-21 14:29 ` Eli Zaretskii
     [not found]   ` <CAG9ihEvK5VVgP9O+TXYSz+BQF1=YzMgzGBbc5s-fewwT34yytA@mail.gmail.com>
     [not found]     ` <CAG9ihEsdD2Dd=paZatMfnD3HJxKsUM=3etTz7c-tDcs-H80PoA@mail.gmail.com>
     [not found]       ` <CAG9ihEsQFkx+uE+pZ7R42GXUFR_C2PSzVK8M5AQuHdtOsND0cg@mail.gmail.com>
     [not found]         ` <CAG9ihEv_OPaYhTgfh2WnfckC5r21U5Hv0qW7Msnwz4Bbvz6ccg@mail.gmail.com>
2021-12-28 17:51           ` Re: Eli Zaretskii
2021-12-28 23:41             ` Re: Davin Pearson
2021-12-31 15:23               ` Re: Anders Lindgren
2022-01-02  1:15                 ` Re: Davin Pearson
2022-01-02  5:19                   ` Re: Stefan Monnier
2022-01-03  0:53                     ` Re: Davin Pearson
2021-12-02 14:09 Re: Angelo Graziosi
2021-11-04  6:36 Re: Pedro Andres Aranda Gutierrez
2017-10-24 18:52 wait_reading_process_ouput hangs in certain cases (w/ patches) Matthias Dahl
2017-11-14 16:03 ` Eli Zaretskii
2017-11-14 16:23   ` Eli Zaretskii
2017-11-14 21:54     ` Paul Eggert
2017-11-15 14:03       ` Matthias Dahl
2017-11-16 16:46         ` Paul Eggert
2017-11-18 14:24           ` Matthias Dahl
2017-11-19  7:07             ` Paul Eggert
2017-11-20 15:29               ` Matthias Dahl
2017-11-21 14:44                 ` Matthias Dahl
2017-11-22  8:55                   ` Paul Eggert
2017-12-04  9:40                     ` Matthias Dahl
2018-02-13 14:25                       ` Matthias Dahl
2018-02-16 16:01                         ` Eli Zaretskii
2018-02-16 16:09                           ` Lars Ingebrigtsen
2018-02-22 11:45                             ` andres.ramirez
2018-02-26 14:39                               ` Matthias Dahl
2018-02-26 15:11                                 ` andrés ramírez
2018-02-26 15:17                                   ` Lars Ingebrigtsen
2018-02-26 15:29                                     ` andrés ramírez
2018-02-26 16:52                                       ` Daniel Colascione
2018-02-26 17:19                                         ` andrés ramírez
2018-02-26 17:24                                           ` Daniel Colascione
2018-02-27  1:53                                             ` Re: andrés ramírez
2016-02-08  7:54 (unknown) steve
2016-02-08 12:56 ` Artur Malabarba
2016-02-08 19:05   ` Re: Steve Purcell
2016-02-08 20:16     ` Re: Artur Malabarba
     [not found] <CAFkz2yroLhknptDnWyC9B1fbZKEwTCV-T0VttHQiwZoaAW-j6A@mail.gmail.com>
2012-12-20  8:36 ` Re: Константин Куликов
2008-08-06 15:50 Re:  Michaël Parienti
2008-08-06 16:57 ` Re: Paul R
2007-04-04 19:09 (unknown) Jost Burkardt
2007-04-05  0:26 ` Jason F. McBrayer
2005-12-03 23:03 Re: solenoids
2005-09-27 14:03 Re: avtologistic
2005-09-18 14:11 Re: Art
2005-09-10 14:39 Re: Abdulaim
2005-08-29 20:51 Re: Alifgin
2005-08-11 16:17 Re: от Александр
2005-07-06 17:37 Re: Ishok
2005-07-05 23:11 Re: Maxus
2005-06-30 18:50 Alex Claire
2005-06-14 23:56 Вера
2005-06-13 21:36 Re: Карина
2005-06-06 10:27 Re: Нина
2005-05-10 17:54 Re: Mariorisa
2005-05-04 17:05 Re: info
2005-04-21  7:57 Re: webmaster
2005-03-28 15:10 Re: info
2005-03-20  5:29 Re: info
2005-03-08 14:48 (no subject) Gian Uberto Lauri
2005-03-08 21:02 ` Peter Dyballa
2005-03-08 21:14   ` Re: Gian Uberto Lauri
2005-03-08 21:24   ` Re: Gian Uberto Lauri
2005-03-03  8:38 Re: support
2005-03-02  5:19 Re: PEREEZDI
2005-02-17  3:39 Re: root
2005-01-28 21:22 Re: Budget
2005-01-24 15:54 Re: support
2005-01-20  2:22 Re: Евгения Гордеевна
2005-01-12 15:30 Re: Сабина Елизаровна
2005-01-11 13:47 Re: Info
2005-01-06 13:53 Re: Документ
2005-01-06 12:16 Re: Документ
2004-12-21 16:08 Re: Алина Соломоновна
2004-12-21 11:12 Re: Маргарита Валериановна
2004-12-15 19:39 Re: Эмма Ульяновна
2004-12-15 17:55 Re: Анжела Геннадиевна
2004-12-12 17:13 Re: Зинаида Аверьяновна
2004-12-10 23:05 Re: Розалия Самойловна
2004-11-29  6:09 Re: Эльвира Викентьевна
2004-11-28 18:11 Re: Ева Давидовна
2004-11-26 21:10 Re: Robbie Womack
2004-11-26 18:31 Re: Joel Bradford
2004-11-11 11:56 Re: Майя Исааковна
2004-11-09  3:13 Re: Регина Валериановна
2004-11-02 19:59 Re: Центр тарифной политики  ОАО "РЖД"
2004-11-02  4:00 Re: Центр тарифной политики  ОАО "РЖД"
2004-10-21 16:59 Re: Евгения Елизаровна
2004-10-21 15:36 Re: Елизавета Аверьяновна
2004-10-10 18:55 Re: John Gard
2004-10-10 18:45 Re: John Gard
2004-09-07  7:12 Re: Ярослав Леонидович
2004-08-08 11:28 Re: lefthand
2004-08-08 10:41 Re: lefthand
2004-08-08  6:42 Re: lefthand
2004-07-29  2:53 Re: info
2004-07-29  2:53 Re: info
2004-07-23 22:19 Re: sugih
2004-07-23 16:17 Re: Murray
2004-07-20 13:58 Re: Vhdl-mode
2004-07-20 13:15 Re: Vhdl-mode
2004-06-26  5:49 Re: Востросаблина Карина
2004-06-13  3:14 Re: Язикова Изабелла
2004-06-11 18:58 Re: Валерий Ланшаков
2004-06-10 22:33 Re: Чагинова Снежана
2004-06-10 15:15 Re: Валерий Ланшаков
2004-06-06 16:08 Re: Щербухина Вероника
2004-06-06  7:43 Re: Валерий Ланшаков
2004-05-31  4:05 Re: Будищева Сабина
2004-05-24  1:55 Re: Резенкова Надежда
2004-05-23  5:34 Re: Горемыкина Оксана
2004-05-22 11:30 Re: Боровистова Эльза
2004-05-16  6:16 Re: Липинская Анна
2004-05-15 21:46 juli
2004-05-15 18:05 RE: juliy
2004-05-15  1:06 Лазлова Виктория
2004-05-12 18:20 Re: Аниськина Мария
2004-05-12 16:50 Re: Сеткова Лора
2004-05-12 16:50 Re: Рютина Ева
2004-05-12  0:59 Re: Манякина Наталья
2004-05-11 23:06 Re: Пыжьева Эмилия
2004-04-21 11:56 Re: Роман
2004-03-11 11:22 Re: Romia Fersi
2002-10-18 18:30 Re: Josep Maria
2002-06-10 22:22 Re: Emiliano La Licata
2002-04-10 11:41 ¿¬Áö
2002-04-04 22:49 Re:Àú ¿¹¿ä Áö¿µ
2002-04-01  7:39 re:¿äûÇϽŠÀÚ·áÀÔ´Ï´Ù °í°´Áö¿øÆÀ

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.