Re: ProC: symbolic constants in the declare section?
Date: 14 Jan 1995 11:54:43 GMT
Message-ID: <3f8e23$685_at_aggedor.rmit.EDU.AU>
Karl Zdero <karlz_at_pst.bt.co.uk> writes:
>zhdkd_at_svusenet.ubs.ch wrote:
>> 29 static char test_arr[ARR_LEN];
>> 29 .........................^
>> PCC-S-0018: Expected "<unsigned_integer>", but found "ARR_LEN" at line
>> Is there a way around this? Pro-C Ver 1.5
Well, actually there IS, if you don't mind declaring test_arr as a pointer, even with Pro*C before 2.0.
Check out the Pro*C section of the FAQ. (http://www.bf.rmit.edu.au/~dtb/orafaq/proc.html) and grab the package I wrote for this and other purposes (ftp://ftp.bf.rmit.edu.au/pub/Oracle/sources/pgmr/vch.cpio.Z)
Your mileage may vary. If you are on a 32-bit UNIX machine then you should be pretty safe. This package permits you do declare the storage in a NORMAL C file (even malloc'ing it dynamically) by creating C preprocessor definitions and functions to deal with varchar types.
READ THE DOCO CAREFULLY, you could be in BIG trouble if you do not understand it or the code.
Regards
David
-- --- David T. Bath | dtb_at_ftp.bf.rmit.edu.au (mail=dtb_at_bf.rmit.edu.au) 3/175 Wattletree Rd | Snr Tech Consultant, Global Consulting Services MALVERN 3144 VIC | 179 Grattan St, Carlton, Vic 3053, Australia +61 3 500 9337 | Ph:+61 3 3477511 Fx:+61 3 3470182 Mb: +61 15 824171 WWW pages incl. ORA FAQ: lynx http://www.bf.rmit.edu.au/~dtbReceived on Sat Jan 14 1995 - 12:54:43 CET