Live data from Hacker News

Extracting the abstract syntax tree from GCC

lwn.net

101–110 of 112 posts

Re: Extracting the abstract syntax tree from GCC

#101
post #90
post #68

Earlier quoted context omitted.

" natural freedom to kill each other " Although that's not a binary thing, I have the natural and legal right to kill in legitimate self-defense. In rare situations, stealing is allowed to prevent a greater loss. In this case, most of us, even those of us who don't like the GPL in practice like me, are not primarily arguing the GPL, but RMS's stewardship of GCC and GNU Emacs about something that's allowed in I believ…

> In this case, most of us, even those of us who don't like the GPL in practice like me, are not primarily arguing the GPL However, people are making the argument that this proves that GPL particularly strange for people to take the position that RMS's behaviour here is anti-freedom and thus obnoxious, and therefore GPL sucks. It shouldn't be necessary to point out that he could pull the same stunt just as easily if…

My only quibble is that since RMS has wrapped himself and this issue in the flag of the GPL and "the [foundation] for which it stands", in terms of the instant controversy, and e.g. conflicts with OpenBSD, they are indivisible.

But I hope I've made it very clear that I indeed view this solely as a stewardship issue that could be true under any FOSS licence, and I repeat that the GPL is a tolerable licence for something like the GCC (well, it might doom serious Ada to the proprietary world, but, eh).

Re: Extracting the abstract syntax tree from GCC

#102
post #100
post #80

Earlier quoted context omitted.

But it sure sounds to me like the shoe fits. Enough that GCC is now existentially threatened by LLVM. ADDED: and I believe this is ~95% because of RMS's stewardship of the project (which already semi-died and was replaced by a fork), not the GPL, which is not a bad fit for a complete work like a compiler.

Would Apple's desire not to use the GPLv3, and subsequent funding of LLVM be related to RMS' actions?

RMS's stewardship of GCC most certainly includes re-licencing it under the GPLv3, it's all one of a part.

And don't one or more of the BSDs have problems with the GLPv3 GCC? It's just not eeevil Apple (and that's part of why I swore off their products in 1987).

Re: Extracting the abstract syntax tree from GCC

#103
post #41

Earlier quoted context omitted.

> the right to look at every single detail of GCC and make it work better for yourself. And yet, the referenced discussion breaks down into RMS on one side and people who want to make gcc work better for themselves on the other.

> And yet, the referenced discussion breaks down into RMS on one side and people who want to make gcc work better for themselves on the other. At the risk of someone building a closed backend off an artifact of the GCC frontend; at the risk of someone profiting off RMS' work without following his conditions for making that work free. It's important to remember that he isn't against Emacs getting the information it ne…

Imagine RMS's argument if the developers of a proprietary software asked "well, which part exactly of our software would you like to alter? We'll study how to give you restricted access to those."

Re: Extracting the abstract syntax tree from GCC

#104
post #102
post #100

Earlier quoted context omitted.

Would Apple's desire not to use the GPLv3, and subsequent funding of LLVM be related to RMS' actions?

RMS's stewardship of GCC most certainly includes re-licencing it under the GPLv3, it's all one of a part. And don't one or more of the BSDs have problems with the GLPv3 GCC? It's just not eeevil Apple (and that's part of why I swore off their products in 1987).

FreeBSD switched to clang, OpenBSD afaik maintains forks of the last GPL2 versions. NetBSD and Dragonfly use GPLv3 gcc versions.

Re: Extracting the abstract syntax tree from GCC

#105

Earlier quoted context omitted.

The one freedom the GPL doesn't have is the freedom to take the freedom away. In BSD and similar you easily can. It is the taking away of freedom that is at the crux of all this.

> In BSD and similar you easily can. Nope. My taking BSD code and producing a proprietary, closed source product it in no way impacts someone else's freedom to do the same, nor does it remove some freedom they previously had.

The freedoms on the original are indeed unchanged in both cases. The freedom on the derived work is what can be taken away with non-GPL.

Re: Extracting the abstract syntax tree from GCC

#106
post #41

Earlier quoted context omitted.

> the right to look at every single detail of GCC and make it work better for yourself. And yet, the referenced discussion breaks down into RMS on one side and people who want to make gcc work better for themselves on the other.

What's the term for a program that's deliberately crippled to prevent you from doing what you want? Defective by design?

It's not defective because you are not the "user" to Stallman. The GPL is about limiting coders freedoms to maximise the freedom of end users (to see code, recompile it, alter the product they purchased).

For Stallman a program/tool is "defective" if it enables programmers to limit end users access to code, .e.g. by enabling proprietary addons to the compiler.

Re: Extracting the abstract syntax tree from GCC

#107
post #87

Earlier quoted context omitted.

True, but it takes effort to change the API, and even if they did something obfuscatory to it automatically with every new version, it wouldn't be all that hard to write something that parses GCC's source code or compiles programs specifically designed to exercise the right paths - and grabs the right bits automatically; a meta-AST-extractor. Similar techniques are already in use for automatically generating wrapper…

The only counter I have to "it wouldn't be all that hard to..." statements is that it is 2015, emacs can't even refactor things like xcode can do. And xcode is considered horrible by refactoring standards. If it were so easy it would have happened by now. One can only conclude gcc and its stewardship have no real desire to allow for such a thing to occur at all. Which means llvm will likely be the future for being ab…

Xcode cannot refactor C++ at all. Not in the slightest. It'll only do C and Obj-C.

It's a pity because it is quite an enjoyable IDE to use every single day for my C++ work (I'm on 6.1.1, doesn't crash unlike the 6.0 series), but missing a feature like that stinks.

Not that I've ever had need to use it so far, but still, it is a pity.

Re: Extracting the abstract syntax tree from GCC

#108
post #94
post #2

comparing emacs to xcode/idea made me lol

I know. XCode really doesn't compare in terms of usability, stability, range of available options, and documentation. Sad really.

Here on HN, Xcode bashing is second only to C++ bashing.

What's wrong with xcode? It has static analysis complete with annotations, integration with instruments for thread / network / CPU / memory monitoring, integration with lldb, code completion, code folding, quick navigation, details about callers and callees from any function, details about generated code (so you can look at the preprocessed code), the same with assembly (if you so desire!), test integration, class hierarchies, documentation for relevant functions (same as man, documentation for Apple SDKs) but IS missing refactoring for C++ (it does C and Obj-C).

Which bit about all of that is missing?? (other than refactoring C++)

I am using 6.1.1 and I haven't had it crash for the past 6 months, using it 7.5 hours a day (and 3 hours a night too). 6.0 was buggy as anything but 6.1.1 is rock-solid for me.

Re: Extracting the abstract syntax tree from GCC

#109

Earlier quoted context omitted.

> we all understand RMS clear, consistent position on the matter. Then why are "we" all still using his software (which was given a license to match his philosophy) and complaining when he maintains his "clear, consistant position on the matter" and refuses to compromise his beliefs. To use a poor analogy, it's like going to church and complaining when they talk about God. There are lots of other options out there fo…

The fundamental issue is that for RMS (and perhaps you?), using software is like going to church and accepting the the moral code of whomever produced that software. However, for most people, that is not the case whatsoever. My baker can have all sorts of moral codes that I don't endorse when I eat his bread. I don't support the FSF, I do support access to source code, and the freedom to extend the source code. Somet…

Bringing up food and morality might be a bad pick if you are arguing that people do not care. Ecological food, humanly treated animals for meat and eggs, and fair trade, is all concepts which carries large market shares and is believed by many people to be superior moral choices.

Using products like those does not mean you have to accept or endorse the the moral code that the products represent. However, for most people, morality do play a part of why they pick those products.

Re: Extracting the abstract syntax tree from GCC

#110

Earlier quoted context omitted.

That's the great irony of the copyleft movement -- it's about restricting what people can do under the guise of "freedom". RMS doesn't want people to "misuse" his software, but his version of misuse is "use it for a purpose that doesn't advance GNU." He's willing to cripple his software so that some theoretical entity that doesn't actually exist and does not agree with his politics can't misuse it. On a practical lev…

It is ironic, but not necessarily nuts. Another case of removing freedoms to promote freedom is much of criminal law. Why does the state restrict my freedom to kill people? When your freedom reduces the global "freedom", the sum of everyone's freedoms after your action, it might make sense to prevent it. In spite of, and because: freedom. Not saying the way RMS is doing it is good, that's a different matter. But rest…

And this is why some call it liberty. You can give a slave freedom by helping them to escape, but you have not provided liberty if the slaver can just hunt down and recapture the free'ed slave.

John Locke said on the subject of liberty: "Freedom is constrained by laws in both the state of nature and political society. Freedom of nature is to be under no other restraint but the law of nature. Freedom of people under government is to be under no restraint apart from standing rules to live by that are common to everyone in the society and made by the lawmaking power established in it. Persons have a right or liberty to (1) follow their own will in all things that the law has not prohibited and (2) not be subject to the inconstant, uncertain, unknown, and arbitrary wills of others."

Post reply on HN