PLC-lang/rusty

Create utility workspace with macros for all internal naming conventions

Open

#913 opened on Jul 18, 2023

 (1 comment) (0 reactions) (0 assignees)Rust (71 forks)auto 404
good first issuelow-priorityrefactor

Repository metrics

Stars
 (351 stars)
PR merge metrics
 (PR metrics pending)

Description

We have several naming conventions that are defined across the project (e.g. internally generated types). Since we split the project into workspaces we keep having problems for finding a single place to define functions/macros for these naming conventions, so they are visible to anybody.

I suggest creating its own crate for utility functions called 'util' and we start with offering macros for all kinds of naming-convention-macros:

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/index.rs#L1489-L1492

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/typesystem.rs#L1273-L1277

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/ast/pre_processor.rs#L162

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/ast/pre_processor.rs#L189

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/resolver/generics.rs#L207

https://github.com/PLC-lang/rusty/blob/9b89598bee70b126eec077cdae1c2631c1e8ce01/src/resolver/generics.rs#L439

Contributor guide