Changeset 3424


Ignore:
Timestamp:
Feb 23, 2008, 11:44:18 PM (13 years ago)
Author:
yura
Message:
  • First very alpha version of debugger.
  • CallListGenerator? collects line numbers of calls. It is used to generate LINENUMBER instruction in jbc back-end.
Location:
to-imperative/trunk/compiler
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • to-imperative/trunk/compiler/rfp_asail_jbc.rf

    r3421 r3424  
    7373$func CW = s;
    7474CW, <Get &CWbox> : s.cv = s.cv;
     75
     76$box MethodCallList;
    7577
    7678RFP_ASAIL_To_JBC (MODULE (e.moduleName) e.module) =
     
    304306    t.qname : (e s.name),
    305307    <Check_Name s.name>,
     308    {
     309      <Get &CallList> : e (s.name e.methodCallList) e,
     310        <Store &MethodCallList e.methodCallList>;
     311      <Store &MethodCallList>;
     312    },
    306313    <Add &ACC_STATIC <Access_Mode s.linkage>> :: s.access,
    307314    <Function_Description (e.args) (e.ress) s.retType> :: s.desc,
     
    526533        }, $fail;;
    527534    },
     535    {
     536      <Get &MethodCallList> : s.lineNumber e.tail,
     537        <Store &MethodCallList e.tail>,
     538        <Label> :: s.line,
     539        <MVvisitLabel <MV> s.line>,
     540        <MVvisitLineNumber <MV> s.lineNumber s.line>;
     541      ;
     542    },
    528543    <MVvisitMethodInsn <MV> &INVOKESTATIC <GetJBCQName e.module s.name> s.desc>,
    529544    {
     
    666681            <MVvisitVarInsn <MV> &ALOAD s.i>;
    667682        }, $fail;;
     683    },
     684    {
     685      <Get &MethodCallList> : s.lineNumber e.tail,
     686        <Store &MethodCallList e.tail>,
     687        <Label> :: s.line,
     688        <MVvisitLabel <MV> s.line>,
     689        <MVvisitLineNumber <MV> s.lineNumber s.line>;
     690      ;
    668691    },
    669692    <MVvisitMethodInsn <MV> &INVOKESTATIC <GetJBCQName e.module s.name> s.desc>,
  • to-imperative/trunk/compiler/rfpc.rf

    r3155 r3424  
    104104  };
    105105
     106CompileASToJBC2 s.env t.as (e.callList) =
     107  <Store &CallList e.callList>,
     108  <CompileASToJBC s.env t.as>;
    106109
    107110Main =
  • to-imperative/trunk/compiler/rfpc.rfi

    r2727 r3424  
    1515$func CompileModule s.env = ;
    1616$func CompileASToJBC s.env t.as = ;
     17$func CompileASToJBC2 s.env t.as t.callList = ;
     18
     19$box CallList;
    1720
    1821$func RFP_Pretty_Print s.channel (e.indent) e.expr = ;
Note: See TracChangeset for help on using the changeset viewer.