summaryrefslogtreecommitdiffstats
path: root/Parser
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1992-03-25 22:32:00 (GMT)
committerGuido van Rossum <guido@python.org>1992-03-25 22:32:00 (GMT)
commit91ece4205b41ec2fbc04028b016d707d876fc296 (patch)
tree6a36f3008386067021cc86abbd2e8f00b2dc1244 /Parser
parent24e77d429de289383070219872f364ad2059354c (diff)
downloadcpython-91ece4205b41ec2fbc04028b016d707d876fc296.zip
cpython-91ece4205b41ec2fbc04028b016d707d876fc296.tar.gz
cpython-91ece4205b41ec2fbc04028b016d707d876fc296.tar.bz2
Guess tab size on the Mac from tab resource.
Diffstat (limited to 'Parser')
-rw-r--r--Parser/parsetok.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/Parser/parsetok.c b/Parser/parsetok.c
index ba98418..95fb123 100644
--- a/Parser/parsetok.c
+++ b/Parser/parsetok.c
@@ -84,6 +84,13 @@ parsefile(fp, filename, g, start, ps1, ps2, n_ret)
fprintf(stderr, "no mem for tok_setupf\n");
return E_NOMEM;
}
+#ifdef macintosh
+ {
+ int tabsize = guesstabsize(filename);
+ if (tabsize > 0)
+ tok->tabsize = tabsize;
+ }
+#endif
ret = parsetok(tok, g, start, n_ret);
if (ret == E_TOKEN || ret == E_SYNTAX) {
char *p;