Recent submissions

Comment · 7 years ago
Can your code detect this case and at least show a warning? I realize it’s extra LoCs, but sitting here and tapping the damn phone with no feedback is not much fun :)
Comment · 9 years ago
That's somewhat uncomfortably close to dox'ing.
Comment · 16 years ago
Hmm, OK. Try a different example - the compiler should allow the following code without any warnings:

  void foo(int * a) { }

  void bar(int * b) { foo(b); }

  void baz(const int * c) { bar(c); }
Point being is that the compiler should warn of the const violation based on whether a function argument or a class member is getting touched in the function code.

In fact, the example above is more relevant, because what I am ultimately aiming for is to not need to make member functions const, and yet be able to call them for const class instances.

Comment · 16 years ago
With regards to the const part of the discussion -

Does anyone knows any research or even a state of affairs of const inference in language design?

The idea is similar to type inference whereby a compiler (or some other tool in a chain) would take care of understanding which arguments/variables/functions are going to be const and generate appropriate warnings based on that. For example,

  void foo(int * a) { (*a)++; }

  void bar(int * b) { foo(b); }

  void baz(const int * c) { bar(c); }
A compiler would generate a warning when baz function, because foo() includes a non-const operation on its argument, bar() is non-const for the same reason, and so it cannot be called for a const pointer.
Comment · 16 years ago
Foreign language was a mandatory class in all Soviet schools. Vast majority of schools taught English, few schools had German and even smaller fraction had French.
Comment · 16 years ago
Anyone else sees this as an opportunity to design a better high-performance gaming UI?
Comment · 16 years ago
Including the needs for backing up confidential data? Hm.
Comment · 16 years ago
> * Required

> Looks like you have a question or two that still needs to be filled out.

If I want to skip a question, I should be able to do so.

Comment · 16 years ago
> mpjamesmoore: @doctorow "let the consumers decide what they want" is my position.

What a hypocrisy.

Determining what consumers wanted was the goal of having public consultations. It worked out that consumers didn't want what the (heavily lobbied) government officials wanted, so whatever the public said was quietly ignored and they proceeded pushing for a bill that they had.

"Let the consumers decide what they want" my ass.

Comment · 16 years ago
My primary experience stems from working for a Canadian-based company with 200+ developers (located in Canada), 80% of which were Chinese programmers. The CTO of the company was Chinese and he had an obvious preference for hiring graduates from his own university and/or country. Top picks, but few with more than a couple of years of non-Chinese experience.

Just to emphasize - EIGHT PERCENT of my coworkers came from Chinese software development companies and they quite naturally brought their work ethics with them. My four years in this company is a basis for my original comment.

If it's not obvious, I am not talking about Chinese nationality, I am talking about developers with Chinese way of working in a software development environment. The way that revolves around never saying No to the boss, which in turn is deeply rooted in their cultural heritage. If the project manager says that the bug needs to be fixed today, it will be fixed today. Meaning that it will no longer be reproducible. How it will be fixed and what else is going to broken along the way is secondary. This will create another bug that can be taken care of later in the same manner.

And this was the company that developed sophisticated networking software including their own embedded OS down to the kernel level. Moreover most of these guys were perfectly capable of NOT cutting corners and doing a splendid coding job if forced. But god forbid if they would ever do it on their own accord. Everything was always done in a rush and sketchy-patchy way. I don't have any other explanation except for it to be a cultural thing.

You can certainly call it a horseshit and a casual racism if you'd like. However that's how things are in reality.

Comment · 16 years ago
Cultural thing - sure, but keep in mind that professional programmer with 10+ years of experience typically can do more in 9-to-5 than your average college graduate on a 24/7 schedule. He needs to be paid appropriately though, which is something that a "startup" full of college kids may not be able to afford.
Comment · 16 years ago
> Chinese like everything simple, doesn't have to be too exact

Oh, don't start. "I don't know what the bug was, but I fixed it." - verbatim quote. This was a mode of operation of disturbingly large number of Chinese devs I have worked with. After several bugfixing iterations of this kind it was easier to throw the code away and redo it from scratch than to understand how that managed to work. So, yeah, "don't have to be exact" is certainly there.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton