What is the difference between the const and _rom C-language keywords?
In the 8051 architecture, besides ROM there are several other memory spaces and most of them require special instructions to access. To designate in which memory space an object is to be defined, a ‘storage specifier’ keyword can be used in your C source code. The 8051 C-compiler recognizes the following storage specifiers: _data, _bdat, _idat, _pdat, _xdat, _rom. The 8051 C-compiler treats the _rom storage type in a special way: Since the ROM memory space is physically read-only, it always implies the type qualifier const. The ANSI-C standard states that the type qualifier const can be used to specify read-only objects. During compilation, it allows the compiler to issue an error message for a source line where an attempt is made to write to the object.