Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fix a number of stylistic issues in etc.linux.memoryerror. #389

Merged
merged 1 commit into from Jan 29, 2013

Conversation

Projects
None yet
2 participants
Member

alexrp commented Jan 21, 2013

  • Made the registration functions public.
  • Moved all public stuff to the top of the file to avoid mistakes like this again.
  • Added else -> static assert(false); branch to the version forest.
  • Fixed some minor code style issues.

This also makes the module actually usable.

(I still strongly disagree with throwing NullPointerError when dereferencing a < 64 kb pointer....)

@ghost

ghost commented Jan 21, 2013

Does this fix issue 9333 (its summary is misleading but still there is problem)?

Member

alexrp commented Jan 22, 2013

From what I can see, the module is compiled into the library, so I'm not sure what 9333 is about.

@ghost

ghost commented Jan 22, 2013

Yes, it does, but using that module results in linking errors as in the example. Either there is a problem with module or it should be used in another way. In both cases making stilistic edits is rather pointless untill the module cannot be used (or users do not know how to use it). I thought the pull was to fix the issue.

Member

alexrp commented Jan 22, 2013

These changes are not pointless. See the description.

Member

alexrp commented Jan 25, 2013

@dawgfoto can you have a look at this? (since you participated in the original review)

Member

MartinNowak commented Jan 25, 2013

Can we get a unittest?
The return type of registerMemoryErrorHandler should be bool.

Thanks for fixing this.

Member

alexrp commented Jan 27, 2013

Now with a unit test, unregisterMemoryErrorHandler -> deregisterMemoryErrorHandler, and returning bool instead of int.

MartinNowak added a commit that referenced this pull request Jan 29, 2013

Merge pull request #389 from alexrp/master
Fix a number of stylistic issues in etc.linux.memoryerror.

@MartinNowak MartinNowak merged commit ff23532 into dlang:master Jan 29, 2013

1 check passed

default Pass: 10
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment