All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

Coccinelle: Source-to-Source Transformation Tool for C Code Refactoring

By

anon111332142

3mo ago· 3 min readenCode

Summary

Coccinelle is a source-to-source transformation tool for C code that enables programmers to write complex style-preserving transformations for tasks like refactoring. The article provides installation instructions, download information for pre-compiled versions, and basic usage guidance for the spatch script that invokes Coccinelle.

Key quotes

· 5 pulled
Coccinelle allows programmers to easily write some complex style-preserving source-to-source transformations on C source code
like for instance to perform some refactorings
To install Coccinelle from its source, see the instructions in install.txt
Once you have installed coccinelle, there is a script 'spatch' in /usr/bin or /usr/local/bin that invokes the Coccinelle program
You can download pre-compiled versions of spatch and check which distributions package it here
Snippet from the RSS feed
Source code of the Coccinelle project (mirror of the main Coccinelle repository located at Inria) - coccinelle/coccinelle

You might also wanna read