all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#66777: program-file silently corrupts expressions with non-ascii characters
@ 2023-10-27 18:56 Tomas Volf
  0 siblings, 0 replies; only message in thread
From: Tomas Volf @ 2023-10-27 18:56 UTC (permalink / raw)
  To: 66777

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

Hello,

when trying to create an executable script using `program-file', I realized it
silently corrupts expressions with non-ascii characters.  Minimal reproduction I
did put together is:

    scheme@(guix-user)> ,use (guix)
    scheme@(guix-user)> ,build (program-file "foo" '(λ))
    $1 = "/gnu/store/im07w0ilskfycpkwid3n7s80hdv263cn-foo"
    scheme@(guix-user)> (call-with-input-file $1 read)
    ;;; <stdin>:3:22: warning: possibly unbound variable `$1'
    $2 = (?)

Notice that $2 is (?) instead of the expected (λ).  If there is a technical
reason why this cannot be handled correctly, it would be great if it at least
failed with an error instead of a silent corruption.

Have a nice day,
Tomas Volf

-- 
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-10-27 18:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-27 18:56 bug#66777: program-file silently corrupts expressions with non-ascii characters Tomas Volf

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.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.