Easy language write support library continue play "Flowers": Command _ place code

Source: Internet
Author: User

In the previous blog, "Easy-to-use language support library can also be used to play" Flowers "(easy-to-write and easy-to-use library (exek) Progress 5)", Play a few" Flowers ", the following continues to play" Flowers.

Easy languageProgramPersonnel probably know that there is an official "Special Function Support library" in easy language. This support library is indeed a real name and is "special ". There is a command "placeCode"Very Special: It can regard its parameters as x86 machine code inserted into the compiled EXE! We know that commands in the library are generally supported and only executed during the running period. The "place code" command affects compilation of easy-language compilers! In addition, the easy-language program that uses this command does not rely on the support library file (spec. FNE), that is, it takes effect only during the compilation period.

So, can I use "easy to write (exek)" to write a command equivalent to the "place code" function? Of course.

I wrote a very simple support library with only one command in it. "command _ place code" has the same function as "place code" and has identical parameters and return values, supports database operations independently of special functions.

Download: myspec. FNE, 51 K.

The simplest way to verify the support for the library command function is to call "command _ place code ({204})" for debugging and execution to see if the program will interrupt the next line of code. If you suspect that I have internally called the "place code" command for the special feature support library, you may wish to remove the spec. FNE file beforehand. (Note: 204 is the machine code of the command int3, which is soft interrupted .)

This is just a "Flower" and has no practical value.

 

Add:

Most common and easy-language users may be unfamiliar with "code placement". After all, it is rare to be familiar with assembly instructions or even x86 machine codes. However, this command is really useful, and in certain cases, it is almost useless. This command is applied in multiple places in the easy-to-write (exek) module.

 

2008.10.1 note:

Two points: 1. Compile a command that is equivalent to the function of "place Code". In fact, the method is very simple and easy to understand (this article is too confusing ). 2. From easy language 4.12, "code placement" has been moved from the support library for special functions to the core library.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.