Originally posted by uid313
View Post
Announcement
Collapse
No announcement yet.
Ada++ Wants To Make The Ada Programming Language More Accessible
Collapse
X
-
- Likes 1
-
-
Originally posted by jacob View PostOf course if network services, among others, were written in Ada instead of C, we would have much less security problems and the Internet would be a lot better place, but it's too late for that now.
Originally posted by jacob View PostThe ecosystem (FOSS included) has moved on and none of the tooling, frameworks, runtimes etc. are Ada-friendly.
Since it looks like Rust now has all the momentum for safety or security-critical code,
Originally posted by jacob View Postmaybe the best way forward would be for it to incorporate those useful features from Ada that it's currently missing, mainly first class support for range types, generic modules and custom memory allocation (getting there with the placement operator?).
Comment
-
Originally posted by pkunk View PostIt is actually dangerous, hard to understand and weird:
Originally posted by pkunk View Post
Originally posted by pkunk View Post
Originally posted by pkunk View Post
Originally posted by pkunk View PostLast edited by pal666; 04 April 2020, 08:51 PM.
Comment
-
Originally posted by pal666 View Postor we wouldn't have internet at all(where are all those network services written in ada?)
Originally posted by pal666 View Postumm, wasn't that java? btw, why lack of ecosystem is problem only for ada, but not for rust?
Rust doesn't have an ecosystem problem.
Originally posted by pal666 View Postwhy not incorporate features into language in which all those network services are already written instead?
- Likes 2
Comment
-
If this is their understanding of the C/C++ binary operators, then I have no faith in their project whatsoever:
The difference is that && and || are short-circuit operators, which evaluate terms only as necessary, and & and | will unconditionally evaluate all terms.
Anyone who has written more than two C programs knows that the & and | operators are binary AND and OR operators, not logical operators. And && and || are the logical AND and OR operators. The result of (1&2) is 0, whereas the result of (1&&2) is true. The result of (1|2) is 3, the result of (1||2) is true.
Sheesh!
- Likes 1
Comment
-
The problem with Ada is not that scope delimiters are spelled "begins" and "end" instead of "{" and "}". The problem is that its requires an entire replacement of OS userspace runtime. See, most modern programming languages leverage the C-language OS userspace runtime (libc.so, MSVCRT.DLL, etc). Ada does not, which means someone has to write and maintain one for each and every OS out there. Without that, applications are not portable and without portability, you aren't going to have widespread adoption.
The C runtime is usually offered by the OS developer -- Microsoft and Apple offer their own C runtime for their OSes, GNU offers one for GNU/Linux and Google offers one for Android/Linux. Heck, Microsoft offers one for WSL, which could also be described as GNU/Windows. Who develops and maintains the Ada equivalent for those popular OSes? In each case, some organization is investing a lot of resources into developing and maintaining the C-language OS userspace runtime, and interestingly they distribute it for free with their OS.
You'll find the Go programming language is in a similar situation, except that Google invests in providing the Go runtime for a select few OSes. Again, the OS userspace runtime is distributed for free by the developer, this time with a free distribution of the language.
Comes along Ada, and the only people that develop the language runtime charge an arm and a leg in license fees and distribute under very restrictive commercial conditions. The only free alternative is the GNU gnat system, and it's hardly accessible or up to date with the latest kernel changes. It is no mystery why few developers choose Ada as their development environment and that mystery is not that it doesn't look enough like C.
Comment
-
Originally posted by usta View PostAs far as i know, in C++ it came with C++11 , Still in both of them they are optional and still some older compilers exist which devs need to keep their code more compatible.
I am still waiting that c and c++ 's 2020's standard became available and all new compiler sets them as default. But it looks like it will take about 10 more years to see that
In other words, the various fixed-width integer types have been mandatory parts of the C language for 21 years, and of the C++ language for 9 years.
If you depend on a compiler more than 21 years old for your target, it's unlikely you're worried about portability. On the other hand, pretty much everything in C++20 is implemented in the big three compilers as extensions before being accepted into the standard (by policy of the standards committee), so you'll find any new features available the day the standard is published. C21 not so much because Microsoft has yet to provide a C99 compiler, but the other guys are on top of things.
Comment
-
Originally posted by bregma View PostThe problem with Ada is not that scope delimiters are spelled "begins" and "end" instead of "{" and "}". The problem is that its requires an entire replacement of OS userspace runtime. See, most modern programming languages leverage the C-language OS userspace runtime (libc.so, MSVCRT.DLL, etc). Ada does not, which means someone has to write and maintain one for each and every OS out there. Without that, applications are not portable and without portability, you aren't going to have widespread adoption.
The C runtime is usually offered by the OS developer -- Microsoft and Apple offer their own C runtime for their OSes, GNU offers one for GNU/Linux and Google offers one for Android/Linux. Heck, Microsoft offers one for WSL, which could also be described as GNU/Windows. Who develops and maintains the Ada equivalent for those popular OSes? In each case, some organization is investing a lot of resources into developing and maintaining the C-language OS userspace runtime, and interestingly they distribute it for free with their OS.
Originally posted by bregma View PostYou'll find the Go programming language is in a similar situation, except that Google invests in providing the Go runtime for a select few OSes. Again, the OS userspace runtime is distributed for free by the developer, this time with a free distribution of the language.
Comes along Ada, and the only people that develop the language runtime charge an arm and a leg in license fees and distribute under very restrictive commercial conditions. The only free alternative is the GNU gnat system, and it's hardly accessible or up to date with the latest kernel changes. It is no mystery why few developers choose Ada as their development environment and that mystery is not that it doesn't look enough like C.
- GNAT Pro, the paid commercial version (note that you pay development licenses, not runtime licenses) which allows you to do what you want commercially speaking.
- GNAT Community Edition, for free and under GPL (same compiler, but less tools and no support). If you link with this runtime, your software will be tainted by GPL. If you already do free software (GPL), that's not an issue.
There's a third distribution of GNAT which is the GNU's GCC one. GNAT being a GCC front-end, AdaCore synchronizes with the GCC project once a year. They take latest changes from GCC, and they commit their Ada changes to GCC. And this distribution has a special license, the "GNAT Modified General Public License", which is the GPL with the exception of allowing to link with the runtime without being tainted by the GPL. So you can do proprietary software with this version. And it is available in most distributions that package GCC (debian, fedora, raspbian, cygwin, ...).
The three versions contain the same software (compiler and runtime), but vary in license terms and the GNU's version can lag by one year compared to AdaCore's versions (but one can live with that).
There are other Ada compilers but I don't know them, so I won't talk about them. GNAT already covers a lot of hardware targets.
Comment
-
Originally posted by phuclv View Post
It's only dangerous when it returns an lvalue. If it returns nothing then we can just use i++ alone in a single line and no problem would occur
EDIT: As a side-note, Rust removes operator altogether, which I'm an avid fan of: https://github.com/dtolnay/rust-faq#...ment-operators
- Likes 3
Comment
Comment