| File Variables |
| Argument passing - Subroutines and Functions - Mike Pope |
| RevTech Replies - Mike Pope (RevTech UK Ltd) |
| Symbol Table Structure |
| Reader's Clinic - Functions and Subroutines |
| Reader's Letters - Jim Owen |
| Playing with Scan Codes |
| Argument passing - Subroutines and Functions - Mike Pope |
| Reader's Clinic - Line Length > 256 Characters |
| QTIPS - String Space |
| QTIPS - String Space Format Errors |
| Reader's Forum - Numeric Precision in R/Basic - Hal Wyman |
| VERBatim - V119 |
| VERBatim - V125 |
| VERBatim - V118 |
| Advanced Revelation Assembler Interface Module - Yves Pattyn, Technical Manager, Distribase, France |
RevMedia FKB
| Document | V2I6A1 |
| Title | Reader's Letters - Jim Owen |
| Keywords | INT() SPACE FUNCTION |
| Text | "I've discovered something that might be of interest to some AREV programmers regarding the CALLING of homemade functions I had a function called SPC which padded blank spaces onto a variable For example X = 65 Y = SPC(X 5 "R") would return Y = ' 65' (Unsure as to why this differs FROM Y = 65 "R#5" Ed) However I discovered that this function ALSO changed X! I wanted my function to work like INT() which does not change the value of the variable inside the parens only the value to the left of the '=' RTI told me that the C esque use of local vs global VARIABLES doesn't apply to RBASIC One way to solve it was to make parameter 1 a literal string This was done by CALLING the function thus X = 65 Y = SPC(X:" " 5 "R") Concatenating a null to the variable changes it to a string and does NOT change X Another way around the problem was to immediately stuff some other variable WITH X on entering the function then operating on and returning this new variable Incidentally the INT() function is in assembler and avoids the problem altogether" (Volume 2 Issue 6 Page 3) |
Page last modified: 08/02/03