Get promoted types for foreign variadic function

XMLWordPrintable

    • Type: Bug
    • Resolution: Won't Fix
    • Priority: P3
    • 22
    • Affects Version/s: 21
    • Component/s: core-libs
    • None

      java.lang.foreign.Linker documentation mentions about the need for using the promoted types in FunctionDescriptor for a downcall to foreign variadic function. Since the set of promoted types are platform specific, it's impossible to write portable code without an essential API.
      Essential API is of the form:
      Class/MemoryLayout[] getSupportedVariadicTypes(); (Linker class)

      Linker.nativeLinker().getSupportedVariadicTypes() can be used to create an acceptable FunctionDescriptor

            Assignee:
            Jorn Vernee
            Reporter:
            Prashanthram Gundarlahally
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: