You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unicode based Emojis in variable and method names.
Proposed
Prototype: Not Started
Implementation: Not Started
Specification: Not Started
Summary
People long for a feature in programming: the use of unicode based characters, like emojis since they are always custom and unique. Example emojis include the sob emoji and others. I would like all of the emojis currently supported by unicode (which was then become part of some emoji version stuff).
Motivation
Well users currently get to choose their variable or method names, however there are limitations to this, for starters c# code files use UTF-8 BOM by default which supports using emojis in the files, yet the language would not compile the code if emojis was used for variable names, method names, etc of private or internal symbols (as long as they use english based method names for their public api).
This would allow programmers to not only write working and great code, but also have fun too by being able to use emojis for local variables, in using blocks or statements, etc that does not get exposed to public api.
The expected outcome is code like below:
Except that it would be able to compile.
Detailed design
publicclassExample{// example internal method with emojis.internalvoidEmojiTime😂😂😂😂(){// example local variable with emojis.var 😂😂😂 =string.Empty;// use it later.}// example private method using emojis.privatevoidAnotherEmoji😂😂😂😂😂(){// example using block using emojis.using(var 😂😂😂😂 =new MemoryStream(){// do stuff to the stream.}// example using statement using emojis.
using var 😂😂😂 =new MemoryStream();// do stuff to the stream.}// example internal property using emojis.
internal byte[] 😂😂😂😂😂😂 { get;set;}// example private property using emojis.privatebyte[] 😂😂 {get;set;}// anything else that can make internal or private variables or members of any// type using emojis that I have not thought of above.}
The entire variable spec, class spec (people would probably want to use emojis for class names too on internal/private only classes), enum spec (for internal or private enumeration members), struct spec (for internal/private structures) for variables(or class/enum/struct members) as this very well could apply to the whole thing. However I would like emojis only usable on non-public members (internal or private) to avoid issues with users who cannot type emojis.
Drawbacks
I do not see any drawbacks with allowing usage of emojis in variable, member, or method names as long as they are not allowed to be an public member name for fear of someone unable to type the emojis from having issues.
Alternatives
I have not considered any other ones that would allow using emojis for variable names, member, or method names.
I think the impact of not doing this is limited to the people who want to use emojis for variable, member, and method names of internal symbols.
Unresolved questions
None so far, this is a new proposal.
Design meetings
None so far, this is a new proposal.
The text was updated successfully, but these errors were encountered:
AraHaan
changed the title
[Proposal]: Emojis in Variable and method names.
[Proposal]: Emojis in Variable, member, and method names.
Feb 8, 2021
AraHaan
changed the title
[Proposal]: Emojis in Variable, member, and method names.
[Proposal]: Emojis in internal/private Variable, member, and method names.
Feb 8, 2021
Unicode based Emojis in variable and method names.
Summary
People long for a feature in programming: the use of unicode based characters, like emojis since they are always custom and unique. Example emojis include the sob emoji and others. I would like all of the emojis currently supported by unicode (which was then become part of some emoji version stuff).
Motivation
Well users currently get to choose their variable or method names, however there are limitations to this, for starters c# code files use UTF-8 BOM by default which supports using emojis in the files, yet the language would not compile the code if emojis was used for variable names, method names, etc of private or internal symbols (as long as they use english based method names for their public api).
This would allow programmers to not only write working and great code, but also have fun too by being able to use emojis for local variables, in using blocks or statements, etc that does not get exposed to public api.
The expected outcome is code like below:
Except that it would be able to compile.
Detailed design
The entire variable spec, class spec (people would probably want to use emojis for class names too on internal/private only classes), enum spec (for internal or private enumeration members), struct spec (for internal/private structures) for variables(or class/enum/struct members) as this very well could apply to the whole thing. However I would like emojis only usable on non-public members (internal or private) to avoid issues with users who cannot type emojis.
Drawbacks
I do not see any drawbacks with allowing usage of emojis in variable, member, or method names as long as they are not allowed to be an public member name for fear of someone unable to type the emojis from having issues.
Alternatives
I have not considered any other ones that would allow using emojis for variable names, member, or method names.
I think the impact of not doing this is limited to the people who want to use emojis for variable, member, and method names of internal symbols.
Unresolved questions
None so far, this is a new proposal.
Design meetings
None so far, this is a new proposal.
The text was updated successfully, but these errors were encountered: