Two patches from Jack Jansen:

Three bgen mods:
- support for FSSpecs passed-by-value and points-passed-by-reference added.
- strip single-line comments when parsing header files
- if a definition is blacklisted _do_ output it, but in comment
diff --git a/Tools/bgen/bgen/macsupport.py b/Tools/bgen/bgen/macsupport.py
index ba2fd8f..344f87b 100644
--- a/Tools/bgen/bgen/macsupport.py
+++ b/Tools/bgen/bgen/macsupport.py
@@ -15,7 +15,7 @@
 ScriptCode = Type("ScriptCode", "h")
 Size = Type("Size", "l")
 Style = Type("Style", "b")
-StyleParameter = Type("StyleParameter", "h")
+StyleParameter = Type("Style", "h")
 CharParameter = Type("CharParameter", "h")
 TextEncoding = Type("TextEncoding", "l")
 
@@ -31,7 +31,7 @@
 Str255 = OpaqueArrayType("Str255", "PyMac_BuildStr255", "PyMac_GetStr255")
 
 # File System Specifications
-FSSpec_ptr = OpaqueType("FSSpec", "PyMac_BuildFSSpec", "PyMac_GetFSSpec")
+FSSpec = FSSpec_ptr = OpaqueType("FSSpec", "PyMac_BuildFSSpec", "PyMac_GetFSSpec")
 
 # OSType and ResType: 4-byte character strings
 def OSTypeType(typename):
@@ -66,6 +66,7 @@
 # Quickdraw data types
 Rect = Rect_ptr = OpaqueType("Rect", "PyMac_BuildRect", "PyMac_GetRect")
 Point = OpaqueByValueType("Point", "PyMac_BuildPoint", "PyMac_GetPoint")
+Point_ptr = OpaqueType("Point", "PyMac_BuildPoint", "PyMac_GetPoint")
 
 # Event records
 EventRecord = OpaqueType("EventRecord", "PyMac_BuildEventRecord", "PyMac_GetEventRecord")
@@ -84,7 +85,6 @@
 # Various buffer types
 
 InBuffer = VarInputBufferType('char', 'long', 'l')		# (buf, len)
-OptionalInBuffer = OptionalVarInputBufferType('char', 'long', 'l')		# (buf, len)
 
 InOutBuffer = HeapInputOutputBufferType('char', 'long', 'l')	# (inbuf, outbuf, len)
 VarInOutBuffer = VarHeapInputOutputBufferType('char', 'long', 'l') # (inbuf, outbuf, &len)
@@ -151,9 +151,9 @@
 # This requires that the OSErr type (defined above) has a non-trivial
 # errorCheck method.
 class OSErrMixIn:
-	"Mix-in class to treat OSErr/OSStatus return values special"
+	"Mix-in class to treat OSErr return values special"
 	def makereturnvar(self):
-		if self.returntype.__class__ == OSErrType:
+		if self.returntype is OSErr:
 			return Variable(self.returntype, "_err", ErrorMode)
 		else:
 			return Variable(self.returntype, "_rv", OutMode)
diff --git a/Tools/bgen/bgen/scantools.py b/Tools/bgen/bgen/scantools.py
index 80cfd5e..f31996d 100644
--- a/Tools/bgen/bgen/scantools.py
+++ b/Tools/bgen/bgen/scantools.py
@@ -234,10 +234,13 @@
 		self.args_pat = "(\(<args>\([^(;=)]+\|([^(;=)]*)\)*\))"
 		self.whole_pat = self.type_pat + self.name_pat + self.args_pat
 #		self.sym_pat = "^[ \t]*\(<name>[a-zA-Z0-9_]+\)[ \t]*=" + \
-#		               "[ \t]*\(<defn>[-0-9'\"][^\t\n,;}]*\),?"
+#		               "[ \t]*\(<defn>[-0-9'\"(][^\t\n,;}]*\),?"
 		self.sym_pat = "^[ \t]*\(<name>[a-zA-Z0-9_]+\)[ \t]*=" + \
-		               "[ \t]*\(<defn>[-0-9_a-zA-Z'\"][^\t\n,;}]*\),?"
+		               "[ \t]*\(<defn>[-0-9_a-zA-Z'\"(][^\t\n,;}]*\),?"
 		self.asplit_pat = "^\(<type>.*[^a-zA-Z0-9_]\)\(<name>[a-zA-Z0-9_]+\)$"
+		self.comment1_pat = "\(<rest>.*\)//.*"
+		# note that the next pattern only removes comments that are wholly within one line
+		self.comment2_pat = "\(<rest>.*\)/\*.*\*/"
 
 	def compilepatterns(self):
 		for name in dir(self):
@@ -372,6 +375,10 @@
 			while 1:
 				try: line = self.getline()
 				except EOFError: break
+				if self.comment1.match(line) >= 0:
+					line = self.comment1.group('rest')
+				if self.comment2.match(line) >= 0:
+					line = self.comment2.group('rest')
 				if self.defsfile and self.sym.match(line) >= 0:
 					self.dosymdef()
 					continue
@@ -386,6 +393,8 @@
 		name, defn = self.sym.group('name', 'defn')
 		if not name in self.blacklistnames:
 			self.defsfile.write("%s = %s\n" % (name, defn))
+		else:
+			self.defsfile.write("# %s = %s\n" % (name, defn))
 
 	def dofuncspec(self):
 		raw = self.line