Jump to content


Photo
- - - - -

Could you go away from eval() in order to support HipHop?


  • Please log in to reply
9 replies to this topic

#1 TSP

TSP

    Spam Happy

  • +Clients
  • 822 posts

Posted 24 May 2011 - 12:48 PM

Hi, we would like if there were done some changes in the core files to make it more supportive of tools like for example the PHP optimization tool HipHop: https://github.com/f...iphop-php/wiki/

As it is now it's not possible for us to use this "right out of the box" due to some of the code you use. So we would appreciate it if you could look at the possibillity to rewrite your code in order to support tools like HipHop. Especially the use of eval() is problematic, we haven't really looked too closely into whether you would have to change other functions or not. (And..: http://www.blog.high...p-eval-is-evil/ )

I am administrator TSP on the norwegian IPB 3.2.3-board Diskusjon.no.


#2 Ryan H.

Ryan H.

    Watch how I soar.

  • +Clients
  • 2,808 posts

Posted 24 May 2011 - 12:55 PM

The entire template logic system uses eval() at its core... that's probably not about to change.

Ryan Hoerr / "No1 1000" - Sublime Development

IP.Board 3.4 Resources bullet_star.pngbullet_star.pngbullet_star.pngbullet_star.pngbullet_star.png
Mod Advanced Tags & Prefixes
Mod Easy Pages
Skin Graphite
Skin Thoreau


#3 Marcher Technologies

Marcher Technologies

    $life=FALSE;$code=TRUE;$time--;

  • +Clients
  • 11,164 posts

Posted 24 May 2011 - 12:59 PM

Hi, we would like if there were done some changes in the core files to make it more supportive of tools like for example the PHP optimization tool HipHop: https://github.com/f...iphop-php/wiki/

As it is now it's not possible for us to use this "right out of the box" due to some of the code you use. So we would appreciate it if you could look at the possibillity to rewrite your code in order to support tools like HipHop. Especially the use of eval() is problematic, we haven't really looked too closely into whether you would have to change other functions or not. (And..: http://www.blog.high...p-eval-is-evil/ )

if you read through the comments on that link/ever bothered to learn the proper use of eval() including cleaning user input, you would realize that even though it is a pain to switch the syntax correctly, it is not evil...
You are correct in stating hiphop is not usuable right out of the box, however, twouldnt be too difficult to integrate this into ipb... just the hiphop source code needs tweaks to function in ipb right.
EDIT... took another look... why would anyone sack eval()? pretty much breaks ipcontent and a lot of other stuff, for what? to switch php to c++ then to binary?
seems a waste.

#4 Kyanar

Kyanar

    Let's say my yearly license expired in...

  • +Clients
  • 5,189 posts

Posted 24 May 2011 - 02:40 PM

So, rewrite the template engine from the ground up to support HipHop. Great idea, they should dumb down templating and make half of all the cool stuff you can do impossible, just so four people can use the technology of the week.

Here's what Facebook has to say about what HipHop is for:

HipHop is not the right solution for everyone deploying PHP. We think it will be useful to companies running very large PHP infrastructures who do not wish to rewrite complex logic within C or C++.

It certainly doesn't say "it will be useful for companies and individuals deploying Commercial off the Shelf software". Most CotS software will be incompatible, and the reason is simple. With so many diverse environments, you sometimes have to go low level to support desired functionality, because the high level stuff isn't guaranteed to be available (just look at the xml parsing in IPB for example).

I can't speak for the developers, obviously as just another customer, but I guarantee the answer is "no".
Mat / Fusion Digital Entertainment Limited
Our Website: http://www.fusiondigital.co.nz/
Our Forums: http://community.fusiondigital.co.nz/

Chronicle, the desktop time tracker for Windows • Fusion Menu, the leading navigation enhancement application for IP.Board • CommunityContact, the in development community newsletter application


#5 TSP

TSP

    Spam Happy

  • +Clients
  • 822 posts

Posted 24 May 2011 - 04:10 PM

Happy to see the answers here, I'm just sharing some ideas here on behalf of our tech staff. On how they think IPS could make it easier for larger boards to get better overall performance, I'm not an expert - so I'm happy to see your replies. Will ask him if he can post his reasoning behind it here ;)

But as far as I know there are other solutions than using eval, or isn't it? What would be disadvantages from switching from eval to another solution?

I am administrator TSP on the norwegian IPB 3.2.3-board Diskusjon.no.


#6 bfarber

bfarber

    RBT-KS

  • IPS Management
  • 27,076 posts

Posted 25 May 2011 - 11:07 AM

The template system, actually, largely doesn't use eval() (unless you run IN_DEV). Some hook functionality and IP.Content functionality, however, does. This is not likely to change in the immediate future.
Brandon Farber
Developer / Senior Support

If it sounds like fun, it's not allowed on the bus!

Posted Image     Posted Image

Invision Power Services, Inc.

#7 mkarpeko

mkarpeko

    IPB Newbie

  • +Clients
  • 9 posts

Posted 05 June 2012 - 04:55 AM

Hello,

Any news to remove "eval" from native IPB code?)

#8 stoo2000

stoo2000

    I've been here a while...

  • +Clients
  • 2,804 posts

Posted 05 June 2012 - 07:26 AM

Hello,

Any news to remove "eval" from native IPB code?)

The template system, actually, largely doesn't use eval() (unless you run IN_DEV). Some hook functionality and IP.Content functionality, however, does. This is not likely to change in the immediate future.


Stuart Silvester

Tracker 2.1.0 - Now Available!!!

Trader Feedback System v1.4 - Download Now - NEW
Member Map v1.0.9 - Download Now
Content Spy v1.1.2 - Purchase Here


#9 bfarber

bfarber

    RBT-KS

  • IPS Management
  • 27,076 posts

Posted 05 June 2012 - 08:25 AM

Hello,

Any news to remove "eval" from native IPB code?)


Are you experiencing some problem with eval we're not aware of?

eval() is used extremely sparingly in our code base as it is.
Brandon Farber
Developer / Senior Support

If it sounds like fun, it's not allowed on the bus!

Posted Image     Posted Image

Invision Power Services, Inc.

#10 Wolfie

Wolfie

    Don't get mad, get N*Raged!

  • +Clients
  • 12,452 posts

Posted 06 June 2012 - 12:33 PM

Hi, we would like if there were done some changes in the core files to make it more supportive of tools like for example the PHP optimization tool HipHop: https://github.com/f...iphop-php/wiki/

As it is now it's not possible for us to use this "right out of the box" due to some of the code you use. So we would appreciate it if you could look at the possibillity to rewrite your code in order to support tools like HipHop. Especially the use of eval() is problematic, we haven't really looked too closely into whether you would have to change other functions or not. (And..: http://www.blog.high...p-eval-is-evil/ )

Have you considered asking the PHP developers to remove the eval() function? That will ensure that all scripts will be compatible since no script would be able to have that command. While you're at it, ask the automotive execs if they'd be willing to live poor for a week. I'm sure that they'd be willing to spend only $1million during that week and then come back like, "Whew that was rough!"


But as far as I know there are other solutions than using eval, or isn't it? What would be disadvantages from switching from eval to another solution?

What other solution do you have in mind? Do you know of something that will perform the same function as eval() but without using the eval() function?

٩(͡๏̯͡๏)۶ Click here to browse or purchase IPS software. ٩(͡๏̯͡๏)۶
n-raged.com
- Dacity.Com

♪ Me and you ♪
♪ a two-man crew ♪
♪ side by side we're unified ♪
♪ and we will never be divided ♪

Spoiler

CLICK HERE AND VOTE IP.BOARD AS BEST FORUM SOFTWARE FOR 2013!!!





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users