[Gridflow-cvs] [svn] commit: r6314 - in /trunk/src: classes1.cxx source_filter.rb

svn-gridflow at artengine.ca svn-gridflow at artengine.ca
Tue Sep 21 16:38:38 EDT 2010


Author: matju
Date: Tue Sep 21 16:38:06 2010
New Revision: 6314

Log:
\attr: accept spaces before semicolon

Modified:
    trunk/src/classes1.cxx
    trunk/src/source_filter.rb

Modified: trunk/src/classes1.cxx
==============================================================================
--- trunk/src/classes1.cxx (original)
+++ trunk/src/classes1.cxx Tue Sep 21 16:38:06 2010
@@ -335,8 +335,8 @@
 // in1: whatever nt
 // out0: same nt as in1
 \class GridStore : FObject {
-	PtrGrid r; // can't be \attr
-	PtrGrid put_at; // can't be //\attr
+	PtrGrid r; // can't be \attr (why ?)
+	PtrGrid put_at; // can't be //\attr (why ?)
 	\attr Numop *op;
 	int32 *wdex ; // temporary buffer, copy of put_at
 	int32 *fromb;
@@ -837,14 +837,14 @@
 //{ Dim[B]<T>,Dim[B]<T>,Dim[B]<T> -> Dim[*As,B]<T> }
 \class GridFor : FObject {
 	\attr PtrGrid from;
-	\attr PtrGrid to;
+	\attr PtrGrid to  ;
 	\attr PtrGrid step;
 	\constructor (Grid *from, Grid *to, Grid *step=0) {
 		this->from.constrain(expect_max_one_dim);
 		this->to  .constrain(expect_max_one_dim);
 		this->step.constrain(expect_max_one_dim);
 		this->from=from;
-		this->to  =to;
+		this->to  =to  ;
 		this->step=step;
 	}
 	\decl 0 set (Grid *l=0) {from=l;}

Modified: trunk/src/source_filter.rb
==============================================================================
--- trunk/src/source_filter.rb (original)
+++ trunk/src/source_filter.rb Tue Sep 21 16:38:06 2010
@@ -105,7 +105,7 @@
 def handle_attr(line)
 	line.gsub!(/\/\/.*$/,"") # remove comment
 	frame = $stack[-1]; raise "missing \\class #{where}" if not frame or not ClassDecl===frame
-	type = line.gsub(%r"//.*$","").gsub(%r"/\*.*\*/","").gsub(%r";?\s*$","")
+	type = line.gsub(%r"//.*$","").gsub(%r"/\*.*\*/","").gsub(%r"\s*;?\s*$","")
 	virtual = !!type.slice!(/\(\)$/)
 	name = type.slice!(/\w+$/)
 	handle_decl "void ___get(t_symbol *s);" if frame.attrs.size==0



More information about the Gridflow-cvs mailing list