Jump to content

Recommended Posts

  • 5 months later...
Posted

@Andreik I was recently playing with your RTA and found a few problems --

  • I had to change your #include delimiters to "" instead of <> to avoid the wrong copy of BinaryCall.au3 from being accessed
     
  • Memory_DllOpen returns an error when running in x64 mode, resulting in the following error --
    "C:\Users\danpo\OneDrive\Desktop\AutoIt\RTA\Real Time Assembler.au3" (72) : ==> Subscript used on non-accessible variable.:
    ConsoleWrite('Fasmg version: ' & Memory_DllCall($hFasmg, 'str', 'fasmg_GetVersion')[0] & @CRLF)
    ConsoleWrite('Fasmg version: ' & Memory_DllCall($hFasmg, 'str', 'fasmg_GetVersion')^ ERROR

    Either there needs to be error checking added or simply display a message and exit if @AutoItX64 equals 1.

  • I encounter a bug where commenting the line include 'line.inc' causes the error "Variable used without being declared". IMO, the regex for determining $iLine and $iDirective should not include "\S" in the initial capture group.

Posted (edited)
  On 11/19/2023 at 4:43 PM, Danp2 said:

Memory_DllOpen returns an error when running in x64 mode, resulting in the following error --

Expand  
  On 6/4/2023 at 5:35 PM, Andreik said:

Even if it can generate code for various CPUs, use the call/execute functionality just in 32-bit mode (really, don't try to run 64-bit code and then ask why it doesn't work or why it's crashing :mad2: ).

Expand  

But I agree that I could add a message to prevent the code to be executed in 64-bit applications. Actually there is an unofficial 64bit version of fasm but I don't know when I will have time to test some cases and maybe to include it in this project.

  On 11/19/2023 at 4:43 PM, Danp2 said:

I had to change your #include delimiters to "" instead of <> to avoid the wrong copy of BinaryCall.au3 from being accessed

Expand  

What do you mean? Do you have another BinaryCall.au3 somewhere?

I will check the other issue addressed above and I will come back with an answer soon. Thanks for feedback.

Edited by Andreik
Posted
  On 11/19/2023 at 4:43 PM, Danp2 said:

I encounter a bug where commenting the line include 'line.inc' causes the error "Variable used without being declared". IMO, the regex for determining $iLine and $iDirective should not include "\S" in the initial capture group.

Expand  

This might be an option or a negative lookup to check if the line include 'line.inc' it's commented but I preferred the lazy way, to modify this line in Compile():

If $iLine And $iDirective And $iCodeLines Then

This will work because $iCodeLines will be set just if there is a line that starts with include 'line.inc' but I agree, there are betters ways for doing this, including a better regex. Feel free to change it by your own desire. I uploaded a new version and hopefully I fixed the problems that your encountered. Thanks again for feedback.

Posted
  On 11/19/2023 at 6:24 PM, Andreik said:

What do you mean? Do you have another BinaryCall.au3 somewhere?

Expand  

Yes... in the directory where I keep my 3rd party UDFs.

  On 11/19/2023 at 7:09 PM, Andreik said:
If $iLine And $iDirective And $iCodeLines Then
Expand  

This won't work because the variable is declared locally in the For loop, so it doesn't exist in some instances. You could do this instead --

If $iLine And $iDirective And IsDeclared("iCodeLines") Then

 

Posted
  On 11/19/2023 at 8:36 PM, Danp2 said:

This won't work because the variable is declared locally in the For loop, so it doesn't exist in some instances. You could do this instead --

Expand  

I didn't mentioned but I changed that too. Check out first post. :whistle:

Posted

Anyway I am planning to change the GUI and other parts of the script so the user might be able to define structures and modify the data within and then use the pointers to these structures as parameters in calls. When this changes will take place probably I will replace that part also with better regex patterns.

Posted

This would require some changes to generate opcodes for the source code mentioned and even more changes to call the code directly from the application. I will keep this request on my To Do/ To Investigate list and have a look as soon as I get some time.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...