Ticket Change Details
Overview

Artifact ID: 821293e0caad48f5726245383f21e53498669d8e
Ticket: 2b566b4c81d33f2ec0cfa228966b5804d83c1a0c
[tcc4tcl::cproc] errors when given more than one argl argument
User & Date: anonymous on 2014-06-13 16:02:46
Changes

  1. foundin changed to: "0.17"
  2. icomment:
    Attempting to create a [tcc4tcl::cproc] with an argl greater than one errors with "invalid type".
    
    % tcc4tcl::cproc add {int a, int b} int {return a+b;}
    <string>:4: error: invalid type
    compilation failed
    
    The full error message:
    
    <string>:4: error: invalid type
    compilation failed
        while executing
    "$tcc(cc) compile $code"
        (procedure "::tcc4tcl::cc" line 8)
        invoked from within
    "::tcc4tcl::cc {
    #include <tcl.h>
    static int
    c_add(int a,, int b) {
    return a+b;}
    
    
    int Cmd_N4__add (ClientData dummy,Tcl_Interp *ip,int objc,Tcl_Obj *C..."
        ("uplevel" body line 1)
        invoked from within
    "uplevel 1 [list ${ns}::cc $code]"
        (procedure "::tcc4tcl::ccommand" line 40)
        invoked from within
    "::tcc4tcl::ccommand add {dummy ip objc objv} {  int _a,;
      int _b;
      int rv;
      if (objc != 3) {
        Tcl_WrongNumArgs(ip, 1, objv, "a, b");
        return ..."
        ("uplevel" body line 1)
        invoked from within
    "uplevel 1 [list ${ns}::ccommand $name {dummy ip objc objv} $cbody]"
        (procedure "tcc4tcl::cproc" line 5)
        invoked from within
    "tcc4tcl::cproc add {int a, int b} int {return a+b;}"
        (file "tcc.tcl" line 3)
    
    Maybe something to do with c_add having more than one ',' between each argument? 
    
    c_add(int a,, int b) {return a+b;}
    
  3. login: "anonymous"
  4. mimetype: "text/x-fossil-plain"
  5. severity changed to: "Critical"
  6. status changed to: "Open"
  7. title changed to:
    [tcc4tcl::cproc] errors when given more than one argl argument
    
  8. type changed to: "Code_Defect"