×

Announcing: Slashdot Deals - Explore geek apps, games, gadgets and more. (what is this?)

Thank you!

We are sorry to see you leave - Beta is different and we value the time you took to try it out. Before you decide to go, please take a look at some value-adds for Beta and learn more about it. Thank you for reading Slashdot, and for making the site better!

Comments

top

Is D an Underrated Programming Language?

RoLi Re:D is a regression (383 comments)

Another point:

The preprocessor-haters always only offer theoretical arguments ("it supports conditional compilation!") but they never post real code.

Why?

Very simple:

First, even they have a hard time to learn C++ templates and all the other highly complicated replacements.

Second, even when you know about it, using templates is pretty hard actual work. You don't do that kind of work for a posting in a discussion-forum.

Third, when you do the work and compare all that highly sophisticated template-code with the preprocessor-stuff it is supposed to replace, you will realize that just using the preprocessor is so much easier that it is almost comical.

about a week ago
top

Is D an Underrated Programming Language?

RoLi Re:D is a regression (383 comments)

You only offer emotional arguments ("a blight", "relic from the past", etc.).

Yes, the preprocessor does not work at the same level as the compiler - and that is the good thing about it because it gives you leverage about what the compiler sees and it allows you to guarantee that the logic outside the #ifdefs is untouched by any changes - therefore you get much higher quality/stability.

Your example with the untested feature can be solved by isolating the crazy untested code in its own module, and simply *not enabling that module in the build scripts*.

So you have to have modules for every tiny feature?

And all that bloat and overhead just to satisfy your emotional sense of aesthetics?

So to avoid 2 lines of "ugly" code (#ifdef / #endif) you need to create a module, adapt the build-system, etc. etc.?

And we have not even gone into some "advanced" stuff like

#if defined(TEST_1) && defined(TEST_2)

So easy to do with the preprocessor - how do you do that with modules? Create a third module that contains just the code that is needed when both other modules are included? And hide everything in the build-system so that nobody can find and/or debug it?

And again, why all that overhead when all you get is a program that is slower, uses more RAM and (yes!) is much more difficult to understand and debug?

Ideally, the buld-system should not contain any logic. All the logic should be in the source-code.

And of course your "aesthetics before function" - approach may be acceptable on the PC where all that bloat does not matter much. But it is a absolute no-go in embedded-systems programming. Just two years ago I have worked in a project where we had only 128 KB (yes, that is kilobytes) of RAM. And we had to frequently cut the bloat to stay under that limit.

In that situation you forget about "modules", object-orientation and all that other buzz-words from the ivory-tower pretty fast.

So what do you do when you have a new revision of a circuit board that has a different pin-layout?

Do you throw away everything (several man-months of programming and testing) and create a sophisticated module-system that will create numerous other problems and limitations to satisfy aesthetics?

No: You use the preprocessor to add the new stuff while still avoiding any change for the old, so the old stuff can still be used and tested and (more importantly) you can compare the old with the new.

about a week ago
top

Is D an Underrated Programming Language?

RoLi Re:D is a regression (383 comments)

D supports conditional compilation [dlang.org]. And has features to accomplish any other sane use of the preprocessor, but in a cleaner way as first class language constructs.

As I explained to the other guy, it does not help against syntax errors. It does not allow for strict separation of features.

Yeah, but should you? That's basically writing code in a feature-poor unstructured string manipulation meta-language.

I certainly agree that the C-preprocessor is a poor language. But the problem lies in the lack of features of the preprocessor, not the fact that it is a preprocessor.

So yes, it is a poor language - but that is still better than no preprocessor at all.

about a week ago
top

Is D an Underrated Programming Language?

RoLi Re:D is a regression (383 comments)

You don't need a preprocessor to have conditionally compiled code.

Yes, you do.

Because programmers make mistakes and "crazy_new_untested_code.c" may include everything from normal software bugs to syntax errors.

A preprocessor is the only way to ignore syntax errors.

C# supports your use-case (producing different code depending on symbols being defined)

Don't lie. The use case was:

the program will still compile and work just fine, no matter what crazy things the new guy who was hired to program "crazy_new_untested_code.c" does.

If the guy checks in some syntax error in C#, it will no longer compile. End of story.

With a preprocessor you can be absolutely SURE that some disabled code does not influence your program. And if the programmer only has write access to "crazy_new_untested_code.c" he does not even have a theoretical possibility of breaking it.

I have not seen any supposed "replacements" of preprocessors that can do that. These "replacements" are full of unrealistic assumptions straight from the ivory tower. (for example your assumption that all code that is checked in is syntactically correct)

The preprocessor makes code harder to understand, very hard to parse, and makes things like refactoring tools, static analysis tools, etc. much harder than they should be.

Preprocessor-code is much easier to understand than C++ templates. (Yes, I admit it - I have once looked at these template programming and I have long since forgotten about C++ templates) In fact the basic #ifdef structure is straightforward.

Another use-case:

typedef struct {
one int;
#ifdef GREATFEATURE
two int;
#endif
} mystructure;

In that case mystructure will be just as big as actually needed. Can you easily provide the same functionality with C++ templates? Probably not, you probably have to check some book and forum to come up with the code - if it's possible at all, which I'm not sure.

And that is the reason why C is still king for embedded software.

about a week ago
top

Is D an Underrated Programming Language?

RoLi D is a regression (383 comments)

D may be "nicer" in some niche-aspects, but they destroy all that by dropping the preprocessor. Yes, I know that the snobists don't like it and think it's "outdated". Yet the preprocessor offers something that no other language feature offers: Because the preprocessor "creates" the C-code, you can do *everything* with it.

For example:

#ifdef UNTESTED_FEATURE
        #include "crazy_new_untested_code.c"
#endif

You know what?

If you unset UNTESTED_FEATURE, the program will still compile and work just fine, no matter what crazy things the new guy who was hired to program "crazy_new_untested_code.c" does. He still can check in his work, testers can try it out by setting UNTESTED_FEATURE, etc.

This is the reason why we keep using C after all these years. It's the only (major?) language with preprocessor.

about a week ago
top

Exoplanet Hunting NGTS Telescope Array Achieves First Light

RoLi Re:Not much aperture (19 comments)

Ground-based telescopes are "as good as Hubble" for some applications, better at some and worse at others.

Hubble is still one of the best telescopes ever.

For example the "Hubble deep field" would not be possible with a ground-based telescope, regardless of how good the software may be.

about two weeks ago
top

KDE Frameworks 5.3 and Plasma 2.1 – First Impressions

RoLi Re:Wow, that actually looks decent (84 comments)

KDE has always had the kitchen sink mentality and it has suffered for it. All those buttons, menus and settings are great for people who want to change every last setting but they're a usability nightmare. I believe the reason that GNOME is the default in most Linux dists, particularly enterprise ones is because KDE provides far more opportunities for users to screw things up and raising support tickets. That's the reason it has lived in GNOME's shadow all this time.

Usability depends on the user. I like it when I can customize it to fit my needs and there is absolutely zero need to have another Gnome with a different name.

I can't handle Gnome because it is a usability nightmare for me.

about two weeks ago
top

KDE Frameworks 5.3 and Plasma 2.1 – First Impressions

RoLi Re:Wow, that actually looks decent (84 comments)

Similar story for me, I've bin a big fan of KDE 1 through 3, I delayed KDE 4 as long as I could and even after all those years it's still bugs, bugs, bugs.

Yet KDE is still the best desktop environment out there - but the lesson I have learned (and you probably too) is to only use KDE but not use any critical KDE applications. I also used KMail in KDE 3 but I migrated to Thunderbird because I have heard so many horror-stories about KMail in KDE 4.

Let's hope KDE 5 becomes more stable.

about two weeks ago
top

Russia Says Drivers Must Not Have "Sex Disorders" To Get License

RoLi Re:Insanity (412 comments)

Not really, it was Hitler who removed the "unnatural"-clause in the homosexuality-paragraph 1935. That's no big surprise because most of his buddies were homos. Yes that is correct: before 1935, homosexuality was considered unnatural and you could lose your civil rights, afterwards it was just an ordinary minor crime. A big step for the LBGT movement.

And if you don't believe me, just look up the laws on Wikisource. This is not some conspiracy-nut war-propaganda, it's a law that was put on the books and everybody can check it - if they are interested in the truth, which most aren't.

The homos only got retroactively "victims" of the Nazis in the 1970s.

He also was a vegetarian and a fan of animal rights. A real progressive.

about three weeks ago
top

Russia Says Drivers Must Not Have "Sex Disorders" To Get License

RoLi Re:Here it is. Hope you can read Russian. Re:sourc (412 comments)

Exactly. Basically the Russians were greeted with open arms in Crimea, there was not a single death during that "invasion".

Compare that to the mess of Iraq, Afghanistan, Syria, Libya, etc.

But maybe that is the problem the Americans have with Crimea. They only stop nagging and criticizing when the country is in ruin and blood runs in the streets. They would love to drop some bombs on Crimea to show those bastards good old democracy.

about three weeks ago
top

Russia Says Drivers Must Not Have "Sex Disorders" To Get License

RoLi Re:They (well some of them) are mental disorders (412 comments)

It's only a disorder if it has a major negative impact on a person or society.

Well they have a high risk of becoming a murderer (about half of serial killers are homosexuals, which is an overrepresentation of about 1000-2500%) of becoming murdered (by aforementioned killers), of suicide and of sexually transferrable diseases.

To say that this is caused by "discrimination" is just flat out wrong, because the murder-rate tripled during the "sexual revolution", and did not decrease. Arguably a virus like AIDS could not have spread so wide and far before it as well. So the "reduction of discrimination" (which in the West has become special privileges already) actually decreased the homo-life expectancy, both because of murder and diseases. So it's the exact opposite of what you are claiming: Discrimination actually protected them from themselves.

People who are not brainwashed by Hollywood (for example the good people of Russia) know that. And now when the West has declared war on them, there is no longer a reason to suck up to the West.

Good for them.

about three weeks ago
top

What Language Will the World Speak In 2115?

RoLi Re:Few you say? (578 comments)

What do you mean by 'decadent' here?

All Westernized peoples are incapable - despite all the ressources available - to replace themselves.

If a plant does not grow despite all external needs are met then we say it is sick, wouldn't you agree?

This sickness exists only for the last couple of generations, so it's clearly not genetic and therefore cultural, i.e. decadence.

Why should the 'decadence' of a language stop you from using it

Because it corrupts the children, plain and simple. It is the difference between your children and especially the daughters "seeking careers" (i.e. the decline or extinction of your family-line) and sleeping around (i.e. using unhealthy anti-baby pills, abortions, risk of sexual diseases) or starting families (i.e. the growth and survival of your family).

Just look at the USA: The founding population will become a minority in about 20 years. Are the people concerned about that? No, they even cheer on their own destruction.

In the 1960s, the murder-rate tripled and rapes and other crimes increased similarily. Are Americans concerned about that? No, they think the 1960s was progress and good. They don't care about their women being raped and murdered. In fact they even hide the identities of the perpetrators and concentrate on fake rape hoaxes instead.

The US constitution starts with "We, the people [..] and our posterity", but Americans don't care about their posterity anymore and the US has been turned into an "idea-nation", i.e. no nation at all.

Peoples willing to survive will only be able to do so when they distance themselves from Western mainstream culture and a different language is one way of doing that. There are other ways (religion, ideology, etc.) but a different language makes it much easier.

if it helps you pass your message across clearly, and if it does so better than many other languages because of its rich vocabulary?

The question is, is that advantage really worth all the above problems? When your daughter is depressed because of the anti-baby-pill and is becoming a drug addict because of it (I'm of course talking about 100% legal drugs from your doctor) is a job with a little bit more salary really worth that? There are millions of women in the US who are chronically depressed and are on drugs. And even if they can hold a good job for quite some time, may their drug addiction, their mental instability and their general unhappiness also endanger the "good job" they hold?

Millions of women take hormones to make them sterile and other drugs to combat the side effects of these hormones. And people don't question that, they say it's normal, that it's "liberating".

If you would do something like that to farm animals you would get jailed for abuse.

about three weeks ago
top

How Civilizations Can Spread Across a Galaxy

RoLi Re:How? (272 comments)

Voyager was not designed to go fast, so going 50 times faster is not as hard as it sounds.

about a month ago
top

How Civilizations Can Spread Across a Galaxy

RoLi Re: (272 comments)

"One AU is about 1.5e11 meters."

So you propose an environment that is baked 24/7 with the Sun at the zenith at all times? And you claim that that is desirable? Humans could only survive on that with pretty heavy airconditioning.

"If it was made of metal 1 cm thick"

Right. And it has to be airtight, it has to be somehow able to support plants, houses and streets - and withstand a constant bombardment of micrometeorites. All that on 1cm.
And it has to rotate at enormeous speeds to create gravity (which would not work at the poles anyway, so the poles would fall into the Sun).

"you would only need to dismantle two earth sized planets"

OK, then you have a huge sheet of 1cm thick bare metal. How many planets do we need to actually do something with it? Growing plants needs a little more than 1cm of soil. So the soil alone would take a couple of planets.

about a month ago
top

How Civilizations Can Spread Across a Galaxy

RoLi Re: (272 comments)

Currently we are covering the Earth with greenhouses because (drumroll) they provide a better (yes, I said it) environment for plants than nature does.

In 400,000 years, one can imagine most of the Earth covered by greenhouses.

Think about that for a moment.

So of course any space colonization will be based on greenhouses and not on terraforming or any other such nonsense.

about a month ago
top

What Language Will the World Speak In 2115?

RoLi Re:Few you say? (578 comments)

If what you write were true, it would have happened a very long time ago.

But it didn't. Why?

Because a language is basically like a uniform that marks "us" vs. "them". It creates group cohesion and community.

To be exact any non-English language, because English is spoken by anybody anyway, therefore does not give any identity.

English-speakers everywhere (be it a native US or a cosmopolitan European or Chinese) are having very few children and are living in a destructive "pop culture" that is not very conducive for large families.

Non-English-speakers on the other hand are isolated from "pop culture" a lot better, therefore can have more stable and larger families - and are growing in all countries.

That trend can be seen everywhere. Traditional English speakers will be a minority in all the major English-speaking nations (US, UK, Australia). Maybe they can hold out and maintain a majority in New Zealand.

A good example are the Amish: Just 200 Swiss/Germans came to America and they did NOT assimilate. 200 years later they are 250,000 and still doubling every generation. That is only possible because they are isolated from the majority culture - and their ancient German dialect is one of the things that helps them do that: If the children don't understand Lady Gaga, they won't be influenced by her.

And that is the reason why no language replaced all the others: When the dominant culture/language becomes decadent, people have no other choice than to push other cultures/languages in order to survive.

about a month ago
top

How We'll Program 1000 Cores - and Get Linus Ranting, Again

RoLi Re:Linus Lock (449 comments)

True enough, but of course, that's not what happens, so... Effectively -- of course they can and do switch roles when memory is shared -- one is monitoring your ethernet, several are kicking in and out of httpd threads and/or processes, and so on for hundreds of OS tasks, and if you're like me, more than a few users tasks as well. For every task within a process that isn't hidebound by disk (and there are already a lot of them) having an additional available core is a very worthy thing.

Yeah, that's the theory.

In real life, my 6-core, 32 GB-RAM box swaps even the tiniest process to disk (which is of course SSD) so that even opening the KDE-menu takes ages after some time.

I think programmers are just too lazy to really use the hardware (which exists already today). For example the smart thing to do would be to make sure that the user interface is never swapped to disk. That would reduce available RAM only slightly but would dramatically improve performance.

But of course nobody does it because 1) their mind was closed by academia which preaches inefficient but supposedly programmer-friendly things like OO, scripting, one-size-fits-all frameworks etc. and 2) because everybody is hoping to squash every problem with faster hardware.

So it won't happen.

In 20 years, we will run huge machines that will slow down everything by running as much as possible on Python and Javascript because that's what is hip and performance be damned. (Isn't the Windows 8 framework - user interface based on CSS and Javascript already?)
Performance will probably suffer because instead of having fonts on disk (how 20th-century is that?) our computers will load fonts from Google about 10 times per hour.

about a month ago
top

NSA Says They Have VPNs In a 'Vulcan Death Grip'

RoLi Re:all countries do this espionage (234 comments)

No. I live in a small country (less than 10 Mio pop.) and we have only a rudimentary espionage agency that only seems to exists as an excuse (they never did anything notable - ever).

And you know what? No false flag terror attacks, no privacy invasions, no nothing.

about a month ago
top

NSA Says They Have VPNs In a 'Vulcan Death Grip'

RoLi Re:NSA-resistant VPN's were done before... (234 comments)

If "It's not rocket science" then how are the security services getting back to the end users over generations of networking products?

Not by "breaking" VPN.

They compromised the hardware (got it while it was shipped) or tried dictionary attacks. The former will only work when they already read your snail-mail and the latter will only work when you use weak passwords.

They don't have some magic pixie dust that can hack into everything.

about a month ago
top

NSA Says They Have VPNs In a 'Vulcan Death Grip'

RoLi Re:Sigh. (234 comments)

Exactly.

Non-technical journalists who have no idea write these scare-articles because they have to turn everything into some alarmist nonsense.

about a month ago

Submissions

top

South African Health department blames Excel for loss of 4 million

RoLi RoLi writes  |  more than 2 years ago

RoLi (141856) writes "The chief of the health department of the South African province of Limpopo, which has a population of over 5 million people, blames Excel for the loss of the equivalent of $4 million.

A committee has found irregularities in office supplies in the fiscal year 2009-2010. This was justified by declaring that the department had so much to manage that the result would no longer fit into Microsoft Excel. However, she admitted that their current asset management system was inadequate.

The committee seemingly found this explanation credible, because the only consequence of the affair are 13 million Rand (~$1M) for a new "asset management system" for the health department."

Link to Original Source
top

Austria: Cardinal Puts Preaching Ban on Imam

RoLi RoLi writes  |  more than 2 years ago

RoLi (141856) writes "Imam Shaker Assem will no longer be allowed to hold Friday-prayers in the Afro-Asiatic Institute (AAI), which is a catholic endowment organization in Vienna, because he called for reinstatement of the Califate, demanded the death penalty for adultery and rejected Israel's right to exist."
Link to Original Source
top

Will Microsoft-IIS become legacy software?

RoLi RoLi writes  |  about 3 years ago

RoLi (141856) writes "The share in Japan, Germany, Russia and many other countries already lies below 4% for many years. But also traditionally Microsoft-friendly countries can turn away from IIS, for example in the last 10 years, the share in France fell from 35% to 5%, in Brazil and Taiwan from over 45% to 15% and in India even from 65% to 18%.

In more and more countries, Microsoft will face the problem that third parties (webhosters, IT-departments within companies, fleelancing programmers, etc.) don't even offer support for their products and the know-how is lost because Microsoft-webservers are seen more and more as a legacy-technology."

Link to Original Source
top

12,000 dollars for a lemonade, or: Bilingualism in

RoLi RoLi writes  |  more than 3 years ago

RoLi (141856) writes "On that day, Michel Thibodeau flew from Toronto to Ottawa (both English-speaking cities in Canada) and ordered 7up in French but got served Sprite. After having used the same trick to win a lawsuit against the same airline, he sued again for 25,000 dollars. Is it a justified indemnification for psychic damages or is it a type of "low intensity conflict" or a "civil war with juridical means" in which everybody, including judges, want to further the interests of "their side"?"
Link to Original Source
top

Why there will be no IPv6 transition

RoLi RoLi writes  |  more than 3 years ago

RoLi (141856) writes "The mistake in the design of IPv6 is not really in the technology. The mistake does not lie in the design of the protocol itself, but in the incompatibility of the addresses. Because it is not a technological but a administrative problem, there will hardly be a technical solution for it.

The future is hard to predict and it will be hard to predict how long IPv4 will live, but one thing is sure: What ever will come after it, it won't be IPv6."

Link to Original Source

Journals

RoLi has no journal entries.

Slashdot Login

Need an Account?

Forgot your password?