ekzhang / crepe

Datalog compiler embedded in Rust as a procedural macro
Apache License 2.0
453 stars 16 forks source link

add visibility modifiers to structs and fields, support struct attributes #7

Closed cuddlefishie closed 3 years ago

cuddlefishie commented 3 years ago

closes #4 supersedes #5

The parser now accepts visibility modifiers on struct declarations and their fields inside the crepe! block.

Also attributes can be added on struct definitions, allowing custom derive or other attributes to be associated to the types.

The attributes can be placed after an @input or @output modifier and as usual before the struct declaration.

ekzhang commented 3 years ago

Thank you! This seems to work very well. I also appreciate that you added tests for visibility/attrs & updated the UI test output for rustc 1.48.