Search Results

Search found 3 results on 1 pages for 'koan'.

Page 1/1 | 1 

  • Is there a better strategy than relying on the compiler to catch errors?

    - by koan
    I've been programming in C and C++ for some time, although I would say I'm far from being an expert. For some time, I've been using various strategies to develop my code such as unit tests, test driven design, code reviews and so on. When I wrote my first programs in BASIC, I typed in long blocks before finding they would not run and they were a nightmare to debug. So I learned to write a small bit and then test it. These days, I often find myself repeatedly writing a small bit of code then using the compiler to find all the mistakes. That's OK if it picks up a typo but when you start adjusting the parameters types etc just to make it compile you can screw up the design. It also seems that the compiler is creeping into the design process when it should only be used for checking syntax. There's a danger here of over reliance on the compiler to make my programs better. Are there better strategies than this? I vaguely remember some time ago an article on a company developing a type of C compiler where an extra header file also specified the prototypes. The idea was that inconsistencies in the API definition would be easier to catch if you had to define it twice in different ways.

    Read the article

  • Reliance on the compiler

    - by koan
    I've been programming in C and C++ for some time, although I would say I'm far from being expert. For some time I've been using various strategies to develop my code such as unit tests, test driven design, code reviews and so on. When I wrote my first programs in BASIC I typed in long listings before finding they would not run and they were a nightmare to debug. So I learnt to write a small bit and then test it. These days I often find myself repeatedly writing a small bit of code then using the compiler to find all the mistakes. That's OK if it picks up a typo but when you start adjusting the parameters types etc just to make it compile you can screw up the design. It also seems that the compiler is creeping into the design process when it should only be used for checking syntax. There's a danger here of over reliance on the compiler to make my programs better. Are there better strategies than this ? I vaguely remember some time ago an article on a company developing a type of C compiler where an extra header file also specified the prototypes. The idea was that inconsistencies in the API definition would be easier to catch if you had to define it twice in different ways.

    Read the article

  • OpenCL support on Leopard

    - by koan
    I want to use OpenCL in my software but I am running Leopard. I will probably update to Snow Leopard later. In the mean time I would like to get started with OpenCL in Leopard. Setting up on 10.5 is confusing: most SDKs and articles assume that you must be using Snow Leopard. Searching for "Using OpenCL on Leopard" is completely useless, as you would expect. I downloaded the cuda toolkit, devdriver and gpucomputing SDK from nvidia but the examples won't compile because OpenCL/opencl.h is not found. The OpenCL release notes don't mention MacOSX so again I think this is assuming that all Mac users are running Snow Leopard. Where can I find OpenCL includes and libraries for Mac OSX 10.5 ? Or, is this just a waste of time and I should go and get Snow Leopard ASAP ? After upgrading to Snow Leopard I would like my software to support Leopard. Is this possible ?

    Read the article

1