public inbox for kawa@sourceware.org
 help / color / mirror / Atom feed
From: Ross Merrifield <rosswmerrifield@gmail.com>
To: Per Bothner <per@bothner.com>
Cc: kawa@sourceware.org
Subject: Re: Having trouble using JAX-RS annotation in Kawa Scheme class
Date: Tue, 28 Feb 2023 11:42:36 -0800	[thread overview]
Message-ID: <CAO1-sXjLbCmtvZAoRNTjDpqJ61f75Av0G4fY8f-Kw8UNzYEERA@mail.gmail.com> (raw)
In-Reply-To: <48704d5d-d836-4276-c115-8cd0d7af5f8c@bothner.com>

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

Per,

The (@Produces (string[] "text/plain")) syntax is working as expected now!
Unfortunately, the more elegant ["text/plain"] syntax still results in the
'annotation must be constant' error, but I can live with the more verbose
version.

Thanks,

Ross

On Tue, Feb 28, 2023 at 11:27 AM Per Bothner <per@bothner.com> wrote:

> On 2/28/23 09:01, Ross Merrifield via Kawa wrote:
> > But when I change my Annotation to (@Produces (String[] "text/plain")) I
> > get the error "annotation value must be constant". Checking the javadoc
> for
> > @prodcues does indicate the expected type of the value is String[]:
>
> I would try one or both of:
>
> (@Produces ["text/plain"]) ; Most elegant
> (@Produces (string[] "text/plain")) ; matches a test in
> testsuite/annotations1.scm
>
> There is a subtle difference between:
>     string[]
>     String[]
>     java.lang.String[]
> -which I can't remember off-hand and don't feel like looking up.
> --
>         --Per Bothner
> per@bothner.com   http://per.bothner.com/
>

      reply	other threads:[~2023-02-28 19:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-28 17:01 Ross Merrifield
2023-02-28 17:37 ` Arvydas Silanskas
2023-02-28 19:03   ` Ross Merrifield
2023-02-28 19:26 ` Per Bothner
2023-02-28 19:42   ` Ross Merrifield [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAO1-sXjLbCmtvZAoRNTjDpqJ61f75Av0G4fY8f-Kw8UNzYEERA@mail.gmail.com \
    --to=rosswmerrifield@gmail.com \
    --cc=kawa@sourceware.org \
    --cc=per@bothner.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).