Re:Learn C programming and the rest will come
by maxxxxx on Wednesday November 29, 2017 @10:41AM
(#15807606)
Good. What other languages are still being used that teach these concepts?
[ Parent
| on HN ]
Re:Learn C programming and the rest will come
by pjmlp on Wednesday November 29, 2017 @11:02AM
(#15807807)
D, Go, Ada, Rust, C#, Swift, Common Lisp, Eiffel, C++
Re:Learn C programming and the rest will come
by maxxxxx on Wednesday November 29, 2017 @11:05AM
(#15807833)
C# doesn't really. C++ definitely does. The others I don't know.
Re:Learn C programming and the rest will come
by pjmlp on Wednesday November 29, 2017 @12:24PM
(#15808739)
Sure it does.
- compiles to native code via ngen, mono, .NET Native, MDIL, IL2CPP
- has pointers in unsafe code
- has value types
- structs allow for layout control
- value types can be stack allocated, it also allows for alloca in unsafe code
- memory can be allocated outside GC via safe handles or marshaling services
- latest versions have support for zero allocation memory references
The only thing it doesn't do properly is to have global statics, but it can be worked around via a singleton.
Re:Learn C programming and the rest will come
by maxxxxx on Wednesday November 29, 2017 @12:34PM
(#15808873)
I wouldn't recommend using C# for learning these concepts. Unsafe mode exists but it's not very straightforward in my view. I don't think I could understand unsafe mode without prior knowledge of C.