Mercurial > hg > octave-lyh
diff liboctave/Array.cc @ 309:5638a94baa25
[project @ 1994-01-19 01:39:52 by jwe]
author | jwe |
---|---|
date | Wed, 19 Jan 1994 01:39:52 +0000 |
parents | c9894e8d5f04 |
children | 42fe4794ded9 |
line wrap: on
line diff
--- a/liboctave/Array.cc +++ b/liboctave/Array.cc @@ -1,7 +1,7 @@ // Template array classes -*- C++ -*- /* -Copyright (C) 1993 John W. Eaton +Copyright (C) 1993, 1994 John W. Eaton This file is part of Octave. @@ -985,8 +985,8 @@ delete old_rep; } -#ifdef __GNUG__ -#if defined (OCTAVE_SOURCE) && defined (USE_EXTERNAL_TEMPLATES) +#if defined (__GNUG__) && defined (USE_EXTERNAL_TEMPLATES) +#if defined (OCTAVE_SOURCE) typedef Array<double> array_type_double; typedef Array2<double> array2_type_double; @@ -997,6 +997,20 @@ typedef Array2<Complex> array2_type_complex; typedef DiagArray<Complex> diag_array_type_complex; +#elif defined (USER_TYPEDEFS) + +// Users can generate their own .o files with their own types, as many +// times as they like. USER_TYPEDEFS should be defined to be the name +// of an include file that contains typdefs for the desired types. +// +// For example, if my-types.h contains typedefs for the Array types +// you are interested in, you might compile this file with the command +// +// g++ -fexternal-templates -DUSER_EXTERNAL_TEMPLATES \ +// -DUSER_TYPEDEFS=\"my-types.h\" + +#include USER_TYPEDEFS + #endif #endif