Skip to content

Documentation outdated (v1.1.2 vs v1.2.7) #220

@sodiumnitrate

Description

@sodiumnitrate

Hi,
As far as I can see, the only documentation for the C API is for v1.1.2. There seem to be key differences between these two versions, notably the two extra fields in the edlibAlignConfig struct.

Old documentation says to do something like:

EdlibAlignResult result = edlibAlign("ACGTTAC", 7, "CGTTAG", 6, edlibNewAlignConfig(-1, EDLIB_MODE_SHW, EDLIB_TASK_PATH));

while this gives an error in v1.2.7:

error: too few arguments to function ‘EdlibAlignConfig edlibNewAlignConfig(int, EdlibAlignMode, EdlibAlignTask, const EdlibEqualityPair*, int)’
    9 |                                     edlibNewAlignConfig(-1, EDLIB_MODE_SHW, EDLIB_TASK_PATH));
      |                                     ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

In file included from src/edlib_test.cpp:3:
src/edlib/include/edlib.h:146:32: note: declared here
  146 |     EDLIB_API EdlibAlignConfig edlibNewAlignConfig(
      |                                ^~~~~~~~~~~~~~~~~~~

The following works:

EdlibAlignResult result = edlibAlign("ACGTTAC", 7, "CGTTAG", 6, edlibNewAlignConfig(-1, EDLIB_MODE_SHW, EDLIB_TASK_PATH, NULL, 0));

While the code is commented quite well that I was able to figure it out quickly, I just wanted to note it here in case others are stuck. Of course, updating the docs would be ideal, but I understand it takes time.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions