• Transpiling between Oberon, Modula and Pascal

    From 711 Spooky Mart@21:1/5 to All on Thu Oct 21 22:37:44 2021
    What _good_ and up-to-date tools exist, if any, for transpiling between
    Oberon, FreePascal, ObjectPascal, and the Modulas? Where would I look
    for these. Please don't say "google" since the search engines really
    suck nowadays.

    --
    ┏━━━━┓──┏━━┓───┏━━┓── ┌────────────────────────┐ ┌────────┐
    ┗━━┓─┃──┗┓─┃───┗┓─┃── │ Spooky Mart [chan] 711 │ │ always │
    ───┃─┃──┏┛─┗┓──┏┛─┗┓─ │ https://bitmessage.org │ │ open │
    ───┗━┛──┗━━━┛──┗━━━┛─ └────────────────────────┘ └────────┘

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Program Language Analyst@21:1/5 to All on Fri Oct 22 21:00:22 2021
    On 22.10.21 05:37, 711 Spooky Mart wrote:
    What _good_ and up-to-date tools exist, if any, for transpiling between Oberon, FreePascal, ObjectPascal, and the Modulas? Where would I look
    for these. Please don't say "google" since the search engines really
    suck nowadays.


    I don't think there is any. I'm working on a modest sort of formatter
    for Object Pascal which can change some of the characteristics of the
    Units. I tried to find something like that without success before I
    started working on that tool.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From G.K.@21:1/5 to Program Language Analyst on Wed Dec 7 07:24:22 2022
    On 10/22/21 14:00, Program Language Analyst wrote:
    On 22.10.21 05:37, 711 Spooky Mart wrote:
    What _good_ and up-to-date tools exist, if any, for transpiling between
    Oberon, FreePascal, ObjectPascal, and the Modulas? Where would I look
    for these. Please don't say "google" since the search engines really
    suck nowadays.


    I don't think there is any. I'm working on a modest sort of formatter
    for Object Pascal which can change some of the characteristics of the
    Units. I tried to find something like that without success before I
    started working on that tool.

    How is this project coming along? Do you have a public repository?

    --

    G.K.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Program Language Analyst@21:1/5 to G.K. on Wed Nov 8 17:44:57 2023
    On 12/7/22 14:24, G.K. wrote:
    On 10/22/21 14:00, Program Language Analyst wrote:
    On 22.10.21 05:37, 711 Spooky Mart wrote:
    What _good_ and up-to-date tools exist, if any, for transpiling between
    Oberon, FreePascal, ObjectPascal, and the Modulas? Where would I look
    for these. Please don't say "google" since the search engines really
    suck nowadays.


    I don't think there is any. I'm working on a modest sort of formatter
    for Object Pascal which can change some of the characteristics of the
    Units. I tried to find something like that without success before I
    started working on that tool.

    How is this project coming along? Do you have a public repository?

    Unfortunately, it is on hold.

    Right now I'm working on a ptop which is part of the FreePascal basic
    toolset although it seems not to be actively maintained. I'm in the
    final phase completing the first version of ptop which behaves as it was intended to behave by the original author as far as I can tell. I fully understand all the parts of ptop and I found several small bugs which I
    have fixed.

    This work will be merged into the official release of ptop if approved
    by my co-worker from the the FreePascal community who has write access
    to the official FreePascal repo.

    I also understand the limitations of the approach taken by ptop and I've already collected a set of changes for a next generation of ptop
    necessary to ironing out most of the weaknesses of the current approach.

    If this improved approach will be successful the next generation of ptop
    will also be made available through the FreePascal repository.

    My transformator project is implemented with Delphi and FreePascal, i.e.
    can be compiled with both, Delphi and FreePascal, and runs on UNIX and
    Windows.

    To avoid having to implement the language frontend I tried out different frontends from the FreePascal community. I gave up because none of these collected all the information I need.

    Then I tried JEDI Code Formatter which seemed to be not maintained (see https://github.com/quadroid/jcf-pascal-format) and I reached the point
    where I understood most of the decisions made by the original author.
    Then I simplified some of the data structures according to the ideas the
    author had in mind as I understood them but hadn't time so far to
    complete these steps.

    I also removed the dependency from the Lazarus GUI which was only
    introduced by importing some declarations. A command line tool or -
    generally spoken - the formatter should not depend on any GUI related
    parts. In fact, the dependency can be flipped, i.e. the common
    declarations can be imported from Lazarus without harm if the formatter
    is needed.

    So far, the object tree is populated and contains all the information I
    need, but the generation phase is not implemented. The project is not
    abandoned and will sooner or later be published as a replacement for
    ptop and JEDI Code Formatter. Before I continue I will study the work of
    Jay and quadroid on JEDI.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)