Re: parts of speech in Ruby



On 10/8/07, Morton Goldberg <m_goldberg@xxxxxxxxxxxxx> wrote:
On Oct 8, 2007, at 5:44 PM, Chad Perrin wrote:

I'm curious -- exactly what class of syntactic element is `=` in Ruby,
where "class of syntactic element" is roughly analogous to "part of
speech". If objects are nouns and methods are verbs, that means
`=` is
neither a noun nor a verb. Is it a participle? Is it
punctuation? If
it's a participle, I'd like to know what class of syntactic element
that
is in Ruby. If it's punctuation, I'd like some explanation for how
that
works conceptually -- because I think of punctuation in Ruby as being
stuff like the parentheses around a method argument.

Anyone? Bueller?

I think it might be consider a copula. See <http://en.wikipedia.org/
wiki/Copula>.

Regards, Morton

I agree with Morton a little here, since "a = b" doesn't necessarily
mean "a is b".

I suppose it's all about how far you want to take it conceptually.
Like, for example, in my head I see "a = b" as "a tries to put on b's
shoes", or to make it more short, something like, "b marries a".

In another language, that might sound more like "b, a, they become
together for a while".

For all simplicity, though, I guess the copula term could best
describe it for the English language.

Not a straight answer, but, there you go.

class C
def []= something
puts "hello"
end
end

b = C.new[] = "hola"

The semantics break down when you look at a single symbol (in this
case, '=') and try to replace it with a word (be it verb, transitive,
cupola or otherwise).

I don't know your use case, but I think it's impossible to translate a
programming language into a spoken one. I would be fascinated if you
could prove me wrong though.

Todd

.



Relevant Pages

  • Re: why the -s in English verbs?
    ... ekkilu> I am not fully happy, ... ekkilu> language (since a language like Vietnamese shows that 1st ... frequently used nouns, and you use different ones w.r.t. familiarity, ... Does its verb take different froms ...
    (sci.lang)
  • Re: Talk About....
    ... "faith and credit" are ephemeral concepts NOT nouns. ... Nouns, ... adjective, but the way it is used as a noun, not a verb. ...
    (alt.gathering.rainbow)
  • Re: Progamming language for hackers?
    ... >But I think I understand this programming language! ... I like to "aaa the (datatype) bbb and I'd like to have ... How to do (the main verb) - part ...
    (comp.programming)
  • Re: OT: Verbal Pet Peeves
    ... The verb loan is one of the words English settlers brought to ... We live in a culture that is dominated by an overly-synthetic language ... and mistakenly believe that the vernacular may ... very strict on sentence fragments and run-on sentences. ...
    (alt.smokers.pipes)
  • Re: Talk About....
    ... "faith and credit" are ephemeral concepts NOT nouns. ... Nouns, ... adjective, but the way it is used as a noun, not a verb. ...
    (alt.gathering.rainbow)