News for hackers. Stuff that matters.
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by tshadwell on Thursday May 22, 2014 @01:20PM (#7784953)
Perhaps I am looking at this wrong, but I don't see why you would use a Markdown parser written in PHP if you're looking for speed. Case in point the parsedown system is fast because it has heavy use of regular expressions, which parse faster and run faster than the host language-- it already relies on a language other than PHP to essentially emulate parts of a well-written lexer.

As debaserab2 says[1], if you are looking for speed, consider PHP extensions.

In my opinion, writing a system like this is a misappropriation of PHP, which evolved from and works best as a hybrid templating/scripting language. It becomes a powerful development platform when its extensive library of C functions is used to do most heavy lifting.

[1] https://news.ycombinator.com/item?id=7784219

Re:Show HN: Fast and Extensible Parser for Markdown in PHP by NaNaN on Thursday May 22, 2014 @04:41PM (#7786368)
If someone has done it well without compiling C library, why don't you try it (on a shared server, maybe)?
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by tshadwell on Tuesday May 27, 2014 @02:41PM (#7806085)
I don't understand what you mean. Could you also explain the negativity around this comment? I didn't think it was a badly voiced opinion, and karma is not meant to be used to show how much you agree or disagree with someone.
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by NaNaN on Wednesday May 28, 2014 @11:29AM (#7810743)
I had no right to downvote your reply. (even now) ;) Please take it easy. I just want to say that using C library is not always preferred.
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by tshadwell on Wednesday May 28, 2014 @11:48AM (#7810866)
I agree, but I did not mean to make any sweeping statement in that regard, but in the case of a standardised markup like markdown, there are already suites of field-tested C libraries that provide much better speed than this library would; for markdown content, this provides a better experience for your users.
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by NaNaN on Wednesday May 28, 2014 @07:46PM (#7813760)
Agree, too. Well, plain text sucks. So I like to use smiley symbols now. ;-)
Re:Show HN: Fast and Extensible Parser for Markdown in PHP by tshadwell on Friday May 30, 2014 @02:41AM (#7820580)
:¬)