summaryrefslogtreecommitdiffstats
path: root/Tools/bgen
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1995-06-09 20:56:31 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1995-06-09 20:56:31 (GMT)
commit7d0bc8343f55f2e467abb2ce50b76b054897d72f (patch)
treec3a2618e7c6c09c201d03bb67dc1038cab7dc534 /Tools/bgen
parenta0e76bebd3ddb05461c9f692ff1f53267203aaae (diff)
downloadcpython-7d0bc8343f55f2e467abb2ce50b76b054897d72f.zip
cpython-7d0bc8343f55f2e467abb2ce50b76b054897d72f.tar.gz
cpython-7d0bc8343f55f2e467abb2ce50b76b054897d72f.tar.bz2
Ported to Universal Header 2.0.1f (i.e. CW6)
Diffstat (limited to 'Tools/bgen')
-rw-r--r--Tools/bgen/bgen/macsupport.py5
-rw-r--r--Tools/bgen/bgen/scantools.py7
2 files changed, 10 insertions, 2 deletions
diff --git a/Tools/bgen/bgen/macsupport.py b/Tools/bgen/bgen/macsupport.py
index f17bb96..6d226d4 100644
--- a/Tools/bgen/bgen/macsupport.py
+++ b/Tools/bgen/bgen/macsupport.py
@@ -16,6 +16,11 @@ ScriptCode = Type("ScriptCode", "h")
Size = Type("Size", "l")
Style = Type("Style", "b")
+UInt16 = Type("UInt16", "h")
+SInt16 = Type("SInt16", "h")
+UInt32 = Type("UInt32", "l")
+SInt32 = Type("SInt32", "l")
+
# Pascal strings
ConstStr255Param = OpaqueArrayType("Str255", "PyMac_BuildStr255", "PyMac_GetStr255")
Str255 = OpaqueArrayType("Str255", "PyMac_BuildStr255", "PyMac_GetStr255")
diff --git a/Tools/bgen/bgen/scantools.py b/Tools/bgen/bgen/scantools.py
index 3d546d8..09d6f35 100644
--- a/Tools/bgen/bgen/scantools.py
+++ b/Tools/bgen/bgen/scantools.py
@@ -30,7 +30,7 @@ except ImportError:
#CREATOR = 'KAHL' # Guido's favorite text editor on the Mac
#INCLUDEDIR = "D:Development:THINK C:Mac #includes:Apple #includes:"
CREATOR = 'MPCC' # Jack's favorite text editor on the Mac
-INCLUDEDIR = "Moes:CW5 GOLD Ä:Metrowerks C/C++ Ä:Headers Ä:Universal Headers 2.0a3 Ä:"
+INCLUDEDIR = "Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:"
Error = "scantools.Error"
@@ -309,7 +309,10 @@ class Scanner:
except IOError:
pass
# If not on the path, or absolute, try default open()
- return open(filename, 'r')
+ try:
+ return open(filename, 'r')
+ except IOError, arg:
+ raise IOError, (arg, filename)
def getline(self):
if not self.scanfile: