diff nworker.rhope @ 62:b218af069da7

merge
author Mike Pavone <pavone@retrodev.com>
date Sat, 10 Oct 2009 16:43:37 -0400
parents 789a146a48e1
children aabda74c7a88
line wrap: on
line diff
--- a/nworker.rhope	Thu Oct 08 23:16:26 2009 -0400
+++ b/nworker.rhope	Sat Oct 10 16:43:37 2009 -0400
@@ -766,28 +766,46 @@
 Make Init[func,field:out]
 {
 	name <- [field]Index[0]
-	out <- [func]Set Field Null["obj", name]
+	variant <- [[field]Index[1]]Variant >>
+	If[[variant] = ["Boxed"]]
+	{
+		out <- [func]Set Field Null["obj", name]
+	}{
+		out <- func
+	}
 }
 
 Make Copy[func,field:out]
 {
 	name <- [field]Index[0]
-	got <- [func]Read Field["obj", name] {}
-	{ 
-		stream <- [[got]Instruction Stream
-			]AddRef No Dest[~] 
-		out <- [got]Do If[~, stream]
+	variant <- [[field]Index[1]]Variant >>
+	If[[variant] = ["Boxed"]]
+	{
+		got <- [func]Read Field["obj", name] {}
+		{ 
+			stream <- [[got]Instruction Stream
+				]AddRef No Dest[~] 
+			out <- [got]Do If[~, stream]
+		}
+	}{
+		out <- func
 	}
 }
 
 Make Cleanup[func,field:out]
 {
 	name <- [field]Index[0]
-	got <- [func]Read Field["obj", name] {}
-	{ 
-		stream <- [[got]Instruction Stream
-			]Release[~] 
-		out <- [got]Do If[~, stream]
+	variant <- [[field]Index[1]]Variant >>
+	If[[variant] = ["Boxed"]]
+	{
+		got <- [func]Read Field["obj", name] {}
+		{ 
+			stream <- [[got]Instruction Stream
+				]Release[~] 
+			out <- [got]Do If[~, stream]
+		}
+	}{
+		out <- func
 	}
 }