Code Monkey home page Code Monkey logo

vscode-ibmi-languages's Issues

RPGLE Free definition keywords false highlighting

In the example below, pos and time are being highlighted as keywords.

Suggested: Adjust keyword regex to only handle (DCL-(C|S|PARM|PROC) and make separate regex set for "complex" such as (DCL-(DS|PI|PR)).

NOTE: nested data structures are going to be...interesting...

         read  file; 
         dow not %eof(file); 
             if %error;
                 dsply 'The read failed';
                 leave;
             else;
                 chain(n) name database data;
                 time = hours * num_employees
                          + overtime_saved;
                 pos = %scan (',': name);
                 name = %xlate(upper:lower:name);
                 exsr handle_record;
                 read file;
             endif;
         enddo;

Embedded SQL identifier '#'

slightly adjust regex to match RPGLE identifiers defined everywhere else, probably just missed a copy/paste at some point

image

RPG/400 C spec comment error

C Spec, EQ field extends to comment space if comment starts with numeric.

Suggested: regex for numeric literal highlighting to not extend past column 60

     C           PCVKEY    SETLLCP1107C                  8585=1 <==> FD

Unable to install for 1.38.1

Hi

I am not able to install the plugin, saying it is not compatible with the current version of vs code 1.38.1.

Btw, once I got the plugin installed, how to connect to back end? Thanks.

RPGLE/RPG: Gutter breaks highlighting, causes CT Array highlighting

Related to #52 .
The gutter on line 58 gets recognized as a ct array.

So, definitely need to change the ct array regex.

     C           UTIME     IFEQ 0                          FIRST RECORD
     C                     TIME           UTIME   60       GET TIME
     C                     MOVEL'XXXXXX'  PGM    10
     C                     Z-ADD1         RUNNBR  50
*****C*********            CALL 'XXXXXX'
*****C*********            PARM           PGM
*****C*********            PARM           RUNNBR
     C                     EXCPTHEADR
     C                     END
      *

image

H/ breaks syntax highlighting in RPGLE

Something that was changed recently with precompiler regex has broken all highlighting if something like this is in the file...

     H/TITLE Call Menu                 Execute external functio
     H DATFMT(*YMD) DATEDIT(*YMD) DEBUG(*YES)

Highlights *on, *off, etc?

Planning the highlight *on, *off, *loval, *hival, *start, *zero, *zeros, *blank, *blanks, *lock, etc?

No highlighting for fixed format embedded SQL in RPGLE

     C* Embedded SQL fixed form
     C/EXEC SQL
     C+     DECLARE MYCSR     CURSOR FOR
     C+       SELECT * FROM SOMETABLE
     C+           WHERE (COLUMNA = :COLUMNA
     C+           AND    COLUMNB = :COLUMNB
     C+                 )
     C+       ORDER BY  COLUMNA ASC,
     C+                 COLUMNB ASC
     C/END-EXEC
     C*
     C/EXEC SQL
     C+   OPEN MYCSR
     C/END-EXEC
     C*
     C                   IF        SQLCOD = -502
     C/EXEC SQL
     C+   CLOSE MYCSR
     C/END-EXEC
     C                   ELSE
     C                   IF        SQLCOD < 0
     C                   EXSR      MYSUBR
     C                   ENDIF
     C                   ENDIF

image

RPG fixed format

  • Incorrect color of D-section
  • Incorrect color of '' character. This is backslash character.
    image

RPGLE hex literals messed up

    fptr = fopen(fpath: fmode);
    line = fgets(%addr(buffer): %size(buffer): fptr);

    dow (line <> *NULL);
      buffer = %xlate(x'00250D' : '   ': buffer); // CR,LF,NULL
    enddo;

image

Incorrect handling/color-coding of variables and labels with dash (-)

I tested your VS Code extension on an MI source

Dash (-) inside a variable or label is not interpreted correctly, but seems to be considered as a minus operation
e.g. MOVE-USAGE:
CPYBLA IO-SRCLIB,OIR-SRCLIB

Slash (/) in CMP* MI operations seems to be considered as a divide operation
e.g. CMPBLA(B) LIBNAM,'QTEMP '/EQ(TEMPLIB)

RPGLE free precompiler not highlighting

Not highlighted when past column 5.
Just adjust regex from \s{0,5} to \s*

      * prototypes for xml procedure/function calls
      /copy cgidev2/qrpglesrc,prototypeb
      /copy qsysinc/qrpglesrc,QUSEC

Adjust identifier regex for '#'

Add '#' to identifier regex. Should apply to all languages

     A N79N31                               DSPATR(UL)
     A N31                                  DSPATR(HI)
     A N25                                  OVRATR
      * Lock status
     A                                  8  4'Lock Status:'

image

Outline the source

Hi Barrett,
I am wondering whether is possible to outline procedures' names and other stuff in the OUTLINE panel. I think it will be very helpful.
What do you think about it?

Suggestions on how compile time arrays should be handled?

I'm decently content with compile time arrays just being a clump of data at the bottom of the program with non-sense highlighting. But, if someone has any suggestions for how they should be highlighted please let me know and I could give it a shot

RPG compile time arrays

**     TABER# / TABERD
1Text Text Text Text.
2Text Text Text Text Text Text Text Text Text Text.
3Text Text Text Text Text Text Text Text.
4
5
6
7
8

image

RPG, RPGLE, and DDS gutters

This is something I was painfully unaware of...gutters

RPG

OHMANC                     MOVEL'HELLO'   HELLO  11      
     C                     MOVE 'WORLD'   HELLO          
     C           HELLO     DSPLY          WAIT    1      
     C                     SETON                     LR  

image

RPGLE (mixed fix/free)

YIKESH/TITLE Messing around with fixed and free format              
     H*                                                             
OH NO   ctl-opt option(*srcstmt:*noDebugIO:*nounref) dftActGrp(*no);
     D*                                                             
     DCvtScore         S             10A                            

image

RPGLE I spec small highlighting problem

Small highlighting issue, the numbers next to 'C' should be highlighted constants as well

      *  xxx
     IXYZ123    AC  40   62 C4
      *                        a
     I         OR   41   62 C5
      *                        b
     I         OR   42   62 C6
      *                        c
     I         OR   43   62 C7
      *                        d
     I         OR   44   62 C8
      *                        e

image

Reaching out phisycal source files in the system

Hi,
I really appreciate your work, because I would like to edit IBM i sources from VSC, so I am sorry to ask a question that may be silly, but I can't answer it on my own.
I would like to edit sources which are not in the IFS, but in IBM I operating system.
I tried to open such a mapped folder:
\myip\root\QSYS.LIB\MYLIB.LIB\QILESRC.FILE
and it works, meaning I can see the list of all source members inside it.
But when I open a single member to edit it, it is not translated into the correct code page, so all I see is a long list of useless characters.
How do you reach the IBM system through VSC?
Is there a different way to reach out source files in a library?
Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.