Re: [R-pkg-devel] Invalid UTF-8

2022-10-18 Thread Göran Broström




On 2022-10-18 21:53, peter dalgaard wrote:




On 18 Oct 2022, at 16:37 , Dirk Eddelbuettel 
wrote:


On 17 October 2022 at 13:20, Göran Broström wrote:

| G;ran (US keyboard)

:)

A fortunes candidate?



Incidentally, he's Gæran on a DK keyboard but Gøran on an NO one. The
three Scandinavian languages have the same three extra letters (æøå),
but Swedish writes the former two with diaeresis (like German),
reverses their order in the alphabet (åöä), 


Actually, the order is åäö (Swedish). Didn't know about the different
Scandinavian alphabetical orderings, thanks for the info!

g,


and switches ö and ä on
the keyboard (compared to Danish, that is). Norwegian writes and
sorts like Danish, but has the same key reversion as Swedish.
"Brotherly love"...

-pd



__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] Invalid UTF-8

2022-10-18 Thread peter dalgaard



> On 18 Oct 2022, at 16:37 , Dirk Eddelbuettel  wrote:
> 
> 
> On 17 October 2022 at 13:20, Göran Broström wrote:
> 
> | G;ran (US keyboard)
> 
> :)
> 
> A fortunes candidate?
> 

Incidentally, he's Gæran on a DK keyboard but Gøran on an NO one. The three 
Scandinavian languages have the same three extra letters (æøå), but Swedish 
writes the former two with diaeresis (like German), reverses their order in the 
alphabet (åöä), and switches ö and ä on the keyboard (compared to Danish, that 
is). Norwegian writes and sorts like Danish, but has the same key reversion as 
Swedish. "Brotherly love"...

-pd

-- 
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Office: A 4.23
Email: pd@cbs.dk  Priv: pda...@gmail.com

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] Invalid UTF-8

2022-10-18 Thread Dirk Eddelbuettel


On 17 October 2022 at 13:20, Göran Broström wrote:
| Thanks Ivan,
| 
| I found two simple ways to convert this old file to UTF-8:
| 
| (i) In emacs, C-x  f  (default is utf-8)

That's a good ti[. I had actually hand-edited two lines down to 'seven bits'
instead of this.  Umlaute, accents and special characters for the win! Thanks
Ivan and Göran.

Also, reproducing this warning required both clang(++)-15 and an explicit
setting of -Winvalid-utf8.

| (ii) In RStudio, set Tools-Global Options-Code-Saving-
| Default text encoding  to UTF-8
| 
| No problem with new files.
| 
| G;ran (US keyboard)

:)

A fortunes candidate?

Dirk

-- 
dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] Invalid UTF-8

2022-10-17 Thread Göran Broström

Thanks Ivan,

I found two simple ways to convert this old file to UTF-8:

(i) In emacs, C-x  f  (default is utf-8)

(ii) In RStudio, set Tools-Global Options-Code-Saving-
Default text encoding  to UTF-8

No problem with new files.

G;ran (US keyboard)

Den 2022-10-17 kl. 11:18, skrev Ivan Krylov:

В Mon, 17 Oct 2022 11:07:25 +0200
Göran Broström  пишет:


warning: invalid UTF-8 in comment [-Winvalid-utf8]
(It's my name)

So I wonder: How do I make valid UTF-8 in comment?


The file GB_zeroin.c is saved in Latin-1 encoding. The warning should
go away once you convert it to UTF-8.



__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] Invalid UTF-8

2022-10-17 Thread Ivan Krylov
В Mon, 17 Oct 2022 11:07:25 +0200
Göran Broström  пишет:

> warning: invalid UTF-8 in comment [-Winvalid-utf8]
> (It's my name)
> 
> So I wonder: How do I make valid UTF-8 in comment?

The file GB_zeroin.c is saved in Latin-1 encoding. The warning should
go away once you convert it to UTF-8.

-- 
Best regards,
Ivan

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


[R-pkg-devel] Invalid UTF-8

2022-10-17 Thread Göran Broström

Hello,

I suddenly get Warnings from  CRAN (clang):

warning: invalid UTF-8 in comment [-Winvalid-utf8]
(It's my name)

So I wonder: How do I make valid UTF-8 in comment?
(I already have "Encoding: UTF-8" in the DESCRIPTION file)

Thanks, Göran

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel