This is an archive of the discontinued LLVM Phabricator instance.

[libc] Introduce sys/socket.h
ClosedPublic

Authored by jeffbailey on Feb 20 2023, 10:56 AM.

Details

Summary

This adds sys/socket.h and some definitions on Linux.

Diff Detail

Event Timeline

jeffbailey created this revision.Feb 20 2023, 10:56 AM
Herald added projects: Restricted Project, Restricted Project. · View Herald TranscriptFeb 20 2023, 10:56 AM
jeffbailey requested review of this revision.Feb 20 2023, 10:56 AM

Add missing newline.

sivachandra accepted this revision.Feb 21 2023, 10:12 AM

LGTM but added an inline comment asking to add some documentation.

libc/include/llvm-libc-macros/linux/sys-socket-macros.h
12

Add a comment (against each constant) explaining:

  1. What they indicate
  2. How you arrived at the value. It can be something simple like, "Value specified by POSIX", or "Value matches Linux definition from <linux header>".
  3. Which standard or extension specifies/requires the definition.
This revision is now accepted and ready to land.Feb 21 2023, 10:12 AM

Update comments per Siva's feedback.

This revision was automatically updated to reflect the committed changes.