public inbox for kawa@sourceware.org
 help / color / mirror / Atom feed
* "void-valued expression where value is needed"
@ 2022-09-20 21:02 Panicz Maciej Godek
  2022-09-20 21:41 ` Arvydas Silanskas
  0 siblings, 1 reply; 2+ messages in thread
From: Panicz Maciej Godek @ 2022-09-20 21:02 UTC (permalink / raw)
  To: kawa

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

Suppose that I have some code like

(define (f)::void
  (call-with-values
      (λ () #!void)
    (λ result
      (apply values result))))

When I compile it, Kawa issues the warning:

void-valued expression where value is needed

I wonder whether this warning is desired in such circumstances?

(It surely makes it difficult to write values-agnostic macros)

What is interesting is that the warning disappears if I replace #!void with
(values) [unless I declare the function's return type as ::void].

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

end of thread, other threads:[~2022-09-20 21:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-20 21:02 "void-valued expression where value is needed" Panicz Maciej Godek
2022-09-20 21:41 ` Arvydas Silanskas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).