News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

New INI for Sol_Asm

Started by BogdanOntanu, August 16, 2009, 11:46:28 PM

Previous topic - Next topic

BogdanOntanu

Hi Ketilo,

I have put together a sol_asm.ini file and a few templates for using Sol_Asm with RadASM here:
http://www.oby.ro/files/sol_asm_ini_2009_08_17.zip

If possible please check it out an if ok then please add it to you language packs downloads. New releases of Sol_Asm will include this INI as well. In fact the latest release contains it already.

A few questions/suggestions:

1) About multiple OS Targets
======================
Sol_Asm (and other assemblers) can generate code for Win32/Win64/Lin32/Sol32/MacOSX/Binary as OS targets. Each one of them can have a Debug or Release build. Maybe we need a way to select different OS targets in Project Options?

Maybe we also need separated API files for each OS targets. For example the API file for Windows serves no purpose for Solar_OS. However the assembler is the same and now the only way to use another API file would be to "fake" another assembler / ini file.

I guess that the API files should in fact be unique per OS basis and not per assembler basis? This should help maintaining them.

I have noticed that when I define in my code a structure that is in fact one of the Win32API structures known by Radasm then the RadAsm definition takes precedence (it is shown if I hover) and even more the F2 key does not get me to my include definition location. This can hide dangerous errors in includes.

I think that F2 should go to the structure definition IF the include containing it is a part of the project.



2) If possible add / update the Sol_Asm parser
==============================
I do use TASM parser for now because Sol_Asm syntax is similar but I have a few problems mainly with:

2.a) Support for ENUMS

Sol_ASM can define an enum like this

ENUM MY_MODES,100,358  ;  enum_name, start_value, max_value
MODE_1
MODE_2
...
ENDE

In fact this generates a series of EQU's with:
MODE_1 equ 100
MODE_2 equ 101
and so on. It also checks for a  maximum EQU value of 358 in this case.

Of course that RadASM does not know the values of those ENUM's. If possible please add such a feature to the parser.

2.b) Sol_ASM uses  a different syntax to reserve structure(s) inside structures:


STRUC MY_POINT
x dd ?
y dd ?
ENDS

STRUC MY_CTX
my_dd dd ?
my_points  rs MY_POINT,5    ; reserve 5 (five) structures
my_dw dw ?
ENDS


The RadASM parser will not perform code completion for [esi+MY_CTX.my_points.x] because it does not recognize the nested structure definition.

Hence the MASM style of

...
my_pos MY_POINT <?>
...

is ok for now for one single structure reserved.

IF possible please add the "member_name RS structure_name,count" syntax to the parser.

2.c) Block comments using /* and */

Code collapsing for such block comments used to work OK in version 2.2.1.2 but it stopped working in version 2.2.1.6.

Probably this is my fault but I can not find it yet. Here it is the relevant INI section in sol_asm.ini:


[CodeBlock]
1=proc $,endp,,,4
2=.if,.endif,.elseif,.else,0
3=struc $,ends,,,4
4=macro $,endm,,,12
5=#ifdef,#endif,#else,,0
6=enum $,ende,,,4
7=union,endu,,,4
8=/*,*/,,,2
9=begin,end,,,0


What am I doing wrong here?

2.d) Macro arguments are on a separated line with MARG like this

MACRO ODS_fmt
MARG mfmt1, marglist1 :VARARG
...
ENDM


Other than this few "small" issues I guess that things are similar with the TASM parser but honestly the Sol_Asm syntax might deviate more in the future.

Again thank you for this great RadASM IDE.

Best regards,
Bogdan Ontanu


Ambition is a lame excuse for the ones not brave enough to be lazy.
http://www.oby.ro

KetilO

Hi Bogdan

Great assembler, very fast.
I have created a sol_asm parser. It solves the problems.
Sources is included so you can modify it if needed.

KetilO

BogdanOntanu

Ambition is a lame excuse for the ones not brave enough to be lazy.
http://www.oby.ro