Live data from Hacker News

What is a property?

alperenkeles.com

21–28 of 28 posts

Re: What is a property?

#21

Earlier quoted context omitted.

The worst thing is being corrected about minutiae. It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. Deep down it's all variables. Even the constants are variables from the viewpoint of the CPU that has to load it in its registers. Sometimes I see people saying "in LANG, obj.foo is just 'syntax sugar' for foo(obj)" and I think that technically it has always been "synt…

> It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. For what it's worth, to a researcher in the field of programming languages (like the author of the post), these all have distinct unambiguous meanings. At least as far as PL goes, almost every term has a well-defined meaning, but as those terms were adopted into less-than-academic contexts, the meanings have diluted.…

The problem is that the same word is used for different things.

The comment you are responding to was correct in what "property" means in some settings.

The article itself says:

> A property is a universally quantified computation that must hold for all possible inputs.

But, as you say,

> but as those terms were adopted into less-than-academic contexts, the meanings have diluted.

And, in fact, this meaning has been diluted. And is simply wrong from the perspective of what it originally meant in math.

You are right that a CPU register is a property of the CPU. But the mathematical term for what the article is discussing is invariant, not property.

Feel free to call invariants properties; idgaf. But don't shit all over somebody by claiming to have the intellectual high ground, because there's always a higher ground. And... you're not standing on it.

Re: What is a property?

#22

Earlier quoted context omitted.

The worst thing is being corrected about minutiae. It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. Deep down it's all variables. Even the constants are variables from the viewpoint of the CPU that has to load it in its registers. Sometimes I see people saying "in LANG, obj.foo is just 'syntax sugar' for foo(obj)" and I think that technically it has always been "synt…

> It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. For what it's worth, to a researcher in the field of programming languages (like the author of the post), these all have distinct unambiguous meanings. At least as far as PL goes, almost every term has a well-defined meaning, but as those terms were adopted into less-than-academic contexts, the meanings have diluted.…

To a programmer, it's all just memory. Too many people forget that and chase castles in the sky.

Re: What is a property?

#23

Earlier quoted context omitted.

The worst thing is being corrected about minutiae. It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. Deep down it's all variables. Even the constants are variables from the viewpoint of the CPU that has to load it in its registers. Sometimes I see people saying "in LANG, obj.foo is just 'syntax sugar' for foo(obj)" and I think that technically it has always been "synt…

> It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. For what it's worth, to a researcher in the field of programming languages (like the author of the post), these all have distinct unambiguous meanings. At least as far as PL goes, almost every term has a well-defined meaning, but as those terms were adopted into less-than-academic contexts, the meanings have diluted.…

I'd also like to add that, since immediate-operand instructions exist, constants are absolutely not the same as variables at the machine level, since immediates will never be stored in a register (typically, e.g. "move immediate" will obviously store it in one, and I'm sure there are architectures that use an internal/hidden register that's populated during instruction decode).

Also, in Harvard-architecture systems, the constants, being part of the instruction itself, might not even be in the same memory or even address space as variables ([EEP]ROM/Flash vs RAM).

Re: What is a property?

#24
post #17

Maybe I have a bit of a brain problem, but for me, 90% of the effort that goes into learning anything in tech is spent on identifying which nouns are Nouns, and which are just nouns, and the (often mushy) semantics of how people use those nouns in varying contexts and sub-contexts. I understand the reasons for this complexity - domain-specific terminology is valuable and forms naturally from pre-existing words. It's…

Since we are talking about Haskell, its type system can be explored to answer the question of what is considered a Property by the quickcheck library. The Property type is a datatype for which the definition is private. So we look at functions that creates Property objects. We find class Testable prop where property :: prop -> Property This means anything of the class Testable can be turned into a Property. So let's…

Bruh it was simple word property

Re: What is a property?

#25

Earlier quoted context omitted.

This is literally the difficulties with learning any discipline!

True! I just think it's particularly exaggerated in IT.

I agree!

With most disciplines theres usually a historical reference, homage, or literal-ness to the naming conventions… that can be searched for that will tend to help in illumination.

With software it kind of sort of started out that way… and has seemly devolved into this semblance of appropriating every word ever for who-the-fuck-knows-what… gotta say it’s better than pharmaceutical’s naming conventions. I mean at least software tends to use actual words!

Re: What is a property?

#26
post #17

Maybe I have a bit of a brain problem, but for me, 90% of the effort that goes into learning anything in tech is spent on identifying which nouns are Nouns, and which are just nouns, and the (often mushy) semantics of how people use those nouns in varying contexts and sub-contexts. I understand the reasons for this complexity - domain-specific terminology is valuable and forms naturally from pre-existing words. It's…

Since we are talking about Haskell, its type system can be explored to answer the question of what is considered a Property by the quickcheck library. The Property type is a datatype for which the definition is private. So we look at functions that creates Property objects. We find class Testable prop where property :: prop -> Property This means anything of the class Testable can be turned into a Property. So let's…

If I have to resort to hole-driven development then it seems like something has gone very wrong? I like to understand the libraries I’m using. Libraries should have good API documentation and intuitive type definitions. I shouldn’t have to carefully study how they’re put together, like solving a math homework problem.

Re: What is a property?

#27
post #21

Earlier quoted context omitted.

> It's not a "property" it's an attribute/field/member/key/column/variable/getter/function/procedure. For what it's worth, to a researcher in the field of programming languages (like the author of the post), these all have distinct unambiguous meanings. At least as far as PL goes, almost every term has a well-defined meaning, but as those terms were adopted into less-than-academic contexts, the meanings have diluted.…

The problem is that the same word is used for different things. The comment you are responding to was correct in what "property" means in some settings. The article itself says: > A property is a universally quantified computation that must hold for all possible inputs. But, as you say, > but as those terms were adopted into less-than-academic contexts, the meanings have diluted. And, in fact, this meaning has been d…

My point was not that there exists some supreme truth about what words mean and that either you use words "correctly" or you're an idiot.

Yes, words have different meanings in different settings, but that's not the dilution I was referring to. It's absolutely fine that a word can be used differently in different places.

The "problem", such as it is, is that there are people who use terms from programming languages research to discuss programming languages and they use these terms inaccurately for their context, leading to a dilution in common understanding. For example, there is a definitive difference between a "function" and a "method", and so it is inaccurate to refer to functions generally as "methods". However, I see people gripe about interactions where these things are treated separately, and that is what I am addressing.

The parent comment to mine tried to offer some examples of such terms within the context of programming languages, so my corrections were constrained to that context. But your correction of my point is, I think, incorrect, because the meaning you are trying to use against me is one from a different context than the one we're all talking about.

There's no intellectual high ground here; my point was not to elevate myself above the parent comment. My point was to explain to them that they were, from the point of view of people like the author of the post (I assume), simply incorrect. There's nothing wrong with being wrong from time to time.

Re: What is a property?

#28
post #17

Earlier quoted context omitted.

Since we are talking about Haskell, its type system can be explored to answer the question of what is considered a Property by the quickcheck library. The Property type is a datatype for which the definition is private. So we look at functions that creates Property objects. We find class Testable prop where property :: prop -> Property This means anything of the class Testable can be turned into a Property. So let's…

If I have to resort to hole-driven development then it seems like something has gone very wrong? I like to understand the libraries I’m using. Libraries should have good API documentation and intuitive type definitions. I shouldn’t have to carefully study how they’re put together, like solving a math homework problem.

Hole-driven development is especially useful when at the end of the workday your brain is fried, or when you are simply not in a good mood to understand all the type definitions. It allows you to defer your understanding and still make progress.
Post reply on HN