[Gambas-user] Arch Version 3.18.4 issue with bytecode version

Brian G brian at westwoodsvcs.com
Wed Jan 3 17:52:59 CET 2024


On 1/2/24 16:14, Brian G wrote:
>
> On 1/2/24 14:27, Benoît Minisini wrote:
>> Le 02/01/2024 à 22:41, Brian G a écrit :
>>>
>>> Thinking of Working on the update to scripter to support this, looks 
>>> like an interesting idea if one wants to verify a script/project
>>> can be run by different versions of Gambas byte code. Perhaps a 
>>> #Script Bytecode=nn.nn to limit to higher level versions if
>>> certain types of instructions are used. example calculated goto and 
>>> gosub or @a = 100 etc within a script. In most cases I am not
>>> sure scripts care if they use certain byte codes unless they use 
>>> newer constructs than the current level and may be used in older 
>>> environments.
>>> That's A nice thing about scripts they are pretty portable across 
>>> release versions. And when a script is converted to a project it can 
>>> clearly set the correct
>>> bytecode version for the script being executed.
>>>
>>> Also in converting a project to a script the byte code version of 
>>> the project would convert to #Script ByteCode=
>>>
>>> Not sure of the use cases for forcing a script to a lower version, 
>>> Are there possible uses when a project is converted to a script that 
>>> there are old style gambas statements
>>> that are no longer supported by the latest version of compiler?
>>>
>>> unless it somehow ties into depreciated components.... umm.
>>>
>>> Is it useful?
>>>
>>
>> For me all that is non-sense.
>>
>> A script is compiled when you run it, and you run it only on the 
>> current system, so you don't care what the generated bytecode version 
>> is.
>>
>> If you use a Gambas syntax not supported by your current Gambas 
>> compiler, you get an error, that's all.
>>
>> It seems you have confused the bytecode version with the compiler 
>> supported syntaxes. They are not necessarily related.
>>
>> Regards,
>>
> I agree mostly nonsense, except knowing if the cache matches the 
> compiler version, is it possible to get the bytecode version of a 
> .gambas file
>
> from the file it's self?
>
>
> ----[ http://gambaswiki.org/wiki/doc/netiquette ]----

Does the current interpreter turn off overflow checking when a bytecode version is lower than 3.18?

-- 
~~~~ Brian

-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_0x78BFB26402F48419.asc
Type: application/pgp-keys
Size: 2428 bytes
Desc: OpenPGP public key
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20240103/3c84ffb8/attachment-0001.key>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 665 bytes
Desc: OpenPGP digital signature
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20240103/3c84ffb8/attachment-0001.sig>


More information about the User mailing list