changeset 68:ef460b936b5f

Merge + remove patch from David
author Louis Opter <louis@lse.epitech.net>
date Sat, 18 Feb 2012 16:04:02 +0100
parents b916396fc577
children 8bb53638585b
files PointcutTyping rathaxes_correctly_use_chunk_and_template_sequences_parameters_in_e1000.patch series
diffstat 3 files changed, 8 insertions(+), 136 deletions(-) [+]
line wrap: on
line diff
--- a/PointcutTyping	Sat Feb 18 15:57:45 2012 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,134 +0,0 @@
-# HG changeset patch
-# Parent 48c3aacc384cde5a9678d51eeacf6e97262296ff
-rathaxe: compiler: Add pointcut typing
-
- * rename rtx_seq_param -> rtx_param and  and rtx_seq_parameter -> rtx_parameter_list
- * Use the renamed parsing rule to parse the argument list of a chunk
-    (factorizing the prototype parsing of a template and a pointcut/chunk)
-
-
-diff --git a/rathaxes/compiler/parse/rtxBack.cwp b/rathaxes/compiler/parse/rtxBack.cwp
---- a/rathaxes/compiler/parse/rtxBack.cwp
-+++ b/rathaxes/compiler/parse/rtxBack.cwp
-@@ -184,25 +184,38 @@
- /**/    => local lastNode;
- /**/    #check(cnormNodeBlock_GetLastNode(theBlock, lastNode))
- 
--        // Optional Joinpoint (argument of the pointcut)
-+        // Optional Joinpoint (argument of the pointcut: if none, parenthesis not required)
-         // Build the chunk node, and retrieve the references to it's internals
-         // (body and parameters)
--/**/    => local parameters;
-+/**/    => local param_types;
-+/**/    => local param_identifiers;
- /**/    => local body;
--/**/    => local pointcut;
--/**/    #check(rtxNodeChunk(lastNode, pointcut, parameters, body))
--        rtx_scoped_identifier(pointcut)
--/**/      #check(rtxNodeVarList(parameters))
--        [ rtx_stmt_chunk_params(parameters) ]?
-+/**/    => local pointcutRtype;
-+/**/    => local pointcutId;
-+/**/    #check(rtxNodeChunk(lastNode, pointcutRtype, param_identifiers, body))
-+        rtx_scoped_identifier(pointcutId)
-+        #check(rtxNodeRType(pointcutRtype, pointcutId, param_types))
-+        [ rtx_parameter_list(param_types, param_identifiers) ]?
- /**/    #continue(sError, "Expected block after chunk declaration.")
-         rtx_chunk_body(body)
- ;
- 
-+rtx_stmt_chunk_param(theParam : node) ::=
-+/**/=> local rtype;
-+/**/=> local typeId;
-+    rtx_scoped_identifier(typeId) // for the type
-+    #check(rtxNodeRType(rtype, typeId, ))
-+    identifier:sName // for the identifier's value
-+;
-+
- // If there is any parameters to the chunk, we push it into a param list
- rtx_stmt_chunk_params(theParams : node) ::=
-         '('
--        [ rtx_var_list(theParams) ]?
--/**/    #continue(sError, "Expected ')' to end parameter list.")
-+            [
-+                #pushItem(theParams)
-+                rtx_stmt_chunk_param(theParams#back)
-+            ]?
-+/**/        #continue(sError, "Expected ')' to end parameter list.")
-         ')'
- ;
- 
-diff --git a/rathaxes/compiler/parse/rtxCommon.cwp b/rathaxes/compiler/parse/rtxCommon.cwp
---- a/rathaxes/compiler/parse/rtxCommon.cwp
-+++ b/rathaxes/compiler/parse/rtxCommon.cwp
-@@ -131,18 +131,18 @@
-  *
-  */
- 
--rtx_seq_param(theParams : node, theIdentifiers : node) ::=
-+rtx_param(theParams : node, theIdentifiers : node) ::=
-     #pushItem(theIdentifiers)
-     #pushItem(theParams)
-     rtx_scoped_identifier(theParams#back)
-     [    #readIdentifier:theIdentifiers#back ]?
- ;
- 
--rtx_seq_parameter(theParams : node, theIdentifiers : node) ::=
-+rtx_parameter_list(theParams : node, theIdentifiers : node) ::=
-     '('
-     [
--        rtx_seq_param(theParams, theIdentifiers)
--        [ ',' rtx_seq_param(theParams, theIdentifiers) ]*
-+        rtx_param(theParams, theIdentifiers)
-+        [ ',' rtx_param(theParams, theIdentifiers) ]*
-     ]?
-     ')'
- ;
-@@ -152,5 +152,5 @@
- /**/=> local params;
-     rtx_scoped_identifier(nameNode)
-     #check(rtxNodeRType(theRtype, nameNode, params))
--    rtx_seq_parameter(params, theIdentifiers)
-+    rtx_parameter_list(params, theIdentifiers)
- ;
-diff --git a/rathaxes/compiler/parse/rtxMiddle.cwp b/rathaxes/compiler/parse/rtxMiddle.cwp
---- a/rathaxes/compiler/parse/rtxMiddle.cwp
-+++ b/rathaxes/compiler/parse/rtxMiddle.cwp
-@@ -68,8 +68,8 @@
-     #continue(sError, "Expected pointcut name after declaration type.")
-     rtx_scoped_identifier(nameNode)
-     #check(rtxNodeItfPointcutDeclaration(theDecl, theQualif, nameNode, params))
--    #continue(sError, "Expected parameters to pointcut '"+nameNode.name+"'")
--    [rtx_pointcut_parameter(params)]?
-+    #continue(sError, "Expected parameters to pointcut '"+rtxRtypeName<nameNode.type>(nameNode)+"'")
-+    [rtx_pointcut_parameters(params)]
-     #continue(sError, "Missing ';' ending pointcut declaration.")
-     ';'
- ;
-@@ -165,9 +165,12 @@
-     rtx_scoped_identifier(theParams#back)
- ;
- 
--rtx_pointcut_parameter(theParams : node) ::=
-+rtx_pointcut_parameters(theParams : node) ::=
-     '('
--    [ rtx_pointcut_param(theParams) [ ',' rtx_pointcut_param(theParams) ]* ]?
-+    [
-+        rtx_pointcut_param(theParams)
-+        [ ',' rtx_pointcut_param(theParams) ]*
-+    ]?
-     ')'
- ;
- 
-diff --git a/rathaxes/compiler/passes/back/rtxMeta.inc.cws b/rathaxes/compiler/passes/back/rtxMeta.inc.cws
---- a/rathaxes/compiler/passes/back/rtxMeta.inc.cws
-+++ b/rathaxes/compiler/passes/back/rtxMeta.inc.cws
-@@ -278,7 +278,7 @@
- 
-                 tpl_pointcut(thePointcut : node) ::=
-                         "pointcut"
--/**/                    =>local pointcutId;
-+/**/                    => local pointcutId;
- /**/                    => local theParams;
- /**/                    => local theDefault;
- /**/                    #check(rtxNodePointcut(thePointcut, pointcutId, theParams, theDefault))
--- a/rathaxes_correctly_use_chunk_and_template_sequences_parameters_in_e1000.patch	Sat Feb 18 15:57:45 2012 +0100
+++ b/rathaxes_correctly_use_chunk_and_template_sequences_parameters_in_e1000.patch	Sat Feb 18 16:04:02 2012 +0100
@@ -508,7 +508,7 @@
 diff --git a/rathaxes/samples/e1000/lkm.rtx b/rathaxes/samples/e1000/lkm.rtx
 --- a/rathaxes/samples/e1000/lkm.rtx
 +++ b/rathaxes/samples/e1000/lkm.rtx
-@@ -2,44 +2,44 @@
+@@ -2,50 +2,50 @@
  {
      Ethernet::open(Ethernet::Device dev)
      {
@@ -562,6 +562,13 @@
      LKM::author = "Rathaxes";
      LKM::description = "Hello World Loadable Kernel Module (LKM)";
      LKM::license = "GPL";
+ 
+     PCI::vendor_id = 0x8086;
+-    PCI::product_id = 0x100f;
++    PCI::product_id = 0x100e;
+     PCI::set_master = true;
+ 
+     Ethernet::ifname = "rtx%d";
 diff --git a/rathaxes/samples/e1000/log.blt b/rathaxes/samples/e1000/log.blt
 --- a/rathaxes/samples/e1000/log.blt
 +++ b/rathaxes/samples/e1000/log.blt
--- a/series	Sat Feb 18 15:57:45 2012 +0100
+++ b/series	Sat Feb 18 16:04:02 2012 +0100
@@ -1,2 +1,1 @@
 rathaxes_correctly_use_chunk_and_template_sequences_parameters_in_e1000.patch
-PointcutTyping