Does this work? It uses a helper function, `prune`, to parse the var-val
clauses.
#lang racket
(define-for-syntax (prune stx)
(syntax-case stx ()
[()
#'()]
[((var val) others ...)
(cons #'(var val)
(prune #'(others ...)))]
[(var others ...)
(cons #'(var #f)
(prune #'(others ...)))]))
(define-syntax (aux stx)
(syntax-case stx ()
[(_ terms ...)
(with-syntax ([((var val) ...) (prune #'(terms ...))])
#'(define-values (var ...) (values val ...)))]))
(aux a (b (* 2 pi)) c (d pi))
a
b
c
d
;; output shown below
#f
6.283185307179586
#f
3.141592653589793