Welcome to Sulekha IT Training.

Unlock your academic potential here.

“Let’s start the learning journey together”

Do you have a minute to answer few questions about your learning objective

We appreciate your interest, you will receive a call from course advisor shortly
* fields are mandatory

Verification code has been sent to your
Mobile Number: Change number

  • Please Enter valid OTP.
Resend OTP in Seconds Resend now
please fill the mandatory fields including otp.

Peachpie lets PHP complied files to be executed in .NET framework

  • Link Copied
Peachpie lets PHP complied files to be executed in .NET framework

After the announcement of making .NET framework an open-source resource, Microsoft continued its open-source revolution by making its Roslyn complier technology an open-source resource too. This powerful compiler can enable the developer to compile codes of C# to JavaScript and thereby enabling an interactive scripting environment with C#.




Now a recently unveiled Roslyn-based compiler project named Peachpie allows PHP to be compiled into portable class libraries and executed in the .Net framework.




In addition to possible performance gains, compiling to .Net provides PHP developers access to the existing culture of software written for .Net, as well as features of the .Net runtime itself.




Another advantage of using Roslyn: It generates abstract syntax trees (ASTs) from PHP code. Allowing the source code to be transformed by the compiler and made available to the user makes it easier to write analysis tools or applications that modify the behavior of other applications.




Peachpie stems from an earlier project named Phalanger, a PHP runtime and compiler for .Net. Provided as a toolset for Visual Studio 2010 through 2015, Phalanger enabled such tasks as debugging a PHP website directly in Visual Studio.




Many features planned for Peachpie aren't available yet, as the current emphasis is on providing a working example of the technology. For now, the parser supports only PHP 5, although support for PHP 7 is planned. A basic implementation of the AST is available, but plans are under way to build ASTs using Roslyn's advanced ISymbol interface. And none of the .Net-related reflection or introspection tools are available yet.




PHP's broad deployment -- it's been in use for 20 years -- guarantees it will remain a common technology choice for rapid Web development. With PHP 7, the language enjoyed a major performance boost and gained its own abstract syntax tree functionality, among other feats.




But PHP's inconsistent design and piecemeal evolution opened up opportunities for other platforms, such as Node.js, to step in and offer a more modern set of solutions. (PHP debugging, for instance, has long been problematic).




Peachpie isn't likely to arrest that trend, but it will at least provide a way for both .Net and PHP developers to leverage what each development environment has to offer: PHP's breadth of existing applications and development expertise and .Net's runtime and metaprogramming facilities.


Take the next step toward your professional goals

Talk to Training Provider

Don't hesitate to talk to the course advisor right now

Take the next step towards your professional goals in .Net

Don't hesitate to talk with our course advisor right now

Receive a call

Contact Now

Make a call

+1-732-338-7323

Take our FREE Skill Assessment Test to discover your strengths and earn a certificate upon completion.

Enroll for the next batch

Related blogs on .Net to learn more

Latest blogs on technology to explore

Courses you may be intrested to learn
X

Take the next step towards your professional goals

Contact now