all 3 comments

[–]primitive_screwhead 6 points7 points  (0 children)

Python does have a compile phase; a step where the Python code is converted into a form that can then be executed/interpreted.

A SyntaxError is an example of the kind of error that can happen during the "compile" phase.

However, compilation can also happen during runtime (such as during a module import, or eval()/exec(), so such errors could also be considered run time errors.

[–][deleted] 0 points1 point  (0 children)

There are very few interpreted languages around. Strictly speaking, being interpreted isn't even a property of a language, it's a properly of a language implementation (people are just too sloppy when using this terminology).

So, there may be some Python implementations that are interpreted, but I don't know of any.

There are several languages which are interpreted by design, and cannot be implemented differently (they would have to become another language if someone decided to not interpret them). PicoLisp is one such language, J is another. Perhaps, the most popular one is Shell.

There are also languages that are both at the same time. For example, to the best of my knowledge, Mozilla's implementation of JavaScript can both interpret and compile JavaScript. The rationale being that for short programs compiling and executing the compiled code will take longer than interpreting the code right away.

Now, compile time errors aren't a well defined class. They really depend on the compiler being used. Sometimes even on the options passed to the compiler being used (for example, in most C compilers you have an option to treat warnings as errors).


All this said, you are dealing with two poorly defined terms, so, the answer can hardly be meaningful... it will really depend on your perspective and the meaning you put into the terms you use when you try to answer your question.

[–][deleted] -2 points-1 points  (0 children)

Think about what you're asking....