From 8ff3dfaf5a77d7ef96490cc9dc418979e505903f Mon Sep 17 00:00:00 2001 From: dkf Date: Mon, 13 Oct 2008 13:13:45 +0000 Subject: Added magic for Objective C. [Bug 2163447] --- ChangeLog | 5 +++++ generic/tclOOInt.h | 17 ++++++++++++++++- 2 files changed, 21 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 2bab9cd..d021174 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-10-13 Donal K. Fellows + + * generic/tclOOInt.h: Added macro magic to make things work with + Objective C. [Bug 2163447] + 2008-10-12 Miguel Sofer * generic/tclCompile.c: fix bug in srcDelta encoding within diff --git a/generic/tclOOInt.h b/generic/tclOOInt.h index dbd7df2..4b6b8a0 100644 --- a/generic/tclOOInt.h +++ b/generic/tclOOInt.h @@ -9,13 +9,26 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclOOInt.h,v 1.8 2008/09/23 05:05:54 dkf Exp $ + * RCS: @(#) $Id: tclOOInt.h,v 1.9 2008/10/13 13:13:45 dkf Exp $ */ +#ifndef TCL_OO_INTERNAL_H +#define TCL_OO_INTERNAL_H 1 + #include #include "tclOO.h" /* + * Hack to make things work with Objective C. Note that ObjC isn't really + * supported, but we don't want to to be actively hostile to it. [Bug 2163447] + */ + +#ifdef __OBJC__ +#define Class TclOOClass +#define Object TclOOObject +#endif /* __OBJC__ */ + +/* * Forward declarations. */ @@ -584,6 +597,8 @@ MODULE_SCOPE void TclOOSetupVariableResolver(Tcl_Namespace *nsPtr); ckfree((char *) (ptr)); \ } \ } while(0) + +#endif /* TCL_OO_INTERNAL_H */ /* * Local Variables: -- cgit v0.12