3 ms·
Forgive me, is swift not in the c family? I could have sworn that it was, but I'm not overly familiar with it.
by danielvaughn 4y ago
Forgive me, is swift not in the c family? I could have sworn that it was, but I'm not overly familiar with it.
- kibwen 4y agoLots of languages, including Java and Javascript, have been described as being "in the C family", but this papers over a whole lot of important details. Swift is a low-ish-level imperative-ish language with C-ish syntax.
- obliquely 4y agoYou could just as plausibly say that Swift is a high-ish-level functional-ish language with a modern syntax. Whereas C blows up at runtime, Swift nags-and-whines at compile time - in that way it's very unlike C. All that said "in the C family" is highly ambiguous at best...
- BuckRogers 4y agoWhen I hear that C family languages are no longer to be utilized, I’m assuming they mean memory unsafe options. C & C++. Everything else is just as good of an idea as the next. C family is the most successful language paradigm in the history of software. Abandoning those constructs would be suicide. Nothing would get done.
- pyth0 4y agoI would think it is. It runs on the Objective-C runtime and has interop with it and C.
- SimDeBeau 4y agoIt was built to interop well with obj-c which is a c superset, but it’s not a c-family language more than something like c# or kotlin
- jcranmer 4y agoAs I would use the terminology, the C family of languages generally corresponds to languages that follow C's general syntactic rules, such as how you represent operators (particularly = is assignment and == is equality), curly braces for blocks, and to lesser degrees, making distinction between statement/expression, or having types precede variable names. "C-like", by contrast, is a language whose semantics follow closely to C, and in particular, the C-with-extensions languages like C++ or Objective-C are usually going to fall into this category.