PEP 318 - Function Modifier Syntax

Courageous jkraska at san.rr.com
Tue Jun 10 20:58:24 EDT 2003


>Yes, but computer languages do not benefit from having words
>with multiple distinct meanings.

Failure to establish a benefit is not an existence proof of a
detriment. Be that as it may, I agree with you that an alternate
word would be helpful (although it has the disadvantage of breaking
backwards compatability, whereas reusing an old keyword does not).
to muddle things up.

There are many options:

Various punctuation-governed:

	def myfunc (myvar); synchronized:
	def myfunc (myvar), final:

Modifier tuple first:
	
	def (synchronized) myfunc (myvar):
	def (final, synchronized) myfunc (myvar):

Modifier tuple second:

	def myfunc (myvar) (synchronized):
	def myfunc (myvar) (final, synchronized):

Different keyword:

	def myfunction (myvar) using final, synchronized:

Where "using" is defined to mean "using the semantics
of".

C//





More information about the Python-list mailing list