forked from massemanet/redbug
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
redbug:start_distribution/1 was using an invalid call to net_kernel:start/1 passing a map (an invalid one, at that) instead of the required list. net_kernel:start/1 has been deprecated since at least OTP 22, with net_kernel:start/2 (which *does* take a map) preferred. Dialyzer rightly complained, although the code *appeared* to function somehow, despite net_kernel:start/? code explicitly raising an error on the passed configuration properties. This redbug:start_distribution/1 change makes dialyzer happy, complies with the documented and implemented net_kernel:start/2 function, and appears to work properly on OTP 24 and 26. The spec for redbug:start/2 was wildly inaccurate and has been corrected (mostly) - there's still room for tightening up the return types, but dialyzer is happy now. The result pattern matching in redbug_dist_eunit:x_test_/0 has been revised to work on OTP <25 as well as 25+ through use of a macro, though it's unclear *why* the match was failing as the test code predates OTP 25. Given the age of the OTP releases that need this macro, it's questionable whether further investigation is worth the effort. Co-authored-by: Martin Sumner <[email protected]> Co-authored-by: Ted Burghart <[email protected]>
- Loading branch information
1 parent
b07c943
commit a18a40f
Showing
2 changed files
with
39 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters