June 24, 2024, 12:58:51 AM

News:

Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........


Question about DEF and DIM

Started by Rock Ridge Farm (Larry), May 11, 2024, 06:54:23 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Rock Ridge Farm (Larry)

While working on the new compiler I discovered that DIM and DEF produce
the same output. Example DIM x:int and Def x:int.
Any ideas????

billhsln

Older compatibility.  DIM was EBA, DEF is IWB, if I remember right.

Bill
When all else fails, get a bigger hammer.

Brian

From the EBA help file:

Array dimensions must be a constant or resolve to a constant. For dynamic arrays see the NEW statement. A colon ':' may be used as a shortcut to the AS keyword. DIM is a synonym for DEF and the two can be used interchangeably.

Brian

Rock Ridge Farm (Larry)

OK - that is solved - now for the next: Does anyone use byte packing
in structures ie: TYPE abc,1
I can find little to no value to it in the new compiler - it produces
llvm .ll output.

Actually had a couple of very good days. Hands are working.

Larry

Brian

May 14, 2024, 03:24:52 AM #4 Last Edit: May 14, 2024, 04:22:48 AM by Brian
I've never actually used it myself, but would use it if I picked up an example using it. Seems to be in the Sapero or PT domain!

Although I think the option should be there to include a packing value, if needed

Brian

Egil

Quote from: Rock Ridge Farm (Larry) on May 13, 2024, 04:32:39 PMActually had a couple of very good days. Hands are working.

Larry


Nice to see that you are up and going Larry, almost can't wait to see the finished product.
Never used TYPE myself yet, but I agree with Brian it would be nice to have the possibility to use it.

Good Luck1

Egil
Support Amateur Radio  -  Have a ham  for dinner!

Rock Ridge Farm (Larry)


billhsln

I know I haven't used the 'Type abc,1'.  Of course, I also don't know why it might be required.

Bill
When all else fails, get a bigger hammer.