Skip to content

Some pointer sugar.#27

Draft
saeta wants to merge 1 commit intomainfrom
pointer-sugar
Draft

Some pointer sugar.#27
saeta wants to merge 1 commit intomainfrom
pointer-sugar

Conversation

@saeta
Copy link
Owner

@saeta saeta commented May 22, 2020

This, unfortunately, is somewhat unsatisfying, as it cannot obviate
all need for .pointee. In particular, it cannot satisfy the case
when the pointee needs to be modified in some fashion. (i.e. inout)

This, unfortunately, is somewhat unsatisfying, as it cannot obviate
all need for `.pointee`. In particular, it cannot satisfy the case
when the pointee needs to be modified in some fashion. (i.e. `inout`)
@saeta saeta requested a review from dabrahams May 22, 2020 01:56
@saeta saeta changed the title First attempt at some pointer sugar. Some pointer sugar. May 22, 2020
@dabrahams
Copy link
Collaborator

…thus driving home the reason I always argued this should be spelled subscript(), i.e. p[]

Copy link
Collaborator

@dabrahams dabrahams left a comment

Choose a reason for hiding this comment

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

IMO this should be the empty subscript so it works with lvalues, or nothing at all with the rationale that [] only saves one character over [0], and then we should decide that [0] is OK.

@texasmichelle texasmichelle changed the base branch from master to main December 8, 2020 01:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants