Jump to content
IGNORED

How to declare negative ints in Action! ?


Recommended Posts

Convoluted logic on my part. :) Probably Mr. Parker was so focused on getting the indirection and pointer thing right that it took priority over what should have been an obvious option with a 16k cart. It probably could be fixed if people can't tolerate the work around Kyle presented.

 

The indirection/pointer thing.

 

Proc Main()

Byte Right_Margin=82, My_Margin=[0]

;Right_Margin refers/points to memory location 82, My_Margin is a byte somewhere in memory whose location is decided by the cart and initialized to the value 0

Right_Margin=My_Margin

;Uses the pointer Right_Margin to store the value of My_Margin<0> in memory location 82

Return

 

So things like memory location -1 weren't really a priority to implement in declarations since it sort of doesn't exist other then by wrap. 16k [compiler, editor, runtime] space problem. Matter of fact, if you are a professor of computer science, you may have even left it out/made it an error on purpose. It is one of the reasons why I like Action since there is still a way to do what you want to do, you just have to be serious about it and really mean it!

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...