emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Best way to extract info from C files?
@ 2024-02-13 15:58 Stefano Ghirlanda
  2024-02-13 16:18 ` Stefano Ghirlanda
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Stefano Ghirlanda @ 2024-02-13 15:58 UTC (permalink / raw)
  To: emacs-orgmode

Hi all!

I'm trying to build a simple code documentation tool for org-mode, so
I'm looking for ways to get information from C files (to begin with,
ideally it will be easy to add other languages). Things like function
prototypes, struct definitions, etc. What would be the best tool for
this? My search has come up with things like lsp-mode, semantic, etags
but I have no experience with any of these. What would be easiest to
work with / setup, and have the necessary functionality? Or should I
just write my own parsing code?

More specifically, my initial goal is to be able to parse things in a
format similar naturaldocs.org, for example:

// Function: This is a brief description.
// Parameters:
// - x: The first parameter
// - y: The second parameter
// Return: A value
int my_function( int x, int y );

and transform this into something like:

* Documentation

** my_function

This is a brief description

| Parameters: |                                      |
| x                   | The first parameter       |
| y                   | The second parameter |
|----------------------------------------------------|
| Return          | A value                         |

To be improved iteratively :)

Thanks!

-- 
Stefano Ghirlanda
CTO, DataWorks - https://dataworks.consulting
Guest Professor - Stockholm University Centre for Cultural Evolution


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-02-21  2:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-13 15:58 Best way to extract info from C files? Stefano Ghirlanda
2024-02-13 16:18 ` Stefano Ghirlanda
2024-02-13 18:59 ` Jude DaShiell
2024-02-20 11:05 ` Ihor Radchenko
2024-02-21  2:15   ` Stefano Ghirlanda

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).