Deutsch English Français Italiano |
<20240401111552.00006ddc@gmail.com> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: John Ames <commodorejohn@gmail.com> Newsgroups: comp.unix.shell,comp.unix.programmer,comp.lang.misc Subject: Re: Command Languages Versus Programming Languages Date: Mon, 1 Apr 2024 11:15:52 -0700 Organization: A noiseless patient Spider Lines: 50 Message-ID: <20240401111552.00006ddc@gmail.com> References: <uu54la$3su5b$6@dont-email.me> <87edbtz43p.fsf@tudado.org> <types-20240401151149@ram.dialup.fu-berlin.de> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Injection-Date: Mon, 01 Apr 2024 18:15:55 +0200 (CEST) Injection-Info: dont-email.me; posting-host="6e54db6547ba0cd3cfb65d52cc115a0b"; logging-data="2740188"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19jwYNQ0/dJ2pKcPUevrJUZ9BYVqspbZ2M=" Cancel-Lock: sha1:VeZb9MLS83OW2vCwLr7VT4vVP4Y= X-Newsreader: Claws Mail 4.2.0 (GTK 3.24.38; x86_64-w64-mingw32) Bytes: 3784 On 1 Apr 2024 14:16:33 GMT ram@zedat.fu-berlin.de (Stefan Ram) wrote: > In a non-scripting programming language, the types often are > based on hardware, like "16 bit integer", and typing is often > handled in a static and rather strict way. Higher types, like > strings whose size can change at run time, are often missing. Notwithstanding the fuzziness granted by the use of "often" here, this doesn't seem like a terribly accurate assessment. Lots of compiled/ "non-scripting" languages - *however* you define that - have dynamic strings; even C++ provides that as part of the standard library (admittedly, not as a basic language construct, but that's C for you - *every* data structure is essentially pointers in a trenchcoat.) AFAIK it's much rarer to *lack* that capability; C does, for aforementioned reasons (although you can certainly roll your own,) O.G. Pascal did (as a hideous misfeature,) probably a few other current systems languages... but not many spring to mind. It's also not terribly true that "non-scripting" languages are pre- dominantly statically-typed. It's more common, certainly, but there are still a number of compiled applications languages with some kind of dynamic support. And while the division of number types into floating- point and integer is very frequently the case, most language standards don't specify word sizes that strictly (even in C, stdint.h wasn't introduced until C99 - which lead to headaches of its own, as anyone who's tried to run old code that makes assumptions about sizeof(int) on targets that break those assumptions can attest.) Plenty of "non- scripting" languages include or can be extended with support for arbitrary bignum types, as well. > Scripting languages handle the memory for you. In a scripting > language, you cannot call "malloc" to obtain the obligation to > free this piece of memory exactly once in the future. They are > garbage collected. And while this is pretty true of scripting languages, it doesn't make for a good point-of-contrast with "non-scripting" languages; *piles* of them include support for automatic memory management, and some (outside of the C family) don't even include facilities for doing it "by hand." Overall, this seems like a very narrow and C-centric view of programming language design - and while C is definitely *my* language-of-choice for application development,* let's not pretend it's the absolute be-all and end-all, as if there *could* be such a thing in a field as vast and diverse as this! * (Funnily enough, for a lot of "scripting" type jobs, my go-to is actually a compiled language - FreeBasic.)