Pointers? #8
Replies: 1 comment 2 replies
-
At least in languages with unconstrained pointers like C and C++, this is playing with fire. Rockwell's programming model does not really have them. However, you can use aliases to get some of the benefits. That's about as close as you can get. The InOut/ByRef probably refers to parameter handling when calling a procedure. If you have pass by value, then the value is copied and passed to a procedure. I can't really think of how to do that with Rockwell's model. ByRef means that instead of passing a copy of the data, you pass a reference to it. If it is a reference (usually a pointer under the hood) you can modify the data that is passed and the caller of the procedure will see the difference. The calling convention of (at least in ladder logic) procedures is actually a lot closer to early FORTRAN than anything else I can think of. E.g. No stack. When you call a procedure, I strongly suspect that the arguments are pass ByRef. All this is guesses based on behavior I've seen. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
What is this referring too?
Beta Was this translation helpful? Give feedback.
All reactions