Skip to content

rPackages.CNEr: fix build#411384

Closed
Kupac wants to merge 1 commit intoNixOS:r-updatesfrom
Kupac:fix_CNEr
Closed

rPackages.CNEr: fix build#411384
Kupac wants to merge 1 commit intoNixOS:r-updatesfrom
Kupac:fix_CNEr

Conversation

@Kupac
Copy link
Contributor

@Kupac Kupac commented May 27, 2025

Correct type signatures

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • Nixpkgs 25.11 Release Notes (or backporting 24.11 and 25.05 Nixpkgs Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
  • NixOS 25.11 Release Notes (or backporting 24.11 and 25.05 NixOS Release notes)
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

Correct type signatures
@github-actions github-actions bot added the 6.topic: R R is a programming language for statistical computing and data visualization. label May 27, 2025
@nix-owners nix-owners bot requested a review from jbedo May 27, 2025 13:12
@Kupac Kupac closed this May 27, 2025
Comment on lines +10 to +20
+void slUniqify(void *pList, int (*compare )(const void *elem1, const void *elem2), void (*freeFunc)())
/* Return sorted list with duplicates removed.
* Compare should be same type of function as slSort's compare (taking
* pointers to pointers to elements. Free should take a simple
@@ -356,7 +356,7 @@ while ((el = slPopHead(&oldList)) != NULL)
{
if ((newList == NULL) || (compare(&newList, &el) != 0))
slAddHead(&newList, el);
- else if (free != NULL)
+ else if (freeFunc != NULL)
free(el);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the comment says

Free should take a simple pointer to dispose of duplicate element

...this should be void (*freeFunc)(void *) and freeFunc(el).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: R R is a programming language for statistical computing and data visualization.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants