0
votes
Vote UpVote

Enum values in their own namespaces/scopes: Scoped Enums (Delphi)

The Wiert Corner – A while ago, I needed several enum types in the same unit with overlapping enumeration values. Putting each in an encompassing type wasn’t possible and I didn’t want to put each in their own unit. Luckily, Delphi 2009 introduced the “scoped enum” feature effectively promoting the enumeration type into a scope or namespace. Since the below was hard to find combined with the word “namespace” I’ve quoted it in full: Type Switch Syntax {$SCOPEDEUNMS ON}, or {$SCOPEDENUMS OFF} Default {$SCOPEDENUMS OFF} Scope Local Remarks ...
Favorite? Off-Topic? jpluimers @ 2018-08-29 07:04

Statistics

Visits: 158
Votes: 0
Favorites: 0
Off-Topic: 0

Visits by Source

User Actions

Users who voted for this posting

Subscribe:
Contact us to advertise on DelphiFeeds.com

Community Links

Torry Firebird News

Sponsor

 
Please login or register to use this functionality.
(click on this box to dismiss)