Spec-driven development of code. Sorry for not specifying. (Irony? ;-))

Yes, that'd be an example of the tests / specs I'm talking about. I'm also 
suggesting that the programmer needs to be encouraged and made aware of their 
assumptions and requirements for doing something - hence baking them into the 
language / IDE (workspace / class browser) itself. This is essential in the 
documentation process, for inspection of code.

For example, if my entire operating system had been written in this theoretical 
spec-driven environment, I could look at it bit by bit and essentially teach 
myself what was encoded into the specs and learn how the operating system works 
at any level I'm interested in. I'm not stipulating this for restriction, only 
encouragement. "Checksumming" would allow the code to be quickly checked for 
correctness before running each time, or put a different way - code could not 
be compiled until the specs / tests had run through passing.

I think this is better off baked in because it would encourage programmers 
(users of the language) to write down what they intend to do before they do it. 
Something most people do whenever they're going to do something complicated 
anyway. It would encourage people to take care and to not code things quickly, 
but it would also provide regression tests.

This level of spec-driven / self-testing could not be performed as a principle 
and a general process as easily as if the environment / language was aware of 
it.

Regards,
Julian

On 11/10/2010, at 1:11 PM, K. K. Subramaniam wrote:

> On Sunday 10 Oct 2010 10:51:44 pm Julian Leviston wrote:
>> Does anyone know about a language (possibly something in smalltalk) that
>> involves spec-driven development?
> Spec-driven development of what? There have been many attempts at encoding 
> specifications (purely descriptive code without imperatvie components) but 
> they 
> are all highly domain-specific. See "Specification Language" in Wikipedia for 
> starters.
> 
> Smalltalk uses a prototyping approach - build as you go. It does support 
> "assert" statements to capture invariants. e.g.
> 
>       self assert: myclass instVarNames isEmpty.
> 
> and a Test framework (See SUnit-* Packages in Squeak) for validations..
> 
> Subbu


_______________________________________________
fonc mailing list
fonc@vpri.org
http://vpri.org/mailman/listinfo/fonc

Reply via email to