bugnyacc parser generator - Bugs: bug #59307, functions accepting structs

 
 

bug #59307: functions accepting structs

Submitter:  None
Submitted:  Mon 19 Oct 2020 05:36:18 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  mwette
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Tue 20 Oct 2020 01:34:52 PM UTC, comment #2: 

Fixed in v1.03.1, released Oct 20, 2020

Matt Wette <mwette>
Group administrator
Tue 20 Oct 2020 12:51:23 PM UTC, comment #1: 

verified bug in 1.03.
I am working on a solution.

Matt Wette <mwette>
Group administrator
Mon 19 Oct 2020 05:36:18 PM UTC, original submission:  

Example:

struct foo
{
        int bar;
        int baz;
};

void qaz(struct foo zaq);


Attempting to process the code above with compile-ffi causes it to crash with the following error:

mdecl->fh-unwrapper missed:
  ("zaq" (struct-ref (ident "foo")))
Backtrace:
In ice-9/boot-9.scm:
    829:9 19 (catch _ _ #<procedure 7f9093dfc520 at scripts/compile…> …)
In scripts/compile-ffi.scm:
    233:8 18 (_)
In nyacc/lang/c99/ffi-help.scm:
   2177:4 17 (compile-ffi-file _ _)
In ice-9/ports.scm:
   445:17 16 (call-with-input-file _ _ #:binary _ #:encoding _ # _)
In system/base/compile.scm:
     43:4 15 (call-once _)
In ice-9/boot-9.scm:
    841:4 14 (with-throw-handler _ _ _)
In system/base/compile.scm:
    59:11 13 (_)
In nyacc/lang/c99/ffi-help.scm:
  2193:20 12 (_ #<closed: file 7f9093dffd90>)
In unknown file:
          11 (eval (define-ffi-module (test) #:include (quote (#))) #)
In nyacc/lang/c99/ffi-help.scm:
  1944:10 10 (expand-ffi-module-spec (test) ((include "test.h")))
In sxml/fold.scm:
    89:21  9 (fold-values #<procedure 7f9093e101e0 at nyacc/lang/…> . #)
In ice-9/boot-9.scm:
    829:9  8 (catch ffi-help-error #<procedure 7f9095622ec0 at nyac…> …)
In nyacc/lang/c99/ffi-help.scm:
   1159:4  7 (cnvt-udecl _ _ ((struct . "foo")) ((struct . "foo") # …))
  1046:22  6 (cnvt-fctn "qaz" _ ((param-decl (decl-spec-list (…)) #)))
    863:5  5 (gen-exec-params ((param-decl (decl-spec-list (# …)) #)))
In srfi/srfi-1.scm:
   466:18  4 (fold #<procedure 7f909559fd80 at nyacc/lang/c99/ffi-h…> …)
In nyacc/lang/c99/ffi-help.scm:
   874:31  3 (_ _ ())
    948:7  2 (mdecl->fh-unwrapper _)
In unknown file:
           1 (scm-error misc-error #f "~A" ("MDECL-FH-UNWRAPPER") #f)
In ice-9/boot-9.scm:
   752:25  0 (dispatch-exception _ _ _)

ice-9/boot-9.scm:752:25: In procedure dispatch-exception:
MDECL-FH-UNWRAPPER


Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by mwette (Posted a comment)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-10-20 mwette StatusIn Progress Fixed
        Open/ClosedOpen Closed
    2020-10-20 mwette StatusNone In Progress
        Assigned toNone mwette

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code