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

Is it? (I honestly have no idea about Lisp.) It isn't just about being able to do stuff at compile time: In Perl's case, as I understand it, you can't determine if a string of text is a valid (in the sense of generating an AST!) Perl program without executing it. This precludes things like reliable syntax highlighting.

Languages can include meta-programming/macro facilities without effecting whether or not the parser can do its job; I am fairly certain that Rust's macros are an example of this. Python, as a more dynamic language, also includes metaprogramming facilities (metaclasses, decorators) but IIRC, can still be parsed without needing to simulate a Turing machine.



> Is it? (I honestly have no idea about Lisp.)

In Lisp you can modify the read table at run time, so you can do whatever you want. The functions the reader calls when it comes across '(', ')', ' ', and every other character are all completely customisable.


For Rust, yes, you're right. That's why the ! exists in the invocation, the parser can skip over the stuff after it and it's fine.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

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

Search: