Hacker News new | past | comments | ask | show | jobs | submit | bradtgmurray's comments login

That looks a lot like C to me, which I wouldn't call a dynamic language.

  typedef struct Foo {
    int a;
    int b;
  } Foo;

  Foo f = (Foo) { .a = 1 }; // This will initialize b to zero.


Isn't it funny how C has so many ways to accomplish the same thing. Why did you use a typedef with a tag?

  typedef struct {
    int a;
    int b;
  } Foo;

  Foo f = { .a = 1 };


Tagless structs can't be forward-declared.

(Obviously, this looks like a local struct, so there's possibly no need for forward declaration. But you might have a snippet to generate this sort of thing for you. Or maybe it's just force of habit. And so on.)


> Or maybe it's just force of habit.

Or cargo-culting.

edit: wow somebody felt threatened. I have no shame stating that I cargo-culted exactly that for a while before I actually wondered what I was doing.


I'm guilty of this when writing C. I really have no desire to learn the language properly (it's hard enough to fit C++ in my brain), so I'll just follow the patterns others have set.

Microsoft does stuff like:

    typedef struct _FOO {
        ...
    } FOO, *PFOO;
Yeah ok fine, I'll do that.


When doing this in your own libraries, be sure to document how to generate the struct tag name from the typedef name. (MS don't do this - but they're not consistent about it anyway.) Then when people see a typedef'd struct used somewhere in a header, they'll know how to forward declare it in their own headers.


What's forward declaring mean?



Which means the profit margin is shrinking. It's not all about whether you're in the red or in the black, it's about how much profit you're making.


> Which means the profit margin is shrinking.

Not if you judge by the telcos' profitability.

The cost of transferring each bit is exponentially decreasing as network equipment tracks Moore's law. Their costs are going down, not up.

What this is really about is damaging competitors to their cable TV operations. Wail about Netflix using a lot of bandwidth, never mind that the cost of providing that bandwidth is falling as fast as the demand for it is rising, and you can put on a good show for the regulators as to why you need to destroy Netflix and push everybody back onto U-verse and cable TV.


That depends entirely on whether you see bandwidth costs as revenue or an expense. For many of these companies it's both, but generally they make most their money from consumers, and in that case it's an expense (to the degree it's got an ongoing price at all, given peering arrangements).


It is a net positive, I just wish they would focus more on their core users. Their basic code diff tool could use a lot of love to make it on par with the diffs generated from other tools.


Half the speed of native, but you're not comparing apples to apples. This slower code is also run in an environment where it's safe to download a random blob from the internet and just start running. This comes at some cost.


Also, I think the argument that "slow" isnt moving us forward is just not thinking the issue entirely through. Most people writing code today would not be if not for slower (and more human understandable) languages.

Why dont we just remove all keys from a developer's device besides 0s and 1s so they can program in the fastest computer language!


I wish they just put more effort into making their web interfaces more responsive. Trying to use Campfire from the browser on my Galaxy Nexus is nearly impossible.


Not sure if serious.


As a person living and working in Waterloo for a startup, I wouldn't be so quick to generalize. I quite like it here.


They have an external NFC tag that you can place near your front door that triggers the app on your phone to unlock your door through the web.


He makes a lot of money, therefore he should throw money into a fire.


On a somewhat related note, are there any tutorials out there for a guide to emacs and org-mode for vim users?


You could do this same thing on Twitter. Is the already large install base the only thing Google Buzz has going for it?


The first time I opened Buzz, I saw random thoughts from people in my neighborhood. If you're asking for restaurant suggestions, that's going to be far more helpful than Twitter, where you need to have people following you or searching for something in your tweet for people to ever see it.


I think what GMail did for conversations in email,GBuzz does for conversations in Twitter. The @reply mechanism and the retweet convention never really worked well for me in Twitter, although that may be because I was not using the necessary third party tooling to visualize it.

Also, you can add more than 140 characters, real links, pictures, etc. You lose some of the public version of SMS feel that Twitter has, but those constraints were becoming more of an annoyance to me.


Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: