Custom Permissions provide an excellent means to describe process or task based permissoins in our Force.com applications / packages. These can be assigned to Profiles or Permission Sets. An excellent feature!
As a Visualforce developer its really easy to check if a user has a given Custom Permission via $Permission, however as a Apex developer this requires at least two SOQL queries. Much like how Custom Labels are available to both Visualforce ($Label) and Apex (System.Labels), this idea to suggest that Apex exposes Custom Permissions as a native entity within Apex to avoid impacting the SOQL query governor.
Apex: (idea being requested here)
(already available approach via SOQL, snippet from helper class described here
List<CustomPermission> customPermissions =
[SELECT Id, DeveloperName
WHERE NamespacePrefix = :namespacePrefix];
List<SetupEntityAccess> setupEntities =
WHERE SetupEntityId in :customPermissionNamesById.keySet() AND
ParentId IN (SELECT PermissionSetId
WHERE AssigneeId = :UserInfo.getUserId())];
(already available, shown for reference here)