Difference between revisions of "Holywar"
m (→Q&A) |
m |
||
Line 1: | Line 1: | ||
The page is dedicated to holywars about Pascal language (any kind of pascal included). | The page is dedicated to holywars about Pascal language (any kind of pascal included). | ||
− | If you're Pascal developer being involved into a next flame about Pascal language, you're encouraged to use the page. | + | If you're Pascal developer being involved into a next flame about Pascal language, you're encouraged to use the page. Pascal has something of a stigma as an "educational, and therefore weak" language, but it has nothing in common with a real life. |
== Why do we use Pascal == | == Why do we use Pascal == | ||
Line 9: | Line 9: | ||
Often programmers are free to choose their tools, especially then coding as a hobby (rather than for their living). | Often programmers are free to choose their tools, especially then coding as a hobby (rather than for their living). | ||
Lots of Pascal programmers choose the language because of: | Lots of Pascal programmers choose the language because of: | ||
− | * modern Object Pascal is simply one of the most productive languages and it can be used for almost everything | + | * modern Object Pascal is simply one of the most productive languages and it can be used for almost everything. |
** [[FPC_Applications/Projects_Gallery]] | ** [[FPC_Applications/Projects_Gallery]] | ||
** [[Projects_using_Lazarus]] | ** [[Projects_using_Lazarus]] |
Revision as of 23:48, 27 February 2010
The page is dedicated to holywars about Pascal language (any kind of pascal included).
If you're Pascal developer being involved into a next flame about Pascal language, you're encouraged to use the page. Pascal has something of a stigma as an "educational, and therefore weak" language, but it has nothing in common with a real life.
Why do we use Pascal
(if you don't use (Object) Pascal, please don't edit the section)
Often programmers are free to choose their tools, especially then coding as a hobby (rather than for their living). Lots of Pascal programmers choose the language because of:
- modern Object Pascal is simply one of the most productive languages and it can be used for almost everything.
- well structured modular language
- safe and clean syntax, great for team work
- fast compile-time
- Object Pascal have really nice oop/interfaces implementation
Q&A
Q: Why there're so many limitations on what expressions i can use in "for" and "while" operators? Why can't i define a really complex type in one line?
A: to force you to create maintainable and readable code
Q: Pascal doesn't allow to specify complex types without intermediate types. I.e. "an array of pointers to a function that accepts 2 ints and returns a pointer to function that returns a float"
<c>
float (*(*a[10])(int, int))()
</c>
A: Has it any advantage to define no intermediate type? <delphi> type
TFloatRetFunc = function : single; TSomeArray = array [0..9] of function (a, b: Integer): TFloatRetFunc;
</delphi>
Advantages over C/C++
- no preprocessor (better code reading and understanding)
- no hardly readable and poorly debugged STL