fpc2js

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

fpc2js

Victor Campillo
Hi,

Testing the preview that Michael was so kind to share, I found the next
minor problems trying to compile the packages included, I think that
everything is related to that the project is work in progress so nothing
to worry much about.

  * Package fcl_base
      o The package is configured as "designtime and runtime" and this
        cause that the IDE complains about missing register procedure if
        you try to install.
      o Inside the folder fcl-base there is a unit called "browserapp"
        that is not used in the package which could be correct but I
        mention it just in case you forgot to include it in the package.
      o It does not include the command to call pas2js compiler.
      o Adding the command to call pas2js and changing the package to
        runtime just compile fine.
  * Package fcl-db
      o The package include the unit "restconnection" which is missing.
      o Just removing restconnection, the package compile without problems.
  * Package fpcunit
      o The package include the unit "htmltestreport" which is missing.
      o The package is configured as "designtime and runtime" and this
        cause that the IDE complains about missing register procedure if
        you try to install.
      o It does not include the command to call pas2js compiler.
      o Solving the previous remarks, the compilation fails with the
message "plaintestreport.pas(166,6) Error: identifier not found "IRound""


I will try to convert a little JavaScript project I have to pascal and
use pas2js, I will let you know if I found any problems do it.

Best Regards.

--
Victor Campillo

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Marcos Douglas B. Santos
On Wed, Dec 6, 2017 at 9:48 AM, Victor Campillo
<[hidden email]> wrote:

> Hi,
>
> Testing the preview that Michael was so kind to share, I found the next
> minor problems trying to compile the packages included, I think that
> everything is related to that the project is work in progress so nothing to
> worry much about.
>
>  * Package fcl_base
>      o The package is configured as "designtime and runtime" and this
>        cause that the IDE complains about missing register procedure if
>        you try to install.
>      o Inside the folder fcl-base there is a unit called "browserapp"
>        that is not used in the package which could be correct but I
>        mention it just in case you forgot to include it in the package.
>      o It does not include the command to call pas2js compiler.
>      o Adding the command to call pas2js and changing the package to
>        runtime just compile fine.
>  * Package fcl-db
>      o The package include the unit "restconnection" which is missing.
>      o Just removing restconnection, the package compile without problems.
>  * Package fpcunit
>      o The package include the unit "htmltestreport" which is missing.
>      o The package is configured as "designtime and runtime" and this
>        cause that the IDE complains about missing register procedure if
>        you try to install.
>      o It does not include the command to call pas2js compiler.
>      o Solving the previous remarks, the compilation fails with the message
> "plaintestreport.pas(166,6) Error: identifier not found "IRound""
>
>
> I will try to convert a little JavaScript project I have to pascal and use
> pas2js, I will let you know if I found any problems do it.

Thank you that work!

Best,
Marcos Douglas
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Michael Van Canneyt
In reply to this post by Victor Campillo


On Wed, 6 Dec 2017, Victor Campillo wrote:

> Hi,
>
> Testing the preview that Michael was so kind to share, I found the next
> minor problems trying to compile the packages included, I think that
> everything is related to that the project is work in progress so nothing
> to worry much about.
>
>  * Package fcl_base
>      o The package is configured as "designtime and runtime" and this
>        cause that the IDE complains about missing register procedure if
>        you try to install.
>      o Inside the folder fcl-base there is a unit called "browserapp"
>        that is not used in the package which could be correct but I
>        mention it just in case you forgot to include it in the package.
>      o It does not include the command to call pas2js compiler.
>      o Adding the command to call pas2js and changing the package to
>        runtime just compile fine.
>  * Package fcl-db
>      o The package include the unit "restconnection" which is missing.
>      o Just removing restconnection, the package compile without problems.
>  * Package fpcunit
>      o The package include the unit "htmltestreport" which is missing.
>      o The package is configured as "designtime and runtime" and this
>        cause that the IDE complains about missing register procedure if
>        you try to install.
>      o It does not include the command to call pas2js compiler.
>      o Solving the previous remarks, the compilation fails with the
> message "plaintestreport.pas(166,6) Error: identifier not found "IRound""
>
>
> I will try to convert a little JavaScript project I have to pascal and
> use pas2js, I will let you know if I found any problems do it.
Thank you very much for your remarks!

I have fixed all issues and re-uploaded the file:
http://www.freepascal.org/~michael/pas2js/pas2js-demo-0.8.37.zip

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Victor Campillo
On 06/12/17 14:33, Michael Van Canneyt wrote:
>
> Thank you very much for your remarks!
>
> I have fixed all issues and re-uploaded the file:
> http://www.freepascal.org/~michael/pas2js/pas2js-demo-0.8.37.zip
>
Hi Michael,

Thank you, now in package fpcunit I get this error.

consoletestrunner.pas(300,40) Error: not yet implemented: :TParamsExpr
[20170601191003]

Best Regards.

--
Victor Campillo

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Michael Van Canneyt


On Wed, 6 Dec 2017, Victor Campillo wrote:

> On 06/12/17 14:33, Michael Van Canneyt wrote:
>>
>> Thank you very much for your remarks!
>>
>> I have fixed all issues and re-uploaded the file:
>> http://www.freepascal.org/~michael/pas2js/pas2js-demo-0.8.37.zip
>>
> Hi Michael,
>
> Thank you, now in package fpcunit I get this error.
>
> consoletestrunner.pas(300,40) Error: not yet implemented: :TParamsExpr
> [20170601191003]

Change line 300 to

   for i := low(DefaultLongOpts) to Length(DefaultLongOpts)-1 do

and it should compile again.

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Victor Campillo
On 06/12/17 15:19, Michael Van Canneyt wrote:
>
> Change line 300 to
>
>   for i := low(DefaultLongOpts) to Length(DefaultLongOpts)-1 do
>
> and it should compile again.
>
> Michael.

Hi,

Yes, that change solves the problem.

Regarding the rtl package, in the folder rtl there are two units that
are not included in the package, contnrs and libjquery.

I don't know if they should be included but I try to include libjquery
in the package and it compiles fine, but contnrs fails with the next error.

contnrs.pas(663,34) Error: Pascal element not supported: :TParamsExpr

--
Victor Campillo

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Michael Van Canneyt


On Wed, 6 Dec 2017, Victor Campillo wrote:

> On 06/12/17 15:19, Michael Van Canneyt wrote:
>>
>> Change line 300 to
>>
>>   for i := low(DefaultLongOpts) to Length(DefaultLongOpts)-1 do
>>
>> and it should compile again.
>>
>> Michael.
>
> Hi,
>
> Yes, that change solves the problem.
>
> Regarding the rtl package, in the folder rtl there are two units that
> are not included in the package, contnrs and libjquery.
>
> I don't know if they should be included but I try to include libjquery
> in the package and it compiles fine, but contnrs fails with the next error.
>
> contnrs.pas(663,34) Error: Pascal element not supported: :TParamsExpr
I am aware of this problem, this is something Mattias Gaertner needs to look
at.

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Mattias Gaertner
In reply to this post by Victor Campillo

> Victor Campillo <[hidden email]> hat am 6. Dezember 2017 um 12:48 geschrieben:
>[...]
>  o It does not include the command to call pas2js compiler.

Correct. pas2js does not support ppu files (yet), so it compiles all units everytime. For the same reason the package is set to build manually.


>  o Adding the command to call pas2js and changing the package to
>  runtime just compile fine.

Yes, but since no one compiles the package manually, it is unnecessary.

Mattias
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: fpc2js

Victor Campillo
On 06/12/17 19:32, Mattias Gaertner wrote:
> Yes, but since no one compiles the package manually, it is unnecessary.

Hi Mattias,

Yes, it is unnecessary, but I suppose that many people could try to
compile the packages as a first approach to the project as I did, just
to test if everything compiles without errors.

This weekend I have been playing with pas2js and I liked it very much,
so far everything I have done with it works fine, nothing fussy, mostly
XMLHttpRequest and DOM.

Keep up the good work guys, coding for the web without the need to do it
directly in Javascript is amazing, I don't like the untyped languages.

Best Regards.

--
Victor Campillo

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal