Take the 2-minute tour ×
English Language & Usage Stack Exchange is a question and answer site for linguists, etymologists, and serious English language enthusiasts. It's 100% free, no registration required.

Is this sentence grammatically correct?

[This method] binds a handler to one or more events to be executed once for each matched element.

source

Is it just a contraction of the following sentence?

This method binds a handler to one or more events, that is (supposed) to be executed once for each matched element.

share|improve this question
1  
In both of your sentences, it's not clear what is supposed "to be executed once for each matched element." I assume the handler is supposed to be executed, but the grammatical structure of your sentences implies that the events are supposed to be executed. The first one is worse than the second, because you lose the clue from the singular verb "is", and because in English "to be" almost always modifies the noun immediately preceding, while "that is" is a somewhat more flexible construction. –  Peter Shor Sep 29 '12 at 12:36
    
Apologies. I read this as meaning the events are to be executed, and edited accordingly; but after reading the comments I'm no longer sure. If it's the handler which is executed, it should read events, which is to be executed*, with a comma and which. –  StoneyB Sep 29 '12 at 13:16
    
@PeterShor Thank you. Very embarassing for me, but at least somebody else made the same mistake! –  StoneyB Sep 29 '12 at 13:22
    
I rolled back to the OP's original question, and added a comma before "that". Maybe it should be a "which". –  Peter Shor Sep 29 '12 at 13:24
1  
@StoneyB: The first example is one the OP found somewhere online, and he is asking whether it's correct or not. We shouldn't change it. (Clearly, it's incorrect. It at least needs the comma.) –  Peter Shor Sep 29 '12 at 13:34

2 Answers 2

up vote 2 down vote accepted

The sentence is grammatically correct, mostly (it wants a comma after events, to make clear that it is the handler which is executed).

The expansion is a little trickier. Your first level of expansion is correct:

handler ... to be executed < handler ... which is to be executed

However is to be should not be parsed as an ellipsis of is supposed to be (or expected or desired or anything else of the sort). That's what the idiom means, but it's not how it came to be.

(Before I take this any farther I need to enter a caveat: I'm not a scholar of OE. I only know this stuff because I had occasion to look it up last week in the course of the discussion of this question, so anything I say stands under correction by those more knowledgeable.)

If you look up this use of be in OED 1 you'll find it under senses 16 and 17:

16.With the dative infinitive, making a future of appointment or arrangement; hence of necessity, obligation, or duty; in which sense have is now commonly substituted.

17.The same construction is used in the sense of 'to be proper or fit (to)'. . .

That 'dative infinitive' refers to an OE construction which has been lost except in 'fossilized' expressions like this we're discussing. OE had I believe no distinct gerund; instead it employed what we now call the 'bare' infinitive and applied the appropriate case-ending. The idiom at hand employed to, which at that time was the ordinary preposition and took the dative case. For instance, OED's first citation under sense 17 is this:

c. 1175 Lamb.Hom. 133 Hit is to witene.

"It is (proper or fit) to know . . . " witen is the infinitive, and -e is added to mark the dative.

Of course, when English lost its case-endings (and acquired its gerunds), the underlying grammatical structure vanished from sight. We now parse the to as an 'infinitive marker' and the verb as a 'bare infinitive'. And that leads to just the sort of perplexities you'll find in the comments to the question I link above.

Because the idiom itself lived on, and evolved: notably, by the end of the 16th century it had been analogically extended to the passive voice, which is how your example uses it.

The same deep history lies behind the idiom have to (alluded to at the end of the sense 16 definition), which has an even more complicated recent history.

But what it all comes down to is that handler (which is) to be executed is complete and meaningful as it stands, and requires no further expansion.

(I love the English language.)

share|improve this answer
    
Thank you for so detailed explanation of my "second level of expansion". But what about the "first level"? Why can we just omit "that/which is"? –  thorn Sep 29 '12 at 15:30
    
@thorn Cuz we can! ... It's just like "The store that/which is on the corner" > "The store on the corner". –  StoneyB Sep 29 '12 at 15:56

It is perfectly grammatical.

It is a common construction, and can certainly be analysed as a contraction of "which is ... " or "that is ...". I don't know whether that analysis is currently favoured in the academic world, or whether it is regarded as a seprate construction with equivalent meaning.

You're also right that the construction "to be Xed" has an implication of "supposed to".

share|improve this answer
1  
It's grammatical, but does it mean what the OP wants it to? For the OP's second sentence, I assume that the handler is supposed to be executed, and not that the events is supposed to be executed. For the first sentence, it's hard for me to read it without concluding that the events are to be executed. –  Peter Shor Sep 29 '12 at 12:51
    
I would unhesitatingly read it as the events, and in the second form take "is" as an error. It didn't occur to me the OP might intend it to apply to the handler in either form - but I agree that pragmatically that is a more likely meaning. –  Colin Fine Sep 29 '12 at 13:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.