githwxi / ATS-Postiats

ATS2: Unleashing the Potentials of Types and Templates
www.ats-lang.org
Other
352 stars 54 forks source link

Bit fields? #271

Open armeenm opened 2 years ago

armeenm commented 2 years ago

Is it possible to use bit fields in ATS2?

githwxi commented 2 years ago

Yes.

You can do bit fields in C and give your operations some types in ATS. ATS can be seen as a front end to C. At this point, there is no syntax in ATS2 to support bit fields. Such support is possible in ATS3 in the future, though.