Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: Java programming and Perl

by heatblazer (Scribe)
on Dec 04, 2012 at 10:54 UTC ( #1007060=note: print w/ replies, xml ) Need Help??


in reply to Re: Java programming and Perl
in thread Java programming and Perl

Well, I agree with that PerlInterpreter will cause a size overload, but as I read now, Java`s default embed scripting language for end users is Rhino and it`s a javascript written in java. I was interested in Perl as end user script language instead of JS, because Perl is much more powerful and flexible, with CPan and the textual process power, so using Perl is definitely > than JavaScript. I don`t know if size overload is greater in priority than lose of functionality.


Comment on Re^2: Java programming and Perl
Re^3: Java programming and Perl
by ColonelPanic (Friar) on Dec 04, 2012 at 11:11 UTC

    I do have to admit, there is definitely a "cool factor" to using Perl on Android. As long as you are just experiementing, go ahead and have fun!

    Still, if you plan to release your app to others, you have to think about the costs. This will add at least several megabytes to your project. You will also be using a build of Perl that is experimental.

    This is not about the superiority of Perl to Javascript--I agree 100% that Perl is a better language. This is about the appropriateness of the tool for your task. Perl on Android would almost never be a good choice for a production app.



    When's the last time you used duct tape on a duct? --Larry Wall

      Point taken, thanks for the advice. It`s definitely a shame that no other script language derivates the ideas of Perl. Since I know JS enough for simple end user scripting, I`ll stick with it... or till Perl-Java hybridization gets further, so I`ll be prepared for that hour. Regards.

        "It`s definitely a shame that no other script language derivates the ideas of Perl.

        Actually, Ruby is pretty similar to Perl.

        perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'
Re^3: Java programming and Perl
by davido (Archbishop) on Dec 04, 2012 at 11:12 UTC

    Your curiosity is a desirable attribute. But let me make a suggestion. I've embedded Perl interpreters into C and C++ projects before. It's not terribly difficult to get something simple up and running. A basic framework is found in perlembed. However, it can get very complex, very fast.

    My suggestion is this: Read perlembed thoroughly, and then get an interpreter embedded in a C program. Put it through its paces with C first, before ever considering moving onto the next step of exposing the C code to Java. In particular (since you mention the power of CPAN), work on getting the embedded interpreter to work with CPAN distributions that you think will be used by your Franken-Java creation.

    Interfacing Perl with other languages at an 'internals' level is one of those pursuits where it's best to learn to walk before trying to run. When you look down you'll notice that you're skirting a cliff. ;)


    Dave

      Thanks for the interesting topic. I totally agree it gets quite a bite for me to handle. Indeed it looks scary... not as cliff tho` :)

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1007060]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2014-12-21 10:58 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (104 votes), past polls