GraphBLAS / LAGraph-Working-Group

Public document and planning repository for the LAGraph Working Group

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Function signature convention (style guide)

mcmillan03 opened this issue · comments

How should signatures be named and structured.

With namespaces and reasonable default arguments.

But given that we're in C, we just prefix everything with LAGr_.

To drill down a bit:

  • There's a good chance that LAGraph will start to modularize and segment by domain. If algorithms were truly unique to an application area, I would suggest we add that to the signature (e.g. LAGr_ML_ or LAGr_NetSci_). However, many algorithms are unlikely to be used by only a single domain area. Maybe they can have their own version in their domain tailored specifically to their area, but we risk a lot of code duplication if we assume that from the start.
  • Regarding argument ordering, do we want to use output-first like GraphBLAS? It would seem reasonable to do so.
  • From a broader style and philosophy perspective, should we keep names short (LAGr_bc) or long (LAGr_BetweennessCentrality)?