Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I noticed that too. Unless you _ask_ for a script, they throw away the scripts they write.

They are particularly bad at complex multiline parsing. Writing all sorts of weird/crude python/awk scripts and getting confused in the process.

I wish they would use Perl6/Grammer or Haskell/Parsec or similar and write better parsing scripts.



For the non haskell folks like myself, what would that look like/ why is parsing better? Perl i get


Perl has powerful regular expressions, but it only goes so far. Doing multiline/nested structured parsing is too painful.

Perl6/Raku has built in grammers that can do that idiomatically.

If you have a couple minutes, give this a glance. It will give you an idea.

https://andrewshitov.com/2018/10/31/a-simple-parser-in-perl-...

I am no expert in haskell either. But parsec is similar in concept.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: